aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/v4l2-ctrls.c
diff options
context:
space:
mode:
authorSakari Ailus <sakari.ailus@iki.fi>2012-02-02 18:17:54 -0500
committerMauro Carvalho Chehab <mchehab@redhat.com>2012-05-14 07:37:44 -0400
commitc643ee135190389e03cffd80e762c9c71dc9a165 (patch)
treedbd22fb0fe7c816f1b8595bbd01605ea43f624e7 /drivers/media/video/v4l2-ctrls.c
parent8c9d236ec64f1f1e7764385e7b5eae88eec7c02b (diff)
[media] v4l: Image processing control class
Add control class for image processing controls. The control class deals with controls processing image, for example digital gain or noise filtering, which can be present in any part of the pipeline. Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/v4l2-ctrls.c')
-rw-r--r--drivers/media/video/v4l2-ctrls.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/drivers/media/video/v4l2-ctrls.c b/drivers/media/video/v4l2-ctrls.c
index 7a2f855d4e21..edb2a6a066ca 100644
--- a/drivers/media/video/v4l2-ctrls.c
+++ b/drivers/media/video/v4l2-ctrls.c
@@ -650,6 +650,11 @@ const char *v4l2_ctrl_get_name(u32 id)
650 case V4L2_CID_HBLANK: return "Horizontal Blanking"; 650 case V4L2_CID_HBLANK: return "Horizontal Blanking";
651 case V4L2_CID_ANALOGUE_GAIN: return "Analogue Gain"; 651 case V4L2_CID_ANALOGUE_GAIN: return "Analogue Gain";
652 652
653 /* Image processing controls */
654 case V4L2_CID_IMAGE_PROC_CLASS: return "Image Processing Controls";
655 case V4L2_CID_LINK_FREQ: return "Link Frequency";
656 case V4L2_CID_PIXEL_RATE: return "Pixel Rate";
657
653 default: 658 default:
654 return NULL; 659 return NULL;
655 } 660 }
@@ -741,6 +746,9 @@ void v4l2_ctrl_fill(u32 id, const char **name, enum v4l2_ctrl_type *type,
741 case V4L2_CID_JPEG_CHROMA_SUBSAMPLING: 746 case V4L2_CID_JPEG_CHROMA_SUBSAMPLING:
742 *type = V4L2_CTRL_TYPE_MENU; 747 *type = V4L2_CTRL_TYPE_MENU;
743 break; 748 break;
749 case V4L2_CID_LINK_FREQ:
750 *type = V4L2_CTRL_TYPE_INTEGER_MENU;
751 break;
744 case V4L2_CID_RDS_TX_PS_NAME: 752 case V4L2_CID_RDS_TX_PS_NAME:
745 case V4L2_CID_RDS_TX_RADIO_TEXT: 753 case V4L2_CID_RDS_TX_RADIO_TEXT:
746 *type = V4L2_CTRL_TYPE_STRING; 754 *type = V4L2_CTRL_TYPE_STRING;
@@ -752,6 +760,7 @@ void v4l2_ctrl_fill(u32 id, const char **name, enum v4l2_ctrl_type *type,
752 case V4L2_CID_FLASH_CLASS: 760 case V4L2_CID_FLASH_CLASS:
753 case V4L2_CID_JPEG_CLASS: 761 case V4L2_CID_JPEG_CLASS:
754 case V4L2_CID_IMAGE_SOURCE_CLASS: 762 case V4L2_CID_IMAGE_SOURCE_CLASS:
763 case V4L2_CID_IMAGE_PROC_CLASS:
755 *type = V4L2_CTRL_TYPE_CTRL_CLASS; 764 *type = V4L2_CTRL_TYPE_CTRL_CLASS;
756 /* You can neither read not write these */ 765 /* You can neither read not write these */
757 *flags |= V4L2_CTRL_FLAG_READ_ONLY | V4L2_CTRL_FLAG_WRITE_ONLY; 766 *flags |= V4L2_CTRL_FLAG_READ_ONLY | V4L2_CTRL_FLAG_WRITE_ONLY;
@@ -775,8 +784,11 @@ void v4l2_ctrl_fill(u32 id, const char **name, enum v4l2_ctrl_type *type,
775 break; 784 break;
776 case V4L2_CID_MPEG_VIDEO_DEC_FRAME: 785 case V4L2_CID_MPEG_VIDEO_DEC_FRAME:
777 case V4L2_CID_MPEG_VIDEO_DEC_PTS: 786 case V4L2_CID_MPEG_VIDEO_DEC_PTS:
787 *flags |= V4L2_CTRL_FLAG_VOLATILE;
788 /* Fall through */
789 case V4L2_CID_PIXEL_RATE:
778 *type = V4L2_CTRL_TYPE_INTEGER64; 790 *type = V4L2_CTRL_TYPE_INTEGER64;
779 *flags |= V4L2_CTRL_FLAG_READ_ONLY | V4L2_CTRL_FLAG_VOLATILE; 791 *flags |= V4L2_CTRL_FLAG_READ_ONLY;
780 *min = *max = *step = *def = 0; 792 *min = *max = *step = *def = 0;
781 break; 793 break;
782 default: 794 default: