1 .. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
5 ***********************
6 Codec Control Reference
7 ***********************
9 Below all controls within the Codec control class are described. First
10 the generic controls, then controls specific for certain hardware.
14 These controls are applicable to all codecs and not just MPEG. The
15 defines are prefixed with V4L2_CID_MPEG/V4L2_MPEG as the controls
16 were originally made for MPEG codecs and later extended to cover all
20 Generic Codec Controls
21 ======================
29 ``V4L2_CID_CODEC_CLASS (class)``
30 The Codec class descriptor. Calling
31 :ref:`VIDIOC_QUERYCTRL` for this control will
32 return a description of this control class. This description can be
33 used as the caption of a Tab page in a GUI, for example.
35 .. _v4l2-mpeg-stream-type:
37 ``V4L2_CID_MPEG_STREAM_TYPE``
40 enum v4l2_mpeg_stream_type -
41 The MPEG-1, -2 or -4 output stream type. One cannot assume anything
42 here. Each hardware MPEG encoder tends to support different subsets
43 of the available MPEG stream types. This control is specific to
44 multiplexed MPEG streams. The currently defined stream types are:
52 * - ``V4L2_MPEG_STREAM_TYPE_MPEG2_PS``
53 - MPEG-2 program stream
54 * - ``V4L2_MPEG_STREAM_TYPE_MPEG2_TS``
55 - MPEG-2 transport stream
56 * - ``V4L2_MPEG_STREAM_TYPE_MPEG1_SS``
57 - MPEG-1 system stream
58 * - ``V4L2_MPEG_STREAM_TYPE_MPEG2_DVD``
59 - MPEG-2 DVD-compatible stream
60 * - ``V4L2_MPEG_STREAM_TYPE_MPEG1_VCD``
61 - MPEG-1 VCD-compatible stream
62 * - ``V4L2_MPEG_STREAM_TYPE_MPEG2_SVCD``
63 - MPEG-2 SVCD-compatible stream
67 ``V4L2_CID_MPEG_STREAM_PID_PMT (integer)``
68 Program Map Table Packet ID for the MPEG transport stream (default
71 ``V4L2_CID_MPEG_STREAM_PID_AUDIO (integer)``
72 Audio Packet ID for the MPEG transport stream (default 256)
74 ``V4L2_CID_MPEG_STREAM_PID_VIDEO (integer)``
75 Video Packet ID for the MPEG transport stream (default 260)
77 ``V4L2_CID_MPEG_STREAM_PID_PCR (integer)``
78 Packet ID for the MPEG transport stream carrying PCR fields (default
81 ``V4L2_CID_MPEG_STREAM_PES_ID_AUDIO (integer)``
84 ``V4L2_CID_MPEG_STREAM_PES_ID_VIDEO (integer)``
87 .. _v4l2-mpeg-stream-vbi-fmt:
89 ``V4L2_CID_MPEG_STREAM_VBI_FMT``
92 enum v4l2_mpeg_stream_vbi_fmt -
93 Some cards can embed VBI data (e. g. Closed Caption, Teletext) into
94 the MPEG stream. This control selects whether VBI data should be
95 embedded, and if so, what embedding method should be used. The list
96 of possible VBI formats depends on the driver. The currently defined
101 .. tabularcolumns:: |p{6.6 cm}|p{10.9cm}|
107 * - ``V4L2_MPEG_STREAM_VBI_FMT_NONE``
108 - No VBI in the MPEG stream
109 * - ``V4L2_MPEG_STREAM_VBI_FMT_IVTV``
110 - VBI in private packets, IVTV format (documented in the kernel
112 ``Documentation/userspace-api/media/drivers/cx2341x-uapi.rst``)
116 .. _v4l2-mpeg-audio-sampling-freq:
118 ``V4L2_CID_MPEG_AUDIO_SAMPLING_FREQ``
121 enum v4l2_mpeg_audio_sampling_freq -
122 MPEG Audio sampling frequency. Possible values are:
130 * - ``V4L2_MPEG_AUDIO_SAMPLING_FREQ_44100``
132 * - ``V4L2_MPEG_AUDIO_SAMPLING_FREQ_48000``
134 * - ``V4L2_MPEG_AUDIO_SAMPLING_FREQ_32000``
139 .. _v4l2-mpeg-audio-encoding:
141 ``V4L2_CID_MPEG_AUDIO_ENCODING``
144 enum v4l2_mpeg_audio_encoding -
145 MPEG Audio encoding. This control is specific to multiplexed MPEG
146 streams. Possible values are:
154 * - ``V4L2_MPEG_AUDIO_ENCODING_LAYER_1``
155 - MPEG-1/2 Layer I encoding
156 * - ``V4L2_MPEG_AUDIO_ENCODING_LAYER_2``
157 - MPEG-1/2 Layer II encoding
158 * - ``V4L2_MPEG_AUDIO_ENCODING_LAYER_3``
159 - MPEG-1/2 Layer III encoding
160 * - ``V4L2_MPEG_AUDIO_ENCODING_AAC``
161 - MPEG-2/4 AAC (Advanced Audio Coding)
162 * - ``V4L2_MPEG_AUDIO_ENCODING_AC3``
163 - AC-3 aka ATSC A/52 encoding
167 .. _v4l2-mpeg-audio-l1-bitrate:
169 ``V4L2_CID_MPEG_AUDIO_L1_BITRATE``
172 enum v4l2_mpeg_audio_l1_bitrate -
173 MPEG-1/2 Layer I bitrate. Possible values are:
181 * - ``V4L2_MPEG_AUDIO_L1_BITRATE_32K``
183 * - ``V4L2_MPEG_AUDIO_L1_BITRATE_64K``
185 * - ``V4L2_MPEG_AUDIO_L1_BITRATE_96K``
187 * - ``V4L2_MPEG_AUDIO_L1_BITRATE_128K``
189 * - ``V4L2_MPEG_AUDIO_L1_BITRATE_160K``
191 * - ``V4L2_MPEG_AUDIO_L1_BITRATE_192K``
193 * - ``V4L2_MPEG_AUDIO_L1_BITRATE_224K``
195 * - ``V4L2_MPEG_AUDIO_L1_BITRATE_256K``
197 * - ``V4L2_MPEG_AUDIO_L1_BITRATE_288K``
199 * - ``V4L2_MPEG_AUDIO_L1_BITRATE_320K``
201 * - ``V4L2_MPEG_AUDIO_L1_BITRATE_352K``
203 * - ``V4L2_MPEG_AUDIO_L1_BITRATE_384K``
205 * - ``V4L2_MPEG_AUDIO_L1_BITRATE_416K``
207 * - ``V4L2_MPEG_AUDIO_L1_BITRATE_448K``
212 .. _v4l2-mpeg-audio-l2-bitrate:
214 ``V4L2_CID_MPEG_AUDIO_L2_BITRATE``
217 enum v4l2_mpeg_audio_l2_bitrate -
218 MPEG-1/2 Layer II bitrate. Possible values are:
226 * - ``V4L2_MPEG_AUDIO_L2_BITRATE_32K``
228 * - ``V4L2_MPEG_AUDIO_L2_BITRATE_48K``
230 * - ``V4L2_MPEG_AUDIO_L2_BITRATE_56K``
232 * - ``V4L2_MPEG_AUDIO_L2_BITRATE_64K``
234 * - ``V4L2_MPEG_AUDIO_L2_BITRATE_80K``
236 * - ``V4L2_MPEG_AUDIO_L2_BITRATE_96K``
238 * - ``V4L2_MPEG_AUDIO_L2_BITRATE_112K``
240 * - ``V4L2_MPEG_AUDIO_L2_BITRATE_128K``
242 * - ``V4L2_MPEG_AUDIO_L2_BITRATE_160K``
244 * - ``V4L2_MPEG_AUDIO_L2_BITRATE_192K``
246 * - ``V4L2_MPEG_AUDIO_L2_BITRATE_224K``
248 * - ``V4L2_MPEG_AUDIO_L2_BITRATE_256K``
250 * - ``V4L2_MPEG_AUDIO_L2_BITRATE_320K``
252 * - ``V4L2_MPEG_AUDIO_L2_BITRATE_384K``
257 .. _v4l2-mpeg-audio-l3-bitrate:
259 ``V4L2_CID_MPEG_AUDIO_L3_BITRATE``
262 enum v4l2_mpeg_audio_l3_bitrate -
263 MPEG-1/2 Layer III bitrate. Possible values are:
271 * - ``V4L2_MPEG_AUDIO_L3_BITRATE_32K``
273 * - ``V4L2_MPEG_AUDIO_L3_BITRATE_40K``
275 * - ``V4L2_MPEG_AUDIO_L3_BITRATE_48K``
277 * - ``V4L2_MPEG_AUDIO_L3_BITRATE_56K``
279 * - ``V4L2_MPEG_AUDIO_L3_BITRATE_64K``
281 * - ``V4L2_MPEG_AUDIO_L3_BITRATE_80K``
283 * - ``V4L2_MPEG_AUDIO_L3_BITRATE_96K``
285 * - ``V4L2_MPEG_AUDIO_L3_BITRATE_112K``
287 * - ``V4L2_MPEG_AUDIO_L3_BITRATE_128K``
289 * - ``V4L2_MPEG_AUDIO_L3_BITRATE_160K``
291 * - ``V4L2_MPEG_AUDIO_L3_BITRATE_192K``
293 * - ``V4L2_MPEG_AUDIO_L3_BITRATE_224K``
295 * - ``V4L2_MPEG_AUDIO_L3_BITRATE_256K``
297 * - ``V4L2_MPEG_AUDIO_L3_BITRATE_320K``
302 ``V4L2_CID_MPEG_AUDIO_AAC_BITRATE (integer)``
303 AAC bitrate in bits per second.
305 .. _v4l2-mpeg-audio-ac3-bitrate:
307 ``V4L2_CID_MPEG_AUDIO_AC3_BITRATE``
310 enum v4l2_mpeg_audio_ac3_bitrate -
311 AC-3 bitrate. Possible values are:
319 * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_32K``
321 * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_40K``
323 * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_48K``
325 * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_56K``
327 * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_64K``
329 * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_80K``
331 * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_96K``
333 * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_112K``
335 * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_128K``
337 * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_160K``
339 * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_192K``
341 * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_224K``
343 * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_256K``
345 * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_320K``
347 * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_384K``
349 * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_448K``
351 * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_512K``
353 * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_576K``
355 * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_640K``
360 .. _v4l2-mpeg-audio-mode:
362 ``V4L2_CID_MPEG_AUDIO_MODE``
365 enum v4l2_mpeg_audio_mode -
366 MPEG Audio mode. Possible values are:
374 * - ``V4L2_MPEG_AUDIO_MODE_STEREO``
376 * - ``V4L2_MPEG_AUDIO_MODE_JOINT_STEREO``
378 * - ``V4L2_MPEG_AUDIO_MODE_DUAL``
380 * - ``V4L2_MPEG_AUDIO_MODE_MONO``
385 .. _v4l2-mpeg-audio-mode-extension:
387 ``V4L2_CID_MPEG_AUDIO_MODE_EXTENSION``
390 enum v4l2_mpeg_audio_mode_extension -
391 Joint Stereo audio mode extension. In Layer I and II they indicate
392 which subbands are in intensity stereo. All other subbands are coded
393 in stereo. Layer III is not (yet) supported. Possible values are:
395 .. tabularcolumns:: |p{9.1cm}|p{8.4cm}|
401 * - ``V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_4``
402 - Subbands 4-31 in intensity stereo
403 * - ``V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_8``
404 - Subbands 8-31 in intensity stereo
405 * - ``V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_12``
406 - Subbands 12-31 in intensity stereo
407 * - ``V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_16``
408 - Subbands 16-31 in intensity stereo
412 .. _v4l2-mpeg-audio-emphasis:
414 ``V4L2_CID_MPEG_AUDIO_EMPHASIS``
417 enum v4l2_mpeg_audio_emphasis -
418 Audio Emphasis. Possible values are:
426 * - ``V4L2_MPEG_AUDIO_EMPHASIS_NONE``
428 * - ``V4L2_MPEG_AUDIO_EMPHASIS_50_DIV_15_uS``
429 - 50/15 microsecond emphasis
430 * - ``V4L2_MPEG_AUDIO_EMPHASIS_CCITT_J17``
435 .. _v4l2-mpeg-audio-crc:
437 ``V4L2_CID_MPEG_AUDIO_CRC``
440 enum v4l2_mpeg_audio_crc -
441 CRC method. Possible values are:
449 * - ``V4L2_MPEG_AUDIO_CRC_NONE``
451 * - ``V4L2_MPEG_AUDIO_CRC_CRC16``
452 - 16 bit parity check
456 ``V4L2_CID_MPEG_AUDIO_MUTE (boolean)``
457 Mutes the audio when capturing. This is not done by muting audio
458 hardware, which can still produce a slight hiss, but in the encoder
459 itself, guaranteeing a fixed and reproducible audio bitstream. 0 =
462 .. _v4l2-mpeg-audio-dec-playback:
464 ``V4L2_CID_MPEG_AUDIO_DEC_PLAYBACK``
467 enum v4l2_mpeg_audio_dec_playback -
468 Determines how monolingual audio should be played back. Possible
473 .. tabularcolumns:: |p{9.8cm}|p{7.7cm}|
479 * - ``V4L2_MPEG_AUDIO_DEC_PLAYBACK_AUTO``
480 - Automatically determines the best playback mode.
481 * - ``V4L2_MPEG_AUDIO_DEC_PLAYBACK_STEREO``
483 * - ``V4L2_MPEG_AUDIO_DEC_PLAYBACK_LEFT``
484 - Left channel playback.
485 * - ``V4L2_MPEG_AUDIO_DEC_PLAYBACK_RIGHT``
486 - Right channel playback.
487 * - ``V4L2_MPEG_AUDIO_DEC_PLAYBACK_MONO``
489 * - ``V4L2_MPEG_AUDIO_DEC_PLAYBACK_SWAPPED_STEREO``
490 - Stereo playback with swapped left and right channels.
494 .. _v4l2-mpeg-audio-dec-multilingual-playback:
496 ``V4L2_CID_MPEG_AUDIO_DEC_MULTILINGUAL_PLAYBACK``
499 enum v4l2_mpeg_audio_dec_playback -
500 Determines how multilingual audio should be played back.
502 .. _v4l2-mpeg-video-encoding:
504 ``V4L2_CID_MPEG_VIDEO_ENCODING``
507 enum v4l2_mpeg_video_encoding -
508 MPEG Video encoding method. This control is specific to multiplexed
509 MPEG streams. Possible values are:
517 * - ``V4L2_MPEG_VIDEO_ENCODING_MPEG_1``
518 - MPEG-1 Video encoding
519 * - ``V4L2_MPEG_VIDEO_ENCODING_MPEG_2``
520 - MPEG-2 Video encoding
521 * - ``V4L2_MPEG_VIDEO_ENCODING_MPEG_4_AVC``
522 - MPEG-4 AVC (H.264) Video encoding
526 .. _v4l2-mpeg-video-aspect:
528 ``V4L2_CID_MPEG_VIDEO_ASPECT``
531 enum v4l2_mpeg_video_aspect -
532 Video aspect. Possible values are:
540 * - ``V4L2_MPEG_VIDEO_ASPECT_1x1``
541 * - ``V4L2_MPEG_VIDEO_ASPECT_4x3``
542 * - ``V4L2_MPEG_VIDEO_ASPECT_16x9``
543 * - ``V4L2_MPEG_VIDEO_ASPECT_221x100``
547 ``V4L2_CID_MPEG_VIDEO_B_FRAMES (integer)``
548 Number of B-Frames (default 2)
550 ``V4L2_CID_MPEG_VIDEO_GOP_SIZE (integer)``
551 GOP size (default 12)
553 ``V4L2_CID_MPEG_VIDEO_GOP_CLOSURE (boolean)``
554 GOP closure (default 1)
556 ``V4L2_CID_MPEG_VIDEO_PULLDOWN (boolean)``
557 Enable 3:2 pulldown (default 0)
559 .. _v4l2-mpeg-video-bitrate-mode:
561 ``V4L2_CID_MPEG_VIDEO_BITRATE_MODE``
564 enum v4l2_mpeg_video_bitrate_mode -
565 Video bitrate mode. Possible values are:
573 * - ``V4L2_MPEG_VIDEO_BITRATE_MODE_VBR``
575 * - ``V4L2_MPEG_VIDEO_BITRATE_MODE_CBR``
577 * - ``V4L2_MPEG_VIDEO_BITRATE_MODE_CQ``
582 ``V4L2_CID_MPEG_VIDEO_BITRATE (integer)``
583 Average video bitrate in bits per second.
585 ``V4L2_CID_MPEG_VIDEO_BITRATE_PEAK (integer)``
586 Peak video bitrate in bits per second. Must be larger or equal to
587 the average video bitrate. It is ignored if the video bitrate mode
588 is set to constant bitrate.
590 ``V4L2_CID_MPEG_VIDEO_CONSTANT_QUALITY (integer)``
591 Constant quality level control. This control is applicable when
592 ``V4L2_CID_MPEG_VIDEO_BITRATE_MODE`` value is
593 ``V4L2_MPEG_VIDEO_BITRATE_MODE_CQ``. Valid range is 1 to 100
594 where 1 indicates lowest quality and 100 indicates highest quality.
595 Encoder will decide the appropriate quantization parameter and
596 bitrate to produce requested frame quality.
599 ``V4L2_CID_MPEG_VIDEO_FRAME_SKIP_MODE (enum)``
601 enum v4l2_mpeg_video_frame_skip_mode -
602 Indicates in what conditions the encoder should skip frames. If
603 encoding a frame would cause the encoded stream to be larger then a
604 chosen data limit then the frame will be skipped. Possible values
608 .. tabularcolumns:: |p{8.2cm}|p{9.3cm}|
618 * - ``V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_DISABLED``
619 - Frame skip mode is disabled.
620 * - ``V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_LEVEL_LIMIT``
621 - Frame skip mode enabled and buffer limit is set by the chosen
622 level and is defined by the standard.
623 * - ``V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT``
624 - Frame skip mode enabled and buffer limit is set by the
625 :ref:`VBV (MPEG1/2/4) <v4l2-mpeg-video-vbv-size>` or
626 :ref:`CPB (H264) buffer size <v4l2-mpeg-video-h264-cpb-size>` control.
632 ``V4L2_CID_MPEG_VIDEO_TEMPORAL_DECIMATION (integer)``
633 For every captured frame, skip this many subsequent frames (default
636 ``V4L2_CID_MPEG_VIDEO_MUTE (boolean)``
637 "Mutes" the video to a fixed color when capturing. This is useful
638 for testing, to produce a fixed video bitstream. 0 = unmuted, 1 =
641 ``V4L2_CID_MPEG_VIDEO_MUTE_YUV (integer)``
642 Sets the "mute" color of the video. The supplied 32-bit integer is
643 interpreted as follows (bit 0 = least significant bit):
652 - V chrominance information
654 - U chrominance information
656 - Y luminance information
662 .. _v4l2-mpeg-video-dec-pts:
664 ``V4L2_CID_MPEG_VIDEO_DEC_PTS (integer64)``
665 This read-only control returns the 33-bit video Presentation Time
666 Stamp as defined in ITU T-REC-H.222.0 and ISO/IEC 13818-1 of the
667 currently displayed frame. This is the same PTS as is used in
668 :ref:`VIDIOC_DECODER_CMD`.
670 .. _v4l2-mpeg-video-dec-frame:
672 ``V4L2_CID_MPEG_VIDEO_DEC_FRAME (integer64)``
673 This read-only control returns the frame counter of the frame that
674 is currently displayed (decoded). This value is reset to 0 whenever
675 the decoder is started.
677 ``V4L2_CID_MPEG_VIDEO_DEC_CONCEAL_COLOR (integer64)``
678 This control sets the conceal color in YUV color space. It describes
679 the client preference of the error conceal color in case of an error
680 where the reference frame is missing. The decoder should fill the
681 reference buffer with the preferred color and use it for future
682 decoding. The control is using 16 bits per channel.
683 Applicable to decoders.
710 ``V4L2_CID_MPEG_VIDEO_DECODER_SLICE_INTERFACE (boolean)``
711 If enabled the decoder expects to receive a single slice per buffer,
712 otherwise the decoder expects a single frame in per buffer.
713 Applicable to the decoder, all codecs.
715 ``V4L2_CID_MPEG_VIDEO_DEC_DISPLAY_DELAY_ENABLE (boolean)``
716 If the display delay is enabled then the decoder is forced to return
717 a CAPTURE buffer (decoded frame) after processing a certain number
718 of OUTPUT buffers. The delay can be set through
719 ``V4L2_CID_MPEG_VIDEO_DEC_DISPLAY_DELAY``. This
720 feature can be used for example for generating thumbnails of videos.
721 Applicable to the decoder.
723 ``V4L2_CID_MPEG_VIDEO_DEC_DISPLAY_DELAY (integer)``
724 Display delay value for decoder. The decoder is forced to
725 return a decoded frame after the set 'display delay' number of
726 frames. If this number is low it may result in frames returned out
727 of display order, in addition the hardware may still be using the
728 returned buffer as a reference picture for subsequent frames.
730 ``V4L2_CID_MPEG_VIDEO_AU_DELIMITER (boolean)``
731 If enabled then, AUD (Access Unit Delimiter) NALUs will be generated.
732 That could be useful to find the start of a frame without having to
733 fully parse each NALU. Applicable to the H264 and HEVC encoders.
735 ``V4L2_CID_MPEG_VIDEO_H264_VUI_SAR_ENABLE (boolean)``
736 Enable writing sample aspect ratio in the Video Usability
737 Information. Applicable to the H264 encoder.
739 .. _v4l2-mpeg-video-h264-vui-sar-idc:
741 ``V4L2_CID_MPEG_VIDEO_H264_VUI_SAR_IDC``
744 enum v4l2_mpeg_video_h264_vui_sar_idc -
745 VUI sample aspect ratio indicator for H.264 encoding. The value is
746 defined in the table E-1 in the standard. Applicable to the H264
755 * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_UNSPECIFIED``
757 * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_1x1``
759 * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_12x11``
761 * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_10x11``
763 * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_16x11``
765 * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_40x33``
767 * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_24x11``
769 * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_20x11``
771 * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_32x11``
773 * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_80x33``
775 * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_18x11``
777 * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_15x11``
779 * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_64x33``
781 * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_160x99``
783 * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_4x3``
785 * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_3x2``
787 * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_2x1``
789 * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_EXTENDED``
794 ``V4L2_CID_MPEG_VIDEO_H264_VUI_EXT_SAR_WIDTH (integer)``
795 Extended sample aspect ratio width for H.264 VUI encoding.
796 Applicable to the H264 encoder.
798 ``V4L2_CID_MPEG_VIDEO_H264_VUI_EXT_SAR_HEIGHT (integer)``
799 Extended sample aspect ratio height for H.264 VUI encoding.
800 Applicable to the H264 encoder.
802 .. _v4l2-mpeg-video-h264-level:
804 ``V4L2_CID_MPEG_VIDEO_H264_LEVEL``
807 enum v4l2_mpeg_video_h264_level -
808 The level information for the H264 video elementary stream.
809 Applicable to the H264 encoder. Possible values are:
817 * - ``V4L2_MPEG_VIDEO_H264_LEVEL_1_0``
819 * - ``V4L2_MPEG_VIDEO_H264_LEVEL_1B``
821 * - ``V4L2_MPEG_VIDEO_H264_LEVEL_1_1``
823 * - ``V4L2_MPEG_VIDEO_H264_LEVEL_1_2``
825 * - ``V4L2_MPEG_VIDEO_H264_LEVEL_1_3``
827 * - ``V4L2_MPEG_VIDEO_H264_LEVEL_2_0``
829 * - ``V4L2_MPEG_VIDEO_H264_LEVEL_2_1``
831 * - ``V4L2_MPEG_VIDEO_H264_LEVEL_2_2``
833 * - ``V4L2_MPEG_VIDEO_H264_LEVEL_3_0``
835 * - ``V4L2_MPEG_VIDEO_H264_LEVEL_3_1``
837 * - ``V4L2_MPEG_VIDEO_H264_LEVEL_3_2``
839 * - ``V4L2_MPEG_VIDEO_H264_LEVEL_4_0``
841 * - ``V4L2_MPEG_VIDEO_H264_LEVEL_4_1``
843 * - ``V4L2_MPEG_VIDEO_H264_LEVEL_4_2``
845 * - ``V4L2_MPEG_VIDEO_H264_LEVEL_5_0``
847 * - ``V4L2_MPEG_VIDEO_H264_LEVEL_5_1``
849 * - ``V4L2_MPEG_VIDEO_H264_LEVEL_5_2``
851 * - ``V4L2_MPEG_VIDEO_H264_LEVEL_6_0``
853 * - ``V4L2_MPEG_VIDEO_H264_LEVEL_6_1``
855 * - ``V4L2_MPEG_VIDEO_H264_LEVEL_6_2``
860 .. _v4l2-mpeg-video-mpeg2-level:
862 ``V4L2_CID_MPEG_VIDEO_MPEG2_LEVEL``
865 enum v4l2_mpeg_video_mpeg2_level -
866 The level information for the MPEG2 elementary stream. Applicable to
867 MPEG2 codecs. Possible values are:
875 * - ``V4L2_MPEG_VIDEO_MPEG2_LEVEL_LOW``
877 * - ``V4L2_MPEG_VIDEO_MPEG2_LEVEL_MAIN``
879 * - ``V4L2_MPEG_VIDEO_MPEG2_LEVEL_HIGH_1440``
880 - High-1440 Level (H-14)
881 * - ``V4L2_MPEG_VIDEO_MPEG2_LEVEL_HIGH``
886 .. _v4l2-mpeg-video-mpeg4-level:
888 ``V4L2_CID_MPEG_VIDEO_MPEG4_LEVEL``
891 enum v4l2_mpeg_video_mpeg4_level -
892 The level information for the MPEG4 elementary stream. Applicable to
893 the MPEG4 encoder. Possible values are:
901 * - ``V4L2_MPEG_VIDEO_MPEG4_LEVEL_0``
903 * - ``V4L2_MPEG_VIDEO_MPEG4_LEVEL_0B``
905 * - ``V4L2_MPEG_VIDEO_MPEG4_LEVEL_1``
907 * - ``V4L2_MPEG_VIDEO_MPEG4_LEVEL_2``
909 * - ``V4L2_MPEG_VIDEO_MPEG4_LEVEL_3``
911 * - ``V4L2_MPEG_VIDEO_MPEG4_LEVEL_3B``
913 * - ``V4L2_MPEG_VIDEO_MPEG4_LEVEL_4``
915 * - ``V4L2_MPEG_VIDEO_MPEG4_LEVEL_5``
920 .. _v4l2-mpeg-video-h264-profile:
922 ``V4L2_CID_MPEG_VIDEO_H264_PROFILE``
925 enum v4l2_mpeg_video_h264_profile -
926 The profile information for H264. Applicable to the H264 encoder.
933 .. tabularcolumns:: |p{10.2cm}|p{7.3cm}|
939 * - ``V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE``
941 * - ``V4L2_MPEG_VIDEO_H264_PROFILE_CONSTRAINED_BASELINE``
942 - Constrained Baseline profile
943 * - ``V4L2_MPEG_VIDEO_H264_PROFILE_MAIN``
945 * - ``V4L2_MPEG_VIDEO_H264_PROFILE_EXTENDED``
947 * - ``V4L2_MPEG_VIDEO_H264_PROFILE_HIGH``
949 * - ``V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_10``
951 * - ``V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_422``
953 * - ``V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_444_PREDICTIVE``
954 - High 444 Predictive profile
955 * - ``V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_10_INTRA``
956 - High 10 Intra profile
957 * - ``V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_422_INTRA``
958 - High 422 Intra profile
959 * - ``V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_444_INTRA``
960 - High 444 Intra profile
961 * - ``V4L2_MPEG_VIDEO_H264_PROFILE_CAVLC_444_INTRA``
962 - CAVLC 444 Intra profile
963 * - ``V4L2_MPEG_VIDEO_H264_PROFILE_SCALABLE_BASELINE``
964 - Scalable Baseline profile
965 * - ``V4L2_MPEG_VIDEO_H264_PROFILE_SCALABLE_HIGH``
966 - Scalable High profile
967 * - ``V4L2_MPEG_VIDEO_H264_PROFILE_SCALABLE_HIGH_INTRA``
968 - Scalable High Intra profile
969 * - ``V4L2_MPEG_VIDEO_H264_PROFILE_STEREO_HIGH``
970 - Stereo High profile
971 * - ``V4L2_MPEG_VIDEO_H264_PROFILE_MULTIVIEW_HIGH``
972 - Multiview High profile
973 * - ``V4L2_MPEG_VIDEO_H264_PROFILE_CONSTRAINED_HIGH``
974 - Constrained High profile
980 .. _v4l2-mpeg-video-mpeg2-profile:
982 ``V4L2_CID_MPEG_VIDEO_MPEG2_PROFILE``
985 enum v4l2_mpeg_video_mpeg2_profile -
986 The profile information for MPEG2. Applicable to MPEG2 codecs.
993 .. tabularcolumns:: |p{10.2cm}|p{7.3cm}|
999 * - ``V4L2_MPEG_VIDEO_MPEG2_PROFILE_SIMPLE``
1000 - Simple profile (SP)
1001 * - ``V4L2_MPEG_VIDEO_MPEG2_PROFILE_MAIN``
1003 * - ``V4L2_MPEG_VIDEO_MPEG2_PROFILE_SNR_SCALABLE``
1004 - SNR Scalable profile (SNR)
1005 * - ``V4L2_MPEG_VIDEO_MPEG2_PROFILE_SPATIALLY_SCALABLE``
1006 - Spatially Scalable profile (Spt)
1007 * - ``V4L2_MPEG_VIDEO_MPEG2_PROFILE_HIGH``
1009 * - ``V4L2_MPEG_VIDEO_MPEG2_PROFILE_MULTIVIEW``
1010 - Multi-view profile (MVP)
1017 .. _v4l2-mpeg-video-mpeg4-profile:
1019 ``V4L2_CID_MPEG_VIDEO_MPEG4_PROFILE``
1022 enum v4l2_mpeg_video_mpeg4_profile -
1023 The profile information for MPEG4. Applicable to the MPEG4 encoder.
1024 Possible values are:
1030 .. tabularcolumns:: |p{11.8cm}|p{5.7cm}|
1036 * - ``V4L2_MPEG_VIDEO_MPEG4_PROFILE_SIMPLE``
1038 * - ``V4L2_MPEG_VIDEO_MPEG4_PROFILE_ADVANCED_SIMPLE``
1039 - Advanced Simple profile
1040 * - ``V4L2_MPEG_VIDEO_MPEG4_PROFILE_CORE``
1042 * - ``V4L2_MPEG_VIDEO_MPEG4_PROFILE_SIMPLE_SCALABLE``
1043 - Simple Scalable profile
1044 * - ``V4L2_MPEG_VIDEO_MPEG4_PROFILE_ADVANCED_CODING_EFFICIENCY``
1045 - Advanced Coding Efficiency profile
1051 ``V4L2_CID_MPEG_VIDEO_MAX_REF_PIC (integer)``
1052 The maximum number of reference pictures used for encoding.
1053 Applicable to the encoder.
1055 .. _v4l2-mpeg-video-multi-slice-mode:
1057 ``V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MODE``
1060 enum v4l2_mpeg_video_multi_slice_mode -
1061 Determines how the encoder should handle division of frame into
1062 slices. Applicable to the encoder. Possible values are:
1066 .. tabularcolumns:: |p{9.6cm}|p{7.9cm}|
1072 * - ``V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_SINGLE``
1073 - Single slice per frame.
1074 * - ``V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_MB``
1075 - Multiple slices with set maximum number of macroblocks per slice.
1076 * - ``V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_BYTES``
1077 - Multiple slice with set maximum size in bytes per slice.
1081 ``V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MAX_MB (integer)``
1082 The maximum number of macroblocks in a slice. Used when
1083 ``V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MODE`` is set to
1084 ``V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_MB``. Applicable to the
1087 ``V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MAX_BYTES (integer)``
1088 The maximum size of a slice in bytes. Used when
1089 ``V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MODE`` is set to
1090 ``V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_BYTES``. Applicable to the
1093 .. _v4l2-mpeg-video-h264-loop-filter-mode:
1095 ``V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_MODE``
1098 enum v4l2_mpeg_video_h264_loop_filter_mode -
1099 Loop filter mode for H264 encoder. Possible values are:
1105 .. tabularcolumns:: |p{13.5cm}|p{4.0cm}|
1111 * - ``V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_ENABLED``
1112 - Loop filter is enabled.
1113 * - ``V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_DISABLED``
1114 - Loop filter is disabled.
1115 * - ``V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY``
1116 - Loop filter is disabled at the slice boundary.
1123 ``V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_ALPHA (integer)``
1124 Loop filter alpha coefficient, defined in the H264 standard.
1125 This value corresponds to the slice_alpha_c0_offset_div2 slice header
1126 field, and should be in the range of -6 to +6, inclusive. The actual alpha
1127 offset FilterOffsetA is twice this value.
1128 Applicable to the H264 encoder.
1130 ``V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_BETA (integer)``
1131 Loop filter beta coefficient, defined in the H264 standard.
1132 This corresponds to the slice_beta_offset_div2 slice header field, and
1133 should be in the range of -6 to +6, inclusive. The actual beta offset
1134 FilterOffsetB is twice this value.
1135 Applicable to the H264 encoder.
1137 .. _v4l2-mpeg-video-h264-entropy-mode:
1139 ``V4L2_CID_MPEG_VIDEO_H264_ENTROPY_MODE``
1142 enum v4l2_mpeg_video_h264_entropy_mode -
1143 Entropy coding mode for H264 - CABAC/CAVALC. Applicable to the H264
1144 encoder. Possible values are:
1147 .. tabularcolumns:: |p{9.0cm}|p{8.5cm}|
1154 * - ``V4L2_MPEG_VIDEO_H264_ENTROPY_MODE_CAVLC``
1155 - Use CAVLC entropy coding.
1156 * - ``V4L2_MPEG_VIDEO_H264_ENTROPY_MODE_CABAC``
1157 - Use CABAC entropy coding.
1161 ``V4L2_CID_MPEG_VIDEO_H264_8X8_TRANSFORM (boolean)``
1162 Enable 8X8 transform for H264. Applicable to the H264 encoder.
1164 ``V4L2_CID_MPEG_VIDEO_H264_CONSTRAINED_INTRA_PREDICTION (boolean)``
1165 Enable constrained intra prediction for H264. Applicable to the H264
1168 ``V4L2_CID_MPEG_VIDEO_H264_CHROMA_QP_INDEX_OFFSET (integer)``
1169 Specify the offset that should be added to the luma quantization
1170 parameter to determine the chroma quantization parameter. Applicable
1171 to the H264 encoder.
1173 ``V4L2_CID_MPEG_VIDEO_CYCLIC_INTRA_REFRESH_MB (integer)``
1174 Cyclic intra macroblock refresh. This is the number of continuous
1175 macroblocks refreshed every frame. Each frame a successive set of
1176 macroblocks is refreshed until the cycle completes and starts from
1177 the top of the frame. Setting this control to zero means that
1178 macroblocks will not be refreshed. Note that this control will not
1179 take effect when ``V4L2_CID_MPEG_VIDEO_INTRA_REFRESH_PERIOD`` control
1180 is set to non zero value.
1181 Applicable to H264, H263 and MPEG4 encoder.
1183 ``V4L2_CID_MPEG_VIDEO_INTRA_REFRESH_PERIOD_TYPE (enum)``
1185 enum v4l2_mpeg_video_intra_refresh_period_type -
1186 Sets the type of intra refresh. The period to refresh
1187 the whole frame is specified by V4L2_CID_MPEG_VIDEO_INTRA_REFRESH_PERIOD.
1188 Note that if this control is not present, then it is undefined what
1189 refresh type is used and it is up to the driver to decide.
1190 Applicable to H264 and HEVC encoders. Possible values are:
1192 .. tabularcolumns:: |p{9.6cm}|p{7.9cm}|
1198 * - ``V4L2_MPEG_VIDEO_INTRA_REFRESH_PERIOD_TYPE_RANDOM``
1199 - The whole frame is completely refreshed randomly
1200 after the specified period.
1201 * - ``V4L2_MPEG_VIDEO_INTRA_REFRESH_PERIOD_TYPE_CYCLIC``
1202 - The whole frame MBs are completely refreshed in cyclic order
1203 after the specified period.
1205 ``V4L2_CID_MPEG_VIDEO_INTRA_REFRESH_PERIOD (integer)``
1206 Intra macroblock refresh period. This sets the period to refresh
1207 the whole frame. In other words, this defines the number of frames
1208 for which the whole frame will be intra-refreshed. An example:
1209 setting period to 1 means that the whole frame will be refreshed,
1210 setting period to 2 means that the half of macroblocks will be
1211 intra-refreshed on frameX and the other half of macroblocks
1212 will be refreshed in frameX + 1 and so on. Setting the period to
1213 zero means no period is specified.
1214 Note that if the client sets this control to non zero value the
1215 ``V4L2_CID_MPEG_VIDEO_CYCLIC_INTRA_REFRESH_MB`` control shall be
1216 ignored. Applicable to H264 and HEVC encoders.
1218 ``V4L2_CID_MPEG_VIDEO_FRAME_RC_ENABLE (boolean)``
1219 Frame level rate control enable. If this control is disabled then
1220 the quantization parameter for each frame type is constant and set
1221 with appropriate controls (e.g.
1222 ``V4L2_CID_MPEG_VIDEO_H263_I_FRAME_QP``). If frame rate control is
1223 enabled then quantization parameter is adjusted to meet the chosen
1224 bitrate. Minimum and maximum value for the quantization parameter
1225 can be set with appropriate controls (e.g.
1226 ``V4L2_CID_MPEG_VIDEO_H263_MIN_QP``). Applicable to encoders.
1228 ``V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE (boolean)``
1229 Macroblock level rate control enable. Applicable to the MPEG4 and
1232 ``V4L2_CID_MPEG_VIDEO_MPEG4_QPEL (boolean)``
1233 Quarter pixel motion estimation for MPEG4. Applicable to the MPEG4
1236 ``V4L2_CID_MPEG_VIDEO_H263_I_FRAME_QP (integer)``
1237 Quantization parameter for an I frame for H263. Valid range: from 1
1240 ``V4L2_CID_MPEG_VIDEO_H263_MIN_QP (integer)``
1241 Minimum quantization parameter for H263. Valid range: from 1 to 31.
1243 ``V4L2_CID_MPEG_VIDEO_H263_MAX_QP (integer)``
1244 Maximum quantization parameter for H263. Valid range: from 1 to 31.
1246 ``V4L2_CID_MPEG_VIDEO_H263_P_FRAME_QP (integer)``
1247 Quantization parameter for an P frame for H263. Valid range: from 1
1250 ``V4L2_CID_MPEG_VIDEO_H263_B_FRAME_QP (integer)``
1251 Quantization parameter for an B frame for H263. Valid range: from 1
1254 ``V4L2_CID_MPEG_VIDEO_H264_I_FRAME_QP (integer)``
1255 Quantization parameter for an I frame for H264. Valid range: from 0
1258 ``V4L2_CID_MPEG_VIDEO_H264_MIN_QP (integer)``
1259 Minimum quantization parameter for H264. Valid range: from 0 to 51.
1261 ``V4L2_CID_MPEG_VIDEO_H264_MAX_QP (integer)``
1262 Maximum quantization parameter for H264. Valid range: from 0 to 51.
1264 ``V4L2_CID_MPEG_VIDEO_H264_P_FRAME_QP (integer)``
1265 Quantization parameter for an P frame for H264. Valid range: from 0
1268 ``V4L2_CID_MPEG_VIDEO_H264_B_FRAME_QP (integer)``
1269 Quantization parameter for an B frame for H264. Valid range: from 0
1272 ``V4L2_CID_MPEG_VIDEO_H264_I_FRAME_MIN_QP (integer)``
1273 Minimum quantization parameter for the H264 I frame to limit I frame
1274 quality to a range. Valid range: from 0 to 51. If
1275 V4L2_CID_MPEG_VIDEO_H264_MIN_QP is also set, the quantization parameter
1276 should be chosen to meet both requirements.
1278 ``V4L2_CID_MPEG_VIDEO_H264_I_FRAME_MAX_QP (integer)``
1279 Maximum quantization parameter for the H264 I frame to limit I frame
1280 quality to a range. Valid range: from 0 to 51. If
1281 V4L2_CID_MPEG_VIDEO_H264_MAX_QP is also set, the quantization parameter
1282 should be chosen to meet both requirements.
1284 ``V4L2_CID_MPEG_VIDEO_H264_P_FRAME_MIN_QP (integer)``
1285 Minimum quantization parameter for the H264 P frame to limit P frame
1286 quality to a range. Valid range: from 0 to 51. If
1287 V4L2_CID_MPEG_VIDEO_H264_MIN_QP is also set, the quantization parameter
1288 should be chosen to meet both requirements.
1290 ``V4L2_CID_MPEG_VIDEO_H264_P_FRAME_MAX_QP (integer)``
1291 Maximum quantization parameter for the H264 P frame to limit P frame
1292 quality to a range. Valid range: from 0 to 51. If
1293 V4L2_CID_MPEG_VIDEO_H264_MAX_QP is also set, the quantization parameter
1294 should be chosen to meet both requirements.
1296 ``V4L2_CID_MPEG_VIDEO_H264_B_FRAME_MIN_QP (integer)``
1297 Minimum quantization parameter for the H264 B frame to limit B frame
1298 quality to a range. Valid range: from 0 to 51. If
1299 V4L2_CID_MPEG_VIDEO_H264_MIN_QP is also set, the quantization parameter
1300 should be chosen to meet both requirements.
1302 ``V4L2_CID_MPEG_VIDEO_H264_B_FRAME_MAX_QP (integer)``
1303 Maximum quantization parameter for the H264 B frame to limit B frame
1304 quality to a range. Valid range: from 0 to 51. If
1305 V4L2_CID_MPEG_VIDEO_H264_MAX_QP is also set, the quantization parameter
1306 should be chosen to meet both requirements.
1308 ``V4L2_CID_MPEG_VIDEO_MPEG4_I_FRAME_QP (integer)``
1309 Quantization parameter for an I frame for MPEG4. Valid range: from 1
1312 ``V4L2_CID_MPEG_VIDEO_MPEG4_MIN_QP (integer)``
1313 Minimum quantization parameter for MPEG4. Valid range: from 1 to 31.
1315 ``V4L2_CID_MPEG_VIDEO_MPEG4_MAX_QP (integer)``
1316 Maximum quantization parameter for MPEG4. Valid range: from 1 to 31.
1318 ``V4L2_CID_MPEG_VIDEO_MPEG4_P_FRAME_QP (integer)``
1319 Quantization parameter for an P frame for MPEG4. Valid range: from 1
1322 ``V4L2_CID_MPEG_VIDEO_MPEG4_B_FRAME_QP (integer)``
1323 Quantization parameter for an B frame for MPEG4. Valid range: from 1
1326 .. _v4l2-mpeg-video-vbv-size:
1328 ``V4L2_CID_MPEG_VIDEO_VBV_SIZE (integer)``
1329 The Video Buffer Verifier size in kilobytes, it is used as a
1330 limitation of frame skip. The VBV is defined in the standard as a
1331 mean to verify that the produced stream will be successfully
1332 decoded. The standard describes it as "Part of a hypothetical
1333 decoder that is conceptually connected to the output of the encoder.
1334 Its purpose is to provide a constraint on the variability of the
1335 data rate that an encoder or editing process may produce.".
1336 Applicable to the MPEG1, MPEG2, MPEG4 encoders.
1338 .. _v4l2-mpeg-video-vbv-delay:
1340 ``V4L2_CID_MPEG_VIDEO_VBV_DELAY (integer)``
1341 Sets the initial delay in milliseconds for VBV buffer control.
1343 .. _v4l2-mpeg-video-hor-search-range:
1345 ``V4L2_CID_MPEG_VIDEO_MV_H_SEARCH_RANGE (integer)``
1346 Horizontal search range defines maximum horizontal search area in
1347 pixels to search and match for the present Macroblock (MB) in the
1348 reference picture. This V4L2 control macro is used to set horizontal
1349 search range for motion estimation module in video encoder.
1351 .. _v4l2-mpeg-video-vert-search-range:
1353 ``V4L2_CID_MPEG_VIDEO_MV_V_SEARCH_RANGE (integer)``
1354 Vertical search range defines maximum vertical search area in pixels
1355 to search and match for the present Macroblock (MB) in the reference
1356 picture. This V4L2 control macro is used to set vertical search
1357 range for motion estimation module in video encoder.
1359 .. _v4l2-mpeg-video-force-key-frame:
1361 ``V4L2_CID_MPEG_VIDEO_FORCE_KEY_FRAME (button)``
1362 Force a key frame for the next queued buffer. Applicable to
1363 encoders. This is a general, codec-agnostic keyframe control.
1365 .. _v4l2-mpeg-video-h264-cpb-size:
1367 ``V4L2_CID_MPEG_VIDEO_H264_CPB_SIZE (integer)``
1368 The Coded Picture Buffer size in kilobytes, it is used as a
1369 limitation of frame skip. The CPB is defined in the H264 standard as
1370 a mean to verify that the produced stream will be successfully
1371 decoded. Applicable to the H264 encoder.
1373 ``V4L2_CID_MPEG_VIDEO_H264_I_PERIOD (integer)``
1374 Period between I-frames in the open GOP for H264. In case of an open
1375 GOP this is the period between two I-frames. The period between IDR
1376 (Instantaneous Decoding Refresh) frames is taken from the GOP_SIZE
1377 control. An IDR frame, which stands for Instantaneous Decoding
1378 Refresh is an I-frame after which no prior frames are referenced.
1379 This means that a stream can be restarted from an IDR frame without
1380 the need to store or decode any previous frames. Applicable to the
1383 .. _v4l2-mpeg-video-header-mode:
1385 ``V4L2_CID_MPEG_VIDEO_HEADER_MODE``
1388 enum v4l2_mpeg_video_header_mode -
1389 Determines whether the header is returned as the first buffer or is
1390 it returned together with the first frame. Applicable to encoders.
1391 Possible values are:
1397 .. tabularcolumns:: |p{10.3cm}|p{7.2cm}|
1403 * - ``V4L2_MPEG_VIDEO_HEADER_MODE_SEPARATE``
1404 - The stream header is returned separately in the first buffer.
1405 * - ``V4L2_MPEG_VIDEO_HEADER_MODE_JOINED_WITH_1ST_FRAME``
1406 - The stream header is returned together with the first encoded
1414 ``V4L2_CID_MPEG_VIDEO_REPEAT_SEQ_HEADER (boolean)``
1415 Repeat the video sequence headers. Repeating these headers makes
1416 random access to the video stream easier. Applicable to the MPEG1, 2
1419 ``V4L2_CID_MPEG_VIDEO_DECODER_MPEG4_DEBLOCK_FILTER (boolean)``
1420 Enabled the deblocking post processing filter for MPEG4 decoder.
1421 Applicable to the MPEG4 decoder.
1423 ``V4L2_CID_MPEG_VIDEO_MPEG4_VOP_TIME_RES (integer)``
1424 vop_time_increment_resolution value for MPEG4. Applicable to the
1427 ``V4L2_CID_MPEG_VIDEO_MPEG4_VOP_TIME_INC (integer)``
1428 vop_time_increment value for MPEG4. Applicable to the MPEG4
1431 ``V4L2_CID_MPEG_VIDEO_H264_SEI_FRAME_PACKING (boolean)``
1432 Enable generation of frame packing supplemental enhancement
1433 information in the encoded bitstream. The frame packing SEI message
1434 contains the arrangement of L and R planes for 3D viewing.
1435 Applicable to the H264 encoder.
1437 ``V4L2_CID_MPEG_VIDEO_H264_SEI_FP_CURRENT_FRAME_0 (boolean)``
1438 Sets current frame as frame0 in frame packing SEI. Applicable to the
1441 .. _v4l2-mpeg-video-h264-sei-fp-arrangement-type:
1443 ``V4L2_CID_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE``
1446 enum v4l2_mpeg_video_h264_sei_fp_arrangement_type -
1447 Frame packing arrangement type for H264 SEI. Applicable to the H264
1448 encoder. Possible values are:
1454 .. tabularcolumns:: |p{12cm}|p{5.5cm}|
1460 * - ``V4L2_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_CHEKERBOARD``
1461 - Pixels are alternatively from L and R.
1462 * - ``V4L2_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_COLUMN``
1463 - L and R are interlaced by column.
1464 * - ``V4L2_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_ROW``
1465 - L and R are interlaced by row.
1466 * - ``V4L2_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_SIDE_BY_SIDE``
1467 - L is on the left, R on the right.
1468 * - ``V4L2_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_TOP_BOTTOM``
1469 - L is on top, R on bottom.
1470 * - ``V4L2_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_TEMPORAL``
1471 - One view per frame.
1479 ``V4L2_CID_MPEG_VIDEO_H264_FMO (boolean)``
1480 Enables flexible macroblock ordering in the encoded bitstream. It is
1481 a technique used for restructuring the ordering of macroblocks in
1482 pictures. Applicable to the H264 encoder.
1484 .. _v4l2-mpeg-video-h264-fmo-map-type:
1486 ``V4L2_CID_MPEG_VIDEO_H264_FMO_MAP_TYPE``
1489 enum v4l2_mpeg_video_h264_fmo_map_type -
1490 When using FMO, the map type divides the image in different scan
1491 patterns of macroblocks. Applicable to the H264 encoder. Possible
1498 .. tabularcolumns:: |p{12.5cm}|p{5.0cm}|
1504 * - ``V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_INTERLEAVED_SLICES``
1505 - Slices are interleaved one after other with macroblocks in run
1507 * - ``V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_SCATTERED_SLICES``
1508 - Scatters the macroblocks based on a mathematical function known to
1509 both encoder and decoder.
1510 * - ``V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_FOREGROUND_WITH_LEFT_OVER``
1511 - Macroblocks arranged in rectangular areas or regions of interest.
1512 * - ``V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_BOX_OUT``
1513 - Slice groups grow in a cyclic way from centre to outwards.
1514 * - ``V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_RASTER_SCAN``
1515 - Slice groups grow in raster scan pattern from left to right.
1516 * - ``V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_WIPE_SCAN``
1517 - Slice groups grow in wipe scan pattern from top to bottom.
1518 * - ``V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_EXPLICIT``
1519 - User defined map type.
1527 ``V4L2_CID_MPEG_VIDEO_H264_FMO_SLICE_GROUP (integer)``
1528 Number of slice groups in FMO. Applicable to the H264 encoder.
1530 .. _v4l2-mpeg-video-h264-fmo-change-direction:
1532 ``V4L2_CID_MPEG_VIDEO_H264_FMO_CHANGE_DIRECTION``
1535 enum v4l2_mpeg_video_h264_fmo_change_dir -
1536 Specifies a direction of the slice group change for raster and wipe
1537 maps. Applicable to the H264 encoder. Possible values are:
1539 .. tabularcolumns:: |p{9.6cm}|p{7.9cm}|
1545 * - ``V4L2_MPEG_VIDEO_H264_FMO_CHANGE_DIR_RIGHT``
1546 - Raster scan or wipe right.
1547 * - ``V4L2_MPEG_VIDEO_H264_FMO_CHANGE_DIR_LEFT``
1548 - Reverse raster scan or wipe left.
1552 ``V4L2_CID_MPEG_VIDEO_H264_FMO_CHANGE_RATE (integer)``
1553 Specifies the size of the first slice group for raster and wipe map.
1554 Applicable to the H264 encoder.
1556 ``V4L2_CID_MPEG_VIDEO_H264_FMO_RUN_LENGTH (integer)``
1557 Specifies the number of consecutive macroblocks for the interleaved
1558 map. Applicable to the H264 encoder.
1560 ``V4L2_CID_MPEG_VIDEO_H264_ASO (boolean)``
1561 Enables arbitrary slice ordering in encoded bitstream. Applicable to
1564 ``V4L2_CID_MPEG_VIDEO_H264_ASO_SLICE_ORDER (integer)``
1565 Specifies the slice order in ASO. Applicable to the H264 encoder.
1566 The supplied 32-bit integer is interpreted as follows (bit 0 = least
1578 - Slice position or order
1582 ``V4L2_CID_MPEG_VIDEO_H264_HIERARCHICAL_CODING (boolean)``
1583 Enables H264 hierarchical coding. Applicable to the H264 encoder.
1585 .. _v4l2-mpeg-video-h264-hierarchical-coding-type:
1587 ``V4L2_CID_MPEG_VIDEO_H264_HIERARCHICAL_CODING_TYPE``
1590 enum v4l2_mpeg_video_h264_hierarchical_coding_type -
1591 Specifies the hierarchical coding type. Applicable to the H264
1592 encoder. Possible values are:
1600 * - ``V4L2_MPEG_VIDEO_H264_HIERARCHICAL_CODING_B``
1601 - Hierarchical B coding.
1602 * - ``V4L2_MPEG_VIDEO_H264_HIERARCHICAL_CODING_P``
1603 - Hierarchical P coding.
1607 ``V4L2_CID_MPEG_VIDEO_H264_HIERARCHICAL_CODING_LAYER (integer)``
1608 Specifies the number of hierarchical coding layers. Applicable to
1611 ``V4L2_CID_MPEG_VIDEO_H264_HIERARCHICAL_CODING_LAYER_QP (integer)``
1612 Specifies a user defined QP for each layer. Applicable to the H264
1613 encoder. The supplied 32-bit integer is interpreted as follows (bit
1614 0 = least significant bit):
1627 ``V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L0_BR (integer)``
1628 Indicates bit rate (bps) for hierarchical coding layer 0 for H264 encoder.
1630 ``V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L1_BR (integer)``
1631 Indicates bit rate (bps) for hierarchical coding layer 1 for H264 encoder.
1633 ``V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L2_BR (integer)``
1634 Indicates bit rate (bps) for hierarchical coding layer 2 for H264 encoder.
1636 ``V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L3_BR (integer)``
1637 Indicates bit rate (bps) for hierarchical coding layer 3 for H264 encoder.
1639 ``V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L4_BR (integer)``
1640 Indicates bit rate (bps) for hierarchical coding layer 4 for H264 encoder.
1642 ``V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L5_BR (integer)``
1643 Indicates bit rate (bps) for hierarchical coding layer 5 for H264 encoder.
1645 ``V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L6_BR (integer)``
1646 Indicates bit rate (bps) for hierarchical coding layer 6 for H264 encoder.
1648 ``V4L2_CID_FWHT_I_FRAME_QP (integer)``
1649 Quantization parameter for an I frame for FWHT. Valid range: from 1
1652 ``V4L2_CID_FWHT_P_FRAME_QP (integer)``
1653 Quantization parameter for a P frame for FWHT. Valid range: from 1
1661 MFC 5.1 MPEG Controls
1662 =====================
1664 The following MPEG class controls deal with MPEG decoding and encoding
1665 settings that are specific to the Multi Format Codec 5.1 device present
1666 in the S5P family of SoCs by Samsung.
1669 .. _mfc51-control-id:
1674 ``V4L2_CID_MPEG_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY_ENABLE (boolean)``
1675 If the display delay is enabled then the decoder is forced to return
1676 a CAPTURE buffer (decoded frame) after processing a certain number
1677 of OUTPUT buffers. The delay can be set through
1678 ``V4L2_CID_MPEG_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY``. This
1679 feature can be used for example for generating thumbnails of videos.
1680 Applicable to the H264 decoder.
1684 This control is deprecated. Use the standard
1685 ``V4L2_CID_MPEG_VIDEO_DEC_DISPLAY_DELAY_ENABLE`` control instead.
1687 ``V4L2_CID_MPEG_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY (integer)``
1688 Display delay value for H264 decoder. The decoder is forced to
1689 return a decoded frame after the set 'display delay' number of
1690 frames. If this number is low it may result in frames returned out
1691 of display order, in addition the hardware may still be using the
1692 returned buffer as a reference picture for subsequent frames.
1696 This control is deprecated. Use the standard
1697 ``V4L2_CID_MPEG_VIDEO_DEC_DISPLAY_DELAY`` control instead.
1699 ``V4L2_CID_MPEG_MFC51_VIDEO_H264_NUM_REF_PIC_FOR_P (integer)``
1700 The number of reference pictures used for encoding a P picture.
1701 Applicable to the H264 encoder.
1703 ``V4L2_CID_MPEG_MFC51_VIDEO_PADDING (boolean)``
1704 Padding enable in the encoder - use a color instead of repeating
1705 border pixels. Applicable to encoders.
1707 ``V4L2_CID_MPEG_MFC51_VIDEO_PADDING_YUV (integer)``
1708 Padding color in the encoder. Applicable to encoders. The supplied
1709 32-bit integer is interpreted as follows (bit 0 = least significant
1719 - V chrominance information
1721 - U chrominance information
1723 - Y luminance information
1729 ``V4L2_CID_MPEG_MFC51_VIDEO_RC_REACTION_COEFF (integer)``
1730 Reaction coefficient for MFC rate control. Applicable to encoders.
1734 #. Valid only when the frame level RC is enabled.
1736 #. For tight CBR, this field must be small (ex. 2 ~ 10). For
1737 VBR, this field must be large (ex. 100 ~ 1000).
1739 #. It is not recommended to use the greater number than
1740 FRAME_RATE * (10^9 / BIT_RATE).
1742 ``V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_DARK (boolean)``
1743 Adaptive rate control for dark region. Valid only when H.264 and
1744 macroblock level RC is enabled
1745 (``V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE``). Applicable to the H264
1748 ``V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_SMOOTH (boolean)``
1749 Adaptive rate control for smooth region. Valid only when H.264 and
1750 macroblock level RC is enabled
1751 (``V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE``). Applicable to the H264
1754 ``V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_STATIC (boolean)``
1755 Adaptive rate control for static region. Valid only when H.264 and
1756 macroblock level RC is enabled
1757 (``V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE``). Applicable to the H264
1760 ``V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_ACTIVITY (boolean)``
1761 Adaptive rate control for activity region. Valid only when H.264 and
1762 macroblock level RC is enabled
1763 (``V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE``). Applicable to the H264
1766 .. _v4l2-mpeg-mfc51-video-frame-skip-mode:
1768 ``V4L2_CID_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE``
1773 This control is deprecated. Use the standard
1774 ``V4L2_CID_MPEG_VIDEO_FRAME_SKIP_MODE`` control instead.
1776 enum v4l2_mpeg_mfc51_video_frame_skip_mode -
1777 Indicates in what conditions the encoder should skip frames. If
1778 encoding a frame would cause the encoded stream to be larger then a
1779 chosen data limit then the frame will be skipped. Possible values
1783 .. tabularcolumns:: |p{9.4cm}|p{8.1cm}|
1793 * - ``V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_DISABLED``
1794 - Frame skip mode is disabled.
1795 * - ``V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_LEVEL_LIMIT``
1796 - Frame skip mode enabled and buffer limit is set by the chosen
1797 level and is defined by the standard.
1798 * - ``V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT``
1799 - Frame skip mode enabled and buffer limit is set by the VBV
1800 (MPEG1/2/4) or CPB (H264) buffer size control.
1806 ``V4L2_CID_MPEG_MFC51_VIDEO_RC_FIXED_TARGET_BIT (integer)``
1807 Enable rate-control with fixed target bit. If this setting is
1808 enabled, then the rate control logic of the encoder will calculate
1809 the average bitrate for a GOP and keep it below or equal the set
1810 bitrate target. Otherwise the rate control logic calculates the
1811 overall average bitrate for the stream and keeps it below or equal
1812 to the set bitrate. In the first case the average bitrate for the
1813 whole stream will be smaller then the set bitrate. This is caused
1814 because the average is calculated for smaller number of frames, on
1815 the other hand enabling this setting will ensure that the stream
1816 will meet tight bandwidth constraints. Applicable to encoders.
1818 .. _v4l2-mpeg-mfc51-video-force-frame-type:
1820 ``V4L2_CID_MPEG_MFC51_VIDEO_FORCE_FRAME_TYPE``
1823 enum v4l2_mpeg_mfc51_video_force_frame_type -
1824 Force a frame type for the next queued buffer. Applicable to
1825 encoders. Possible values are:
1827 .. tabularcolumns:: |p{9.9cm}|p{7.6cm}|
1833 * - ``V4L2_MPEG_MFC51_FORCE_FRAME_TYPE_DISABLED``
1834 - Forcing a specific frame type disabled.
1835 * - ``V4L2_MPEG_MFC51_FORCE_FRAME_TYPE_I_FRAME``
1837 * - ``V4L2_MPEG_MFC51_FORCE_FRAME_TYPE_NOT_CODED``
1838 - Force a non-coded frame.
1841 CX2341x MPEG Controls
1842 =====================
1844 The following MPEG class controls deal with MPEG encoding settings that
1845 are specific to the Conexant CX23415 and CX23416 MPEG encoding chips.
1848 .. _cx2341x-control-id:
1853 .. _v4l2-mpeg-cx2341x-video-spatial-filter-mode:
1855 ``V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE``
1858 enum v4l2_mpeg_cx2341x_video_spatial_filter_mode -
1859 Sets the Spatial Filter mode (default ``MANUAL``). Possible values
1863 .. tabularcolumns:: |p{11.5cm}|p{6.0cm}|
1869 * - ``V4L2_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE_MANUAL``
1870 - Choose the filter manually
1871 * - ``V4L2_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE_AUTO``
1872 - Choose the filter automatically
1876 ``V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER (integer (0-15))``
1877 The setting for the Spatial Filter. 0 = off, 15 = maximum. (Default
1880 .. _luma-spatial-filter-type:
1882 ``V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE``
1885 enum v4l2_mpeg_cx2341x_video_luma_spatial_filter_type -
1886 Select the algorithm to use for the Luma Spatial Filter (default
1887 ``1D_HOR``). Possible values:
1889 .. tabularcolumns:: |p{13.1cm}|p{4.4cm}|
1899 * - ``V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_OFF``
1901 * - ``V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_1D_HOR``
1902 - One-dimensional horizontal
1903 * - ``V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_1D_VERT``
1904 - One-dimensional vertical
1905 * - ``V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_2D_HV_SEPARABLE``
1906 - Two-dimensional separable
1907 * - ``V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_2D_SYM_NON_SEPARABLE``
1908 - Two-dimensional symmetrical non-separable
1914 .. _chroma-spatial-filter-type:
1916 ``V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE``
1919 enum v4l2_mpeg_cx2341x_video_chroma_spatial_filter_type -
1920 Select the algorithm for the Chroma Spatial Filter (default
1921 ``1D_HOR``). Possible values are:
1927 .. tabularcolumns:: |p{11.0cm}|p{6.5cm}|
1933 * - ``V4L2_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_OFF``
1935 * - ``V4L2_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_1D_HOR``
1936 - One-dimensional horizontal
1942 .. _v4l2-mpeg-cx2341x-video-temporal-filter-mode:
1944 ``V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE``
1947 enum v4l2_mpeg_cx2341x_video_temporal_filter_mode -
1948 Sets the Temporal Filter mode (default ``MANUAL``). Possible values
1959 * - ``V4L2_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_MANUAL``
1960 - Choose the filter manually
1961 * - ``V4L2_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_AUTO``
1962 - Choose the filter automatically
1968 ``V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER (integer (0-31))``
1969 The setting for the Temporal Filter. 0 = off, 31 = maximum. (Default
1970 is 8 for full-scale capturing and 0 for scaled capturing.)
1972 .. _v4l2-mpeg-cx2341x-video-median-filter-type:
1974 ``V4L2_CID_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE``
1977 enum v4l2_mpeg_cx2341x_video_median_filter_type -
1978 Median Filter Type (default ``OFF``). Possible values are:
1985 .. tabularcolumns:: |p{11.0cm}|p{6.5cm}|
1991 * - ``V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF``
1993 * - ``V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_HOR``
1995 * - ``V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_VERT``
1997 * - ``V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_HOR_VERT``
1998 - Horizontal and vertical filter
1999 * - ``V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_DIAG``
2006 ``V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM (integer (0-255))``
2007 Threshold above which the luminance median filter is enabled
2010 ``V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP (integer (0-255))``
2011 Threshold below which the luminance median filter is enabled
2014 ``V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM (integer (0-255))``
2015 Threshold above which the chroma median filter is enabled (default
2018 ``V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP (integer (0-255))``
2019 Threshold below which the chroma median filter is enabled (default
2022 ``V4L2_CID_MPEG_CX2341X_STREAM_INSERT_NAV_PACKETS (boolean)``
2023 The CX2341X MPEG encoder can insert one empty MPEG-2 PES packet into
2024 the stream between every four video frames. The packet size is 2048
2025 bytes, including the packet_start_code_prefix and stream_id
2026 fields. The stream_id is 0xBF (private stream 2). The payload
2027 consists of 0x00 bytes, to be filled in by the application. 0 = do
2028 not insert, 1 = insert packets.
2031 VPX Control Reference
2032 =====================
2034 The VPX controls include controls for encoding parameters of VPx video
2043 .. _v4l2-vpx-num-partitions:
2045 ``V4L2_CID_MPEG_VIDEO_VPX_NUM_PARTITIONS``
2048 enum v4l2_vp8_num_partitions -
2049 The number of token partitions to use in VP8 encoder. Possible
2058 * - ``V4L2_CID_MPEG_VIDEO_VPX_1_PARTITION``
2059 - 1 coefficient partition
2060 * - ``V4L2_CID_MPEG_VIDEO_VPX_2_PARTITIONS``
2061 - 2 coefficient partitions
2062 * - ``V4L2_CID_MPEG_VIDEO_VPX_4_PARTITIONS``
2063 - 4 coefficient partitions
2064 * - ``V4L2_CID_MPEG_VIDEO_VPX_8_PARTITIONS``
2065 - 8 coefficient partitions
2069 ``V4L2_CID_MPEG_VIDEO_VPX_IMD_DISABLE_4X4 (boolean)``
2070 Setting this prevents intra 4x4 mode in the intra mode decision.
2072 .. _v4l2-vpx-num-ref-frames:
2074 ``V4L2_CID_MPEG_VIDEO_VPX_NUM_REF_FRAMES``
2077 enum v4l2_vp8_num_ref_frames -
2078 The number of reference pictures for encoding P frames. Possible
2081 .. tabularcolumns:: |p{7.5cm}|p{7.5cm}|
2091 * - ``V4L2_CID_MPEG_VIDEO_VPX_1_REF_FRAME``
2092 - Last encoded frame will be searched
2093 * - ``V4L2_CID_MPEG_VIDEO_VPX_2_REF_FRAME``
2094 - Two frames will be searched among the last encoded frame, the
2095 golden frame and the alternate reference (altref) frame. The
2096 encoder implementation will decide which two are chosen.
2097 * - ``V4L2_CID_MPEG_VIDEO_VPX_3_REF_FRAME``
2098 - The last encoded frame, the golden frame and the altref frame will
2107 ``V4L2_CID_MPEG_VIDEO_VPX_FILTER_LEVEL (integer)``
2108 Indicates the loop filter level. The adjustment of the loop filter
2109 level is done via a delta value against a baseline loop filter
2112 ``V4L2_CID_MPEG_VIDEO_VPX_FILTER_SHARPNESS (integer)``
2113 This parameter affects the loop filter. Anything above zero weakens
2114 the deblocking effect on the loop filter.
2116 ``V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_REF_PERIOD (integer)``
2117 Sets the refresh period for the golden frame. The period is defined
2118 in number of frames. For a value of 'n', every nth frame starting
2119 from the first key frame will be taken as a golden frame. For eg.
2120 for encoding sequence of 0, 1, 2, 3, 4, 5, 6, 7 where the golden
2121 frame refresh period is set as 4, the frames 0, 4, 8 etc will be
2122 taken as the golden frames as frame 0 is always a key frame.
2124 .. _v4l2-vpx-golden-frame-sel:
2126 ``V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_SEL``
2129 enum v4l2_vp8_golden_frame_sel -
2130 Selects the golden frame for encoding. Possible values are:
2136 .. tabularcolumns:: |p{8.6cm}|p{8.9cm}|
2142 * - ``V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_USE_PREV``
2143 - Use the (n-2)th frame as a golden frame, current frame index being
2145 * - ``V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_USE_REF_PERIOD``
2146 - Use the previous specific frame indicated by
2147 ``V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_REF_PERIOD`` as a
2155 ``V4L2_CID_MPEG_VIDEO_VPX_MIN_QP (integer)``
2156 Minimum quantization parameter for VP8.
2158 ``V4L2_CID_MPEG_VIDEO_VPX_MAX_QP (integer)``
2159 Maximum quantization parameter for VP8.
2161 ``V4L2_CID_MPEG_VIDEO_VPX_I_FRAME_QP (integer)``
2162 Quantization parameter for an I frame for VP8.
2164 ``V4L2_CID_MPEG_VIDEO_VPX_P_FRAME_QP (integer)``
2165 Quantization parameter for a P frame for VP8.
2167 .. _v4l2-mpeg-video-vp8-profile:
2169 ``V4L2_CID_MPEG_VIDEO_VP8_PROFILE``
2172 enum v4l2_mpeg_video_vp8_profile -
2173 This control allows selecting the profile for VP8 encoder.
2174 This is also used to enumerate supported profiles by VP8 encoder or decoder.
2175 Possible values are:
2181 * - ``V4L2_MPEG_VIDEO_VP8_PROFILE_0``
2183 * - ``V4L2_MPEG_VIDEO_VP8_PROFILE_1``
2185 * - ``V4L2_MPEG_VIDEO_VP8_PROFILE_2``
2187 * - ``V4L2_MPEG_VIDEO_VP8_PROFILE_3``
2190 .. _v4l2-mpeg-video-vp9-profile:
2192 ``V4L2_CID_MPEG_VIDEO_VP9_PROFILE``
2195 enum v4l2_mpeg_video_vp9_profile -
2196 This control allows selecting the profile for VP9 encoder.
2197 This is also used to enumerate supported profiles by VP9 encoder or decoder.
2198 Possible values are:
2204 * - ``V4L2_MPEG_VIDEO_VP9_PROFILE_0``
2206 * - ``V4L2_MPEG_VIDEO_VP9_PROFILE_1``
2208 * - ``V4L2_MPEG_VIDEO_VP9_PROFILE_2``
2210 * - ``V4L2_MPEG_VIDEO_VP9_PROFILE_3``
2213 .. _v4l2-mpeg-video-vp9-level:
2215 ``V4L2_CID_MPEG_VIDEO_VP9_LEVEL (enum)``
2217 enum v4l2_mpeg_video_vp9_level -
2218 This control allows selecting the level for VP9 encoder.
2219 This is also used to enumerate supported levels by VP9 encoder or decoder.
2220 More information can be found at
2221 `webmproject <https://www.webmproject.org/vp9/levels/>`__. Possible values are:
2227 * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_1_0``
2229 * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_1_1``
2231 * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_2_0``
2233 * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_2_1``
2235 * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_3_0``
2237 * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_3_1``
2239 * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_4_0``
2241 * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_4_1``
2243 * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_5_0``
2245 * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_5_1``
2247 * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_5_2``
2249 * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_6_0``
2251 * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_6_1``
2253 * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_6_2``
2257 High Efficiency Video Coding (HEVC/H.265) Control Reference
2258 ===========================================================
2260 The HEVC/H.265 controls include controls for encoding parameters of HEVC/H.265
2264 .. _hevc-control-id:
2266 HEVC/H.265 Control IDs
2267 ----------------------
2269 ``V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP (integer)``
2270 Minimum quantization parameter for HEVC.
2271 Valid range: from 0 to 51 for 8 bit and from 0 to 63 for 10 bit.
2273 ``V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP (integer)``
2274 Maximum quantization parameter for HEVC.
2275 Valid range: from 0 to 51 for 8 bit and from 0 to 63 for 10 bit.
2277 ``V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_QP (integer)``
2278 Quantization parameter for an I frame for HEVC.
2279 Valid range: [V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP,
2280 V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP].
2282 ``V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_QP (integer)``
2283 Quantization parameter for a P frame for HEVC.
2284 Valid range: [V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP,
2285 V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP].
2287 ``V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_QP (integer)``
2288 Quantization parameter for a B frame for HEVC.
2289 Valid range: [V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP,
2290 V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP].
2292 ``V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_MIN_QP (integer)``
2293 Minimum quantization parameter for the HEVC I frame to limit I frame
2294 quality to a range. Valid range: from 0 to 51 for 8 bit and from 0 to 63 for 10 bit.
2295 If V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP is also set, the quantization parameter
2296 should be chosen to meet both requirements.
2298 ``V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_MAX_QP (integer)``
2299 Maximum quantization parameter for the HEVC I frame to limit I frame
2300 quality to a range. Valid range: from 0 to 51 for 8 bit and from 0 to 63 for 10 bit.
2301 If V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP is also set, the quantization parameter
2302 should be chosen to meet both requirements.
2304 ``V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_MIN_QP (integer)``
2305 Minimum quantization parameter for the HEVC P frame to limit P frame
2306 quality to a range. Valid range: from 0 to 51 for 8 bit and from 0 to 63 for 10 bit.
2307 If V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP is also set, the quantization parameter
2308 should be chosen to meet both requirements.
2310 ``V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_MAX_QP (integer)``
2311 Maximum quantization parameter for the HEVC P frame to limit P frame
2312 quality to a range. Valid range: from 0 to 51 for 8 bit and from 0 to 63 for 10 bit.
2313 If V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP is also set, the quantization parameter
2314 should be chosen to meet both requirements.
2316 ``V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_MIN_QP (integer)``
2317 Minimum quantization parameter for the HEVC B frame to limit B frame
2318 quality to a range. Valid range: from 0 to 51 for 8 bit and from 0 to 63 for 10 bit.
2319 If V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP is also set, the quantization parameter
2320 should be chosen to meet both requirements.
2322 ``V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_MAX_QP (integer)``
2323 Maximum quantization parameter for the HEVC B frame to limit B frame
2324 quality to a range. Valid range: from 0 to 51 for 8 bit and from 0 to 63 for 10 bit.
2325 If V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP is also set, the quantization parameter
2326 should be chosen to meet both requirements.
2328 ``V4L2_CID_MPEG_VIDEO_HEVC_HIER_QP (boolean)``
2329 HIERARCHICAL_QP allows the host to specify the quantization parameter
2330 values for each temporal layer through HIERARCHICAL_QP_LAYER. This is
2331 valid only if HIERARCHICAL_CODING_LAYER is greater than 1. Setting the
2332 control value to 1 enables setting of the QP values for the layers.
2334 .. _v4l2-hevc-hier-coding-type:
2336 ``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_TYPE``
2339 enum v4l2_mpeg_video_hevc_hier_coding_type -
2340 Selects the hierarchical coding type for encoding. Possible values are:
2346 .. tabularcolumns:: |p{8.2cm}|p{9.3cm}|
2352 * - ``V4L2_MPEG_VIDEO_HEVC_HIERARCHICAL_CODING_B``
2353 - Use the B frame for hierarchical coding.
2354 * - ``V4L2_MPEG_VIDEO_HEVC_HIERARCHICAL_CODING_P``
2355 - Use the P frame for hierarchical coding.
2362 ``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_LAYER (integer)``
2363 Selects the hierarchical coding layer. In normal encoding
2364 (non-hierarchial coding), it should be zero. Possible values are [0, 6].
2365 0 indicates HIERARCHICAL CODING LAYER 0, 1 indicates HIERARCHICAL CODING
2368 ``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L0_QP (integer)``
2369 Indicates quantization parameter for hierarchical coding layer 0.
2370 Valid range: [V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP,
2371 V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP].
2373 ``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L1_QP (integer)``
2374 Indicates quantization parameter for hierarchical coding layer 1.
2375 Valid range: [V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP,
2376 V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP].
2378 ``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L2_QP (integer)``
2379 Indicates quantization parameter for hierarchical coding layer 2.
2380 Valid range: [V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP,
2381 V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP].
2383 ``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L3_QP (integer)``
2384 Indicates quantization parameter for hierarchical coding layer 3.
2385 Valid range: [V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP,
2386 V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP].
2388 ``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L4_QP (integer)``
2389 Indicates quantization parameter for hierarchical coding layer 4.
2390 Valid range: [V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP,
2391 V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP].
2393 ``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L5_QP (integer)``
2394 Indicates quantization parameter for hierarchical coding layer 5.
2395 Valid range: [V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP,
2396 V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP].
2398 ``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L6_QP (integer)``
2399 Indicates quantization parameter for hierarchical coding layer 6.
2400 Valid range: [V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP,
2401 V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP].
2403 .. _v4l2-hevc-profile:
2405 ``V4L2_CID_MPEG_VIDEO_HEVC_PROFILE``
2408 enum v4l2_mpeg_video_hevc_profile -
2409 Select the desired profile for HEVC encoder.
2415 .. tabularcolumns:: |p{9.0cm}|p{8.5cm}|
2421 * - ``V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN``
2423 * - ``V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN_STILL_PICTURE``
2424 - Main still picture profile.
2425 * - ``V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN_10``
2433 .. _v4l2-hevc-level:
2435 ``V4L2_CID_MPEG_VIDEO_HEVC_LEVEL``
2438 enum v4l2_mpeg_video_hevc_level -
2439 Selects the desired level for HEVC encoder.
2441 ================================== =========
2442 ``V4L2_MPEG_VIDEO_HEVC_LEVEL_1`` Level 1.0
2443 ``V4L2_MPEG_VIDEO_HEVC_LEVEL_2`` Level 2.0
2444 ``V4L2_MPEG_VIDEO_HEVC_LEVEL_2_1`` Level 2.1
2445 ``V4L2_MPEG_VIDEO_HEVC_LEVEL_3`` Level 3.0
2446 ``V4L2_MPEG_VIDEO_HEVC_LEVEL_3_1`` Level 3.1
2447 ``V4L2_MPEG_VIDEO_HEVC_LEVEL_4`` Level 4.0
2448 ``V4L2_MPEG_VIDEO_HEVC_LEVEL_4_1`` Level 4.1
2449 ``V4L2_MPEG_VIDEO_HEVC_LEVEL_5`` Level 5.0
2450 ``V4L2_MPEG_VIDEO_HEVC_LEVEL_5_1`` Level 5.1
2451 ``V4L2_MPEG_VIDEO_HEVC_LEVEL_5_2`` Level 5.2
2452 ``V4L2_MPEG_VIDEO_HEVC_LEVEL_6`` Level 6.0
2453 ``V4L2_MPEG_VIDEO_HEVC_LEVEL_6_1`` Level 6.1
2454 ``V4L2_MPEG_VIDEO_HEVC_LEVEL_6_2`` Level 6.2
2455 ================================== =========
2457 ``V4L2_CID_MPEG_VIDEO_HEVC_FRAME_RATE_RESOLUTION (integer)``
2458 Indicates the number of evenly spaced subintervals, called ticks, within
2459 one second. This is a 16 bit unsigned integer and has a maximum value up to
2460 0xffff and a minimum value of 1.
2464 ``V4L2_CID_MPEG_VIDEO_HEVC_TIER``
2467 enum v4l2_mpeg_video_hevc_tier -
2468 TIER_FLAG specifies tiers information of the HEVC encoded picture. Tier
2469 were made to deal with applications that differ in terms of maximum bit
2470 rate. Setting the flag to 0 selects HEVC tier as Main tier and setting
2471 this flag to 1 indicates High tier. High tier is for applications requiring
2474 ================================== ==========
2475 ``V4L2_MPEG_VIDEO_HEVC_TIER_MAIN`` Main tier.
2476 ``V4L2_MPEG_VIDEO_HEVC_TIER_HIGH`` High tier.
2477 ================================== ==========
2480 ``V4L2_CID_MPEG_VIDEO_HEVC_MAX_PARTITION_DEPTH (integer)``
2481 Selects HEVC maximum coding unit depth.
2483 .. _v4l2-hevc-loop-filter-mode:
2485 ``V4L2_CID_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE``
2488 enum v4l2_mpeg_video_hevc_loop_filter_mode -
2489 Loop filter mode for HEVC encoder. Possible values are:
2495 .. tabularcolumns:: |p{12.1cm}|p{5.4cm}|
2501 * - ``V4L2_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE_DISABLED``
2502 - Loop filter is disabled.
2503 * - ``V4L2_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE_ENABLED``
2504 - Loop filter is enabled.
2505 * - ``V4L2_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY``
2506 - Loop filter is disabled at the slice boundary.
2513 ``V4L2_CID_MPEG_VIDEO_HEVC_LF_BETA_OFFSET_DIV2 (integer)``
2514 Selects HEVC loop filter beta offset. The valid range is [-6, +6].
2516 ``V4L2_CID_MPEG_VIDEO_HEVC_LF_TC_OFFSET_DIV2 (integer)``
2517 Selects HEVC loop filter tc offset. The valid range is [-6, +6].
2519 .. _v4l2-hevc-refresh-type:
2521 ``V4L2_CID_MPEG_VIDEO_HEVC_REFRESH_TYPE``
2524 enum v4l2_mpeg_video_hevc_hier_refresh_type -
2525 Selects refresh type for HEVC encoder.
2526 Host has to specify the period into
2527 V4L2_CID_MPEG_VIDEO_HEVC_REFRESH_PERIOD.
2533 .. tabularcolumns:: |p{6.2cm}|p{11.3cm}|
2539 * - ``V4L2_MPEG_VIDEO_HEVC_REFRESH_NONE``
2540 - Use the B frame for hierarchical coding.
2541 * - ``V4L2_MPEG_VIDEO_HEVC_REFRESH_CRA``
2542 - Use CRA (Clean Random Access Unit) picture encoding.
2543 * - ``V4L2_MPEG_VIDEO_HEVC_REFRESH_IDR``
2544 - Use IDR (Instantaneous Decoding Refresh) picture encoding.
2551 ``V4L2_CID_MPEG_VIDEO_HEVC_REFRESH_PERIOD (integer)``
2552 Selects the refresh period for HEVC encoder.
2553 This specifies the number of I pictures between two CRA/IDR pictures.
2554 This is valid only if REFRESH_TYPE is not 0.
2556 ``V4L2_CID_MPEG_VIDEO_HEVC_LOSSLESS_CU (boolean)``
2557 Indicates HEVC lossless encoding. Setting it to 0 disables lossless
2558 encoding. Setting it to 1 enables lossless encoding.
2560 ``V4L2_CID_MPEG_VIDEO_HEVC_CONST_INTRA_PRED (boolean)``
2561 Indicates constant intra prediction for HEVC encoder. Specifies the
2562 constrained intra prediction in which intra largest coding unit (LCU)
2563 prediction is performed by using residual data and decoded samples of
2564 neighboring intra LCU only. Setting the value to 1 enables constant intra
2565 prediction and setting the value to 0 disables constant intra prediction.
2567 ``V4L2_CID_MPEG_VIDEO_HEVC_WAVEFRONT (boolean)``
2568 Indicates wavefront parallel processing for HEVC encoder. Setting it to 0
2569 disables the feature and setting it to 1 enables the wavefront parallel
2572 ``V4L2_CID_MPEG_VIDEO_HEVC_GENERAL_PB (boolean)``
2573 Setting the value to 1 enables combination of P and B frame for HEVC
2576 ``V4L2_CID_MPEG_VIDEO_HEVC_TEMPORAL_ID (boolean)``
2577 Indicates temporal identifier for HEVC encoder which is enabled by
2578 setting the value to 1.
2580 ``V4L2_CID_MPEG_VIDEO_HEVC_STRONG_SMOOTHING (boolean)``
2581 Indicates bi-linear interpolation is conditionally used in the intra
2582 prediction filtering process in the CVS when set to 1. Indicates bi-linear
2583 interpolation is not used in the CVS when set to 0.
2585 ``V4L2_CID_MPEG_VIDEO_HEVC_MAX_NUM_MERGE_MV_MINUS1 (integer)``
2586 Indicates maximum number of merge candidate motion vectors.
2587 Values are from 0 to 4.
2589 ``V4L2_CID_MPEG_VIDEO_HEVC_TMV_PREDICTION (boolean)``
2590 Indicates temporal motion vector prediction for HEVC encoder. Setting it to
2591 1 enables the prediction. Setting it to 0 disables the prediction.
2593 ``V4L2_CID_MPEG_VIDEO_HEVC_WITHOUT_STARTCODE (boolean)``
2594 Specifies if HEVC generates a stream with a size of the length field
2595 instead of start code pattern. The size of the length field is configurable
2596 through the V4L2_CID_MPEG_VIDEO_HEVC_SIZE_OF_LENGTH_FIELD control. Setting
2597 the value to 0 disables encoding without startcode pattern. Setting the
2598 value to 1 will enables encoding without startcode pattern.
2600 .. _v4l2-hevc-size-of-length-field:
2602 ``V4L2_CID_MPEG_VIDEO_HEVC_SIZE_OF_LENGTH_FIELD``
2605 enum v4l2_mpeg_video_hevc_size_of_length_field -
2606 Indicates the size of length field.
2607 This is valid when encoding WITHOUT_STARTCODE_ENABLE is enabled.
2613 .. tabularcolumns:: |p{5.5cm}|p{12.0cm}|
2619 * - ``V4L2_MPEG_VIDEO_HEVC_SIZE_0``
2620 - Generate start code pattern (Normal).
2621 * - ``V4L2_MPEG_VIDEO_HEVC_SIZE_1``
2622 - Generate size of length field instead of start code pattern and length is 1.
2623 * - ``V4L2_MPEG_VIDEO_HEVC_SIZE_2``
2624 - Generate size of length field instead of start code pattern and length is 2.
2625 * - ``V4L2_MPEG_VIDEO_HEVC_SIZE_4``
2626 - Generate size of length field instead of start code pattern and length is 4.
2632 ``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L0_BR (integer)``
2633 Indicates bit rate for hierarchical coding layer 0 for HEVC encoder.
2635 ``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L1_BR (integer)``
2636 Indicates bit rate for hierarchical coding layer 1 for HEVC encoder.
2638 ``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L2_BR (integer)``
2639 Indicates bit rate for hierarchical coding layer 2 for HEVC encoder.
2641 ``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L3_BR (integer)``
2642 Indicates bit rate for hierarchical coding layer 3 for HEVC encoder.
2644 ``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L4_BR (integer)``
2645 Indicates bit rate for hierarchical coding layer 4 for HEVC encoder.
2647 ``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L5_BR (integer)``
2648 Indicates bit rate for hierarchical coding layer 5 for HEVC encoder.
2650 ``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L6_BR (integer)``
2651 Indicates bit rate for hierarchical coding layer 6 for HEVC encoder.
2653 ``V4L2_CID_MPEG_VIDEO_REF_NUMBER_FOR_PFRAMES (integer)``
2654 Selects number of P reference pictures required for HEVC encoder.
2655 P-Frame can use 1 or 2 frames for reference.
2657 ``V4L2_CID_MPEG_VIDEO_PREPEND_SPSPPS_TO_IDR (integer)``
2658 Indicates whether to generate SPS and PPS at every IDR. Setting it to 0
2659 disables generating SPS and PPS at every IDR. Setting it to one enables
2660 generating SPS and PPS at every IDR.
2664 ``V4L2_CID_STATELESS_HEVC_SPS (struct)``
2665 Specifies the Sequence Parameter Set fields (as extracted from the
2666 bitstream) for the associated HEVC slice data.
2667 These bitstream parameters are defined according to :ref:`hevc`.
2668 They are described in section 7.4.3.2 "Sequence parameter set RBSP
2669 semantics" of the specification.
2671 .. c:type:: v4l2_ctrl_hevc_sps
2677 .. tabularcolumns:: |p{1.2cm}|p{9.2cm}|p{6.9cm}|
2679 .. cssclass:: longtable
2681 .. flat-table:: struct v4l2_ctrl_hevc_sps
2687 - ``video_parameter_set_id``
2688 - Specifies the value of the vps_video_parameter_set_id of the active VPS
2689 as described in section "7.4.3.2.1 General sequence parameter set RBSP semantics"
2690 of H.265 specifications.
2692 - ``seq_parameter_set_id``
2693 - Provides an identifier for the SPS for reference by other syntax elements
2694 as described in section "7.4.3.2.1 General sequence parameter set RBSP semantics"
2695 of H.265 specifications.
2697 - ``pic_width_in_luma_samples``
2700 - ``pic_height_in_luma_samples``
2703 - ``bit_depth_luma_minus8``
2706 - ``bit_depth_chroma_minus8``
2709 - ``log2_max_pic_order_cnt_lsb_minus4``
2712 - ``sps_max_dec_pic_buffering_minus1``
2715 - ``sps_max_num_reorder_pics``
2718 - ``sps_max_latency_increase_plus1``
2721 - ``log2_min_luma_coding_block_size_minus3``
2724 - ``log2_diff_max_min_luma_coding_block_size``
2727 - ``log2_min_luma_transform_block_size_minus2``
2730 - ``log2_diff_max_min_luma_transform_block_size``
2733 - ``max_transform_hierarchy_depth_inter``
2736 - ``max_transform_hierarchy_depth_intra``
2739 - ``pcm_sample_bit_depth_luma_minus1``
2742 - ``pcm_sample_bit_depth_chroma_minus1``
2745 - ``log2_min_pcm_luma_coding_block_size_minus3``
2748 - ``log2_diff_max_min_pcm_luma_coding_block_size``
2751 - ``num_short_term_ref_pic_sets``
2754 - ``num_long_term_ref_pics_sps``
2757 - ``chroma_format_idc``
2760 - ``sps_max_sub_layers_minus1``
2764 - See :ref:`Sequence Parameter Set Flags <hevc_sps_flags>`
2772 ``Sequence Parameter Set Flags``
2778 .. cssclass:: longtable
2785 * - ``V4L2_HEVC_SPS_FLAG_SEPARATE_COLOUR_PLANE``
2788 * - ``V4L2_HEVC_SPS_FLAG_SCALING_LIST_ENABLED``
2791 * - ``V4L2_HEVC_SPS_FLAG_AMP_ENABLED``
2794 * - ``V4L2_HEVC_SPS_FLAG_SAMPLE_ADAPTIVE_OFFSET``
2797 * - ``V4L2_HEVC_SPS_FLAG_PCM_ENABLED``
2800 * - ``V4L2_HEVC_SPS_FLAG_PCM_LOOP_FILTER_DISABLED``
2803 * - ``V4L2_HEVC_SPS_FLAG_LONG_TERM_REF_PICS_PRESENT``
2806 * - ``V4L2_HEVC_SPS_FLAG_SPS_TEMPORAL_MVP_ENABLED``
2809 * - ``V4L2_HEVC_SPS_FLAG_STRONG_INTRA_SMOOTHING_ENABLED``
2817 ``V4L2_CID_STATELESS_HEVC_PPS (struct)``
2818 Specifies the Picture Parameter Set fields (as extracted from the
2819 bitstream) for the associated HEVC slice data.
2820 These bitstream parameters are defined according to :ref:`hevc`.
2821 They are described in section 7.4.3.3 "Picture parameter set RBSP
2822 semantics" of the specification.
2824 .. c:type:: v4l2_ctrl_hevc_pps
2826 .. tabularcolumns:: |p{1.2cm}|p{8.6cm}|p{7.5cm}|
2828 .. cssclass:: longtable
2830 .. flat-table:: struct v4l2_ctrl_hevc_pps
2836 - ``pic_parameter_set_id``
2837 - Identifies the PPS for reference by other syntax elements.
2839 - ``num_extra_slice_header_bits``
2842 - ``num_ref_idx_l0_default_active_minus1``
2843 - Specifies the inferred value of num_ref_idx_l0_active_minus1
2845 - ``num_ref_idx_l1_default_active_minus1``
2846 - Specifies the inferred value of num_ref_idx_l1_active_minus1
2848 - ``init_qp_minus26``
2851 - ``diff_cu_qp_delta_depth``
2854 - ``pps_cb_qp_offset``
2857 - ``pps_cr_qp_offset``
2860 - ``num_tile_columns_minus1``
2863 - ``num_tile_rows_minus1``
2866 - ``column_width_minus1[20]``
2869 - ``row_height_minus1[22]``
2872 - ``pps_beta_offset_div2``
2875 - ``pps_tc_offset_div2``
2878 - ``log2_parallel_merge_level_minus2``
2882 - Applications and drivers must set this to zero.
2885 - See :ref:`Picture Parameter Set Flags <hevc_pps_flags>`
2889 ``Picture Parameter Set Flags``
2900 * - ``V4L2_HEVC_PPS_FLAG_DEPENDENT_SLICE_SEGMENT_ENABLED``
2903 * - ``V4L2_HEVC_PPS_FLAG_OUTPUT_FLAG_PRESENT``
2906 * - ``V4L2_HEVC_PPS_FLAG_SIGN_DATA_HIDING_ENABLED``
2909 * - ``V4L2_HEVC_PPS_FLAG_CABAC_INIT_PRESENT``
2912 * - ``V4L2_HEVC_PPS_FLAG_CONSTRAINED_INTRA_PRED``
2915 * - ``V4L2_HEVC_PPS_FLAG_TRANSFORM_SKIP_ENABLED``
2918 * - ``V4L2_HEVC_PPS_FLAG_CU_QP_DELTA_ENABLED``
2921 * - ``V4L2_HEVC_PPS_FLAG_PPS_SLICE_CHROMA_QP_OFFSETS_PRESENT``
2924 * - ``V4L2_HEVC_PPS_FLAG_WEIGHTED_PRED``
2927 * - ``V4L2_HEVC_PPS_FLAG_WEIGHTED_BIPRED``
2930 * - ``V4L2_HEVC_PPS_FLAG_TRANSQUANT_BYPASS_ENABLED``
2933 * - ``V4L2_HEVC_PPS_FLAG_TILES_ENABLED``
2936 * - ``V4L2_HEVC_PPS_FLAG_ENTROPY_CODING_SYNC_ENABLED``
2939 * - ``V4L2_HEVC_PPS_FLAG_LOOP_FILTER_ACROSS_TILES_ENABLED``
2942 * - ``V4L2_HEVC_PPS_FLAG_PPS_LOOP_FILTER_ACROSS_SLICES_ENABLED``
2945 * - ``V4L2_HEVC_PPS_FLAG_DEBLOCKING_FILTER_OVERRIDE_ENABLED``
2948 * - ``V4L2_HEVC_PPS_FLAG_PPS_DISABLE_DEBLOCKING_FILTER``
2951 * - ``V4L2_HEVC_PPS_FLAG_LISTS_MODIFICATION_PRESENT``
2954 * - ``V4L2_HEVC_PPS_FLAG_SLICE_SEGMENT_HEADER_EXTENSION_PRESENT``
2957 * - ``V4L2_HEVC_PPS_FLAG_DEBLOCKING_FILTER_CONTROL_PRESENT``
2959 - Specifies the presence of deblocking filter control syntax elements in
2961 * - ``V4L2_HEVC_PPS_FLAG_UNIFORM_SPACING``
2963 - Specifies that tile column boundaries and likewise tile row boundaries
2964 are distributed uniformly across the picture
2970 ``V4L2_CID_STATELESS_HEVC_SLICE_PARAMS (struct)``
2971 Specifies various slice-specific parameters, especially from the NAL unit
2972 header, general slice segment header and weighted prediction parameter
2973 parts of the bitstream.
2974 These bitstream parameters are defined according to :ref:`hevc`.
2975 They are described in section 7.4.7 "General slice segment header
2976 semantics" of the specification.
2978 .. c:type:: v4l2_ctrl_hevc_slice_params
2984 .. tabularcolumns:: |p{5.4cm}|p{6.8cm}|p{5.1cm}|
2986 .. cssclass:: longtable
2988 .. flat-table:: struct v4l2_ctrl_hevc_slice_params
2995 - Size (in bits) of the current slice data.
2997 - ``data_bit_offset``
2998 - Offset (in bits) to the video data in the current slice data.
3003 - ``nuh_temporal_id_plus1``
3008 (V4L2_HEVC_SLICE_TYPE_I, V4L2_HEVC_SLICE_TYPE_P or
3009 V4L2_HEVC_SLICE_TYPE_B).
3011 - ``colour_plane_id``
3014 - ``slice_pic_order_cnt``
3017 - ``num_ref_idx_l0_active_minus1``
3020 - ``num_ref_idx_l1_active_minus1``
3023 - ``collocated_ref_idx``
3026 - ``five_minus_max_num_merge_cand``
3029 - ``slice_qp_delta``
3032 - ``slice_cb_qp_offset``
3035 - ``slice_cr_qp_offset``
3038 - ``slice_act_y_qp_offset``
3041 - ``slice_act_cb_qp_offset``
3044 - ``slice_act_cr_qp_offset``
3047 - ``slice_beta_offset_div2``
3050 - ``slice_tc_offset_div2``
3056 - ``slice_segment_addr``
3059 - ``ref_idx_l0[V4L2_HEVC_DPB_ENTRIES_NUM_MAX]``
3060 - The list of L0 reference elements as indices in the DPB.
3062 - ``ref_idx_l1[V4L2_HEVC_DPB_ENTRIES_NUM_MAX]``
3063 - The list of L1 reference elements as indices in the DPB.
3065 - ``short_term_ref_pic_set_size``
3066 - Specifies the size, in bits, of the short-term reference picture set, described as st_ref_pic_set()
3067 in the specification, included in the slice header or SPS (section 7.3.6.1).
3069 - ``long_term_ref_pic_set_size``
3070 - Specifies the size, in bits, of the long-term reference picture set include in the slice header
3071 or SPS. It is the number of bits in the conditional block if(long_term_ref_pics_present_flag)
3072 in section 7.3.6.1 of the specification.
3075 - Applications and drivers must set this to zero.
3076 * - struct :c:type:`v4l2_hevc_pred_weight_table`
3077 - ``pred_weight_table``
3078 - The prediction weight coefficients for inter-picture prediction.
3081 - See :ref:`Slice Parameters Flags <hevc_slice_params_flags>`
3087 .. _hevc_slice_params_flags:
3089 ``Slice Parameters Flags``
3100 * - ``V4L2_HEVC_SLICE_PARAMS_FLAG_SLICE_SAO_LUMA``
3103 * - ``V4L2_HEVC_SLICE_PARAMS_FLAG_SLICE_SAO_CHROMA``
3106 * - ``V4L2_HEVC_SLICE_PARAMS_FLAG_SLICE_TEMPORAL_MVP_ENABLED``
3109 * - ``V4L2_HEVC_SLICE_PARAMS_FLAG_MVD_L1_ZERO``
3112 * - ``V4L2_HEVC_SLICE_PARAMS_FLAG_CABAC_INIT``
3115 * - ``V4L2_HEVC_SLICE_PARAMS_FLAG_COLLOCATED_FROM_L0``
3118 * - ``V4L2_HEVC_SLICE_PARAMS_FLAG_USE_INTEGER_MV``
3121 * - ``V4L2_HEVC_SLICE_PARAMS_FLAG_SLICE_DEBLOCKING_FILTER_DISABLED``
3124 * - ``V4L2_HEVC_SLICE_PARAMS_FLAG_SLICE_LOOP_FILTER_ACROSS_SLICES_ENABLED``
3127 * - ``V4L2_HEVC_SLICE_PARAMS_FLAG_DEPENDENT_SLICE_SEGMENT``
3135 ``V4L2_CID_STATELESS_HEVC_SCALING_MATRIX (struct)``
3136 Specifies the HEVC scaling matrix parameters used for the scaling process
3137 for transform coefficients.
3138 These matrix and parameters are defined according to :ref:`hevc`.
3139 They are described in section 7.4.5 "Scaling list data semantics" of
3142 .. c:type:: v4l2_ctrl_hevc_scaling_matrix
3148 .. tabularcolumns:: |p{5.4cm}|p{6.8cm}|p{5.1cm}|
3150 .. cssclass:: longtable
3152 .. flat-table:: struct v4l2_ctrl_hevc_scaling_matrix
3158 - ``scaling_list_4x4[6][16]``
3159 - Scaling list is used for the scaling process for transform
3160 coefficients. The values on each scaling list are expected
3161 in raster scan order.
3163 - ``scaling_list_8x8[6][64]``
3164 - Scaling list is used for the scaling process for transform
3165 coefficients. The values on each scaling list are expected
3166 in raster scan order.
3168 - ``scaling_list_16x16[6][64]``
3169 - Scaling list is used for the scaling process for transform
3170 coefficients. The values on each scaling list are expected
3171 in raster scan order.
3173 - ``scaling_list_32x32[2][64]``
3174 - Scaling list is used for the scaling process for transform
3175 coefficients. The values on each scaling list are expected
3176 in raster scan order.
3178 - ``scaling_list_dc_coef_16x16[6]``
3179 - Scaling list is used for the scaling process for transform
3180 coefficients. The values on each scaling list are expected
3181 in raster scan order.
3183 - ``scaling_list_dc_coef_32x32[2]``
3184 - Scaling list is used for the scaling process for transform
3185 coefficients. The values on each scaling list are expected
3186 in raster scan order.
3192 .. c:type:: v4l2_hevc_dpb_entry
3198 .. tabularcolumns:: |p{1.0cm}|p{4.2cm}|p{12.1cm}|
3200 .. flat-table:: struct v4l2_hevc_dpb_entry
3207 - Timestamp of the V4L2 capture buffer to use as reference, used
3208 with B-coded and P-coded frames. The timestamp refers to the
3209 ``timestamp`` field in struct :c:type:`v4l2_buffer`. Use the
3210 :c:func:`v4l2_timeval_to_ns()` function to convert the struct
3211 :c:type:`timeval` in struct :c:type:`v4l2_buffer` to a __u64.
3214 - Long term flag for the reference frame
3215 (V4L2_HEVC_DPB_ENTRY_LONG_TERM_REFERENCE). The flag is set as
3216 described in the ITU HEVC specification chapter "8.3.2 Decoding
3217 process for reference picture set".
3220 - Whether the reference is a field picture or a frame.
3222 - ``pic_order_cnt[2]``
3223 - The picture order count of the reference. Only the first element of the
3224 array is used for frame pictures, while the first element identifies the
3225 top field and the second the bottom field in field-coded pictures.
3228 - Applications and drivers must set this to zero.
3234 .. c:type:: v4l2_hevc_pred_weight_table
3240 .. tabularcolumns:: |p{0.8cm}|p{10.6cm}|p{5.9cm}|
3242 .. flat-table:: struct v4l2_hevc_pred_weight_table
3248 - ``luma_log2_weight_denom``
3251 - ``delta_chroma_log2_weight_denom``
3254 - ``delta_luma_weight_l0[V4L2_HEVC_DPB_ENTRIES_NUM_MAX]``
3257 - ``luma_offset_l0[V4L2_HEVC_DPB_ENTRIES_NUM_MAX]``
3260 - ``delta_chroma_weight_l0[V4L2_HEVC_DPB_ENTRIES_NUM_MAX][2]``
3263 - ``chroma_offset_l0[V4L2_HEVC_DPB_ENTRIES_NUM_MAX][2]``
3266 - ``delta_luma_weight_l1[V4L2_HEVC_DPB_ENTRIES_NUM_MAX]``
3269 - ``luma_offset_l1[V4L2_HEVC_DPB_ENTRIES_NUM_MAX]``
3272 - ``delta_chroma_weight_l1[V4L2_HEVC_DPB_ENTRIES_NUM_MAX][2]``
3275 - ``chroma_offset_l1[V4L2_HEVC_DPB_ENTRIES_NUM_MAX][2]``
3279 - Applications and drivers must set this to zero.
3285 ``V4L2_CID_STATELESS_HEVC_DECODE_MODE (enum)``
3286 Specifies the decoding mode to use. Currently exposes slice-based and
3287 frame-based decoding but new modes might be added later on.
3288 This control is used as a modifier for V4L2_PIX_FMT_HEVC_SLICE
3289 pixel format. Applications that support V4L2_PIX_FMT_HEVC_SLICE
3290 are required to set this control in order to specify the decoding mode
3291 that is expected for the buffer.
3292 Drivers may expose a single or multiple decoding modes, depending
3293 on what they can support.
3297 This menu control is not yet part of the public kernel API and
3298 it is expected to change.
3300 .. c:type:: v4l2_stateless_hevc_decode_mode
3306 .. tabularcolumns:: |p{9.4cm}|p{0.6cm}|p{7.3cm}|
3313 * - ``V4L2_STATELESS_HEVC_DECODE_MODE_SLICE_BASED``
3315 - Decoding is done at the slice granularity.
3316 The OUTPUT buffer must contain a single slice.
3317 * - ``V4L2_STATELESS_HEVC_DECODE_MODE_FRAME_BASED``
3319 - Decoding is done at the frame granularity.
3320 The OUTPUT buffer must contain all slices needed to decode the
3321 frame. The OUTPUT buffer must also contain both fields.
3327 ``V4L2_CID_STATELESS_HEVC_START_CODE (enum)``
3328 Specifies the HEVC slice start code expected for each slice.
3329 This control is used as a modifier for V4L2_PIX_FMT_HEVC_SLICE
3330 pixel format. Applications that support V4L2_PIX_FMT_HEVC_SLICE
3331 are required to set this control in order to specify the start code
3332 that is expected for the buffer.
3333 Drivers may expose a single or multiple start codes, depending
3334 on what they can support.
3338 This menu control is not yet part of the public kernel API and
3339 it is expected to change.
3341 .. c:type:: v4l2_stateless_hevc_start_code
3343 .. tabularcolumns:: |p{9.2cm}|p{0.6cm}|p{7.5cm}|
3350 * - ``V4L2_STATELESS_HEVC_START_CODE_NONE``
3352 - Selecting this value specifies that HEVC slices are passed
3353 to the driver without any start code. The bitstream data should be
3354 according to :ref:`hevc` 7.3.1.1 General NAL unit syntax, hence
3355 contains emulation prevention bytes when required.
3356 * - ``V4L2_STATELESS_HEVC_START_CODE_ANNEX_B``
3358 - Selecting this value specifies that HEVC slices are expected
3359 to be prefixed by Annex B start codes. According to :ref:`hevc`
3360 valid start codes can be 3-bytes 0x000001 or 4-bytes 0x00000001.
3362 ``V4L2_CID_MPEG_VIDEO_BASELAYER_PRIORITY_ID (integer)``
3363 Specifies a priority identifier for the NAL unit, which will be applied to
3364 the base layer. By default this value is set to 0 for the base layer,
3365 and the next layer will have the priority ID assigned as 1, 2, 3 and so on.
3366 The video encoder can't decide the priority id to be applied to a layer,
3367 so this has to come from client.
3368 This is applicable to H264 and valid Range is from 0 to 63.
3369 Source Rec. ITU-T H.264 (06/2019); G.7.4.1.1, G.8.8.1.
3371 ``V4L2_CID_MPEG_VIDEO_LTR_COUNT (integer)``
3372 Specifies the maximum number of Long Term Reference (LTR) frames at any
3373 given time that the encoder can keep.
3374 This is applicable to the H264 and HEVC encoders.
3376 ``V4L2_CID_MPEG_VIDEO_FRAME_LTR_INDEX (integer)``
3377 After setting this control the frame that will be queued next
3378 will be marked as a Long Term Reference (LTR) frame
3379 and given this LTR index which ranges from 0 to LTR_COUNT-1.
3380 This is applicable to the H264 and HEVC encoders.
3381 Source Rec. ITU-T H.264 (06/2019); Table 7.9
3383 ``V4L2_CID_MPEG_VIDEO_USE_LTR_FRAMES (bitmask)``
3384 Specifies the Long Term Reference (LTR) frame(s) to be used for
3385 encoding the next frame queued after setting this control.
3386 This provides a bitmask which consists of bits [0, LTR_COUNT-1].
3387 This is applicable to the H264 and HEVC encoders.
3389 ``V4L2_CID_STATELESS_HEVC_DECODE_PARAMS (struct)``
3390 Specifies various decode parameters, especially the references picture order
3391 count (POC) for all the lists (short, long, before, current, after) and the
3392 number of entries for each of them.
3393 These parameters are defined according to :ref:`hevc`.
3394 They are described in section 8.3 "Slice decoding process" of the
3397 .. c:type:: v4l2_ctrl_hevc_decode_params
3399 .. cssclass:: longtable
3401 .. flat-table:: struct v4l2_ctrl_hevc_decode_params
3407 - ``pic_order_cnt_val``
3408 - PicOrderCntVal as described in section 8.3.1 "Decoding process
3409 for picture order count" of the specification.
3411 - ``short_term_ref_pic_set_size``
3412 - Specifies the size, in bits, of the short-term reference picture set, of the first slice
3413 described as st_ref_pic_set() in the specification, included in the slice header
3414 or SPS (section 7.3.6.1).
3416 - ``long_term_ref_pic_set_size``
3417 - Specifies the size, in bits, of the long-term reference picture set, of the first slice
3418 included in the slice header or SPS. It is the number of bits in the conditional block
3419 if(long_term_ref_pics_present_flag) in section 7.3.6.1 of the specification.
3421 - ``num_active_dpb_entries``
3422 - The number of entries in ``dpb``.
3423 * - struct :c:type:`v4l2_hevc_dpb_entry`
3424 - ``dpb[V4L2_HEVC_DPB_ENTRIES_NUM_MAX]``
3425 - The decoded picture buffer, for meta-data about reference frames.
3427 - ``num_poc_st_curr_before``
3428 - The number of reference pictures in the short-term set that come before
3431 - ``num_poc_st_curr_after``
3432 - The number of reference pictures in the short-term set that come after
3435 - ``num_poc_lt_curr``
3436 - The number of reference pictures in the long-term set.
3438 - ``poc_st_curr_before[V4L2_HEVC_DPB_ENTRIES_NUM_MAX]``
3439 - PocStCurrBefore as described in section 8.3.2 "Decoding process for reference
3440 picture set": provides the index of the short term before references in DPB array.
3442 - ``poc_st_curr_after[V4L2_HEVC_DPB_ENTRIES_NUM_MAX]``
3443 - PocStCurrAfter as described in section 8.3.2 "Decoding process for reference
3444 picture set": provides the index of the short term after references in DPB array.
3446 - ``poc_lt_curr[V4L2_HEVC_DPB_ENTRIES_NUM_MAX]``
3447 - PocLtCurr as described in section 8.3.2 "Decoding process for reference
3448 picture set": provides the index of the long term references in DPB array.
3451 - See :ref:`Decode Parameters Flags <hevc_decode_params_flags>`
3453 .. _hevc_decode_params_flags:
3455 ``Decode Parameters Flags``
3457 .. cssclass:: longtable
3464 * - ``V4L2_HEVC_DECODE_PARAM_FLAG_IRAP_PIC``
3467 * - ``V4L2_HEVC_DECODE_PARAM_FLAG_IDR_PIC``
3470 * - ``V4L2_HEVC_DECODE_PARAM_FLAG_NO_OUTPUT_OF_PRIOR``