From 05834fcf58fe77b0519a8dc40e3c4a5a28dfc88d Mon Sep 17 00:00:00 2001 From: Hans Verkuil Date: Tue, 22 Nov 2011 08:59:34 -0300 Subject: [media] v4l2 spec: clarify usage of V4L2_FBUF_FLAG_OVERLAY Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab --- Documentation/DocBook/media/v4l/vidioc-g-fbuf.xml | 23 ++++++++++++++--------- 1 file changed, 14 insertions(+), 9 deletions(-) (limited to 'Documentation/DocBook/media/v4l') diff --git a/Documentation/DocBook/media/v4l/vidioc-g-fbuf.xml b/Documentation/DocBook/media/v4l/vidioc-g-fbuf.xml index 93817f33703..7c63815e7af 100644 --- a/Documentation/DocBook/media/v4l/vidioc-g-fbuf.xml +++ b/Documentation/DocBook/media/v4l/vidioc-g-fbuf.xml @@ -364,15 +364,20 @@ capability and it is cleared otherwise. V4L2_FBUF_FLAG_OVERLAY 0x0002 - The frame buffer is an overlay surface the same -size as the capture. [?] - - - The purpose of -V4L2_FBUF_FLAG_OVERLAY was never quite clear. -Most drivers seem to ignore this flag. For compatibility with the -bttv driver applications should set the -V4L2_FBUF_FLAG_OVERLAY flag. + If this flag is set for a video capture device, then the +driver will set the initial overlay size to cover the full framebuffer size, +otherwise the existing overlay size (as set by &VIDIOC-S-FMT;) will be used. + +Only one video capture driver (bttv) supports this flag. The use of this flag +for capture devices is deprecated. There is no way to detect which drivers +support this flag, so the only reliable method of setting the overlay size is +through &VIDIOC-S-FMT;. + +If this flag is set for a video output device, then the video output overlay +window is relative to the top-left corner of the framebuffer and restricted +to the size of the framebuffer. If it is cleared, then the video output +overlay window is relative to the video output display. + V4L2_FBUF_FLAG_CHROMAKEY -- cgit v1.2.3 From 6055b12ae0f433314cba98f423fb8c5fc211ca8d Mon Sep 17 00:00:00 2001 From: Hans Verkuil Date: Wed, 11 Jan 2012 07:30:55 -0300 Subject: [media] V4L2 Spec: fix extended control documentation Update the spec to the behavior implemented by the control framework. This should have been documented long ago but for some reason it was never done. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab --- Documentation/DocBook/media/v4l/vidioc-g-ext-ctrls.xml | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) (limited to 'Documentation/DocBook/media/v4l') diff --git a/Documentation/DocBook/media/v4l/vidioc-g-ext-ctrls.xml b/Documentation/DocBook/media/v4l/vidioc-g-ext-ctrls.xml index 6f1f9a629dc..b17a7aac699 100644 --- a/Documentation/DocBook/media/v4l/vidioc-g-ext-ctrls.xml +++ b/Documentation/DocBook/media/v4l/vidioc-g-ext-ctrls.xml @@ -183,7 +183,12 @@ applications must set the array to zero. __u32 ctrl_class The control class to which all controls belong, see -. +. Drivers that use a kernel framework for handling +controls will also accept a value of 0 here, meaning that the controls can +belong to any control class. Whether drivers support this can be tested by setting +ctrl_class to 0 and calling VIDIOC_TRY_EXT_CTRLS +with a count of 0. If that succeeds, then the driver +supports this feature. __u32 @@ -194,10 +199,13 @@ also be zero. __u32 error_idx - Set by the driver in case of an error. It is the -index of the control causing the error or equal to 'count' when the -error is not associated with a particular control. Undefined when the -ioctl returns 0 (success). + Set by the driver in case of an error. If it is equal +to count, then no actual changes were made to +controls. In other words, the error was not associated with setting a particular +control. If it is another value, then only the controls up to error_idx-1 +were modified and control error_idx is the one that +caused the error. The error_idx value is undefined +if the ioctl returned 0 (success). __u32 -- cgit v1.2.3 From dacd4fa37dbafe209a90d6d5b729d2257df4b734 Mon Sep 17 00:00:00 2001 From: Hans Verkuil Date: Wed, 11 Jan 2012 07:37:54 -0300 Subject: [media] V4L2 Spec: improve the G/S_INPUT/OUTPUT documentation As Rupert pointed out, the phrase "It is good practice" should be replaced with "You must". Signed-off-by: Hans Verkuil Cc: Rupert Eibauer Signed-off-by: Mauro Carvalho Chehab --- Documentation/DocBook/media/v4l/vidioc-g-input.xml | 4 ++-- Documentation/DocBook/media/v4l/vidioc-g-output.xml | 5 +++-- 2 files changed, 5 insertions(+), 4 deletions(-) (limited to 'Documentation/DocBook/media/v4l') diff --git a/Documentation/DocBook/media/v4l/vidioc-g-input.xml b/Documentation/DocBook/media/v4l/vidioc-g-input.xml index 08ae82f131f..1d43065090d 100644 --- a/Documentation/DocBook/media/v4l/vidioc-g-input.xml +++ b/Documentation/DocBook/media/v4l/vidioc-g-input.xml @@ -61,8 +61,8 @@ desired input in an integer and call the VIDIOC_S_INPUT ioctl with a pointer to this integer. Side effects are possible. For example inputs may support different video standards, so the driver may implicitly switch the -current standard. It is good practice to select an input before -querying or negotiating any other parameters. +current standard. Because of these possible side effects applications +must select an input before querying or negotiating any other parameters. Information about video inputs is available using the &VIDIOC-ENUMINPUT; ioctl. diff --git a/Documentation/DocBook/media/v4l/vidioc-g-output.xml b/Documentation/DocBook/media/v4l/vidioc-g-output.xml index fd45f1c13cc..4533068ecb8 100644 --- a/Documentation/DocBook/media/v4l/vidioc-g-output.xml +++ b/Documentation/DocBook/media/v4l/vidioc-g-output.xml @@ -61,8 +61,9 @@ desired output in an integer and call the VIDIOC_S_OUTPUT ioctl with a pointer to this integer. Side effects are possible. For example outputs may support different video standards, so the driver may implicitly switch the current -standard. It is good practice to select an output before querying or -negotiating any other parameters. +standard. +standard. Because of these possible side effects applications +must select an output before querying or negotiating any other parameters. Information about video outputs is available using the &VIDIOC-ENUMOUTPUT; ioctl. -- cgit v1.2.3 From aa07eec5320cf1793062c03b8409e7541ca37c31 Mon Sep 17 00:00:00 2001 From: Hans Verkuil Date: Tue, 11 Oct 2011 05:12:52 -0300 Subject: [media] v4l2-ioctl: make tuner 'type' check more strict for S_FREQUENCY As per the feature removal document, make the tuner type check more strict so that it is no longer possible to set the radio frequency through a video node or the TV frequency through a radio node. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab --- Documentation/DocBook/media/v4l/vidioc-g-frequency.xml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'Documentation/DocBook/media/v4l') diff --git a/Documentation/DocBook/media/v4l/vidioc-g-frequency.xml b/Documentation/DocBook/media/v4l/vidioc-g-frequency.xml index 16431813beb..66e9a525786 100644 --- a/Documentation/DocBook/media/v4l/vidioc-g-frequency.xml +++ b/Documentation/DocBook/media/v4l/vidioc-g-frequency.xml @@ -98,8 +98,11 @@ the &v4l2-output; modulator field and the &v4l2-tuner-type; type The tuner type. This is the same value as in the -&v4l2-tuner; type field. The field is not -applicable to modulators, &ie; ignored by drivers. +&v4l2-tuner; type field. The type must be set +to V4L2_TUNER_RADIO for /dev/radioX +device nodes, and to V4L2_TUNER_ANALOG_TV +for all others. The field is not applicable to modulators, &ie; ignored +by drivers. __u32 -- cgit v1.2.3