|
|
@ -27,7 +27,7 @@ float gts[TONE_SPLITS * TONE_SPLITS * TONE_SPLITS * TONE_SPLITS] = { |
|
|
|
0.000000}; |
|
|
|
0.000000}; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
TEST_CASE("camera.test_set_exposure_target") { |
|
|
|
TEST_CASE("camera.test_calculate_exposure_value") { |
|
|
|
// set up fake camerabuf
|
|
|
|
// set up fake camerabuf
|
|
|
|
CameraBuf cb = {}; |
|
|
|
CameraBuf cb = {}; |
|
|
|
VisionBuf vb = {}; |
|
|
|
VisionBuf vb = {}; |
|
|
@ -61,7 +61,7 @@ TEST_CASE("camera.test_set_exposure_target") { |
|
|
|
memset(&fb_y[h_0*W+h_1*W], l[2], h_2*W); |
|
|
|
memset(&fb_y[h_0*W+h_1*W], l[2], h_2*W); |
|
|
|
memset(&fb_y[h_0*W+h_1*W+h_2*W], l[3], h_3*W); |
|
|
|
memset(&fb_y[h_0*W+h_1*W+h_2*W], l[3], h_3*W); |
|
|
|
memset(&fb_y[h_0*W+h_1*W+h_2*W+h_3*W], l[4], h_4*W); |
|
|
|
memset(&fb_y[h_0*W+h_1*W+h_2*W+h_3*W], l[4], h_4*W); |
|
|
|
float ev = set_exposure_target((const CameraBuf*) &cb, rect, 1, 1); |
|
|
|
float ev = calculate_exposure_value((const CameraBuf*) &cb, rect, 1, 1); |
|
|
|
// printf("%d/%d/%d/%d/%d ev is %f\n", h_0, h_1, h_2, h_3, h_4, ev);
|
|
|
|
// printf("%d/%d/%d/%d/%d ev is %f\n", h_0, h_1, h_2, h_3, h_4, ev);
|
|
|
|
// printf("%f\n", ev);
|
|
|
|
// printf("%f\n", ev);
|
|
|
|
|
|
|
|
|
|
|
|