INNER CODE UNIT · C++
crop_width
nihui/opencv-mobile · highgui/src/capture_cvi.cpp:2943
crop_width = width * cap_height / height;
crop_height = cap_height;
}
else
{
// thinner
crop_width = cap_width;
crop_height = height * cap_width / width;
}
}
#define ALIGN(x, a) (((x) + ((a)-1)) & ~((a)-1))
int yuv_buffer_size = ALIGN(cap_width, 64) * ALIGN(cap_height, 64) * 3 / 2;
int bgr_buffer_size = ALIGN(output_width, 64) * ALIGN(output_height, 64) * 3;
int ret_val = 0;