Rename test_camera → camera_test
This commit is contained in:
parent
3573486267
commit
510177b220
|
@ -45,8 +45,9 @@ install_data(['postprocess.sh'],
|
|||
install_dir : get_option('datadir') / 'megapixels/',
|
||||
install_mode: 'rwxr-xr-x')
|
||||
|
||||
# Tools
|
||||
executable('list_devices', 'tools/list_devices.c', 'device.c', dependencies: [gtkdep])
|
||||
executable('test_camera', 'tools/test_camera.c', 'camera.c', 'device.c', dependencies: [gtkdep])
|
||||
executable('camera_test', 'tools/camera_test.c', 'camera.c', 'device.c', dependencies: [gtkdep])
|
||||
|
||||
test_quickpreview = executable('test_quickpreview', 'tests/test_quickpreview.c', 'quickpreview.c', 'camera.c', dependencies: [gtkdep])
|
||||
test('quickpreview', test_quickpreview)
|
||||
|
|
|
@ -46,52 +46,6 @@ static int exposure;
|
|||
|
||||
static char capture_fname[255];
|
||||
|
||||
// static void
|
||||
// process_image(const int *p, int size)
|
||||
// {
|
||||
// time_t rawtime;
|
||||
// char datetime[20] = {0};
|
||||
// struct tm tim;
|
||||
// uint8_t *pixels;
|
||||
// char fname[255];
|
||||
// char fname_target[255];
|
||||
// char command[1024];
|
||||
// char timestamp[30];
|
||||
// char uniquecameramodel[255];
|
||||
// GdkPixbuf *pixbuf;
|
||||
// GdkPixbuf *pixbufrot;
|
||||
// GdkPixbuf *thumb;
|
||||
// GError *error = NULL;
|
||||
// double scale;
|
||||
// cairo_t *cr;
|
||||
// TIFF *tif;
|
||||
// int skip = 2;
|
||||
// long sub_offset = 0;
|
||||
// uint64 exif_offset = 0;
|
||||
// static const short cfapatterndim[] = {2, 2};
|
||||
// static const float neutral[] = {1.0, 1.0, 1.0};
|
||||
// static uint16_t isospeed[] = {0};
|
||||
|
||||
// // Only process preview frames when not capturing
|
||||
// if (capture == 0) {
|
||||
|
||||
// } else {
|
||||
|
||||
|
||||
// if (capture == 0) {
|
||||
|
||||
|
||||
// // Restore the auto exposure and gain if needed
|
||||
// // if (auto_exposure) {
|
||||
// // v4l2_ctrl_set(current.fd, V4L2_CID_EXPOSURE_AUTO, V4L2_EXPOSURE_AUTO);
|
||||
// // }
|
||||
// // if (auto_gain) {
|
||||
// // v4l2_ctrl_set(current.fd, V4L2_CID_AUTOGAIN, 1);
|
||||
// // }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
|
||||
static void
|
||||
register_custom_tiff_tags(TIFF *tif)
|
||||
{
|
||||
|
|
|
@ -131,7 +131,8 @@ int main(int argc, char *argv[])
|
|||
MPCameraMode *m = mp_camera_mode_list_get(mode);
|
||||
printf(" %dx%d interval:%d/%d fmt:%s\n", m->width, m->height, m->frame_interval.numerator, m->frame_interval.denominator, mp_pixel_format_to_str(m->pixel_format));
|
||||
|
||||
if (m->frame_interval.denominator < 15 || m->frame_interval.denominator > 30) {
|
||||
// Skip really slow framerates
|
||||
if (m->frame_interval.denominator < 15) {
|
||||
printf(" Skipping…\n");
|
||||
continue;
|
||||
}
|
Loading…
Reference in New Issue