From 66f5ce5e82d9870b9fc7298fafc0f4a62f1285f7 Mon Sep 17 00:00:00 2001 From: Ken Tossell <ken@tossell.net> Date: Fri, 17 Feb 2012 12:29:21 -0500 Subject: [PATCH] added video format param. set min=0 for unsigned int params --- libuvc_camera/cfg/UVCCamera.cfg | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/libuvc_camera/cfg/UVCCamera.cfg b/libuvc_camera/cfg/UVCCamera.cfg index 5f02b0b..b9ce9a4 100755 --- a/libuvc_camera/cfg/UVCCamera.cfg +++ b/libuvc_camera/cfg/UVCCamera.cfg @@ -25,13 +25,24 @@ gen.add("serial", str_t, SensorLevels.RECONFIGURE_CLOSE, gen.add("index", int_t, SensorLevels.RECONFIGURE_CLOSE, "Index into the list of cameras that match the above parameters.", - 0) + 0, 0) gen.add("width", int_t, SensorLevels.RECONFIGURE_CLOSE, - "Image width.", 640) + "Image width.", 640, 0) gen.add("height", int_t, SensorLevels.RECONFIGURE_CLOSE, - "Image height.", 480) + "Image height.", 480, 0) + +video_modes = gen.enum([gen.const("uncompressed", str_t, "uncompressed", "Use any uncompressed format"), + gen.const("yuyv", str_t, "yuyv", "YUYV"), + gen.const("uyvy", str_t, "uyvy", "UYVY"), + gen.const("rgb", str_t, "rgb", "RGB"), + gen.const("jpeg", str_t, "jpeg", "JPEG/MJPEG")], + "Video stream format") + +gen.add("video_mode", str_t, SensorLevels.RECONFIGURE_CLOSE, + "Format of video stream from camera.", "uncompressed", + edit_method = video_modes) gen.add("frame_rate", double_t, SensorLevels.RECONFIGURE_CLOSE, "Camera speed, frames per second.", 15.0, 0.1, 1000.0) -- GitLab