From patchwork Sat Mar 13 14:43:09 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans Verkuil X-Patchwork-Id: 400256 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-18.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER, INCLUDES_PATCH, MAILING_LIST_MULTI, SPF_HELO_NONE, SPF_PASS, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 36C45C433E6 for ; Sat, 13 Mar 2021 14:44:26 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 066B964F26 for ; Sat, 13 Mar 2021 14:44:26 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234051AbhCMOnt (ORCPT ); Sat, 13 Mar 2021 09:43:49 -0500 Received: from lb1-smtp-cloud9.xs4all.net ([194.109.24.22]:39887 "EHLO lb1-smtp-cloud9.xs4all.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234014AbhCMOn2 (ORCPT ); Sat, 13 Mar 2021 09:43:28 -0500 Received: from cust-b5b5937f ([IPv6:fc0c:c16d:66b8:757f:c639:739b:9d66:799d]) by smtp-cloud9.xs4all.net with ESMTPA id L5UBljyoWC40pL5UFlV5cV; Sat, 13 Mar 2021 15:43:27 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=xs4all.nl; s=s2; t=1615646607; bh=jKdVJI+q0U6oMvWn83VF0vu1qbM3ykBj/enzfRyJLoE=; h=From:To:Subject:Date:Message-Id:MIME-Version:From:Subject; b=PfTbscATwPWZAkf19lPJwrcpL1ZS6+beCHBbhoov46LBqtjDMwYNeIxe8ydP3LUv6 FcXOj3cQmB6XjZq9PiFzCWGRy+Kvf5vtlsbH1TQ/GSV5zjgA2TAptlr/Ou84prUBJM ZPhteBvjFjVJFaTilx2wjML4nRzGJMgE3WsiIukB7pQyuDZ7xmed1XCDYEW2s3a5xY gJZ+nIgS5/BDojw3tg4kI4wwo0x2wlxb7+2kYjDf5HwJk/+Q+NAEphMLSBt4dF4GL1 lJ5IYt1RWjVl+ldfWzkYJb2uZXHZau5rVPErNg9/QYF7y8iRJfIpT+xTonI44HA4qg v4f+d327mGrwQ== From: Hans Verkuil To: linux-media@vger.kernel.org Cc: Ezequiel Garcia , Nicolas Dufresne , Tomasz Figa , Alexandre Courbot , Hans Verkuil Subject: [PATCH 01/15] ext-ctrls-codec.rst: fix typos Date: Sat, 13 Mar 2021 15:43:09 +0100 Message-Id: <20210313144323.143600-2-hverkuil-cisco@xs4all.nl> X-Mailer: git-send-email 2.30.1 In-Reply-To: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> References: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> MIME-Version: 1.0 X-CMAE-Envelope: MS4xfC6oyS35tArlVT3Tnt89cA2C4XNyiVAN7tzIh2jmRj56uarUG0Tiv/X88SAJj0ej6pZYerU9UVVbFdMNCl+eVw8QIESNcP7LB7Y4odaF7qNzoRGvPBO2 3fujnFXXO2XzoCVsZVR3qlBIucI5Q6rHGdSuG9u7riMOpBaUAQmGJzw3YSXkcWU3TzNhpNWPYGruNR+B0BuDzk88WrNbFEf5Ddzqm2l/1iXQ/Ers2/swnYaV A4lja3B5a4mCB3vk6mEHS/qoDF44xmpJB9YTFZXTYojTbI3o+ltxWrrBPU982DNTLFoq6UuUmmyfAoYEqOPnuwxg12YW9xL7iexvbNmw2k4CCsPQnSAt8jOV uR1TxR/woqu3Yw/Ky/q78yWBikpEYw== Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org The _FRAME_SKIP_ enums were missing the _VIDEO prefix. Signed-off-by: Hans Verkuil --- .../userspace-api/media/v4l/ext-ctrls-codec.rst | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst b/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst index 7ee8ae073b91..e2d7c4a87fea 100644 --- a/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst +++ b/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst @@ -615,12 +615,12 @@ enum v4l2_mpeg_video_frame_skip_mode - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_FRAME_SKIP_MODE_DISABLED`` + * - ``V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_DISABLED`` - Frame skip mode is disabled. - * - ``V4L2_MPEG_FRAME_SKIP_MODE_LEVEL_LIMIT`` + * - ``V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_LEVEL_LIMIT`` - Frame skip mode enabled and buffer limit is set by the chosen level and is defined by the standard. - * - ``V4L2_MPEG_FRAME_SKIP_MODE_BUF_LIMIT`` + * - ``V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT`` - Frame skip mode enabled and buffer limit is set by the :ref:`VBV (MPEG1/2/4) ` or :ref:`CPB (H264) buffer size ` control. @@ -2244,12 +2244,12 @@ enum v4l2_mpeg_mfc51_video_frame_skip_mode - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_MFC51_FRAME_SKIP_MODE_DISABLED`` + * - ``V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_DISABLED`` - Frame skip mode is disabled. - * - ``V4L2_MPEG_MFC51_FRAME_SKIP_MODE_LEVEL_LIMIT`` + * - ``V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_LEVEL_LIMIT`` - Frame skip mode enabled and buffer limit is set by the chosen level and is defined by the standard. - * - ``V4L2_MPEG_MFC51_FRAME_SKIP_MODE_BUF_LIMIT`` + * - ``V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT`` - Frame skip mode enabled and buffer limit is set by the VBV (MPEG1/2/4) or CPB (H264) buffer size control. From patchwork Sat Mar 13 14:43:10 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans Verkuil X-Patchwork-Id: 399847 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-15.9 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, UNWANTED_LANGUAGE_BODY,UPPERCASE_50_75,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6D18CC43381 for ; Sat, 13 Mar 2021 14:44:26 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 3D4ED64F18 for ; Sat, 13 Mar 2021 14:44:26 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234058AbhCMOnu (ORCPT ); Sat, 13 Mar 2021 09:43:50 -0500 Received: from lb2-smtp-cloud9.xs4all.net ([194.109.24.26]:43711 "EHLO lb2-smtp-cloud9.xs4all.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234015AbhCMOn3 (ORCPT ); Sat, 13 Mar 2021 09:43:29 -0500 Received: from cust-b5b5937f ([IPv6:fc0c:c16d:66b8:757f:c639:739b:9d66:799d]) by smtp-cloud9.xs4all.net with ESMTPA id L5UBljyoWC40pL5UFlV5cg; Sat, 13 Mar 2021 15:43:27 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=xs4all.nl; s=s2; t=1615646607; bh=1Oy/mwVEGqWNhgntb7NxBNYCPyp4Oi/R43Ehbr9520Q=; h=From:To:Subject:Date:Message-Id:MIME-Version:From:Subject; b=L8xOZNZEel8rOwXTvcQfTMYpSohBwKygmCFodtVBFU8QH9Wcu6ZDvCXqQTtmfmZRv NguEe4GwfSX++4cglkkMchfh2knBajQ+hElTwYwEi3WOi7Ip0Eo0RsA1VClFHnObOM pPueqechzIAEZPmM/sMzKJjXRcEYX2bUo9Cmql3JZzMagwlSA5gJc5YQ9cDjuS4CEr 4gsq9w6jEzD4biSAOEaPfNkj9IGQj2lKpELaPIb2hQOqRYKCWbz7GW8S3gT9kOiCg1 YL5juDNHhVFhds7fG7zOrsJ6f2F27lPZPXWdcClSzr+HfWxyZvbdaQsz3gkJM+lep6 9uekGd6dSXIAg== From: Hans Verkuil To: linux-media@vger.kernel.org Cc: Ezequiel Garcia , Nicolas Dufresne , Tomasz Figa , Alexandre Courbot , Hans Verkuil Subject: [PATCH 02/15] v4l2-controls.h: rename _MPEG_ to _CODEC_ Date: Sat, 13 Mar 2021 15:43:10 +0100 Message-Id: <20210313144323.143600-3-hverkuil-cisco@xs4all.nl> X-Mailer: git-send-email 2.30.1 In-Reply-To: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> References: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> MIME-Version: 1.0 X-CMAE-Envelope: MS4xfC6oyS35tArlVT3Tnt89cA2C4XNyiVAN7tzIh2jmRj56uarUG0Tiv/X88SAJj0ej6pZYerU9UVVbFdMNCl+eVw8QIESNcP7LB7Y4odaF7qNzoRGvPBO2 3fujnFXXO2XzoCVsZVR3qlBIucI5Q6rHGdSuG9u7riMOpBaUAQmGJzw3YSXkcWU3TzNhpNWPYGruNR+B0BuDzk88WrNbFEf5Ddzqm2l/1iXQ/Ers2/swnYaV A4lja3B5a4mCB3vk6mEHS/qoDF44xmpJB9YTFZXTYojTbI3o+ltxWrrBPU982DNTLFoq6UuUmmyfAoYEqOPnuwxg12YW9xL7iexvbNmw2k4CCsPQnSAt8jOV uR1TxR/woqu3Yw/Ky/q78yWBikpEYw== Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org The first codec that was supported in V4L2 was the MPEG codec. As a result of that all codec controls and related data structures where all prefixed with MPEG. This is confusing and in fact makes it hard to find the MPEG-specific controls since all controls have 'MPEG' in their name. This patch renames all controls and data structures to use CODEC instead of MPEG, and adds defines for compatibility at the end. Eventually those compatibility defines would come under #ifndef __KERNEL__ to ensure that the kernel code can't use those anymore, but that can only be done once the use of the old names has been removed from the kernel. This patch has no functional changes, only renames and the addition of compatibility defines at the end. Signed-off-by: Hans Verkuil --- include/uapi/linux/v4l2-controls.h | 1819 ++++++++++++++++++---------- 1 file changed, 1191 insertions(+), 628 deletions(-) diff --git a/include/uapi/linux/v4l2-controls.h b/include/uapi/linux/v4l2-controls.h index 61441c250239..2e8d450495fa 100644 --- a/include/uapi/linux/v4l2-controls.h +++ b/include/uapi/linux/v4l2-controls.h @@ -210,662 +210,657 @@ enum v4l2_colorfx { */ #define V4L2_CID_USER_CCS_BASE (V4L2_CID_USER_BASE + 0x10f0) -/* MPEG-class control IDs */ -/* The MPEG controls are applicable to all codec controls - * and the 'MPEG' part of the define is historical */ +/* Codec-class control IDs */ #define V4L2_CID_CODEC_BASE (V4L2_CTRL_CLASS_CODEC | 0x900) #define V4L2_CID_CODEC_CLASS (V4L2_CTRL_CLASS_CODEC | 1) -/* MPEG streams, specific to multiplexed streams */ -#define V4L2_CID_MPEG_STREAM_TYPE (V4L2_CID_CODEC_BASE+0) -enum v4l2_mpeg_stream_type { - V4L2_MPEG_STREAM_TYPE_MPEG2_PS = 0, /* MPEG-2 program stream */ - V4L2_MPEG_STREAM_TYPE_MPEG2_TS = 1, /* MPEG-2 transport stream */ - V4L2_MPEG_STREAM_TYPE_MPEG1_SS = 2, /* MPEG-1 system stream */ - V4L2_MPEG_STREAM_TYPE_MPEG2_DVD = 3, /* MPEG-2 DVD-compatible stream */ - V4L2_MPEG_STREAM_TYPE_MPEG1_VCD = 4, /* MPEG-1 VCD-compatible stream */ - V4L2_MPEG_STREAM_TYPE_MPEG2_SVCD = 5, /* MPEG-2 SVCD-compatible stream */ -}; -#define V4L2_CID_MPEG_STREAM_PID_PMT (V4L2_CID_CODEC_BASE+1) -#define V4L2_CID_MPEG_STREAM_PID_AUDIO (V4L2_CID_CODEC_BASE+2) -#define V4L2_CID_MPEG_STREAM_PID_VIDEO (V4L2_CID_CODEC_BASE+3) -#define V4L2_CID_MPEG_STREAM_PID_PCR (V4L2_CID_CODEC_BASE+4) -#define V4L2_CID_MPEG_STREAM_PES_ID_AUDIO (V4L2_CID_CODEC_BASE+5) -#define V4L2_CID_MPEG_STREAM_PES_ID_VIDEO (V4L2_CID_CODEC_BASE+6) -#define V4L2_CID_MPEG_STREAM_VBI_FMT (V4L2_CID_CODEC_BASE+7) -enum v4l2_mpeg_stream_vbi_fmt { - V4L2_MPEG_STREAM_VBI_FMT_NONE = 0, /* No VBI in the MPEG stream */ - V4L2_MPEG_STREAM_VBI_FMT_IVTV = 1, /* VBI in private packets, IVTV format */ -}; - -/* MPEG audio controls specific to multiplexed streams */ -#define V4L2_CID_MPEG_AUDIO_SAMPLING_FREQ (V4L2_CID_CODEC_BASE+100) -enum v4l2_mpeg_audio_sampling_freq { - V4L2_MPEG_AUDIO_SAMPLING_FREQ_44100 = 0, - V4L2_MPEG_AUDIO_SAMPLING_FREQ_48000 = 1, - V4L2_MPEG_AUDIO_SAMPLING_FREQ_32000 = 2, -}; -#define V4L2_CID_MPEG_AUDIO_ENCODING (V4L2_CID_CODEC_BASE+101) -enum v4l2_mpeg_audio_encoding { - V4L2_MPEG_AUDIO_ENCODING_LAYER_1 = 0, - V4L2_MPEG_AUDIO_ENCODING_LAYER_2 = 1, - V4L2_MPEG_AUDIO_ENCODING_LAYER_3 = 2, - V4L2_MPEG_AUDIO_ENCODING_AAC = 3, - V4L2_MPEG_AUDIO_ENCODING_AC3 = 4, -}; -#define V4L2_CID_MPEG_AUDIO_L1_BITRATE (V4L2_CID_CODEC_BASE+102) -enum v4l2_mpeg_audio_l1_bitrate { - V4L2_MPEG_AUDIO_L1_BITRATE_32K = 0, - V4L2_MPEG_AUDIO_L1_BITRATE_64K = 1, - V4L2_MPEG_AUDIO_L1_BITRATE_96K = 2, - V4L2_MPEG_AUDIO_L1_BITRATE_128K = 3, - V4L2_MPEG_AUDIO_L1_BITRATE_160K = 4, - V4L2_MPEG_AUDIO_L1_BITRATE_192K = 5, - V4L2_MPEG_AUDIO_L1_BITRATE_224K = 6, - V4L2_MPEG_AUDIO_L1_BITRATE_256K = 7, - V4L2_MPEG_AUDIO_L1_BITRATE_288K = 8, - V4L2_MPEG_AUDIO_L1_BITRATE_320K = 9, - V4L2_MPEG_AUDIO_L1_BITRATE_352K = 10, - V4L2_MPEG_AUDIO_L1_BITRATE_384K = 11, - V4L2_MPEG_AUDIO_L1_BITRATE_416K = 12, - V4L2_MPEG_AUDIO_L1_BITRATE_448K = 13, -}; -#define V4L2_CID_MPEG_AUDIO_L2_BITRATE (V4L2_CID_CODEC_BASE+103) -enum v4l2_mpeg_audio_l2_bitrate { - V4L2_MPEG_AUDIO_L2_BITRATE_32K = 0, - V4L2_MPEG_AUDIO_L2_BITRATE_48K = 1, - V4L2_MPEG_AUDIO_L2_BITRATE_56K = 2, - V4L2_MPEG_AUDIO_L2_BITRATE_64K = 3, - V4L2_MPEG_AUDIO_L2_BITRATE_80K = 4, - V4L2_MPEG_AUDIO_L2_BITRATE_96K = 5, - V4L2_MPEG_AUDIO_L2_BITRATE_112K = 6, - V4L2_MPEG_AUDIO_L2_BITRATE_128K = 7, - V4L2_MPEG_AUDIO_L2_BITRATE_160K = 8, - V4L2_MPEG_AUDIO_L2_BITRATE_192K = 9, - V4L2_MPEG_AUDIO_L2_BITRATE_224K = 10, - V4L2_MPEG_AUDIO_L2_BITRATE_256K = 11, - V4L2_MPEG_AUDIO_L2_BITRATE_320K = 12, - V4L2_MPEG_AUDIO_L2_BITRATE_384K = 13, -}; -#define V4L2_CID_MPEG_AUDIO_L3_BITRATE (V4L2_CID_CODEC_BASE+104) -enum v4l2_mpeg_audio_l3_bitrate { - V4L2_MPEG_AUDIO_L3_BITRATE_32K = 0, - V4L2_MPEG_AUDIO_L3_BITRATE_40K = 1, - V4L2_MPEG_AUDIO_L3_BITRATE_48K = 2, - V4L2_MPEG_AUDIO_L3_BITRATE_56K = 3, - V4L2_MPEG_AUDIO_L3_BITRATE_64K = 4, - V4L2_MPEG_AUDIO_L3_BITRATE_80K = 5, - V4L2_MPEG_AUDIO_L3_BITRATE_96K = 6, - V4L2_MPEG_AUDIO_L3_BITRATE_112K = 7, - V4L2_MPEG_AUDIO_L3_BITRATE_128K = 8, - V4L2_MPEG_AUDIO_L3_BITRATE_160K = 9, - V4L2_MPEG_AUDIO_L3_BITRATE_192K = 10, - V4L2_MPEG_AUDIO_L3_BITRATE_224K = 11, - V4L2_MPEG_AUDIO_L3_BITRATE_256K = 12, - V4L2_MPEG_AUDIO_L3_BITRATE_320K = 13, -}; -#define V4L2_CID_MPEG_AUDIO_MODE (V4L2_CID_CODEC_BASE+105) -enum v4l2_mpeg_audio_mode { - V4L2_MPEG_AUDIO_MODE_STEREO = 0, - V4L2_MPEG_AUDIO_MODE_JOINT_STEREO = 1, - V4L2_MPEG_AUDIO_MODE_DUAL = 2, - V4L2_MPEG_AUDIO_MODE_MONO = 3, -}; -#define V4L2_CID_MPEG_AUDIO_MODE_EXTENSION (V4L2_CID_CODEC_BASE+106) -enum v4l2_mpeg_audio_mode_extension { - V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_4 = 0, - V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_8 = 1, - V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_12 = 2, - V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_16 = 3, -}; -#define V4L2_CID_MPEG_AUDIO_EMPHASIS (V4L2_CID_CODEC_BASE+107) -enum v4l2_mpeg_audio_emphasis { - V4L2_MPEG_AUDIO_EMPHASIS_NONE = 0, - V4L2_MPEG_AUDIO_EMPHASIS_50_DIV_15_uS = 1, - V4L2_MPEG_AUDIO_EMPHASIS_CCITT_J17 = 2, -}; -#define V4L2_CID_MPEG_AUDIO_CRC (V4L2_CID_CODEC_BASE+108) -enum v4l2_mpeg_audio_crc { - V4L2_MPEG_AUDIO_CRC_NONE = 0, - V4L2_MPEG_AUDIO_CRC_CRC16 = 1, -}; -#define V4L2_CID_MPEG_AUDIO_MUTE (V4L2_CID_CODEC_BASE+109) -#define V4L2_CID_MPEG_AUDIO_AAC_BITRATE (V4L2_CID_CODEC_BASE+110) -#define V4L2_CID_MPEG_AUDIO_AC3_BITRATE (V4L2_CID_CODEC_BASE+111) -enum v4l2_mpeg_audio_ac3_bitrate { - V4L2_MPEG_AUDIO_AC3_BITRATE_32K = 0, - V4L2_MPEG_AUDIO_AC3_BITRATE_40K = 1, - V4L2_MPEG_AUDIO_AC3_BITRATE_48K = 2, - V4L2_MPEG_AUDIO_AC3_BITRATE_56K = 3, - V4L2_MPEG_AUDIO_AC3_BITRATE_64K = 4, - V4L2_MPEG_AUDIO_AC3_BITRATE_80K = 5, - V4L2_MPEG_AUDIO_AC3_BITRATE_96K = 6, - V4L2_MPEG_AUDIO_AC3_BITRATE_112K = 7, - V4L2_MPEG_AUDIO_AC3_BITRATE_128K = 8, - V4L2_MPEG_AUDIO_AC3_BITRATE_160K = 9, - V4L2_MPEG_AUDIO_AC3_BITRATE_192K = 10, - V4L2_MPEG_AUDIO_AC3_BITRATE_224K = 11, - V4L2_MPEG_AUDIO_AC3_BITRATE_256K = 12, - V4L2_MPEG_AUDIO_AC3_BITRATE_320K = 13, - V4L2_MPEG_AUDIO_AC3_BITRATE_384K = 14, - V4L2_MPEG_AUDIO_AC3_BITRATE_448K = 15, - V4L2_MPEG_AUDIO_AC3_BITRATE_512K = 16, - V4L2_MPEG_AUDIO_AC3_BITRATE_576K = 17, - V4L2_MPEG_AUDIO_AC3_BITRATE_640K = 18, -}; -#define V4L2_CID_MPEG_AUDIO_DEC_PLAYBACK (V4L2_CID_CODEC_BASE+112) -enum v4l2_mpeg_audio_dec_playback { - V4L2_MPEG_AUDIO_DEC_PLAYBACK_AUTO = 0, - V4L2_MPEG_AUDIO_DEC_PLAYBACK_STEREO = 1, - V4L2_MPEG_AUDIO_DEC_PLAYBACK_LEFT = 2, - V4L2_MPEG_AUDIO_DEC_PLAYBACK_RIGHT = 3, - V4L2_MPEG_AUDIO_DEC_PLAYBACK_MONO = 4, - V4L2_MPEG_AUDIO_DEC_PLAYBACK_SWAPPED_STEREO = 5, -}; -#define V4L2_CID_MPEG_AUDIO_DEC_MULTILINGUAL_PLAYBACK (V4L2_CID_CODEC_BASE+113) - -/* MPEG video controls specific to multiplexed streams */ -#define V4L2_CID_MPEG_VIDEO_ENCODING (V4L2_CID_CODEC_BASE+200) -enum v4l2_mpeg_video_encoding { - V4L2_MPEG_VIDEO_ENCODING_MPEG_1 = 0, - V4L2_MPEG_VIDEO_ENCODING_MPEG_2 = 1, - V4L2_MPEG_VIDEO_ENCODING_MPEG_4_AVC = 2, -}; -#define V4L2_CID_MPEG_VIDEO_ASPECT (V4L2_CID_CODEC_BASE+201) -enum v4l2_mpeg_video_aspect { - V4L2_MPEG_VIDEO_ASPECT_1x1 = 0, - V4L2_MPEG_VIDEO_ASPECT_4x3 = 1, - V4L2_MPEG_VIDEO_ASPECT_16x9 = 2, - V4L2_MPEG_VIDEO_ASPECT_221x100 = 3, -}; -#define V4L2_CID_MPEG_VIDEO_B_FRAMES (V4L2_CID_CODEC_BASE+202) -#define V4L2_CID_MPEG_VIDEO_GOP_SIZE (V4L2_CID_CODEC_BASE+203) -#define V4L2_CID_MPEG_VIDEO_GOP_CLOSURE (V4L2_CID_CODEC_BASE+204) -#define V4L2_CID_MPEG_VIDEO_PULLDOWN (V4L2_CID_CODEC_BASE+205) -#define V4L2_CID_MPEG_VIDEO_BITRATE_MODE (V4L2_CID_CODEC_BASE+206) -enum v4l2_mpeg_video_bitrate_mode { - V4L2_MPEG_VIDEO_BITRATE_MODE_VBR = 0, - V4L2_MPEG_VIDEO_BITRATE_MODE_CBR = 1, - V4L2_MPEG_VIDEO_BITRATE_MODE_CQ = 2, -}; -#define V4L2_CID_MPEG_VIDEO_BITRATE (V4L2_CID_CODEC_BASE+207) -#define V4L2_CID_MPEG_VIDEO_BITRATE_PEAK (V4L2_CID_CODEC_BASE+208) -#define V4L2_CID_MPEG_VIDEO_TEMPORAL_DECIMATION (V4L2_CID_CODEC_BASE+209) -#define V4L2_CID_MPEG_VIDEO_MUTE (V4L2_CID_CODEC_BASE+210) -#define V4L2_CID_MPEG_VIDEO_MUTE_YUV (V4L2_CID_CODEC_BASE+211) -#define V4L2_CID_MPEG_VIDEO_DECODER_SLICE_INTERFACE (V4L2_CID_CODEC_BASE+212) -#define V4L2_CID_MPEG_VIDEO_DECODER_MPEG4_DEBLOCK_FILTER (V4L2_CID_CODEC_BASE+213) -#define V4L2_CID_MPEG_VIDEO_CYCLIC_INTRA_REFRESH_MB (V4L2_CID_CODEC_BASE+214) -#define V4L2_CID_MPEG_VIDEO_FRAME_RC_ENABLE (V4L2_CID_CODEC_BASE+215) -#define V4L2_CID_MPEG_VIDEO_HEADER_MODE (V4L2_CID_CODEC_BASE+216) -enum v4l2_mpeg_video_header_mode { - V4L2_MPEG_VIDEO_HEADER_MODE_SEPARATE = 0, - V4L2_MPEG_VIDEO_HEADER_MODE_JOINED_WITH_1ST_FRAME = 1, - -}; -#define V4L2_CID_MPEG_VIDEO_MAX_REF_PIC (V4L2_CID_CODEC_BASE+217) -#define V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE (V4L2_CID_CODEC_BASE+218) -#define V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MAX_BYTES (V4L2_CID_CODEC_BASE+219) -#define V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MAX_MB (V4L2_CID_CODEC_BASE+220) -#define V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MODE (V4L2_CID_CODEC_BASE+221) -enum v4l2_mpeg_video_multi_slice_mode { - V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_SINGLE = 0, - V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_MB = 1, - V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_BYTES = 2, +/* Codec streams, specific to multiplexed streams */ +#define V4L2_CID_CODEC_STREAM_TYPE (V4L2_CID_CODEC_BASE+0) +enum v4l2_codec_stream_type { + V4L2_CODEC_STREAM_TYPE_MPEG2_PS = 0, /* MPEG-2 program stream */ + V4L2_CODEC_STREAM_TYPE_MPEG2_TS = 1, /* MPEG-2 transport stream */ + V4L2_CODEC_STREAM_TYPE_MPEG1_SS = 2, /* MPEG-1 system stream */ + V4L2_CODEC_STREAM_TYPE_MPEG2_DVD = 3, /* MPEG-2 DVD-compatible stream */ + V4L2_CODEC_STREAM_TYPE_MPEG1_VCD = 4, /* MPEG-1 VCD-compatible stream */ + V4L2_CODEC_STREAM_TYPE_MPEG2_SVCD = 5, /* MPEG-2 SVCD-compatible stream */ +}; +#define V4L2_CID_CODEC_STREAM_PID_PMT (V4L2_CID_CODEC_BASE+1) +#define V4L2_CID_CODEC_STREAM_PID_AUDIO (V4L2_CID_CODEC_BASE+2) +#define V4L2_CID_CODEC_STREAM_PID_VIDEO (V4L2_CID_CODEC_BASE+3) +#define V4L2_CID_CODEC_STREAM_PID_PCR (V4L2_CID_CODEC_BASE+4) +#define V4L2_CID_CODEC_STREAM_PES_ID_AUDIO (V4L2_CID_CODEC_BASE+5) +#define V4L2_CID_CODEC_STREAM_PES_ID_VIDEO (V4L2_CID_CODEC_BASE+6) +#define V4L2_CID_CODEC_STREAM_VBI_FMT (V4L2_CID_CODEC_BASE+7) +enum v4l2_codec_stream_vbi_fmt { + V4L2_CODEC_STREAM_VBI_FMT_NONE = 0, /* No VBI in the codec stream */ + V4L2_CODEC_STREAM_VBI_FMT_IVTV = 1, /* VBI in private packets, IVTV format */ +}; + +/* Codec audio controls specific to multiplexed streams */ +#define V4L2_CID_CODEC_AUDIO_SAMPLING_FREQ (V4L2_CID_CODEC_BASE+100) +enum v4l2_codec_audio_sampling_freq { + V4L2_CODEC_AUDIO_SAMPLING_FREQ_44100 = 0, + V4L2_CODEC_AUDIO_SAMPLING_FREQ_48000 = 1, + V4L2_CODEC_AUDIO_SAMPLING_FREQ_32000 = 2, +}; +#define V4L2_CID_CODEC_AUDIO_ENCODING (V4L2_CID_CODEC_BASE+101) +enum v4l2_codec_audio_encoding { + V4L2_CODEC_AUDIO_ENCODING_LAYER_1 = 0, + V4L2_CODEC_AUDIO_ENCODING_LAYER_2 = 1, + V4L2_CODEC_AUDIO_ENCODING_LAYER_3 = 2, + V4L2_CODEC_AUDIO_ENCODING_AAC = 3, + V4L2_CODEC_AUDIO_ENCODING_AC3 = 4, +}; +#define V4L2_CID_CODEC_AUDIO_L1_BITRATE (V4L2_CID_CODEC_BASE+102) +enum v4l2_codec_audio_l1_bitrate { + V4L2_CODEC_AUDIO_L1_BITRATE_32K = 0, + V4L2_CODEC_AUDIO_L1_BITRATE_64K = 1, + V4L2_CODEC_AUDIO_L1_BITRATE_96K = 2, + V4L2_CODEC_AUDIO_L1_BITRATE_128K = 3, + V4L2_CODEC_AUDIO_L1_BITRATE_160K = 4, + V4L2_CODEC_AUDIO_L1_BITRATE_192K = 5, + V4L2_CODEC_AUDIO_L1_BITRATE_224K = 6, + V4L2_CODEC_AUDIO_L1_BITRATE_256K = 7, + V4L2_CODEC_AUDIO_L1_BITRATE_288K = 8, + V4L2_CODEC_AUDIO_L1_BITRATE_320K = 9, + V4L2_CODEC_AUDIO_L1_BITRATE_352K = 10, + V4L2_CODEC_AUDIO_L1_BITRATE_384K = 11, + V4L2_CODEC_AUDIO_L1_BITRATE_416K = 12, + V4L2_CODEC_AUDIO_L1_BITRATE_448K = 13, +}; +#define V4L2_CID_CODEC_AUDIO_L2_BITRATE (V4L2_CID_CODEC_BASE+103) +enum v4l2_codec_audio_l2_bitrate { + V4L2_CODEC_AUDIO_L2_BITRATE_32K = 0, + V4L2_CODEC_AUDIO_L2_BITRATE_48K = 1, + V4L2_CODEC_AUDIO_L2_BITRATE_56K = 2, + V4L2_CODEC_AUDIO_L2_BITRATE_64K = 3, + V4L2_CODEC_AUDIO_L2_BITRATE_80K = 4, + V4L2_CODEC_AUDIO_L2_BITRATE_96K = 5, + V4L2_CODEC_AUDIO_L2_BITRATE_112K = 6, + V4L2_CODEC_AUDIO_L2_BITRATE_128K = 7, + V4L2_CODEC_AUDIO_L2_BITRATE_160K = 8, + V4L2_CODEC_AUDIO_L2_BITRATE_192K = 9, + V4L2_CODEC_AUDIO_L2_BITRATE_224K = 10, + V4L2_CODEC_AUDIO_L2_BITRATE_256K = 11, + V4L2_CODEC_AUDIO_L2_BITRATE_320K = 12, + V4L2_CODEC_AUDIO_L2_BITRATE_384K = 13, +}; +#define V4L2_CID_CODEC_AUDIO_L3_BITRATE (V4L2_CID_CODEC_BASE+104) +enum v4l2_codec_audio_l3_bitrate { + V4L2_CODEC_AUDIO_L3_BITRATE_32K = 0, + V4L2_CODEC_AUDIO_L3_BITRATE_40K = 1, + V4L2_CODEC_AUDIO_L3_BITRATE_48K = 2, + V4L2_CODEC_AUDIO_L3_BITRATE_56K = 3, + V4L2_CODEC_AUDIO_L3_BITRATE_64K = 4, + V4L2_CODEC_AUDIO_L3_BITRATE_80K = 5, + V4L2_CODEC_AUDIO_L3_BITRATE_96K = 6, + V4L2_CODEC_AUDIO_L3_BITRATE_112K = 7, + V4L2_CODEC_AUDIO_L3_BITRATE_128K = 8, + V4L2_CODEC_AUDIO_L3_BITRATE_160K = 9, + V4L2_CODEC_AUDIO_L3_BITRATE_192K = 10, + V4L2_CODEC_AUDIO_L3_BITRATE_224K = 11, + V4L2_CODEC_AUDIO_L3_BITRATE_256K = 12, + V4L2_CODEC_AUDIO_L3_BITRATE_320K = 13, +}; +#define V4L2_CID_CODEC_AUDIO_MODE (V4L2_CID_CODEC_BASE+105) +enum v4l2_codec_audio_mode { + V4L2_CODEC_AUDIO_MODE_STEREO = 0, + V4L2_CODEC_AUDIO_MODE_JOINT_STEREO = 1, + V4L2_CODEC_AUDIO_MODE_DUAL = 2, + V4L2_CODEC_AUDIO_MODE_MONO = 3, +}; +#define V4L2_CID_CODEC_AUDIO_MODE_EXTENSION (V4L2_CID_CODEC_BASE+106) +enum v4l2_codec_audio_mode_extension { + V4L2_CODEC_AUDIO_MODE_EXTENSION_BOUND_4 = 0, + V4L2_CODEC_AUDIO_MODE_EXTENSION_BOUND_8 = 1, + V4L2_CODEC_AUDIO_MODE_EXTENSION_BOUND_12 = 2, + V4L2_CODEC_AUDIO_MODE_EXTENSION_BOUND_16 = 3, +}; +#define V4L2_CID_CODEC_AUDIO_EMPHASIS (V4L2_CID_CODEC_BASE+107) +enum v4l2_codec_audio_emphasis { + V4L2_CODEC_AUDIO_EMPHASIS_NONE = 0, + V4L2_CODEC_AUDIO_EMPHASIS_50_DIV_15_uS = 1, + V4L2_CODEC_AUDIO_EMPHASIS_CCITT_J17 = 2, +}; +#define V4L2_CID_CODEC_AUDIO_CRC (V4L2_CID_CODEC_BASE+108) +enum v4l2_codec_audio_crc { + V4L2_CODEC_AUDIO_CRC_NONE = 0, + V4L2_CODEC_AUDIO_CRC_CRC16 = 1, +}; +#define V4L2_CID_CODEC_AUDIO_MUTE (V4L2_CID_CODEC_BASE+109) +#define V4L2_CID_CODEC_AUDIO_AAC_BITRATE (V4L2_CID_CODEC_BASE+110) +#define V4L2_CID_CODEC_AUDIO_AC3_BITRATE (V4L2_CID_CODEC_BASE+111) +enum v4l2_codec_audio_ac3_bitrate { + V4L2_CODEC_AUDIO_AC3_BITRATE_32K = 0, + V4L2_CODEC_AUDIO_AC3_BITRATE_40K = 1, + V4L2_CODEC_AUDIO_AC3_BITRATE_48K = 2, + V4L2_CODEC_AUDIO_AC3_BITRATE_56K = 3, + V4L2_CODEC_AUDIO_AC3_BITRATE_64K = 4, + V4L2_CODEC_AUDIO_AC3_BITRATE_80K = 5, + V4L2_CODEC_AUDIO_AC3_BITRATE_96K = 6, + V4L2_CODEC_AUDIO_AC3_BITRATE_112K = 7, + V4L2_CODEC_AUDIO_AC3_BITRATE_128K = 8, + V4L2_CODEC_AUDIO_AC3_BITRATE_160K = 9, + V4L2_CODEC_AUDIO_AC3_BITRATE_192K = 10, + V4L2_CODEC_AUDIO_AC3_BITRATE_224K = 11, + V4L2_CODEC_AUDIO_AC3_BITRATE_256K = 12, + V4L2_CODEC_AUDIO_AC3_BITRATE_320K = 13, + V4L2_CODEC_AUDIO_AC3_BITRATE_384K = 14, + V4L2_CODEC_AUDIO_AC3_BITRATE_448K = 15, + V4L2_CODEC_AUDIO_AC3_BITRATE_512K = 16, + V4L2_CODEC_AUDIO_AC3_BITRATE_576K = 17, + V4L2_CODEC_AUDIO_AC3_BITRATE_640K = 18, +}; +#define V4L2_CID_CODEC_AUDIO_DEC_PLAYBACK (V4L2_CID_CODEC_BASE+112) +enum v4l2_codec_audio_dec_playback { + V4L2_CODEC_AUDIO_DEC_PLAYBACK_AUTO = 0, + V4L2_CODEC_AUDIO_DEC_PLAYBACK_STEREO = 1, + V4L2_CODEC_AUDIO_DEC_PLAYBACK_LEFT = 2, + V4L2_CODEC_AUDIO_DEC_PLAYBACK_RIGHT = 3, + V4L2_CODEC_AUDIO_DEC_PLAYBACK_MONO = 4, + V4L2_CODEC_AUDIO_DEC_PLAYBACK_SWAPPED_STEREO = 5, +}; +#define V4L2_CID_CODEC_AUDIO_DEC_MULTILINGUAL_PLAYBACK (V4L2_CID_CODEC_BASE+113) + +/* Codec video controls specific to multiplexed streams */ +#define V4L2_CID_CODEC_VIDEO_ENCODING (V4L2_CID_CODEC_BASE+200) +enum v4l2_codec_video_encoding { + V4L2_CODEC_VIDEO_ENCODING_MPEG_1 = 0, + V4L2_CODEC_VIDEO_ENCODING_MPEG_2 = 1, + V4L2_CODEC_VIDEO_ENCODING_MPEG_4_AVC = 2, +}; +#define V4L2_CID_CODEC_VIDEO_ASPECT (V4L2_CID_CODEC_BASE+201) +enum v4l2_codec_video_aspect { + V4L2_CODEC_VIDEO_ASPECT_1x1 = 0, + V4L2_CODEC_VIDEO_ASPECT_4x3 = 1, + V4L2_CODEC_VIDEO_ASPECT_16x9 = 2, + V4L2_CODEC_VIDEO_ASPECT_221x100 = 3, +}; +#define V4L2_CID_CODEC_VIDEO_B_FRAMES (V4L2_CID_CODEC_BASE+202) +#define V4L2_CID_CODEC_VIDEO_GOP_SIZE (V4L2_CID_CODEC_BASE+203) +#define V4L2_CID_CODEC_VIDEO_GOP_CLOSURE (V4L2_CID_CODEC_BASE+204) +#define V4L2_CID_CODEC_VIDEO_PULLDOWN (V4L2_CID_CODEC_BASE+205) +#define V4L2_CID_CODEC_VIDEO_BITRATE_MODE (V4L2_CID_CODEC_BASE+206) +enum v4l2_codec_video_bitrate_mode { + V4L2_CODEC_VIDEO_BITRATE_MODE_VBR = 0, + V4L2_CODEC_VIDEO_BITRATE_MODE_CBR = 1, + V4L2_CODEC_VIDEO_BITRATE_MODE_CQ = 2, +}; +#define V4L2_CID_CODEC_VIDEO_BITRATE (V4L2_CID_CODEC_BASE+207) +#define V4L2_CID_CODEC_VIDEO_BITRATE_PEAK (V4L2_CID_CODEC_BASE+208) +#define V4L2_CID_CODEC_VIDEO_TEMPORAL_DECIMATION (V4L2_CID_CODEC_BASE+209) +#define V4L2_CID_CODEC_VIDEO_MUTE (V4L2_CID_CODEC_BASE+210) +#define V4L2_CID_CODEC_VIDEO_MUTE_YUV (V4L2_CID_CODEC_BASE+211) +#define V4L2_CID_CODEC_VIDEO_DECODER_SLICE_INTERFACE (V4L2_CID_CODEC_BASE+212) +#define V4L2_CID_CODEC_VIDEO_DECODER_MPEG4_DEBLOCK_FILTER (V4L2_CID_CODEC_BASE+213) +#define V4L2_CID_CODEC_VIDEO_CYCLIC_INTRA_REFRESH_MB (V4L2_CID_CODEC_BASE+214) +#define V4L2_CID_CODEC_VIDEO_FRAME_RC_ENABLE (V4L2_CID_CODEC_BASE+215) +#define V4L2_CID_CODEC_VIDEO_HEADER_MODE (V4L2_CID_CODEC_BASE+216) +enum v4l2_codec_video_header_mode { + V4L2_CODEC_VIDEO_HEADER_MODE_SEPARATE = 0, + V4L2_CODEC_VIDEO_HEADER_MODE_JOINED_WITH_1ST_FRAME = 1, + +}; +#define V4L2_CID_CODEC_VIDEO_MAX_REF_PIC (V4L2_CID_CODEC_BASE+217) +#define V4L2_CID_CODEC_VIDEO_MB_RC_ENABLE (V4L2_CID_CODEC_BASE+218) +#define V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MAX_BYTES (V4L2_CID_CODEC_BASE+219) +#define V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MAX_MB (V4L2_CID_CODEC_BASE+220) +#define V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MODE (V4L2_CID_CODEC_BASE+221) +enum v4l2_codec_video_multi_slice_mode { + V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_SINGLE = 0, + V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_MAX_MB = 1, + V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_MAX_BYTES = 2, #ifndef __KERNEL__ /* Kept for backwards compatibility reasons. Stupid typo... */ - V4L2_MPEG_VIDEO_MULTI_SICE_MODE_MAX_MB = 1, - V4L2_MPEG_VIDEO_MULTI_SICE_MODE_MAX_BYTES = 2, + V4L2_CODEC_VIDEO_MULTI_SICE_MODE_MAX_MB = 1, + V4L2_CODEC_VIDEO_MULTI_SICE_MODE_MAX_BYTES = 2, #endif }; -#define V4L2_CID_MPEG_VIDEO_VBV_SIZE (V4L2_CID_CODEC_BASE+222) -#define V4L2_CID_MPEG_VIDEO_DEC_PTS (V4L2_CID_CODEC_BASE+223) -#define V4L2_CID_MPEG_VIDEO_DEC_FRAME (V4L2_CID_CODEC_BASE+224) -#define V4L2_CID_MPEG_VIDEO_VBV_DELAY (V4L2_CID_CODEC_BASE+225) -#define V4L2_CID_MPEG_VIDEO_REPEAT_SEQ_HEADER (V4L2_CID_CODEC_BASE+226) -#define V4L2_CID_MPEG_VIDEO_MV_H_SEARCH_RANGE (V4L2_CID_CODEC_BASE+227) -#define V4L2_CID_MPEG_VIDEO_MV_V_SEARCH_RANGE (V4L2_CID_CODEC_BASE+228) -#define V4L2_CID_MPEG_VIDEO_FORCE_KEY_FRAME (V4L2_CID_CODEC_BASE+229) -#define V4L2_CID_MPEG_VIDEO_BASELAYER_PRIORITY_ID (V4L2_CID_CODEC_BASE+230) +#define V4L2_CID_CODEC_VIDEO_VBV_SIZE (V4L2_CID_CODEC_BASE+222) +#define V4L2_CID_CODEC_VIDEO_DEC_PTS (V4L2_CID_CODEC_BASE+223) +#define V4L2_CID_CODEC_VIDEO_DEC_FRAME (V4L2_CID_CODEC_BASE+224) +#define V4L2_CID_CODEC_VIDEO_VBV_DELAY (V4L2_CID_CODEC_BASE+225) +#define V4L2_CID_CODEC_VIDEO_REPEAT_SEQ_HEADER (V4L2_CID_CODEC_BASE+226) +#define V4L2_CID_CODEC_VIDEO_MV_H_SEARCH_RANGE (V4L2_CID_CODEC_BASE+227) +#define V4L2_CID_CODEC_VIDEO_MV_V_SEARCH_RANGE (V4L2_CID_CODEC_BASE+228) +#define V4L2_CID_CODEC_VIDEO_FORCE_KEY_FRAME (V4L2_CID_CODEC_BASE+229) +#define V4L2_CID_CODEC_VIDEO_BASELAYER_PRIORITY_ID (V4L2_CID_CODEC_BASE+230) /* CIDs for the MPEG-2 Part 2 (H.262) codec */ -#define V4L2_CID_MPEG_VIDEO_MPEG2_LEVEL (V4L2_CID_CODEC_BASE+270) -enum v4l2_mpeg_video_mpeg2_level { - V4L2_MPEG_VIDEO_MPEG2_LEVEL_LOW = 0, - V4L2_MPEG_VIDEO_MPEG2_LEVEL_MAIN = 1, - V4L2_MPEG_VIDEO_MPEG2_LEVEL_HIGH_1440 = 2, - V4L2_MPEG_VIDEO_MPEG2_LEVEL_HIGH = 3, -}; -#define V4L2_CID_MPEG_VIDEO_MPEG2_PROFILE (V4L2_CID_CODEC_BASE+271) -enum v4l2_mpeg_video_mpeg2_profile { - V4L2_MPEG_VIDEO_MPEG2_PROFILE_SIMPLE = 0, - V4L2_MPEG_VIDEO_MPEG2_PROFILE_MAIN = 1, - V4L2_MPEG_VIDEO_MPEG2_PROFILE_SNR_SCALABLE = 2, - V4L2_MPEG_VIDEO_MPEG2_PROFILE_SPATIALLY_SCALABLE = 3, - V4L2_MPEG_VIDEO_MPEG2_PROFILE_HIGH = 4, - V4L2_MPEG_VIDEO_MPEG2_PROFILE_MULTIVIEW = 5, +#define V4L2_CID_CODEC_VIDEO_MPEG2_LEVEL (V4L2_CID_CODEC_BASE+270) +enum v4l2_codec_video_mpeg2_level { + V4L2_CODEC_VIDEO_MPEG2_LEVEL_LOW = 0, + V4L2_CODEC_VIDEO_MPEG2_LEVEL_MAIN = 1, + V4L2_CODEC_VIDEO_MPEG2_LEVEL_HIGH_1440 = 2, + V4L2_CODEC_VIDEO_MPEG2_LEVEL_HIGH = 3, +}; +#define V4L2_CID_CODEC_VIDEO_MPEG2_PROFILE (V4L2_CID_CODEC_BASE+271) +enum v4l2_codec_video_mpeg2_profile { + V4L2_CODEC_VIDEO_MPEG2_PROFILE_SIMPLE = 0, + V4L2_CODEC_VIDEO_MPEG2_PROFILE_MAIN = 1, + V4L2_CODEC_VIDEO_MPEG2_PROFILE_SNR_SCALABLE = 2, + V4L2_CODEC_VIDEO_MPEG2_PROFILE_SPATIALLY_SCALABLE = 3, + V4L2_CODEC_VIDEO_MPEG2_PROFILE_HIGH = 4, + V4L2_CODEC_VIDEO_MPEG2_PROFILE_MULTIVIEW = 5, }; /* CIDs for the FWHT codec as used by the vicodec driver. */ #define V4L2_CID_FWHT_I_FRAME_QP (V4L2_CID_CODEC_BASE + 290) #define V4L2_CID_FWHT_P_FRAME_QP (V4L2_CID_CODEC_BASE + 291) -#define V4L2_CID_MPEG_VIDEO_H263_I_FRAME_QP (V4L2_CID_CODEC_BASE+300) -#define V4L2_CID_MPEG_VIDEO_H263_P_FRAME_QP (V4L2_CID_CODEC_BASE+301) -#define V4L2_CID_MPEG_VIDEO_H263_B_FRAME_QP (V4L2_CID_CODEC_BASE+302) -#define V4L2_CID_MPEG_VIDEO_H263_MIN_QP (V4L2_CID_CODEC_BASE+303) -#define V4L2_CID_MPEG_VIDEO_H263_MAX_QP (V4L2_CID_CODEC_BASE+304) -#define V4L2_CID_MPEG_VIDEO_H264_I_FRAME_QP (V4L2_CID_CODEC_BASE+350) -#define V4L2_CID_MPEG_VIDEO_H264_P_FRAME_QP (V4L2_CID_CODEC_BASE+351) -#define V4L2_CID_MPEG_VIDEO_H264_B_FRAME_QP (V4L2_CID_CODEC_BASE+352) -#define V4L2_CID_MPEG_VIDEO_H264_MIN_QP (V4L2_CID_CODEC_BASE+353) -#define V4L2_CID_MPEG_VIDEO_H264_MAX_QP (V4L2_CID_CODEC_BASE+354) -#define V4L2_CID_MPEG_VIDEO_H264_8X8_TRANSFORM (V4L2_CID_CODEC_BASE+355) -#define V4L2_CID_MPEG_VIDEO_H264_CPB_SIZE (V4L2_CID_CODEC_BASE+356) -#define V4L2_CID_MPEG_VIDEO_H264_ENTROPY_MODE (V4L2_CID_CODEC_BASE+357) -enum v4l2_mpeg_video_h264_entropy_mode { - V4L2_MPEG_VIDEO_H264_ENTROPY_MODE_CAVLC = 0, - V4L2_MPEG_VIDEO_H264_ENTROPY_MODE_CABAC = 1, -}; -#define V4L2_CID_MPEG_VIDEO_H264_I_PERIOD (V4L2_CID_CODEC_BASE+358) -#define V4L2_CID_MPEG_VIDEO_H264_LEVEL (V4L2_CID_CODEC_BASE+359) -enum v4l2_mpeg_video_h264_level { - V4L2_MPEG_VIDEO_H264_LEVEL_1_0 = 0, - V4L2_MPEG_VIDEO_H264_LEVEL_1B = 1, - V4L2_MPEG_VIDEO_H264_LEVEL_1_1 = 2, - V4L2_MPEG_VIDEO_H264_LEVEL_1_2 = 3, - V4L2_MPEG_VIDEO_H264_LEVEL_1_3 = 4, - V4L2_MPEG_VIDEO_H264_LEVEL_2_0 = 5, - V4L2_MPEG_VIDEO_H264_LEVEL_2_1 = 6, - V4L2_MPEG_VIDEO_H264_LEVEL_2_2 = 7, - V4L2_MPEG_VIDEO_H264_LEVEL_3_0 = 8, - V4L2_MPEG_VIDEO_H264_LEVEL_3_1 = 9, - V4L2_MPEG_VIDEO_H264_LEVEL_3_2 = 10, - V4L2_MPEG_VIDEO_H264_LEVEL_4_0 = 11, - V4L2_MPEG_VIDEO_H264_LEVEL_4_1 = 12, - V4L2_MPEG_VIDEO_H264_LEVEL_4_2 = 13, - V4L2_MPEG_VIDEO_H264_LEVEL_5_0 = 14, - V4L2_MPEG_VIDEO_H264_LEVEL_5_1 = 15, - V4L2_MPEG_VIDEO_H264_LEVEL_5_2 = 16, - V4L2_MPEG_VIDEO_H264_LEVEL_6_0 = 17, - V4L2_MPEG_VIDEO_H264_LEVEL_6_1 = 18, - V4L2_MPEG_VIDEO_H264_LEVEL_6_2 = 19, -}; -#define V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_ALPHA (V4L2_CID_CODEC_BASE+360) -#define V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_BETA (V4L2_CID_CODEC_BASE+361) -#define V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_MODE (V4L2_CID_CODEC_BASE+362) -enum v4l2_mpeg_video_h264_loop_filter_mode { - V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_ENABLED = 0, - V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_DISABLED = 1, - V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY = 2, -}; -#define V4L2_CID_MPEG_VIDEO_H264_PROFILE (V4L2_CID_CODEC_BASE+363) -enum v4l2_mpeg_video_h264_profile { - V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE = 0, - V4L2_MPEG_VIDEO_H264_PROFILE_CONSTRAINED_BASELINE = 1, - V4L2_MPEG_VIDEO_H264_PROFILE_MAIN = 2, - V4L2_MPEG_VIDEO_H264_PROFILE_EXTENDED = 3, - V4L2_MPEG_VIDEO_H264_PROFILE_HIGH = 4, - V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_10 = 5, - V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_422 = 6, - V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_444_PREDICTIVE = 7, - V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_10_INTRA = 8, - V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_422_INTRA = 9, - V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_444_INTRA = 10, - V4L2_MPEG_VIDEO_H264_PROFILE_CAVLC_444_INTRA = 11, - V4L2_MPEG_VIDEO_H264_PROFILE_SCALABLE_BASELINE = 12, - V4L2_MPEG_VIDEO_H264_PROFILE_SCALABLE_HIGH = 13, - V4L2_MPEG_VIDEO_H264_PROFILE_SCALABLE_HIGH_INTRA = 14, - V4L2_MPEG_VIDEO_H264_PROFILE_STEREO_HIGH = 15, - V4L2_MPEG_VIDEO_H264_PROFILE_MULTIVIEW_HIGH = 16, - V4L2_MPEG_VIDEO_H264_PROFILE_CONSTRAINED_HIGH = 17, -}; -#define V4L2_CID_MPEG_VIDEO_H264_VUI_EXT_SAR_HEIGHT (V4L2_CID_CODEC_BASE+364) -#define V4L2_CID_MPEG_VIDEO_H264_VUI_EXT_SAR_WIDTH (V4L2_CID_CODEC_BASE+365) -#define V4L2_CID_MPEG_VIDEO_H264_VUI_SAR_ENABLE (V4L2_CID_CODEC_BASE+366) -#define V4L2_CID_MPEG_VIDEO_H264_VUI_SAR_IDC (V4L2_CID_CODEC_BASE+367) -enum v4l2_mpeg_video_h264_vui_sar_idc { - V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_UNSPECIFIED = 0, - V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_1x1 = 1, - V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_12x11 = 2, - V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_10x11 = 3, - V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_16x11 = 4, - V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_40x33 = 5, - V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_24x11 = 6, - V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_20x11 = 7, - V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_32x11 = 8, - V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_80x33 = 9, - V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_18x11 = 10, - V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_15x11 = 11, - V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_64x33 = 12, - V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_160x99 = 13, - V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_4x3 = 14, - V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_3x2 = 15, - V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_2x1 = 16, - V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_EXTENDED = 17, -}; -#define V4L2_CID_MPEG_VIDEO_H264_SEI_FRAME_PACKING (V4L2_CID_CODEC_BASE+368) -#define V4L2_CID_MPEG_VIDEO_H264_SEI_FP_CURRENT_FRAME_0 (V4L2_CID_CODEC_BASE+369) -#define V4L2_CID_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE (V4L2_CID_CODEC_BASE+370) -enum v4l2_mpeg_video_h264_sei_fp_arrangement_type { - V4L2_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_CHECKERBOARD = 0, - V4L2_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_COLUMN = 1, - V4L2_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_ROW = 2, - V4L2_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_SIDE_BY_SIDE = 3, - V4L2_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_TOP_BOTTOM = 4, - V4L2_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_TEMPORAL = 5, -}; -#define V4L2_CID_MPEG_VIDEO_H264_FMO (V4L2_CID_CODEC_BASE+371) -#define V4L2_CID_MPEG_VIDEO_H264_FMO_MAP_TYPE (V4L2_CID_CODEC_BASE+372) -enum v4l2_mpeg_video_h264_fmo_map_type { - V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_INTERLEAVED_SLICES = 0, - V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_SCATTERED_SLICES = 1, - V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_FOREGROUND_WITH_LEFT_OVER = 2, - V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_BOX_OUT = 3, - V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_RASTER_SCAN = 4, - V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_WIPE_SCAN = 5, - V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_EXPLICIT = 6, -}; -#define V4L2_CID_MPEG_VIDEO_H264_FMO_SLICE_GROUP (V4L2_CID_CODEC_BASE+373) -#define V4L2_CID_MPEG_VIDEO_H264_FMO_CHANGE_DIRECTION (V4L2_CID_CODEC_BASE+374) -enum v4l2_mpeg_video_h264_fmo_change_dir { - V4L2_MPEG_VIDEO_H264_FMO_CHANGE_DIR_RIGHT = 0, - V4L2_MPEG_VIDEO_H264_FMO_CHANGE_DIR_LEFT = 1, -}; -#define V4L2_CID_MPEG_VIDEO_H264_FMO_CHANGE_RATE (V4L2_CID_CODEC_BASE+375) -#define V4L2_CID_MPEG_VIDEO_H264_FMO_RUN_LENGTH (V4L2_CID_CODEC_BASE+376) -#define V4L2_CID_MPEG_VIDEO_H264_ASO (V4L2_CID_CODEC_BASE+377) -#define V4L2_CID_MPEG_VIDEO_H264_ASO_SLICE_ORDER (V4L2_CID_CODEC_BASE+378) -#define V4L2_CID_MPEG_VIDEO_H264_HIERARCHICAL_CODING (V4L2_CID_CODEC_BASE+379) -#define V4L2_CID_MPEG_VIDEO_H264_HIERARCHICAL_CODING_TYPE (V4L2_CID_CODEC_BASE+380) -enum v4l2_mpeg_video_h264_hierarchical_coding_type { - V4L2_MPEG_VIDEO_H264_HIERARCHICAL_CODING_B = 0, - V4L2_MPEG_VIDEO_H264_HIERARCHICAL_CODING_P = 1, -}; -#define V4L2_CID_MPEG_VIDEO_H264_HIERARCHICAL_CODING_LAYER (V4L2_CID_CODEC_BASE+381) -#define V4L2_CID_MPEG_VIDEO_H264_HIERARCHICAL_CODING_LAYER_QP (V4L2_CID_CODEC_BASE+382) -#define V4L2_CID_MPEG_VIDEO_H264_CONSTRAINED_INTRA_PREDICTION (V4L2_CID_CODEC_BASE+383) -#define V4L2_CID_MPEG_VIDEO_H264_CHROMA_QP_INDEX_OFFSET (V4L2_CID_CODEC_BASE+384) -#define V4L2_CID_MPEG_VIDEO_H264_I_FRAME_MIN_QP (V4L2_CID_CODEC_BASE+385) -#define V4L2_CID_MPEG_VIDEO_H264_I_FRAME_MAX_QP (V4L2_CID_CODEC_BASE+386) -#define V4L2_CID_MPEG_VIDEO_H264_P_FRAME_MIN_QP (V4L2_CID_CODEC_BASE+387) -#define V4L2_CID_MPEG_VIDEO_H264_P_FRAME_MAX_QP (V4L2_CID_CODEC_BASE+388) -#define V4L2_CID_MPEG_VIDEO_H264_B_FRAME_MIN_QP (V4L2_CID_CODEC_BASE+389) -#define V4L2_CID_MPEG_VIDEO_H264_B_FRAME_MAX_QP (V4L2_CID_CODEC_BASE+390) -#define V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L0_BR (V4L2_CID_CODEC_BASE+391) -#define V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L1_BR (V4L2_CID_CODEC_BASE+392) -#define V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L2_BR (V4L2_CID_CODEC_BASE+393) -#define V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L3_BR (V4L2_CID_CODEC_BASE+394) -#define V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L4_BR (V4L2_CID_CODEC_BASE+395) -#define V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L5_BR (V4L2_CID_CODEC_BASE+396) -#define V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L6_BR (V4L2_CID_CODEC_BASE+397) -#define V4L2_CID_MPEG_VIDEO_MPEG4_I_FRAME_QP (V4L2_CID_CODEC_BASE+400) -#define V4L2_CID_MPEG_VIDEO_MPEG4_P_FRAME_QP (V4L2_CID_CODEC_BASE+401) -#define V4L2_CID_MPEG_VIDEO_MPEG4_B_FRAME_QP (V4L2_CID_CODEC_BASE+402) -#define V4L2_CID_MPEG_VIDEO_MPEG4_MIN_QP (V4L2_CID_CODEC_BASE+403) -#define V4L2_CID_MPEG_VIDEO_MPEG4_MAX_QP (V4L2_CID_CODEC_BASE+404) -#define V4L2_CID_MPEG_VIDEO_MPEG4_LEVEL (V4L2_CID_CODEC_BASE+405) -enum v4l2_mpeg_video_mpeg4_level { - V4L2_MPEG_VIDEO_MPEG4_LEVEL_0 = 0, - V4L2_MPEG_VIDEO_MPEG4_LEVEL_0B = 1, - V4L2_MPEG_VIDEO_MPEG4_LEVEL_1 = 2, - V4L2_MPEG_VIDEO_MPEG4_LEVEL_2 = 3, - V4L2_MPEG_VIDEO_MPEG4_LEVEL_3 = 4, - V4L2_MPEG_VIDEO_MPEG4_LEVEL_3B = 5, - V4L2_MPEG_VIDEO_MPEG4_LEVEL_4 = 6, - V4L2_MPEG_VIDEO_MPEG4_LEVEL_5 = 7, -}; -#define V4L2_CID_MPEG_VIDEO_MPEG4_PROFILE (V4L2_CID_CODEC_BASE+406) -enum v4l2_mpeg_video_mpeg4_profile { - V4L2_MPEG_VIDEO_MPEG4_PROFILE_SIMPLE = 0, - V4L2_MPEG_VIDEO_MPEG4_PROFILE_ADVANCED_SIMPLE = 1, - V4L2_MPEG_VIDEO_MPEG4_PROFILE_CORE = 2, - V4L2_MPEG_VIDEO_MPEG4_PROFILE_SIMPLE_SCALABLE = 3, - V4L2_MPEG_VIDEO_MPEG4_PROFILE_ADVANCED_CODING_EFFICIENCY = 4, -}; -#define V4L2_CID_MPEG_VIDEO_MPEG4_QPEL (V4L2_CID_CODEC_BASE+407) - -/* Control IDs for VP8 streams - * Although VP8 is not part of MPEG we add these controls to the MPEG class - * as that class is already handling other video compression standards - */ -#define V4L2_CID_MPEG_VIDEO_VPX_NUM_PARTITIONS (V4L2_CID_CODEC_BASE+500) +#define V4L2_CID_CODEC_VIDEO_H263_I_FRAME_QP (V4L2_CID_CODEC_BASE+300) +#define V4L2_CID_CODEC_VIDEO_H263_P_FRAME_QP (V4L2_CID_CODEC_BASE+301) +#define V4L2_CID_CODEC_VIDEO_H263_B_FRAME_QP (V4L2_CID_CODEC_BASE+302) +#define V4L2_CID_CODEC_VIDEO_H263_MIN_QP (V4L2_CID_CODEC_BASE+303) +#define V4L2_CID_CODEC_VIDEO_H263_MAX_QP (V4L2_CID_CODEC_BASE+304) +#define V4L2_CID_CODEC_VIDEO_H264_I_FRAME_QP (V4L2_CID_CODEC_BASE+350) +#define V4L2_CID_CODEC_VIDEO_H264_P_FRAME_QP (V4L2_CID_CODEC_BASE+351) +#define V4L2_CID_CODEC_VIDEO_H264_B_FRAME_QP (V4L2_CID_CODEC_BASE+352) +#define V4L2_CID_CODEC_VIDEO_H264_MIN_QP (V4L2_CID_CODEC_BASE+353) +#define V4L2_CID_CODEC_VIDEO_H264_MAX_QP (V4L2_CID_CODEC_BASE+354) +#define V4L2_CID_CODEC_VIDEO_H264_8X8_TRANSFORM (V4L2_CID_CODEC_BASE+355) +#define V4L2_CID_CODEC_VIDEO_H264_CPB_SIZE (V4L2_CID_CODEC_BASE+356) +#define V4L2_CID_CODEC_VIDEO_H264_ENTROPY_MODE (V4L2_CID_CODEC_BASE+357) +enum v4l2_codec_video_h264_entropy_mode { + V4L2_CODEC_VIDEO_H264_ENTROPY_MODE_CAVLC = 0, + V4L2_CODEC_VIDEO_H264_ENTROPY_MODE_CABAC = 1, +}; +#define V4L2_CID_CODEC_VIDEO_H264_I_PERIOD (V4L2_CID_CODEC_BASE+358) +#define V4L2_CID_CODEC_VIDEO_H264_LEVEL (V4L2_CID_CODEC_BASE+359) +enum v4l2_codec_video_h264_level { + V4L2_CODEC_VIDEO_H264_LEVEL_1_0 = 0, + V4L2_CODEC_VIDEO_H264_LEVEL_1B = 1, + V4L2_CODEC_VIDEO_H264_LEVEL_1_1 = 2, + V4L2_CODEC_VIDEO_H264_LEVEL_1_2 = 3, + V4L2_CODEC_VIDEO_H264_LEVEL_1_3 = 4, + V4L2_CODEC_VIDEO_H264_LEVEL_2_0 = 5, + V4L2_CODEC_VIDEO_H264_LEVEL_2_1 = 6, + V4L2_CODEC_VIDEO_H264_LEVEL_2_2 = 7, + V4L2_CODEC_VIDEO_H264_LEVEL_3_0 = 8, + V4L2_CODEC_VIDEO_H264_LEVEL_3_1 = 9, + V4L2_CODEC_VIDEO_H264_LEVEL_3_2 = 10, + V4L2_CODEC_VIDEO_H264_LEVEL_4_0 = 11, + V4L2_CODEC_VIDEO_H264_LEVEL_4_1 = 12, + V4L2_CODEC_VIDEO_H264_LEVEL_4_2 = 13, + V4L2_CODEC_VIDEO_H264_LEVEL_5_0 = 14, + V4L2_CODEC_VIDEO_H264_LEVEL_5_1 = 15, + V4L2_CODEC_VIDEO_H264_LEVEL_5_2 = 16, + V4L2_CODEC_VIDEO_H264_LEVEL_6_0 = 17, + V4L2_CODEC_VIDEO_H264_LEVEL_6_1 = 18, + V4L2_CODEC_VIDEO_H264_LEVEL_6_2 = 19, +}; +#define V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_ALPHA (V4L2_CID_CODEC_BASE+360) +#define V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_BETA (V4L2_CID_CODEC_BASE+361) +#define V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_MODE (V4L2_CID_CODEC_BASE+362) +enum v4l2_codec_video_h264_loop_filter_mode { + V4L2_CODEC_VIDEO_H264_LOOP_FILTER_MODE_ENABLED = 0, + V4L2_CODEC_VIDEO_H264_LOOP_FILTER_MODE_DISABLED = 1, + V4L2_CODEC_VIDEO_H264_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY = 2, +}; +#define V4L2_CID_CODEC_VIDEO_H264_PROFILE (V4L2_CID_CODEC_BASE+363) +enum v4l2_codec_video_h264_profile { + V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE = 0, + V4L2_CODEC_VIDEO_H264_PROFILE_CONSTRAINED_BASELINE = 1, + V4L2_CODEC_VIDEO_H264_PROFILE_MAIN = 2, + V4L2_CODEC_VIDEO_H264_PROFILE_EXTENDED = 3, + V4L2_CODEC_VIDEO_H264_PROFILE_HIGH = 4, + V4L2_CODEC_VIDEO_H264_PROFILE_HIGH_10 = 5, + V4L2_CODEC_VIDEO_H264_PROFILE_HIGH_422 = 6, + V4L2_CODEC_VIDEO_H264_PROFILE_HIGH_444_PREDICTIVE = 7, + V4L2_CODEC_VIDEO_H264_PROFILE_HIGH_10_INTRA = 8, + V4L2_CODEC_VIDEO_H264_PROFILE_HIGH_422_INTRA = 9, + V4L2_CODEC_VIDEO_H264_PROFILE_HIGH_444_INTRA = 10, + V4L2_CODEC_VIDEO_H264_PROFILE_CAVLC_444_INTRA = 11, + V4L2_CODEC_VIDEO_H264_PROFILE_SCALABLE_BASELINE = 12, + V4L2_CODEC_VIDEO_H264_PROFILE_SCALABLE_HIGH = 13, + V4L2_CODEC_VIDEO_H264_PROFILE_SCALABLE_HIGH_INTRA = 14, + V4L2_CODEC_VIDEO_H264_PROFILE_STEREO_HIGH = 15, + V4L2_CODEC_VIDEO_H264_PROFILE_MULTIVIEW_HIGH = 16, + V4L2_CODEC_VIDEO_H264_PROFILE_CONSTRAINED_HIGH = 17, +}; +#define V4L2_CID_CODEC_VIDEO_H264_VUI_EXT_SAR_HEIGHT (V4L2_CID_CODEC_BASE+364) +#define V4L2_CID_CODEC_VIDEO_H264_VUI_EXT_SAR_WIDTH (V4L2_CID_CODEC_BASE+365) +#define V4L2_CID_CODEC_VIDEO_H264_VUI_SAR_ENABLE (V4L2_CID_CODEC_BASE+366) +#define V4L2_CID_CODEC_VIDEO_H264_VUI_SAR_IDC (V4L2_CID_CODEC_BASE+367) +enum v4l2_codec_video_h264_vui_sar_idc { + V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_UNSPECIFIED = 0, + V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_1x1 = 1, + V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_12x11 = 2, + V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_10x11 = 3, + V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_16x11 = 4, + V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_40x33 = 5, + V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_24x11 = 6, + V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_20x11 = 7, + V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_32x11 = 8, + V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_80x33 = 9, + V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_18x11 = 10, + V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_15x11 = 11, + V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_64x33 = 12, + V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_160x99 = 13, + V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_4x3 = 14, + V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_3x2 = 15, + V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_2x1 = 16, + V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_EXTENDED = 17, +}; +#define V4L2_CID_CODEC_VIDEO_H264_SEI_FRAME_PACKING (V4L2_CID_CODEC_BASE+368) +#define V4L2_CID_CODEC_VIDEO_H264_SEI_FP_CURRENT_FRAME_0 (V4L2_CID_CODEC_BASE+369) +#define V4L2_CID_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE (V4L2_CID_CODEC_BASE+370) +enum v4l2_codec_video_h264_sei_fp_arrangement_type { + V4L2_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_CHECKERBOARD = 0, + V4L2_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_COLUMN = 1, + V4L2_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_ROW = 2, + V4L2_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_SIDE_BY_SIDE = 3, + V4L2_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_TOP_BOTTOM = 4, + V4L2_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_TEMPORAL = 5, +}; +#define V4L2_CID_CODEC_VIDEO_H264_FMO (V4L2_CID_CODEC_BASE+371) +#define V4L2_CID_CODEC_VIDEO_H264_FMO_MAP_TYPE (V4L2_CID_CODEC_BASE+372) +enum v4l2_codec_video_h264_fmo_map_type { + V4L2_CODEC_VIDEO_H264_FMO_MAP_TYPE_INTERLEAVED_SLICES = 0, + V4L2_CODEC_VIDEO_H264_FMO_MAP_TYPE_SCATTERED_SLICES = 1, + V4L2_CODEC_VIDEO_H264_FMO_MAP_TYPE_FOREGROUND_WITH_LEFT_OVER = 2, + V4L2_CODEC_VIDEO_H264_FMO_MAP_TYPE_BOX_OUT = 3, + V4L2_CODEC_VIDEO_H264_FMO_MAP_TYPE_RASTER_SCAN = 4, + V4L2_CODEC_VIDEO_H264_FMO_MAP_TYPE_WIPE_SCAN = 5, + V4L2_CODEC_VIDEO_H264_FMO_MAP_TYPE_EXPLICIT = 6, +}; +#define V4L2_CID_CODEC_VIDEO_H264_FMO_SLICE_GROUP (V4L2_CID_CODEC_BASE+373) +#define V4L2_CID_CODEC_VIDEO_H264_FMO_CHANGE_DIRECTION (V4L2_CID_CODEC_BASE+374) +enum v4l2_codec_video_h264_fmo_change_dir { + V4L2_CODEC_VIDEO_H264_FMO_CHANGE_DIR_RIGHT = 0, + V4L2_CODEC_VIDEO_H264_FMO_CHANGE_DIR_LEFT = 1, +}; +#define V4L2_CID_CODEC_VIDEO_H264_FMO_CHANGE_RATE (V4L2_CID_CODEC_BASE+375) +#define V4L2_CID_CODEC_VIDEO_H264_FMO_RUN_LENGTH (V4L2_CID_CODEC_BASE+376) +#define V4L2_CID_CODEC_VIDEO_H264_ASO (V4L2_CID_CODEC_BASE+377) +#define V4L2_CID_CODEC_VIDEO_H264_ASO_SLICE_ORDER (V4L2_CID_CODEC_BASE+378) +#define V4L2_CID_CODEC_VIDEO_H264_HIERARCHICAL_CODING (V4L2_CID_CODEC_BASE+379) +#define V4L2_CID_CODEC_VIDEO_H264_HIERARCHICAL_CODING_TYPE (V4L2_CID_CODEC_BASE+380) +enum v4l2_codec_video_h264_hierarchical_coding_type { + V4L2_CODEC_VIDEO_H264_HIERARCHICAL_CODING_B = 0, + V4L2_CODEC_VIDEO_H264_HIERARCHICAL_CODING_P = 1, +}; +#define V4L2_CID_CODEC_VIDEO_H264_HIERARCHICAL_CODING_LAYER (V4L2_CID_CODEC_BASE+381) +#define V4L2_CID_CODEC_VIDEO_H264_HIERARCHICAL_CODING_LAYER_QP (V4L2_CID_CODEC_BASE+382) +#define V4L2_CID_CODEC_VIDEO_H264_CONSTRAINED_INTRA_PREDICTION (V4L2_CID_CODEC_BASE+383) +#define V4L2_CID_CODEC_VIDEO_H264_CHROMA_QP_INDEX_OFFSET (V4L2_CID_CODEC_BASE+384) +#define V4L2_CID_CODEC_VIDEO_H264_I_FRAME_MIN_QP (V4L2_CID_CODEC_BASE+385) +#define V4L2_CID_CODEC_VIDEO_H264_I_FRAME_MAX_QP (V4L2_CID_CODEC_BASE+386) +#define V4L2_CID_CODEC_VIDEO_H264_P_FRAME_MIN_QP (V4L2_CID_CODEC_BASE+387) +#define V4L2_CID_CODEC_VIDEO_H264_P_FRAME_MAX_QP (V4L2_CID_CODEC_BASE+388) +#define V4L2_CID_CODEC_VIDEO_H264_B_FRAME_MIN_QP (V4L2_CID_CODEC_BASE+389) +#define V4L2_CID_CODEC_VIDEO_H264_B_FRAME_MAX_QP (V4L2_CID_CODEC_BASE+390) +#define V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L0_BR (V4L2_CID_CODEC_BASE+391) +#define V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L1_BR (V4L2_CID_CODEC_BASE+392) +#define V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L2_BR (V4L2_CID_CODEC_BASE+393) +#define V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L3_BR (V4L2_CID_CODEC_BASE+394) +#define V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L4_BR (V4L2_CID_CODEC_BASE+395) +#define V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L5_BR (V4L2_CID_CODEC_BASE+396) +#define V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L6_BR (V4L2_CID_CODEC_BASE+397) +#define V4L2_CID_CODEC_VIDEO_MPEG4_I_FRAME_QP (V4L2_CID_CODEC_BASE+400) +#define V4L2_CID_CODEC_VIDEO_MPEG4_P_FRAME_QP (V4L2_CID_CODEC_BASE+401) +#define V4L2_CID_CODEC_VIDEO_MPEG4_B_FRAME_QP (V4L2_CID_CODEC_BASE+402) +#define V4L2_CID_CODEC_VIDEO_MPEG4_MIN_QP (V4L2_CID_CODEC_BASE+403) +#define V4L2_CID_CODEC_VIDEO_MPEG4_MAX_QP (V4L2_CID_CODEC_BASE+404) +#define V4L2_CID_CODEC_VIDEO_MPEG4_LEVEL (V4L2_CID_CODEC_BASE+405) +enum v4l2_codec_video_mpeg4_level { + V4L2_CODEC_VIDEO_MPEG4_LEVEL_0 = 0, + V4L2_CODEC_VIDEO_MPEG4_LEVEL_0B = 1, + V4L2_CODEC_VIDEO_MPEG4_LEVEL_1 = 2, + V4L2_CODEC_VIDEO_MPEG4_LEVEL_2 = 3, + V4L2_CODEC_VIDEO_MPEG4_LEVEL_3 = 4, + V4L2_CODEC_VIDEO_MPEG4_LEVEL_3B = 5, + V4L2_CODEC_VIDEO_MPEG4_LEVEL_4 = 6, + V4L2_CODEC_VIDEO_MPEG4_LEVEL_5 = 7, +}; +#define V4L2_CID_CODEC_VIDEO_MPEG4_PROFILE (V4L2_CID_CODEC_BASE+406) +enum v4l2_codec_video_mpeg4_profile { + V4L2_CODEC_VIDEO_MPEG4_PROFILE_SIMPLE = 0, + V4L2_CODEC_VIDEO_MPEG4_PROFILE_ADVANCED_SIMPLE = 1, + V4L2_CODEC_VIDEO_MPEG4_PROFILE_CORE = 2, + V4L2_CODEC_VIDEO_MPEG4_PROFILE_SIMPLE_SCALABLE = 3, + V4L2_CODEC_VIDEO_MPEG4_PROFILE_ADVANCED_CODING_EFFICIENCY = 4, +}; +#define V4L2_CID_CODEC_VIDEO_MPEG4_QPEL (V4L2_CID_CODEC_BASE+407) + +/* Control IDs for VP8 streams */ +#define V4L2_CID_CODEC_VIDEO_VPX_NUM_PARTITIONS (V4L2_CID_CODEC_BASE+500) enum v4l2_vp8_num_partitions { - V4L2_CID_MPEG_VIDEO_VPX_1_PARTITION = 0, - V4L2_CID_MPEG_VIDEO_VPX_2_PARTITIONS = 1, - V4L2_CID_MPEG_VIDEO_VPX_4_PARTITIONS = 2, - V4L2_CID_MPEG_VIDEO_VPX_8_PARTITIONS = 3, + V4L2_CID_CODEC_VIDEO_VPX_1_PARTITION = 0, + V4L2_CID_CODEC_VIDEO_VPX_2_PARTITIONS = 1, + V4L2_CID_CODEC_VIDEO_VPX_4_PARTITIONS = 2, + V4L2_CID_CODEC_VIDEO_VPX_8_PARTITIONS = 3, }; -#define V4L2_CID_MPEG_VIDEO_VPX_IMD_DISABLE_4X4 (V4L2_CID_CODEC_BASE+501) -#define V4L2_CID_MPEG_VIDEO_VPX_NUM_REF_FRAMES (V4L2_CID_CODEC_BASE+502) +#define V4L2_CID_CODEC_VIDEO_VPX_IMD_DISABLE_4X4 (V4L2_CID_CODEC_BASE+501) +#define V4L2_CID_CODEC_VIDEO_VPX_NUM_REF_FRAMES (V4L2_CID_CODEC_BASE+502) enum v4l2_vp8_num_ref_frames { - V4L2_CID_MPEG_VIDEO_VPX_1_REF_FRAME = 0, - V4L2_CID_MPEG_VIDEO_VPX_2_REF_FRAME = 1, - V4L2_CID_MPEG_VIDEO_VPX_3_REF_FRAME = 2, -}; -#define V4L2_CID_MPEG_VIDEO_VPX_FILTER_LEVEL (V4L2_CID_CODEC_BASE+503) -#define V4L2_CID_MPEG_VIDEO_VPX_FILTER_SHARPNESS (V4L2_CID_CODEC_BASE+504) -#define V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_REF_PERIOD (V4L2_CID_CODEC_BASE+505) -#define V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_SEL (V4L2_CID_CODEC_BASE+506) + V4L2_CID_CODEC_VIDEO_VPX_1_REF_FRAME = 0, + V4L2_CID_CODEC_VIDEO_VPX_2_REF_FRAME = 1, + V4L2_CID_CODEC_VIDEO_VPX_3_REF_FRAME = 2, +}; +#define V4L2_CID_CODEC_VIDEO_VPX_FILTER_LEVEL (V4L2_CID_CODEC_BASE+503) +#define V4L2_CID_CODEC_VIDEO_VPX_FILTER_SHARPNESS (V4L2_CID_CODEC_BASE+504) +#define V4L2_CID_CODEC_VIDEO_VPX_GOLDEN_FRAME_REF_PERIOD (V4L2_CID_CODEC_BASE+505) +#define V4L2_CID_CODEC_VIDEO_VPX_GOLDEN_FRAME_SEL (V4L2_CID_CODEC_BASE+506) enum v4l2_vp8_golden_frame_sel { - V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_USE_PREV = 0, - V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_USE_REF_PERIOD = 1, + V4L2_CID_CODEC_VIDEO_VPX_GOLDEN_FRAME_USE_PREV = 0, + V4L2_CID_CODEC_VIDEO_VPX_GOLDEN_FRAME_USE_REF_PERIOD = 1, }; -#define V4L2_CID_MPEG_VIDEO_VPX_MIN_QP (V4L2_CID_CODEC_BASE+507) -#define V4L2_CID_MPEG_VIDEO_VPX_MAX_QP (V4L2_CID_CODEC_BASE+508) -#define V4L2_CID_MPEG_VIDEO_VPX_I_FRAME_QP (V4L2_CID_CODEC_BASE+509) -#define V4L2_CID_MPEG_VIDEO_VPX_P_FRAME_QP (V4L2_CID_CODEC_BASE+510) +#define V4L2_CID_CODEC_VIDEO_VPX_MIN_QP (V4L2_CID_CODEC_BASE+507) +#define V4L2_CID_CODEC_VIDEO_VPX_MAX_QP (V4L2_CID_CODEC_BASE+508) +#define V4L2_CID_CODEC_VIDEO_VPX_I_FRAME_QP (V4L2_CID_CODEC_BASE+509) +#define V4L2_CID_CODEC_VIDEO_VPX_P_FRAME_QP (V4L2_CID_CODEC_BASE+510) -#define V4L2_CID_MPEG_VIDEO_VP8_PROFILE (V4L2_CID_CODEC_BASE+511) -enum v4l2_mpeg_video_vp8_profile { - V4L2_MPEG_VIDEO_VP8_PROFILE_0 = 0, - V4L2_MPEG_VIDEO_VP8_PROFILE_1 = 1, - V4L2_MPEG_VIDEO_VP8_PROFILE_2 = 2, - V4L2_MPEG_VIDEO_VP8_PROFILE_3 = 3, +#define V4L2_CID_CODEC_VIDEO_VP8_PROFILE (V4L2_CID_CODEC_BASE+511) +enum v4l2_codec_video_vp8_profile { + V4L2_CODEC_VIDEO_VP8_PROFILE_0 = 0, + V4L2_CODEC_VIDEO_VP8_PROFILE_1 = 1, + V4L2_CODEC_VIDEO_VP8_PROFILE_2 = 2, + V4L2_CODEC_VIDEO_VP8_PROFILE_3 = 3, }; /* Deprecated alias for compatibility reasons. */ -#define V4L2_CID_MPEG_VIDEO_VPX_PROFILE V4L2_CID_MPEG_VIDEO_VP8_PROFILE -#define V4L2_CID_MPEG_VIDEO_VP9_PROFILE (V4L2_CID_CODEC_BASE+512) -enum v4l2_mpeg_video_vp9_profile { - V4L2_MPEG_VIDEO_VP9_PROFILE_0 = 0, - V4L2_MPEG_VIDEO_VP9_PROFILE_1 = 1, - V4L2_MPEG_VIDEO_VP9_PROFILE_2 = 2, - V4L2_MPEG_VIDEO_VP9_PROFILE_3 = 3, -}; -#define V4L2_CID_MPEG_VIDEO_VP9_LEVEL (V4L2_CID_CODEC_BASE+513) -enum v4l2_mpeg_video_vp9_level { - V4L2_MPEG_VIDEO_VP9_LEVEL_1_0 = 0, - V4L2_MPEG_VIDEO_VP9_LEVEL_1_1 = 1, - V4L2_MPEG_VIDEO_VP9_LEVEL_2_0 = 2, - V4L2_MPEG_VIDEO_VP9_LEVEL_2_1 = 3, - V4L2_MPEG_VIDEO_VP9_LEVEL_3_0 = 4, - V4L2_MPEG_VIDEO_VP9_LEVEL_3_1 = 5, - V4L2_MPEG_VIDEO_VP9_LEVEL_4_0 = 6, - V4L2_MPEG_VIDEO_VP9_LEVEL_4_1 = 7, - V4L2_MPEG_VIDEO_VP9_LEVEL_5_0 = 8, - V4L2_MPEG_VIDEO_VP9_LEVEL_5_1 = 9, - V4L2_MPEG_VIDEO_VP9_LEVEL_5_2 = 10, - V4L2_MPEG_VIDEO_VP9_LEVEL_6_0 = 11, - V4L2_MPEG_VIDEO_VP9_LEVEL_6_1 = 12, - V4L2_MPEG_VIDEO_VP9_LEVEL_6_2 = 13, +#define V4L2_CID_CODEC_VIDEO_VPX_PROFILE V4L2_CID_MPEG_VIDEO_VP8_PROFILE +#define V4L2_CID_CODEC_VIDEO_VP9_PROFILE (V4L2_CID_CODEC_BASE+512) +enum v4l2_codec_video_vp9_profile { + V4L2_CODEC_VIDEO_VP9_PROFILE_0 = 0, + V4L2_CODEC_VIDEO_VP9_PROFILE_1 = 1, + V4L2_CODEC_VIDEO_VP9_PROFILE_2 = 2, + V4L2_CODEC_VIDEO_VP9_PROFILE_3 = 3, +}; +#define V4L2_CID_CODEC_VIDEO_VP9_LEVEL (V4L2_CID_CODEC_BASE+513) +enum v4l2_codec_video_vp9_level { + V4L2_CODEC_VIDEO_VP9_LEVEL_1_0 = 0, + V4L2_CODEC_VIDEO_VP9_LEVEL_1_1 = 1, + V4L2_CODEC_VIDEO_VP9_LEVEL_2_0 = 2, + V4L2_CODEC_VIDEO_VP9_LEVEL_2_1 = 3, + V4L2_CODEC_VIDEO_VP9_LEVEL_3_0 = 4, + V4L2_CODEC_VIDEO_VP9_LEVEL_3_1 = 5, + V4L2_CODEC_VIDEO_VP9_LEVEL_4_0 = 6, + V4L2_CODEC_VIDEO_VP9_LEVEL_4_1 = 7, + V4L2_CODEC_VIDEO_VP9_LEVEL_5_0 = 8, + V4L2_CODEC_VIDEO_VP9_LEVEL_5_1 = 9, + V4L2_CODEC_VIDEO_VP9_LEVEL_5_2 = 10, + V4L2_CODEC_VIDEO_VP9_LEVEL_6_0 = 11, + V4L2_CODEC_VIDEO_VP9_LEVEL_6_1 = 12, + V4L2_CODEC_VIDEO_VP9_LEVEL_6_2 = 13, }; /* CIDs for HEVC encoding. */ -#define V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP (V4L2_CID_CODEC_BASE + 600) -#define V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP (V4L2_CID_CODEC_BASE + 601) -#define V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_QP (V4L2_CID_CODEC_BASE + 602) -#define V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_QP (V4L2_CID_CODEC_BASE + 603) -#define V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_QP (V4L2_CID_CODEC_BASE + 604) -#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_QP (V4L2_CID_CODEC_BASE + 605) -#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_TYPE (V4L2_CID_CODEC_BASE + 606) -enum v4l2_mpeg_video_hevc_hier_coding_type { - V4L2_MPEG_VIDEO_HEVC_HIERARCHICAL_CODING_B = 0, - V4L2_MPEG_VIDEO_HEVC_HIERARCHICAL_CODING_P = 1, -}; -#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_LAYER (V4L2_CID_CODEC_BASE + 607) -#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L0_QP (V4L2_CID_CODEC_BASE + 608) -#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L1_QP (V4L2_CID_CODEC_BASE + 609) -#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L2_QP (V4L2_CID_CODEC_BASE + 610) -#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L3_QP (V4L2_CID_CODEC_BASE + 611) -#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L4_QP (V4L2_CID_CODEC_BASE + 612) -#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L5_QP (V4L2_CID_CODEC_BASE + 613) -#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L6_QP (V4L2_CID_CODEC_BASE + 614) -#define V4L2_CID_MPEG_VIDEO_HEVC_PROFILE (V4L2_CID_CODEC_BASE + 615) -enum v4l2_mpeg_video_hevc_profile { - V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN = 0, - V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN_STILL_PICTURE = 1, - V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN_10 = 2, -}; -#define V4L2_CID_MPEG_VIDEO_HEVC_LEVEL (V4L2_CID_CODEC_BASE + 616) -enum v4l2_mpeg_video_hevc_level { - V4L2_MPEG_VIDEO_HEVC_LEVEL_1 = 0, - V4L2_MPEG_VIDEO_HEVC_LEVEL_2 = 1, - V4L2_MPEG_VIDEO_HEVC_LEVEL_2_1 = 2, - V4L2_MPEG_VIDEO_HEVC_LEVEL_3 = 3, - V4L2_MPEG_VIDEO_HEVC_LEVEL_3_1 = 4, - V4L2_MPEG_VIDEO_HEVC_LEVEL_4 = 5, - V4L2_MPEG_VIDEO_HEVC_LEVEL_4_1 = 6, - V4L2_MPEG_VIDEO_HEVC_LEVEL_5 = 7, - V4L2_MPEG_VIDEO_HEVC_LEVEL_5_1 = 8, - V4L2_MPEG_VIDEO_HEVC_LEVEL_5_2 = 9, - V4L2_MPEG_VIDEO_HEVC_LEVEL_6 = 10, - V4L2_MPEG_VIDEO_HEVC_LEVEL_6_1 = 11, - V4L2_MPEG_VIDEO_HEVC_LEVEL_6_2 = 12, -}; -#define V4L2_CID_MPEG_VIDEO_HEVC_FRAME_RATE_RESOLUTION (V4L2_CID_CODEC_BASE + 617) -#define V4L2_CID_MPEG_VIDEO_HEVC_TIER (V4L2_CID_CODEC_BASE + 618) -enum v4l2_mpeg_video_hevc_tier { - V4L2_MPEG_VIDEO_HEVC_TIER_MAIN = 0, - V4L2_MPEG_VIDEO_HEVC_TIER_HIGH = 1, -}; -#define V4L2_CID_MPEG_VIDEO_HEVC_MAX_PARTITION_DEPTH (V4L2_CID_CODEC_BASE + 619) -#define V4L2_CID_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE (V4L2_CID_CODEC_BASE + 620) -enum v4l2_cid_mpeg_video_hevc_loop_filter_mode { - V4L2_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE_DISABLED = 0, - V4L2_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE_ENABLED = 1, - V4L2_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY = 2, -}; -#define V4L2_CID_MPEG_VIDEO_HEVC_LF_BETA_OFFSET_DIV2 (V4L2_CID_CODEC_BASE + 621) -#define V4L2_CID_MPEG_VIDEO_HEVC_LF_TC_OFFSET_DIV2 (V4L2_CID_CODEC_BASE + 622) -#define V4L2_CID_MPEG_VIDEO_HEVC_REFRESH_TYPE (V4L2_CID_CODEC_BASE + 623) -enum v4l2_cid_mpeg_video_hevc_refresh_type { - V4L2_MPEG_VIDEO_HEVC_REFRESH_NONE = 0, - V4L2_MPEG_VIDEO_HEVC_REFRESH_CRA = 1, - V4L2_MPEG_VIDEO_HEVC_REFRESH_IDR = 2, -}; -#define V4L2_CID_MPEG_VIDEO_HEVC_REFRESH_PERIOD (V4L2_CID_CODEC_BASE + 624) -#define V4L2_CID_MPEG_VIDEO_HEVC_LOSSLESS_CU (V4L2_CID_CODEC_BASE + 625) -#define V4L2_CID_MPEG_VIDEO_HEVC_CONST_INTRA_PRED (V4L2_CID_CODEC_BASE + 626) -#define V4L2_CID_MPEG_VIDEO_HEVC_WAVEFRONT (V4L2_CID_CODEC_BASE + 627) -#define V4L2_CID_MPEG_VIDEO_HEVC_GENERAL_PB (V4L2_CID_CODEC_BASE + 628) -#define V4L2_CID_MPEG_VIDEO_HEVC_TEMPORAL_ID (V4L2_CID_CODEC_BASE + 629) -#define V4L2_CID_MPEG_VIDEO_HEVC_STRONG_SMOOTHING (V4L2_CID_CODEC_BASE + 630) -#define V4L2_CID_MPEG_VIDEO_HEVC_MAX_NUM_MERGE_MV_MINUS1 (V4L2_CID_CODEC_BASE + 631) -#define V4L2_CID_MPEG_VIDEO_HEVC_INTRA_PU_SPLIT (V4L2_CID_CODEC_BASE + 632) -#define V4L2_CID_MPEG_VIDEO_HEVC_TMV_PREDICTION (V4L2_CID_CODEC_BASE + 633) -#define V4L2_CID_MPEG_VIDEO_HEVC_WITHOUT_STARTCODE (V4L2_CID_CODEC_BASE + 634) -#define V4L2_CID_MPEG_VIDEO_HEVC_SIZE_OF_LENGTH_FIELD (V4L2_CID_CODEC_BASE + 635) -enum v4l2_cid_mpeg_video_hevc_size_of_length_field { - V4L2_MPEG_VIDEO_HEVC_SIZE_0 = 0, - V4L2_MPEG_VIDEO_HEVC_SIZE_1 = 1, - V4L2_MPEG_VIDEO_HEVC_SIZE_2 = 2, - V4L2_MPEG_VIDEO_HEVC_SIZE_4 = 3, -}; -#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L0_BR (V4L2_CID_CODEC_BASE + 636) -#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L1_BR (V4L2_CID_CODEC_BASE + 637) -#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L2_BR (V4L2_CID_CODEC_BASE + 638) -#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L3_BR (V4L2_CID_CODEC_BASE + 639) -#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L4_BR (V4L2_CID_CODEC_BASE + 640) -#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L5_BR (V4L2_CID_CODEC_BASE + 641) -#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L6_BR (V4L2_CID_CODEC_BASE + 642) -#define V4L2_CID_MPEG_VIDEO_REF_NUMBER_FOR_PFRAMES (V4L2_CID_CODEC_BASE + 643) -#define V4L2_CID_MPEG_VIDEO_PREPEND_SPSPPS_TO_IDR (V4L2_CID_CODEC_BASE + 644) -#define V4L2_CID_MPEG_VIDEO_CONSTANT_QUALITY (V4L2_CID_CODEC_BASE + 645) -#define V4L2_CID_MPEG_VIDEO_FRAME_SKIP_MODE (V4L2_CID_CODEC_BASE + 646) -enum v4l2_mpeg_video_frame_skip_mode { - V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_DISABLED = 0, - V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_LEVEL_LIMIT = 1, - V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT = 2, -}; - -#define V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_MIN_QP (V4L2_CID_CODEC_BASE + 647) -#define V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_MAX_QP (V4L2_CID_CODEC_BASE + 648) -#define V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_MIN_QP (V4L2_CID_CODEC_BASE + 649) -#define V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_MAX_QP (V4L2_CID_CODEC_BASE + 650) -#define V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_MIN_QP (V4L2_CID_CODEC_BASE + 651) -#define V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_MAX_QP (V4L2_CID_CODEC_BASE + 652) - -/* MPEG-class control IDs specific to the CX2341x driver as defined by V4L2 */ +#define V4L2_CID_CODEC_VIDEO_HEVC_MIN_QP (V4L2_CID_CODEC_BASE + 600) +#define V4L2_CID_CODEC_VIDEO_HEVC_MAX_QP (V4L2_CID_CODEC_BASE + 601) +#define V4L2_CID_CODEC_VIDEO_HEVC_I_FRAME_QP (V4L2_CID_CODEC_BASE + 602) +#define V4L2_CID_CODEC_VIDEO_HEVC_P_FRAME_QP (V4L2_CID_CODEC_BASE + 603) +#define V4L2_CID_CODEC_VIDEO_HEVC_B_FRAME_QP (V4L2_CID_CODEC_BASE + 604) +#define V4L2_CID_CODEC_VIDEO_HEVC_HIER_QP (V4L2_CID_CODEC_BASE + 605) +#define V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_TYPE (V4L2_CID_CODEC_BASE + 606) +enum v4l2_codec_video_hevc_hier_coding_type { + V4L2_CODEC_VIDEO_HEVC_HIERARCHICAL_CODING_B = 0, + V4L2_CODEC_VIDEO_HEVC_HIERARCHICAL_CODING_P = 1, +}; +#define V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_LAYER (V4L2_CID_CODEC_BASE + 607) +#define V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L0_QP (V4L2_CID_CODEC_BASE + 608) +#define V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L1_QP (V4L2_CID_CODEC_BASE + 609) +#define V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L2_QP (V4L2_CID_CODEC_BASE + 610) +#define V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L3_QP (V4L2_CID_CODEC_BASE + 611) +#define V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L4_QP (V4L2_CID_CODEC_BASE + 612) +#define V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L5_QP (V4L2_CID_CODEC_BASE + 613) +#define V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L6_QP (V4L2_CID_CODEC_BASE + 614) +#define V4L2_CID_CODEC_VIDEO_HEVC_PROFILE (V4L2_CID_CODEC_BASE + 615) +enum v4l2_codec_video_hevc_profile { + V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN = 0, + V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN_STILL_PICTURE = 1, + V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN_10 = 2, +}; +#define V4L2_CID_CODEC_VIDEO_HEVC_LEVEL (V4L2_CID_CODEC_BASE + 616) +enum v4l2_codec_video_hevc_level { + V4L2_CODEC_VIDEO_HEVC_LEVEL_1 = 0, + V4L2_CODEC_VIDEO_HEVC_LEVEL_2 = 1, + V4L2_CODEC_VIDEO_HEVC_LEVEL_2_1 = 2, + V4L2_CODEC_VIDEO_HEVC_LEVEL_3 = 3, + V4L2_CODEC_VIDEO_HEVC_LEVEL_3_1 = 4, + V4L2_CODEC_VIDEO_HEVC_LEVEL_4 = 5, + V4L2_CODEC_VIDEO_HEVC_LEVEL_4_1 = 6, + V4L2_CODEC_VIDEO_HEVC_LEVEL_5 = 7, + V4L2_CODEC_VIDEO_HEVC_LEVEL_5_1 = 8, + V4L2_CODEC_VIDEO_HEVC_LEVEL_5_2 = 9, + V4L2_CODEC_VIDEO_HEVC_LEVEL_6 = 10, + V4L2_CODEC_VIDEO_HEVC_LEVEL_6_1 = 11, + V4L2_CODEC_VIDEO_HEVC_LEVEL_6_2 = 12, +}; +#define V4L2_CID_CODEC_VIDEO_HEVC_FRAME_RATE_RESOLUTION (V4L2_CID_CODEC_BASE + 617) +#define V4L2_CID_CODEC_VIDEO_HEVC_TIER (V4L2_CID_CODEC_BASE + 618) +enum v4l2_codec_video_hevc_tier { + V4L2_CODEC_VIDEO_HEVC_TIER_MAIN = 0, + V4L2_CODEC_VIDEO_HEVC_TIER_HIGH = 1, +}; +#define V4L2_CID_CODEC_VIDEO_HEVC_MAX_PARTITION_DEPTH (V4L2_CID_CODEC_BASE + 619) +#define V4L2_CID_CODEC_VIDEO_HEVC_LOOP_FILTER_MODE (V4L2_CID_CODEC_BASE + 620) +enum v4l2_codec_video_hevc_loop_filter_mode { + V4L2_CODEC_VIDEO_HEVC_LOOP_FILTER_MODE_DISABLED = 0, + V4L2_CODEC_VIDEO_HEVC_LOOP_FILTER_MODE_ENABLED = 1, + V4L2_CODEC_VIDEO_HEVC_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY = 2, +}; +#define V4L2_CID_CODEC_VIDEO_HEVC_LF_BETA_OFFSET_DIV2 (V4L2_CID_CODEC_BASE + 621) +#define V4L2_CID_CODEC_VIDEO_HEVC_LF_TC_OFFSET_DIV2 (V4L2_CID_CODEC_BASE + 622) +#define V4L2_CID_CODEC_VIDEO_HEVC_REFRESH_TYPE (V4L2_CID_CODEC_BASE + 623) +enum v4l2_codec_video_hevc_refresh_type { + V4L2_CODEC_VIDEO_HEVC_REFRESH_NONE = 0, + V4L2_CODEC_VIDEO_HEVC_REFRESH_CRA = 1, + V4L2_CODEC_VIDEO_HEVC_REFRESH_IDR = 2, +}; +#define V4L2_CID_CODEC_VIDEO_HEVC_REFRESH_PERIOD (V4L2_CID_CODEC_BASE + 624) +#define V4L2_CID_CODEC_VIDEO_HEVC_LOSSLESS_CU (V4L2_CID_CODEC_BASE + 625) +#define V4L2_CID_CODEC_VIDEO_HEVC_CONST_INTRA_PRED (V4L2_CID_CODEC_BASE + 626) +#define V4L2_CID_CODEC_VIDEO_HEVC_WAVEFRONT (V4L2_CID_CODEC_BASE + 627) +#define V4L2_CID_CODEC_VIDEO_HEVC_GENERAL_PB (V4L2_CID_CODEC_BASE + 628) +#define V4L2_CID_CODEC_VIDEO_HEVC_TEMPORAL_ID (V4L2_CID_CODEC_BASE + 629) +#define V4L2_CID_CODEC_VIDEO_HEVC_STRONG_SMOOTHING (V4L2_CID_CODEC_BASE + 630) +#define V4L2_CID_CODEC_VIDEO_HEVC_MAX_NUM_MERGE_MV_MINUS1 (V4L2_CID_CODEC_BASE + 631) +#define V4L2_CID_CODEC_VIDEO_HEVC_INTRA_PU_SPLIT (V4L2_CID_CODEC_BASE + 632) +#define V4L2_CID_CODEC_VIDEO_HEVC_TMV_PREDICTION (V4L2_CID_CODEC_BASE + 633) +#define V4L2_CID_CODEC_VIDEO_HEVC_WITHOUT_STARTCODE (V4L2_CID_CODEC_BASE + 634) +#define V4L2_CID_CODEC_VIDEO_HEVC_SIZE_OF_LENGTH_FIELD (V4L2_CID_CODEC_BASE + 635) +enum v4l2_codec_video_hevc_size_of_length_field { + V4L2_CODEC_VIDEO_HEVC_SIZE_0 = 0, + V4L2_CODEC_VIDEO_HEVC_SIZE_1 = 1, + V4L2_CODEC_VIDEO_HEVC_SIZE_2 = 2, + V4L2_CODEC_VIDEO_HEVC_SIZE_4 = 3, +}; +#define V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L0_BR (V4L2_CID_CODEC_BASE + 636) +#define V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L1_BR (V4L2_CID_CODEC_BASE + 637) +#define V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L2_BR (V4L2_CID_CODEC_BASE + 638) +#define V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L3_BR (V4L2_CID_CODEC_BASE + 639) +#define V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L4_BR (V4L2_CID_CODEC_BASE + 640) +#define V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L5_BR (V4L2_CID_CODEC_BASE + 641) +#define V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L6_BR (V4L2_CID_CODEC_BASE + 642) +#define V4L2_CID_CODEC_VIDEO_REF_NUMBER_FOR_PFRAMES (V4L2_CID_CODEC_BASE + 643) +#define V4L2_CID_CODEC_VIDEO_PREPEND_SPSPPS_TO_IDR (V4L2_CID_CODEC_BASE + 644) +#define V4L2_CID_CODEC_VIDEO_CONSTANT_QUALITY (V4L2_CID_CODEC_BASE + 645) +#define V4L2_CID_CODEC_VIDEO_FRAME_SKIP_MODE (V4L2_CID_CODEC_BASE + 646) +enum v4l2_codec_video_frame_skip_mode { + V4L2_CODEC_VIDEO_FRAME_SKIP_MODE_DISABLED = 0, + V4L2_CODEC_VIDEO_FRAME_SKIP_MODE_LEVEL_LIMIT = 1, + V4L2_CODEC_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT = 2, +}; + +#define V4L2_CID_CODEC_VIDEO_HEVC_I_FRAME_MIN_QP (V4L2_CID_CODEC_BASE + 647) +#define V4L2_CID_CODEC_VIDEO_HEVC_I_FRAME_MAX_QP (V4L2_CID_CODEC_BASE + 648) +#define V4L2_CID_CODEC_VIDEO_HEVC_P_FRAME_MIN_QP (V4L2_CID_CODEC_BASE + 649) +#define V4L2_CID_CODEC_VIDEO_HEVC_P_FRAME_MAX_QP (V4L2_CID_CODEC_BASE + 650) +#define V4L2_CID_CODEC_VIDEO_HEVC_B_FRAME_MIN_QP (V4L2_CID_CODEC_BASE + 651) +#define V4L2_CID_CODEC_VIDEO_HEVC_B_FRAME_MAX_QP (V4L2_CID_CODEC_BASE + 652) + +/* Codec-class control IDs specific to the CX2341x driver as defined by V4L2 */ #define V4L2_CID_CODEC_CX2341X_BASE (V4L2_CTRL_CLASS_CODEC | 0x1000) -#define V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE (V4L2_CID_CODEC_CX2341X_BASE+0) -enum v4l2_mpeg_cx2341x_video_spatial_filter_mode { - V4L2_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE_MANUAL = 0, - V4L2_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE_AUTO = 1, -}; -#define V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER (V4L2_CID_CODEC_CX2341X_BASE+1) -#define V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE (V4L2_CID_CODEC_CX2341X_BASE+2) -enum v4l2_mpeg_cx2341x_video_luma_spatial_filter_type { - V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_OFF = 0, - V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_1D_HOR = 1, - V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_1D_VERT = 2, - V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_2D_HV_SEPARABLE = 3, - V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_2D_SYM_NON_SEPARABLE = 4, -}; -#define V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE (V4L2_CID_CODEC_CX2341X_BASE+3) -enum v4l2_mpeg_cx2341x_video_chroma_spatial_filter_type { - V4L2_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_OFF = 0, - V4L2_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_1D_HOR = 1, -}; -#define V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE (V4L2_CID_CODEC_CX2341X_BASE+4) -enum v4l2_mpeg_cx2341x_video_temporal_filter_mode { - V4L2_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_MANUAL = 0, - V4L2_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_AUTO = 1, -}; -#define V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER (V4L2_CID_CODEC_CX2341X_BASE+5) -#define V4L2_CID_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE (V4L2_CID_CODEC_CX2341X_BASE+6) -enum v4l2_mpeg_cx2341x_video_median_filter_type { - V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF = 0, - V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_HOR = 1, - V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_VERT = 2, - V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_HOR_VERT = 3, - V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_DIAG = 4, -}; -#define V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM (V4L2_CID_CODEC_CX2341X_BASE+7) -#define V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP (V4L2_CID_CODEC_CX2341X_BASE+8) -#define V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM (V4L2_CID_CODEC_CX2341X_BASE+9) -#define V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP (V4L2_CID_CODEC_CX2341X_BASE+10) -#define V4L2_CID_MPEG_CX2341X_STREAM_INSERT_NAV_PACKETS (V4L2_CID_CODEC_CX2341X_BASE+11) - -/* MPEG-class control IDs specific to the Samsung MFC 5.1 driver as defined by V4L2 */ +#define V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE (V4L2_CID_CODEC_CX2341X_BASE+0) +enum v4l2_codec_cx2341x_video_spatial_filter_mode { + V4L2_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE_MANUAL = 0, + V4L2_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE_AUTO = 1, +}; +#define V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER (V4L2_CID_CODEC_CX2341X_BASE+1) +#define V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE (V4L2_CID_CODEC_CX2341X_BASE+2) +enum v4l2_codec_cx2341x_video_luma_spatial_filter_type { + V4L2_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_OFF = 0, + V4L2_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_1D_HOR = 1, + V4L2_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_1D_VERT = 2, + V4L2_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_2D_HV_SEPARABLE = 3, + V4L2_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_2D_SYM_NON_SEPARABLE = 4, +}; +#define V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE (V4L2_CID_CODEC_CX2341X_BASE+3) +enum v4l2_codec_cx2341x_video_chroma_spatial_filter_type { + V4L2_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_OFF = 0, + V4L2_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_1D_HOR = 1, +}; +#define V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE (V4L2_CID_CODEC_CX2341X_BASE+4) +enum v4l2_codec_cx2341x_video_temporal_filter_mode { + V4L2_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_MANUAL = 0, + V4L2_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_AUTO = 1, +}; +#define V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER (V4L2_CID_CODEC_CX2341X_BASE+5) +#define V4L2_CID_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE (V4L2_CID_CODEC_CX2341X_BASE+6) +enum v4l2_codec_cx2341x_video_median_filter_type { + V4L2_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF = 0, + V4L2_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_HOR = 1, + V4L2_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_VERT = 2, + V4L2_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_HOR_VERT = 3, + V4L2_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_DIAG = 4, +}; +#define V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM (V4L2_CID_CODEC_CX2341X_BASE+7) +#define V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP (V4L2_CID_CODEC_CX2341X_BASE+8) +#define V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM (V4L2_CID_CODEC_CX2341X_BASE+9) +#define V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP (V4L2_CID_CODEC_CX2341X_BASE+10) +#define V4L2_CID_CODEC_CX2341X_STREAM_INSERT_NAV_PACKETS (V4L2_CID_CODEC_CX2341X_BASE+11) + +/* Codec-class control IDs specific to the Samsung MFC 5.1 driver as defined by V4L2 */ #define V4L2_CID_CODEC_MFC51_BASE (V4L2_CTRL_CLASS_CODEC | 0x1100) -#define V4L2_CID_MPEG_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY (V4L2_CID_CODEC_MFC51_BASE+0) -#define V4L2_CID_MPEG_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY_ENABLE (V4L2_CID_CODEC_MFC51_BASE+1) -#define V4L2_CID_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE (V4L2_CID_CODEC_MFC51_BASE+2) -enum v4l2_mpeg_mfc51_video_frame_skip_mode { - V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_DISABLED = 0, - V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_LEVEL_LIMIT = 1, - V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT = 2, -}; -#define V4L2_CID_MPEG_MFC51_VIDEO_FORCE_FRAME_TYPE (V4L2_CID_CODEC_MFC51_BASE+3) -enum v4l2_mpeg_mfc51_video_force_frame_type { - V4L2_MPEG_MFC51_VIDEO_FORCE_FRAME_TYPE_DISABLED = 0, - V4L2_MPEG_MFC51_VIDEO_FORCE_FRAME_TYPE_I_FRAME = 1, - V4L2_MPEG_MFC51_VIDEO_FORCE_FRAME_TYPE_NOT_CODED = 2, -}; -#define V4L2_CID_MPEG_MFC51_VIDEO_PADDING (V4L2_CID_CODEC_MFC51_BASE+4) -#define V4L2_CID_MPEG_MFC51_VIDEO_PADDING_YUV (V4L2_CID_CODEC_MFC51_BASE+5) -#define V4L2_CID_MPEG_MFC51_VIDEO_RC_FIXED_TARGET_BIT (V4L2_CID_CODEC_MFC51_BASE+6) -#define V4L2_CID_MPEG_MFC51_VIDEO_RC_REACTION_COEFF (V4L2_CID_CODEC_MFC51_BASE+7) -#define V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_ACTIVITY (V4L2_CID_CODEC_MFC51_BASE+50) -#define V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_DARK (V4L2_CID_CODEC_MFC51_BASE+51) -#define V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_SMOOTH (V4L2_CID_CODEC_MFC51_BASE+52) -#define V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_STATIC (V4L2_CID_CODEC_MFC51_BASE+53) -#define V4L2_CID_MPEG_MFC51_VIDEO_H264_NUM_REF_PIC_FOR_P (V4L2_CID_CODEC_MFC51_BASE+54) - -/* Camera class control IDs */ +#define V4L2_CID_CODEC_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY (V4L2_CID_CODEC_MFC51_BASE+0) +#define V4L2_CID_CODEC_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY_ENABLE (V4L2_CID_CODEC_MFC51_BASE+1) +#define V4L2_CID_CODEC_MFC51_VIDEO_FRAME_SKIP_MODE (V4L2_CID_CODEC_MFC51_BASE+2) +enum v4l2_codec_mfc51_video_frame_skip_mode { + V4L2_CODEC_MFC51_VIDEO_FRAME_SKIP_MODE_DISABLED = 0, + V4L2_CODEC_MFC51_VIDEO_FRAME_SKIP_MODE_LEVEL_LIMIT = 1, + V4L2_CODEC_MFC51_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT = 2, +}; +#define V4L2_CID_CODEC_MFC51_VIDEO_FORCE_FRAME_TYPE (V4L2_CID_CODEC_MFC51_BASE+3) +enum v4l2_codec_mfc51_video_force_frame_type { + V4L2_CODEC_MFC51_VIDEO_FORCE_FRAME_TYPE_DISABLED = 0, + V4L2_CODEC_MFC51_VIDEO_FORCE_FRAME_TYPE_I_FRAME = 1, + V4L2_CODEC_MFC51_VIDEO_FORCE_FRAME_TYPE_NOT_CODED = 2, +}; +#define V4L2_CID_CODEC_MFC51_VIDEO_PADDING (V4L2_CID_CODEC_MFC51_BASE+4) +#define V4L2_CID_CODEC_MFC51_VIDEO_PADDING_YUV (V4L2_CID_CODEC_MFC51_BASE+5) +#define V4L2_CID_CODEC_MFC51_VIDEO_RC_FIXED_TARGET_BIT (V4L2_CID_CODEC_MFC51_BASE+6) +#define V4L2_CID_CODEC_MFC51_VIDEO_RC_REACTION_COEFF (V4L2_CID_CODEC_MFC51_BASE+7) +#define V4L2_CID_CODEC_MFC51_VIDEO_H264_ADAPTIVE_RC_ACTIVITY (V4L2_CID_CODEC_MFC51_BASE+50) +#define V4L2_CID_CODEC_MFC51_VIDEO_H264_ADAPTIVE_RC_DARK (V4L2_CID_CODEC_MFC51_BASE+51) +#define V4L2_CID_CODEC_MFC51_VIDEO_H264_ADAPTIVE_RC_SMOOTH (V4L2_CID_CODEC_MFC51_BASE+52) +#define V4L2_CID_CODEC_MFC51_VIDEO_H264_ADAPTIVE_RC_STATIC (V4L2_CID_CODEC_MFC51_BASE+53) +#define V4L2_CID_CODEC_MFC51_VIDEO_H264_NUM_REF_PIC_FOR_P (V4L2_CID_CODEC_MFC51_BASE+54) + +/* Camera class control IDs */ #define V4L2_CID_CAMERA_CLASS_BASE (V4L2_CTRL_CLASS_CAMERA | 0x900) #define V4L2_CID_CAMERA_CLASS (V4L2_CTRL_CLASS_CAMERA | 1) @@ -1120,7 +1115,7 @@ enum v4l2_jpeg_chroma_subsampling { #define V4L2_CID_DEINTERLACING_MODE (V4L2_CID_IMAGE_PROC_CLASS_BASE + 4) #define V4L2_CID_DIGITAL_GAIN (V4L2_CID_IMAGE_PROC_CLASS_BASE + 5) -/* DV-class control IDs defined by V4L2 */ +/* DV-class control IDs defined by V4L2 */ #define V4L2_CID_DV_CLASS_BASE (V4L2_CTRL_CLASS_DV | 0x900) #define V4L2_CID_DV_CLASS (V4L2_CTRL_CLASS_DV | 1) @@ -1185,7 +1180,7 @@ enum v4l2_deemphasis { #define V4L2_CID_RF_TUNER_PLL_LOCK (V4L2_CID_RF_TUNER_CLASS_BASE + 91) -/* Detection-class control IDs defined by V4L2 */ +/* Detection-class control IDs defined by V4L2 */ #define V4L2_CID_DETECT_CLASS_BASE (V4L2_CTRL_CLASS_DETECT | 0x900) #define V4L2_CID_DETECT_CLASS (V4L2_CTRL_CLASS_DETECT | 1) @@ -1201,7 +1196,7 @@ enum v4l2_detect_md_mode { #define V4L2_CID_DETECT_MD_REGION_GRID (V4L2_CID_DETECT_CLASS_BASE + 4) -/* Stateless CODECs controls */ +/* Stateless CODECs controls */ #define V4L2_CID_CODEC_STATELESS_BASE (V4L2_CTRL_CLASS_CODEC_STATELESS | 0x900) #define V4L2_CID_CODEC_STATELESS_CLASS (V4L2_CTRL_CLASS_CODEC_STATELESS | 1) @@ -1666,4 +1661,572 @@ struct v4l2_ctrl_fwht_params { #define V4L2_CID_MPEG_MFC51_BASE V4L2_CID_CODEC_MFC51_BASE #endif +/* + * Originally all these controls and data structures where all called + * MPEG, regardless for which codec they actually applied to. This was + * due to historical reasons: the MPEG codec was the first added to V4L2, + * and unfortunately a lack for foresight meant that that became the + * default prefix, regardless of the actual codec. + * + * Now that MPEG has been replaced with CODEC, we still need to keep + * the old names around to avoid breaking the ABI, hence these defines. + */ +#define v4l2_mpeg_stream_type v4l2_codec_stream_type +#define V4L2_MPEG_STREAM_TYPE_MPEG2_PS V4L2_CODEC_STREAM_TYPE_MPEG2_PS +#define V4L2_MPEG_STREAM_TYPE_MPEG2_TS V4L2_CODEC_STREAM_TYPE_MPEG2_TS +#define V4L2_MPEG_STREAM_TYPE_MPEG1_SS V4L2_CODEC_STREAM_TYPE_MPEG1_SS +#define V4L2_MPEG_STREAM_TYPE_MPEG2_DVD V4L2_CODEC_STREAM_TYPE_MPEG2_DVD +#define V4L2_MPEG_STREAM_TYPE_MPEG1_VCD V4L2_CODEC_STREAM_TYPE_MPEG1_VCD +#define V4L2_MPEG_STREAM_TYPE_MPEG2_SVCD V4L2_CODEC_STREAM_TYPE_MPEG2_SVCD +#define v4l2_mpeg_stream_vbi_fmt v4l2_codec_stream_vbi_fmt +#define V4L2_MPEG_STREAM_VBI_FMT_NONE V4L2_CODEC_STREAM_VBI_FMT_NONE +#define V4L2_MPEG_STREAM_VBI_FMT_IVTV V4L2_CODEC_STREAM_VBI_FMT_IVTV +#define v4l2_mpeg_audio_sampling_freq v4l2_codec_audio_sampling_freq +#define V4L2_MPEG_AUDIO_SAMPLING_FREQ_44100 V4L2_CODEC_AUDIO_SAMPLING_FREQ_44100 +#define V4L2_MPEG_AUDIO_SAMPLING_FREQ_48000 V4L2_CODEC_AUDIO_SAMPLING_FREQ_48000 +#define V4L2_MPEG_AUDIO_SAMPLING_FREQ_32000 V4L2_CODEC_AUDIO_SAMPLING_FREQ_32000 +#define v4l2_mpeg_audio_encoding v4l2_codec_audio_encoding +#define V4L2_MPEG_AUDIO_ENCODING_LAYER_1 V4L2_CODEC_AUDIO_ENCODING_LAYER_1 +#define V4L2_MPEG_AUDIO_ENCODING_LAYER_2 V4L2_CODEC_AUDIO_ENCODING_LAYER_2 +#define V4L2_MPEG_AUDIO_ENCODING_LAYER_3 V4L2_CODEC_AUDIO_ENCODING_LAYER_3 +#define V4L2_MPEG_AUDIO_ENCODING_AAC V4L2_CODEC_AUDIO_ENCODING_AAC +#define V4L2_MPEG_AUDIO_ENCODING_AC3 V4L2_CODEC_AUDIO_ENCODING_AC3 +#define v4l2_mpeg_audio_l1_bitrate v4l2_codec_audio_l1_bitrate +#define V4L2_MPEG_AUDIO_L1_BITRATE_32K V4L2_CODEC_AUDIO_L1_BITRATE_32K +#define V4L2_MPEG_AUDIO_L1_BITRATE_64K V4L2_CODEC_AUDIO_L1_BITRATE_64K +#define V4L2_MPEG_AUDIO_L1_BITRATE_96K V4L2_CODEC_AUDIO_L1_BITRATE_96K +#define V4L2_MPEG_AUDIO_L1_BITRATE_128K V4L2_CODEC_AUDIO_L1_BITRATE_128K +#define V4L2_MPEG_AUDIO_L1_BITRATE_160K V4L2_CODEC_AUDIO_L1_BITRATE_160K +#define V4L2_MPEG_AUDIO_L1_BITRATE_192K V4L2_CODEC_AUDIO_L1_BITRATE_192K +#define V4L2_MPEG_AUDIO_L1_BITRATE_224K V4L2_CODEC_AUDIO_L1_BITRATE_224K +#define V4L2_MPEG_AUDIO_L1_BITRATE_256K V4L2_CODEC_AUDIO_L1_BITRATE_256K +#define V4L2_MPEG_AUDIO_L1_BITRATE_288K V4L2_CODEC_AUDIO_L1_BITRATE_288K +#define V4L2_MPEG_AUDIO_L1_BITRATE_320K V4L2_CODEC_AUDIO_L1_BITRATE_320K +#define V4L2_MPEG_AUDIO_L1_BITRATE_352K V4L2_CODEC_AUDIO_L1_BITRATE_352K +#define V4L2_MPEG_AUDIO_L1_BITRATE_384K V4L2_CODEC_AUDIO_L1_BITRATE_384K +#define V4L2_MPEG_AUDIO_L1_BITRATE_416K V4L2_CODEC_AUDIO_L1_BITRATE_416K +#define V4L2_MPEG_AUDIO_L1_BITRATE_448K V4L2_CODEC_AUDIO_L1_BITRATE_448K +#define v4l2_mpeg_audio_l2_bitrate v4l2_codec_audio_l2_bitrate +#define V4L2_MPEG_AUDIO_L2_BITRATE_32K V4L2_CODEC_AUDIO_L2_BITRATE_32K +#define V4L2_MPEG_AUDIO_L2_BITRATE_48K V4L2_CODEC_AUDIO_L2_BITRATE_48K +#define V4L2_MPEG_AUDIO_L2_BITRATE_56K V4L2_CODEC_AUDIO_L2_BITRATE_56K +#define V4L2_MPEG_AUDIO_L2_BITRATE_64K V4L2_CODEC_AUDIO_L2_BITRATE_64K +#define V4L2_MPEG_AUDIO_L2_BITRATE_80K V4L2_CODEC_AUDIO_L2_BITRATE_80K +#define V4L2_MPEG_AUDIO_L2_BITRATE_96K V4L2_CODEC_AUDIO_L2_BITRATE_96K +#define V4L2_MPEG_AUDIO_L2_BITRATE_112K V4L2_CODEC_AUDIO_L2_BITRATE_112K +#define V4L2_MPEG_AUDIO_L2_BITRATE_128K V4L2_CODEC_AUDIO_L2_BITRATE_128K +#define V4L2_MPEG_AUDIO_L2_BITRATE_160K V4L2_CODEC_AUDIO_L2_BITRATE_160K +#define V4L2_MPEG_AUDIO_L2_BITRATE_192K V4L2_CODEC_AUDIO_L2_BITRATE_192K +#define V4L2_MPEG_AUDIO_L2_BITRATE_224K V4L2_CODEC_AUDIO_L2_BITRATE_224K +#define V4L2_MPEG_AUDIO_L2_BITRATE_256K V4L2_CODEC_AUDIO_L2_BITRATE_256K +#define V4L2_MPEG_AUDIO_L2_BITRATE_320K V4L2_CODEC_AUDIO_L2_BITRATE_320K +#define V4L2_MPEG_AUDIO_L2_BITRATE_384K V4L2_CODEC_AUDIO_L2_BITRATE_384K +#define v4l2_mpeg_audio_l3_bitrate v4l2_codec_audio_l3_bitrate +#define V4L2_MPEG_AUDIO_L3_BITRATE_32K V4L2_CODEC_AUDIO_L3_BITRATE_32K +#define V4L2_MPEG_AUDIO_L3_BITRATE_40K V4L2_CODEC_AUDIO_L3_BITRATE_40K +#define V4L2_MPEG_AUDIO_L3_BITRATE_48K V4L2_CODEC_AUDIO_L3_BITRATE_48K +#define V4L2_MPEG_AUDIO_L3_BITRATE_56K V4L2_CODEC_AUDIO_L3_BITRATE_56K +#define V4L2_MPEG_AUDIO_L3_BITRATE_64K V4L2_CODEC_AUDIO_L3_BITRATE_64K +#define V4L2_MPEG_AUDIO_L3_BITRATE_80K V4L2_CODEC_AUDIO_L3_BITRATE_80K +#define V4L2_MPEG_AUDIO_L3_BITRATE_96K V4L2_CODEC_AUDIO_L3_BITRATE_96K +#define V4L2_MPEG_AUDIO_L3_BITRATE_112K V4L2_CODEC_AUDIO_L3_BITRATE_112K +#define V4L2_MPEG_AUDIO_L3_BITRATE_128K V4L2_CODEC_AUDIO_L3_BITRATE_128K +#define V4L2_MPEG_AUDIO_L3_BITRATE_160K V4L2_CODEC_AUDIO_L3_BITRATE_160K +#define V4L2_MPEG_AUDIO_L3_BITRATE_192K V4L2_CODEC_AUDIO_L3_BITRATE_192K +#define V4L2_MPEG_AUDIO_L3_BITRATE_224K V4L2_CODEC_AUDIO_L3_BITRATE_224K +#define V4L2_MPEG_AUDIO_L3_BITRATE_256K V4L2_CODEC_AUDIO_L3_BITRATE_256K +#define V4L2_MPEG_AUDIO_L3_BITRATE_320K V4L2_CODEC_AUDIO_L3_BITRATE_320K +#define v4l2_mpeg_audio_mode v4l2_codec_audio_mode +#define V4L2_MPEG_AUDIO_MODE_STEREO V4L2_CODEC_AUDIO_MODE_STEREO +#define V4L2_MPEG_AUDIO_MODE_JOINT_STEREO V4L2_CODEC_AUDIO_MODE_JOINT_STEREO +#define V4L2_MPEG_AUDIO_MODE_DUAL V4L2_CODEC_AUDIO_MODE_DUAL +#define V4L2_MPEG_AUDIO_MODE_MONO V4L2_CODEC_AUDIO_MODE_MONO +#define v4l2_mpeg_audio_mode_extension v4l2_codec_audio_mode_extension +#define V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_4 V4L2_CODEC_AUDIO_MODE_EXTENSION_BOUND_4 +#define V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_8 V4L2_CODEC_AUDIO_MODE_EXTENSION_BOUND_8 +#define V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_12 V4L2_CODEC_AUDIO_MODE_EXTENSION_BOUND_12 +#define V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_16 V4L2_CODEC_AUDIO_MODE_EXTENSION_BOUND_16 +#define v4l2_mpeg_audio_emphasis v4l2_codec_audio_emphasis +#define V4L2_MPEG_AUDIO_EMPHASIS_NONE V4L2_CODEC_AUDIO_EMPHASIS_NONE +#define V4L2_MPEG_AUDIO_EMPHASIS_50_DIV_15_uS V4L2_CODEC_AUDIO_EMPHASIS_50_DIV_15_uS +#define V4L2_MPEG_AUDIO_EMPHASIS_CCITT_J17 V4L2_CODEC_AUDIO_EMPHASIS_CCITT_J17 +#define v4l2_mpeg_audio_crc v4l2_codec_audio_crc +#define V4L2_MPEG_AUDIO_CRC_NONE V4L2_CODEC_AUDIO_CRC_NONE +#define V4L2_MPEG_AUDIO_CRC_CRC16 V4L2_CODEC_AUDIO_CRC_CRC16 +#define v4l2_mpeg_audio_ac3_bitrate v4l2_codec_audio_ac3_bitrate +#define V4L2_MPEG_AUDIO_AC3_BITRATE_32K V4L2_CODEC_AUDIO_AC3_BITRATE_32K +#define V4L2_MPEG_AUDIO_AC3_BITRATE_40K V4L2_CODEC_AUDIO_AC3_BITRATE_40K +#define V4L2_MPEG_AUDIO_AC3_BITRATE_48K V4L2_CODEC_AUDIO_AC3_BITRATE_48K +#define V4L2_MPEG_AUDIO_AC3_BITRATE_56K V4L2_CODEC_AUDIO_AC3_BITRATE_56K +#define V4L2_MPEG_AUDIO_AC3_BITRATE_64K V4L2_CODEC_AUDIO_AC3_BITRATE_64K +#define V4L2_MPEG_AUDIO_AC3_BITRATE_80K V4L2_CODEC_AUDIO_AC3_BITRATE_80K +#define V4L2_MPEG_AUDIO_AC3_BITRATE_96K V4L2_CODEC_AUDIO_AC3_BITRATE_96K +#define V4L2_MPEG_AUDIO_AC3_BITRATE_112K V4L2_CODEC_AUDIO_AC3_BITRATE_112K +#define V4L2_MPEG_AUDIO_AC3_BITRATE_128K V4L2_CODEC_AUDIO_AC3_BITRATE_128K +#define V4L2_MPEG_AUDIO_AC3_BITRATE_160K V4L2_CODEC_AUDIO_AC3_BITRATE_160K +#define V4L2_MPEG_AUDIO_AC3_BITRATE_192K V4L2_CODEC_AUDIO_AC3_BITRATE_192K +#define V4L2_MPEG_AUDIO_AC3_BITRATE_224K V4L2_CODEC_AUDIO_AC3_BITRATE_224K +#define V4L2_MPEG_AUDIO_AC3_BITRATE_256K V4L2_CODEC_AUDIO_AC3_BITRATE_256K +#define V4L2_MPEG_AUDIO_AC3_BITRATE_320K V4L2_CODEC_AUDIO_AC3_BITRATE_320K +#define V4L2_MPEG_AUDIO_AC3_BITRATE_384K V4L2_CODEC_AUDIO_AC3_BITRATE_384K +#define V4L2_MPEG_AUDIO_AC3_BITRATE_448K V4L2_CODEC_AUDIO_AC3_BITRATE_448K +#define V4L2_MPEG_AUDIO_AC3_BITRATE_512K V4L2_CODEC_AUDIO_AC3_BITRATE_512K +#define V4L2_MPEG_AUDIO_AC3_BITRATE_576K V4L2_CODEC_AUDIO_AC3_BITRATE_576K +#define V4L2_MPEG_AUDIO_AC3_BITRATE_640K V4L2_CODEC_AUDIO_AC3_BITRATE_640K +#define v4l2_mpeg_audio_dec_playback v4l2_codec_audio_dec_playback +#define V4L2_MPEG_AUDIO_DEC_PLAYBACK_AUTO V4L2_CODEC_AUDIO_DEC_PLAYBACK_AUTO +#define V4L2_MPEG_AUDIO_DEC_PLAYBACK_STEREO V4L2_CODEC_AUDIO_DEC_PLAYBACK_STEREO +#define V4L2_MPEG_AUDIO_DEC_PLAYBACK_LEFT V4L2_CODEC_AUDIO_DEC_PLAYBACK_LEFT +#define V4L2_MPEG_AUDIO_DEC_PLAYBACK_RIGHT V4L2_CODEC_AUDIO_DEC_PLAYBACK_RIGHT +#define V4L2_MPEG_AUDIO_DEC_PLAYBACK_MONO V4L2_CODEC_AUDIO_DEC_PLAYBACK_MONO +#define V4L2_MPEG_AUDIO_DEC_PLAYBACK_SWAPPED_STEREO V4L2_CODEC_AUDIO_DEC_PLAYBACK_SWAPPED_STEREO +#define v4l2_mpeg_video_encoding v4l2_codec_video_encoding +#define V4L2_MPEG_VIDEO_ENCODING_MPEG_1 V4L2_CODEC_VIDEO_ENCODING_MPEG_1 +#define V4L2_MPEG_VIDEO_ENCODING_MPEG_2 V4L2_CODEC_VIDEO_ENCODING_MPEG_2 +#define V4L2_MPEG_VIDEO_ENCODING_MPEG_4_AVC V4L2_CODEC_VIDEO_ENCODING_MPEG_4_AVC +#define v4l2_mpeg_video_aspect v4l2_codec_video_aspect +#define V4L2_MPEG_VIDEO_ASPECT_1x1 V4L2_CODEC_VIDEO_ASPECT_1x1 +#define V4L2_MPEG_VIDEO_ASPECT_4x3 V4L2_CODEC_VIDEO_ASPECT_4x3 +#define V4L2_MPEG_VIDEO_ASPECT_16x9 V4L2_CODEC_VIDEO_ASPECT_16x9 +#define V4L2_MPEG_VIDEO_ASPECT_221x100 V4L2_CODEC_VIDEO_ASPECT_221x100 +#define v4l2_mpeg_video_bitrate_mode v4l2_codec_video_bitrate_mode +#define V4L2_MPEG_VIDEO_BITRATE_MODE_VBR V4L2_CODEC_VIDEO_BITRATE_MODE_VBR +#define V4L2_MPEG_VIDEO_BITRATE_MODE_CBR V4L2_CODEC_VIDEO_BITRATE_MODE_CBR +#define V4L2_MPEG_VIDEO_BITRATE_MODE_CQ V4L2_CODEC_VIDEO_BITRATE_MODE_CQ +#define v4l2_mpeg_video_header_mode v4l2_codec_video_header_mode +#define V4L2_MPEG_VIDEO_HEADER_MODE_SEPARATE V4L2_CODEC_VIDEO_HEADER_MODE_SEPARATE +#define V4L2_MPEG_VIDEO_HEADER_MODE_JOINED_WITH_1ST_FRAME V4L2_CODEC_VIDEO_HEADER_MODE_JOINED_WITH_1ST_FRAME +#define v4l2_mpeg_video_multi_slice_mode v4l2_codec_video_multi_slice_mode +#define V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_SINGLE V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_SINGLE +#define V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_MB V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_MAX_MB +#define V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_BYTES V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_MAX_BYTES +#define V4L2_MPEG_VIDEO_MULTI_SICE_MODE_MAX_MB V4L2_CODEC_VIDEO_MULTI_SICE_MODE_MAX_MB +#define V4L2_MPEG_VIDEO_MULTI_SICE_MODE_MAX_BYTES V4L2_CODEC_VIDEO_MULTI_SICE_MODE_MAX_BYTES +#define v4l2_mpeg_video_mpeg2_level v4l2_codec_video_mpeg2_level +#define V4L2_MPEG_VIDEO_MPEG2_LEVEL_LOW V4L2_CODEC_VIDEO_MPEG2_LEVEL_LOW +#define V4L2_MPEG_VIDEO_MPEG2_LEVEL_MAIN V4L2_CODEC_VIDEO_MPEG2_LEVEL_MAIN +#define V4L2_MPEG_VIDEO_MPEG2_LEVEL_HIGH_1440 V4L2_CODEC_VIDEO_MPEG2_LEVEL_HIGH_1440 +#define V4L2_MPEG_VIDEO_MPEG2_LEVEL_HIGH V4L2_CODEC_VIDEO_MPEG2_LEVEL_HIGH +#define v4l2_mpeg_video_mpeg2_profile v4l2_codec_video_mpeg2_profile +#define V4L2_MPEG_VIDEO_MPEG2_PROFILE_SIMPLE V4L2_CODEC_VIDEO_MPEG2_PROFILE_SIMPLE +#define V4L2_MPEG_VIDEO_MPEG2_PROFILE_MAIN V4L2_CODEC_VIDEO_MPEG2_PROFILE_MAIN +#define V4L2_MPEG_VIDEO_MPEG2_PROFILE_SNR_SCALABLE V4L2_CODEC_VIDEO_MPEG2_PROFILE_SNR_SCALABLE +#define V4L2_MPEG_VIDEO_MPEG2_PROFILE_SPATIALLY_SCALABLE V4L2_CODEC_VIDEO_MPEG2_PROFILE_SPATIALLY_SCALABLE +#define V4L2_MPEG_VIDEO_MPEG2_PROFILE_HIGH V4L2_CODEC_VIDEO_MPEG2_PROFILE_HIGH +#define V4L2_MPEG_VIDEO_MPEG2_PROFILE_MULTIVIEW V4L2_CODEC_VIDEO_MPEG2_PROFILE_MULTIVIEW +#define v4l2_mpeg_video_h264_entropy_mode v4l2_codec_video_h264_entropy_mode +#define V4L2_MPEG_VIDEO_H264_ENTROPY_MODE_CAVLC V4L2_CODEC_VIDEO_H264_ENTROPY_MODE_CAVLC +#define V4L2_MPEG_VIDEO_H264_ENTROPY_MODE_CABAC V4L2_CODEC_VIDEO_H264_ENTROPY_MODE_CABAC +#define v4l2_mpeg_video_h264_level v4l2_codec_video_h264_level +#define V4L2_MPEG_VIDEO_H264_LEVEL_1_0 V4L2_CODEC_VIDEO_H264_LEVEL_1_0 +#define V4L2_MPEG_VIDEO_H264_LEVEL_1B V4L2_CODEC_VIDEO_H264_LEVEL_1B +#define V4L2_MPEG_VIDEO_H264_LEVEL_1_1 V4L2_CODEC_VIDEO_H264_LEVEL_1_1 +#define V4L2_MPEG_VIDEO_H264_LEVEL_1_2 V4L2_CODEC_VIDEO_H264_LEVEL_1_2 +#define V4L2_MPEG_VIDEO_H264_LEVEL_1_3 V4L2_CODEC_VIDEO_H264_LEVEL_1_3 +#define V4L2_MPEG_VIDEO_H264_LEVEL_2_0 V4L2_CODEC_VIDEO_H264_LEVEL_2_0 +#define V4L2_MPEG_VIDEO_H264_LEVEL_2_1 V4L2_CODEC_VIDEO_H264_LEVEL_2_1 +#define V4L2_MPEG_VIDEO_H264_LEVEL_2_2 V4L2_CODEC_VIDEO_H264_LEVEL_2_2 +#define V4L2_MPEG_VIDEO_H264_LEVEL_3_0 V4L2_CODEC_VIDEO_H264_LEVEL_3_0 +#define V4L2_MPEG_VIDEO_H264_LEVEL_3_1 V4L2_CODEC_VIDEO_H264_LEVEL_3_1 +#define V4L2_MPEG_VIDEO_H264_LEVEL_3_2 V4L2_CODEC_VIDEO_H264_LEVEL_3_2 +#define V4L2_MPEG_VIDEO_H264_LEVEL_4_0 V4L2_CODEC_VIDEO_H264_LEVEL_4_0 +#define V4L2_MPEG_VIDEO_H264_LEVEL_4_1 V4L2_CODEC_VIDEO_H264_LEVEL_4_1 +#define V4L2_MPEG_VIDEO_H264_LEVEL_4_2 V4L2_CODEC_VIDEO_H264_LEVEL_4_2 +#define V4L2_MPEG_VIDEO_H264_LEVEL_5_0 V4L2_CODEC_VIDEO_H264_LEVEL_5_0 +#define V4L2_MPEG_VIDEO_H264_LEVEL_5_1 V4L2_CODEC_VIDEO_H264_LEVEL_5_1 +#define V4L2_MPEG_VIDEO_H264_LEVEL_5_2 V4L2_CODEC_VIDEO_H264_LEVEL_5_2 +#define V4L2_MPEG_VIDEO_H264_LEVEL_6_0 V4L2_CODEC_VIDEO_H264_LEVEL_6_0 +#define V4L2_MPEG_VIDEO_H264_LEVEL_6_1 V4L2_CODEC_VIDEO_H264_LEVEL_6_1 +#define V4L2_MPEG_VIDEO_H264_LEVEL_6_2 V4L2_CODEC_VIDEO_H264_LEVEL_6_2 +#define v4l2_mpeg_video_h264_loop_filter_mode v4l2_codec_video_h264_loop_filter_mode +#define V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_ENABLED V4L2_CODEC_VIDEO_H264_LOOP_FILTER_MODE_ENABLED +#define V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_DISABLED V4L2_CODEC_VIDEO_H264_LOOP_FILTER_MODE_DISABLED +#define V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY V4L2_CODEC_VIDEO_H264_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY +#define v4l2_mpeg_video_h264_profile v4l2_codec_video_h264_profile +#define V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE +#define V4L2_MPEG_VIDEO_H264_PROFILE_CONSTRAINED_BASELINE V4L2_CODEC_VIDEO_H264_PROFILE_CONSTRAINED_BASELINE +#define V4L2_MPEG_VIDEO_H264_PROFILE_MAIN V4L2_CODEC_VIDEO_H264_PROFILE_MAIN +#define V4L2_MPEG_VIDEO_H264_PROFILE_EXTENDED V4L2_CODEC_VIDEO_H264_PROFILE_EXTENDED +#define V4L2_MPEG_VIDEO_H264_PROFILE_HIGH V4L2_CODEC_VIDEO_H264_PROFILE_HIGH +#define V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_10 V4L2_CODEC_VIDEO_H264_PROFILE_HIGH_10 +#define V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_422 V4L2_CODEC_VIDEO_H264_PROFILE_HIGH_422 +#define V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_444_PREDICTIVE V4L2_CODEC_VIDEO_H264_PROFILE_HIGH_444_PREDICTIVE +#define V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_10_INTRA V4L2_CODEC_VIDEO_H264_PROFILE_HIGH_10_INTRA +#define V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_422_INTRA V4L2_CODEC_VIDEO_H264_PROFILE_HIGH_422_INTRA +#define V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_444_INTRA V4L2_CODEC_VIDEO_H264_PROFILE_HIGH_444_INTRA +#define V4L2_MPEG_VIDEO_H264_PROFILE_CAVLC_444_INTRA V4L2_CODEC_VIDEO_H264_PROFILE_CAVLC_444_INTRA +#define V4L2_MPEG_VIDEO_H264_PROFILE_SCALABLE_BASELINE V4L2_CODEC_VIDEO_H264_PROFILE_SCALABLE_BASELINE +#define V4L2_MPEG_VIDEO_H264_PROFILE_SCALABLE_HIGH V4L2_CODEC_VIDEO_H264_PROFILE_SCALABLE_HIGH +#define V4L2_MPEG_VIDEO_H264_PROFILE_SCALABLE_HIGH_INTRA V4L2_CODEC_VIDEO_H264_PROFILE_SCALABLE_HIGH_INTRA +#define V4L2_MPEG_VIDEO_H264_PROFILE_STEREO_HIGH V4L2_CODEC_VIDEO_H264_PROFILE_STEREO_HIGH +#define V4L2_MPEG_VIDEO_H264_PROFILE_MULTIVIEW_HIGH V4L2_CODEC_VIDEO_H264_PROFILE_MULTIVIEW_HIGH +#define V4L2_MPEG_VIDEO_H264_PROFILE_CONSTRAINED_HIGH V4L2_CODEC_VIDEO_H264_PROFILE_CONSTRAINED_HIGH +#define v4l2_mpeg_video_h264_vui_sar_idc v4l2_codec_video_h264_vui_sar_idc +#define V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_UNSPECIFIED V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_UNSPECIFIED +#define V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_1x1 V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_1x1 +#define V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_12x11 V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_12x11 +#define V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_10x11 V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_10x11 +#define V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_16x11 V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_16x11 +#define V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_40x33 V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_40x33 +#define V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_24x11 V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_24x11 +#define V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_20x11 V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_20x11 +#define V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_32x11 V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_32x11 +#define V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_80x33 V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_80x33 +#define V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_18x11 V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_18x11 +#define V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_15x11 V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_15x11 +#define V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_64x33 V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_64x33 +#define V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_160x99 V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_160x99 +#define V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_4x3 V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_4x3 +#define V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_3x2 V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_3x2 +#define V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_2x1 V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_2x1 +#define V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_EXTENDED V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_EXTENDED +#define v4l2_mpeg_video_h264_sei_fp_arrangement_type v4l2_codec_video_h264_sei_fp_arrangement_type +#define V4L2_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_CHECKERBOARD V4L2_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_CHECKERBOARD +#define V4L2_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_COLUMN V4L2_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_COLUMN +#define V4L2_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_ROW V4L2_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_ROW +#define V4L2_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_SIDE_BY_SIDE V4L2_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_SIDE_BY_SIDE +#define V4L2_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_TOP_BOTTOM V4L2_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_TOP_BOTTOM +#define V4L2_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_TEMPORAL V4L2_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_TEMPORAL +#define v4l2_mpeg_video_h264_fmo_map_type v4l2_codec_video_h264_fmo_map_type +#define V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_INTERLEAVED_SLICES V4L2_CODEC_VIDEO_H264_FMO_MAP_TYPE_INTERLEAVED_SLICES +#define V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_SCATTERED_SLICES V4L2_CODEC_VIDEO_H264_FMO_MAP_TYPE_SCATTERED_SLICES +#define V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_FOREGROUND_WITH_LEFT_OVER V4L2_CODEC_VIDEO_H264_FMO_MAP_TYPE_FOREGROUND_WITH_LEFT_OVER +#define V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_BOX_OUT V4L2_CODEC_VIDEO_H264_FMO_MAP_TYPE_BOX_OUT +#define V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_RASTER_SCAN V4L2_CODEC_VIDEO_H264_FMO_MAP_TYPE_RASTER_SCAN +#define V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_WIPE_SCAN V4L2_CODEC_VIDEO_H264_FMO_MAP_TYPE_WIPE_SCAN +#define V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_EXPLICIT V4L2_CODEC_VIDEO_H264_FMO_MAP_TYPE_EXPLICIT +#define v4l2_mpeg_video_h264_fmo_change_dir v4l2_codec_video_h264_fmo_change_dir +#define V4L2_MPEG_VIDEO_H264_FMO_CHANGE_DIR_RIGHT V4L2_CODEC_VIDEO_H264_FMO_CHANGE_DIR_RIGHT +#define V4L2_MPEG_VIDEO_H264_FMO_CHANGE_DIR_LEFT V4L2_CODEC_VIDEO_H264_FMO_CHANGE_DIR_LEFT +#define v4l2_mpeg_video_h264_hierarchical_coding_type v4l2_codec_video_h264_hierarchical_coding_type +#define V4L2_MPEG_VIDEO_H264_HIERARCHICAL_CODING_B V4L2_CODEC_VIDEO_H264_HIERARCHICAL_CODING_B +#define V4L2_MPEG_VIDEO_H264_HIERARCHICAL_CODING_P V4L2_CODEC_VIDEO_H264_HIERARCHICAL_CODING_P +#define v4l2_mpeg_video_mpeg4_level v4l2_codec_video_mpeg4_level +#define V4L2_MPEG_VIDEO_MPEG4_LEVEL_0 V4L2_CODEC_VIDEO_MPEG4_LEVEL_0 +#define V4L2_MPEG_VIDEO_MPEG4_LEVEL_0B V4L2_CODEC_VIDEO_MPEG4_LEVEL_0B +#define V4L2_MPEG_VIDEO_MPEG4_LEVEL_1 V4L2_CODEC_VIDEO_MPEG4_LEVEL_1 +#define V4L2_MPEG_VIDEO_MPEG4_LEVEL_2 V4L2_CODEC_VIDEO_MPEG4_LEVEL_2 +#define V4L2_MPEG_VIDEO_MPEG4_LEVEL_3 V4L2_CODEC_VIDEO_MPEG4_LEVEL_3 +#define V4L2_MPEG_VIDEO_MPEG4_LEVEL_3B V4L2_CODEC_VIDEO_MPEG4_LEVEL_3B +#define V4L2_MPEG_VIDEO_MPEG4_LEVEL_4 V4L2_CODEC_VIDEO_MPEG4_LEVEL_4 +#define V4L2_MPEG_VIDEO_MPEG4_LEVEL_5 V4L2_CODEC_VIDEO_MPEG4_LEVEL_5 +#define v4l2_mpeg_video_mpeg4_profile v4l2_codec_video_mpeg4_profile +#define V4L2_MPEG_VIDEO_MPEG4_PROFILE_SIMPLE V4L2_CODEC_VIDEO_MPEG4_PROFILE_SIMPLE +#define V4L2_MPEG_VIDEO_MPEG4_PROFILE_ADVANCED_SIMPLE V4L2_CODEC_VIDEO_MPEG4_PROFILE_ADVANCED_SIMPLE +#define V4L2_MPEG_VIDEO_MPEG4_PROFILE_CORE V4L2_CODEC_VIDEO_MPEG4_PROFILE_CORE +#define V4L2_MPEG_VIDEO_MPEG4_PROFILE_SIMPLE_SCALABLE V4L2_CODEC_VIDEO_MPEG4_PROFILE_SIMPLE_SCALABLE +#define V4L2_MPEG_VIDEO_MPEG4_PROFILE_ADVANCED_CODING_EFFICIENCY V4L2_CODEC_VIDEO_MPEG4_PROFILE_ADVANCED_CODING_EFFICIENCY +#define v4l2_mpeg_video_vp8_profile v4l2_codec_video_vp8_profile +#define V4L2_MPEG_VIDEO_VP8_PROFILE_0 V4L2_CODEC_VIDEO_VP8_PROFILE_0 +#define V4L2_MPEG_VIDEO_VP8_PROFILE_1 V4L2_CODEC_VIDEO_VP8_PROFILE_1 +#define V4L2_MPEG_VIDEO_VP8_PROFILE_2 V4L2_CODEC_VIDEO_VP8_PROFILE_2 +#define V4L2_MPEG_VIDEO_VP8_PROFILE_3 V4L2_CODEC_VIDEO_VP8_PROFILE_3 +#define v4l2_mpeg_video_vp9_profile v4l2_codec_video_vp9_profile +#define V4L2_MPEG_VIDEO_VP9_PROFILE_0 V4L2_CODEC_VIDEO_VP9_PROFILE_0 +#define V4L2_MPEG_VIDEO_VP9_PROFILE_1 V4L2_CODEC_VIDEO_VP9_PROFILE_1 +#define V4L2_MPEG_VIDEO_VP9_PROFILE_2 V4L2_CODEC_VIDEO_VP9_PROFILE_2 +#define V4L2_MPEG_VIDEO_VP9_PROFILE_3 V4L2_CODEC_VIDEO_VP9_PROFILE_3 +#define v4l2_mpeg_video_vp9_level v4l2_codec_video_vp9_level +#define V4L2_MPEG_VIDEO_VP9_LEVEL_1_0 V4L2_CODEC_VIDEO_VP9_LEVEL_1_0 +#define V4L2_MPEG_VIDEO_VP9_LEVEL_1_1 V4L2_CODEC_VIDEO_VP9_LEVEL_1_1 +#define V4L2_MPEG_VIDEO_VP9_LEVEL_2_0 V4L2_CODEC_VIDEO_VP9_LEVEL_2_0 +#define V4L2_MPEG_VIDEO_VP9_LEVEL_2_1 V4L2_CODEC_VIDEO_VP9_LEVEL_2_1 +#define V4L2_MPEG_VIDEO_VP9_LEVEL_3_0 V4L2_CODEC_VIDEO_VP9_LEVEL_3_0 +#define V4L2_MPEG_VIDEO_VP9_LEVEL_3_1 V4L2_CODEC_VIDEO_VP9_LEVEL_3_1 +#define V4L2_MPEG_VIDEO_VP9_LEVEL_4_0 V4L2_CODEC_VIDEO_VP9_LEVEL_4_0 +#define V4L2_MPEG_VIDEO_VP9_LEVEL_4_1 V4L2_CODEC_VIDEO_VP9_LEVEL_4_1 +#define V4L2_MPEG_VIDEO_VP9_LEVEL_5_0 V4L2_CODEC_VIDEO_VP9_LEVEL_5_0 +#define V4L2_MPEG_VIDEO_VP9_LEVEL_5_1 V4L2_CODEC_VIDEO_VP9_LEVEL_5_1 +#define V4L2_MPEG_VIDEO_VP9_LEVEL_5_2 V4L2_CODEC_VIDEO_VP9_LEVEL_5_2 +#define V4L2_MPEG_VIDEO_VP9_LEVEL_6_0 V4L2_CODEC_VIDEO_VP9_LEVEL_6_0 +#define V4L2_MPEG_VIDEO_VP9_LEVEL_6_1 V4L2_CODEC_VIDEO_VP9_LEVEL_6_1 +#define V4L2_MPEG_VIDEO_VP9_LEVEL_6_2 V4L2_CODEC_VIDEO_VP9_LEVEL_6_2 +#define v4l2_mpeg_video_hevc_hier_coding_type v4l2_codec_video_hevc_hier_coding_type +#define V4L2_MPEG_VIDEO_HEVC_HIERARCHICAL_CODING_B V4L2_CODEC_VIDEO_HEVC_HIERARCHICAL_CODING_B +#define V4L2_MPEG_VIDEO_HEVC_HIERARCHICAL_CODING_P V4L2_CODEC_VIDEO_HEVC_HIERARCHICAL_CODING_P +#define v4l2_mpeg_video_hevc_profile v4l2_codec_video_hevc_profile +#define V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN +#define V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN_STILL_PICTURE V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN_STILL_PICTURE +#define V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN_10 V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN_10 +#define v4l2_mpeg_video_hevc_level v4l2_codec_video_hevc_level +#define V4L2_MPEG_VIDEO_HEVC_LEVEL_1 V4L2_CODEC_VIDEO_HEVC_LEVEL_1 +#define V4L2_MPEG_VIDEO_HEVC_LEVEL_2 V4L2_CODEC_VIDEO_HEVC_LEVEL_2 +#define V4L2_MPEG_VIDEO_HEVC_LEVEL_2_1 V4L2_CODEC_VIDEO_HEVC_LEVEL_2_1 +#define V4L2_MPEG_VIDEO_HEVC_LEVEL_3 V4L2_CODEC_VIDEO_HEVC_LEVEL_3 +#define V4L2_MPEG_VIDEO_HEVC_LEVEL_3_1 V4L2_CODEC_VIDEO_HEVC_LEVEL_3_1 +#define V4L2_MPEG_VIDEO_HEVC_LEVEL_4 V4L2_CODEC_VIDEO_HEVC_LEVEL_4 +#define V4L2_MPEG_VIDEO_HEVC_LEVEL_4_1 V4L2_CODEC_VIDEO_HEVC_LEVEL_4_1 +#define V4L2_MPEG_VIDEO_HEVC_LEVEL_5 V4L2_CODEC_VIDEO_HEVC_LEVEL_5 +#define V4L2_MPEG_VIDEO_HEVC_LEVEL_5_1 V4L2_CODEC_VIDEO_HEVC_LEVEL_5_1 +#define V4L2_MPEG_VIDEO_HEVC_LEVEL_5_2 V4L2_CODEC_VIDEO_HEVC_LEVEL_5_2 +#define V4L2_MPEG_VIDEO_HEVC_LEVEL_6 V4L2_CODEC_VIDEO_HEVC_LEVEL_6 +#define V4L2_MPEG_VIDEO_HEVC_LEVEL_6_1 V4L2_CODEC_VIDEO_HEVC_LEVEL_6_1 +#define V4L2_MPEG_VIDEO_HEVC_LEVEL_6_2 V4L2_CODEC_VIDEO_HEVC_LEVEL_6_2 +#define v4l2_mpeg_video_hevc_tier v4l2_codec_video_hevc_tier +#define V4L2_MPEG_VIDEO_HEVC_TIER_MAIN V4L2_CODEC_VIDEO_HEVC_TIER_MAIN +#define V4L2_MPEG_VIDEO_HEVC_TIER_HIGH V4L2_CODEC_VIDEO_HEVC_TIER_HIGH +#define V4L2_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE_DISABLED V4L2_CODEC_VIDEO_HEVC_LOOP_FILTER_MODE_DISABLED +#define V4L2_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE_ENABLED V4L2_CODEC_VIDEO_HEVC_LOOP_FILTER_MODE_ENABLED +#define V4L2_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY V4L2_CODEC_VIDEO_HEVC_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY +#define V4L2_MPEG_VIDEO_HEVC_REFRESH_NONE V4L2_CODEC_VIDEO_HEVC_REFRESH_NONE +#define V4L2_MPEG_VIDEO_HEVC_REFRESH_CRA V4L2_CODEC_VIDEO_HEVC_REFRESH_CRA +#define V4L2_MPEG_VIDEO_HEVC_REFRESH_IDR V4L2_CODEC_VIDEO_HEVC_REFRESH_IDR +#define V4L2_MPEG_VIDEO_HEVC_SIZE_0 V4L2_CODEC_VIDEO_HEVC_SIZE_0 +#define V4L2_MPEG_VIDEO_HEVC_SIZE_1 V4L2_CODEC_VIDEO_HEVC_SIZE_1 +#define V4L2_MPEG_VIDEO_HEVC_SIZE_2 V4L2_CODEC_VIDEO_HEVC_SIZE_2 +#define V4L2_MPEG_VIDEO_HEVC_SIZE_4 V4L2_CODEC_VIDEO_HEVC_SIZE_4 +#define v4l2_mpeg_video_frame_skip_mode v4l2_codec_video_frame_skip_mode +#define V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_DISABLED V4L2_CODEC_VIDEO_FRAME_SKIP_MODE_DISABLED +#define V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_LEVEL_LIMIT V4L2_CODEC_VIDEO_FRAME_SKIP_MODE_LEVEL_LIMIT +#define V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT V4L2_CODEC_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT +#define v4l2_mpeg_cx2341x_video_spatial_filter_mode v4l2_codec_cx2341x_video_spatial_filter_mode +#define V4L2_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE_MANUAL V4L2_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE_MANUAL +#define V4L2_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE_AUTO V4L2_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE_AUTO +#define v4l2_mpeg_cx2341x_video_luma_spatial_filter_type v4l2_codec_cx2341x_video_luma_spatial_filter_type +#define V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_OFF V4L2_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_OFF +#define V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_1D_HOR V4L2_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_1D_HOR +#define V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_1D_VERT V4L2_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_1D_VERT +#define V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_2D_HV_SEPARABLE V4L2_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_2D_HV_SEPARABLE +#define V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_2D_SYM_NON_SEPARABLE V4L2_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_2D_SYM_NON_SEPARABLE +#define v4l2_mpeg_cx2341x_video_chroma_spatial_filter_type v4l2_codec_cx2341x_video_chroma_spatial_filter_type +#define V4L2_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_OFF V4L2_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_OFF +#define V4L2_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_1D_HOR V4L2_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_1D_HOR +#define v4l2_mpeg_cx2341x_video_temporal_filter_mode v4l2_codec_cx2341x_video_temporal_filter_mode +#define V4L2_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_MANUAL V4L2_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_MANUAL +#define V4L2_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_AUTO V4L2_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_AUTO +#define v4l2_mpeg_cx2341x_video_median_filter_type v4l2_codec_cx2341x_video_median_filter_type +#define V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF V4L2_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF +#define V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_HOR V4L2_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_HOR +#define V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_VERT V4L2_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_VERT +#define V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_HOR_VERT V4L2_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_HOR_VERT +#define V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_DIAG V4L2_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_DIAG +#define v4l2_mpeg_mfc51_video_frame_skip_mode v4l2_codec_mfc51_video_frame_skip_mode +#define V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_DISABLED V4L2_CODEC_MFC51_VIDEO_FRAME_SKIP_MODE_DISABLED +#define V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_LEVEL_LIMIT V4L2_CODEC_MFC51_VIDEO_FRAME_SKIP_MODE_LEVEL_LIMIT +#define V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT V4L2_CODEC_MFC51_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT +#define v4l2_mpeg_mfc51_video_force_frame_type v4l2_codec_mfc51_video_force_frame_type +#define V4L2_MPEG_MFC51_VIDEO_FORCE_FRAME_TYPE_DISABLED V4L2_CODEC_MFC51_VIDEO_FORCE_FRAME_TYPE_DISABLED +#define V4L2_MPEG_MFC51_VIDEO_FORCE_FRAME_TYPE_I_FRAME V4L2_CODEC_MFC51_VIDEO_FORCE_FRAME_TYPE_I_FRAME +#define V4L2_MPEG_MFC51_VIDEO_FORCE_FRAME_TYPE_NOT_CODED V4L2_CODEC_MFC51_VIDEO_FORCE_FRAME_TYPE_NOT_CODED +#define V4L2_CID_MPEG_STREAM_TYPE V4L2_CID_CODEC_STREAM_TYPE +#define V4L2_CID_MPEG_STREAM_PID_PMT V4L2_CID_CODEC_STREAM_PID_PMT +#define V4L2_CID_MPEG_STREAM_PID_AUDIO V4L2_CID_CODEC_STREAM_PID_AUDIO +#define V4L2_CID_MPEG_STREAM_PID_VIDEO V4L2_CID_CODEC_STREAM_PID_VIDEO +#define V4L2_CID_MPEG_STREAM_PID_PCR V4L2_CID_CODEC_STREAM_PID_PCR +#define V4L2_CID_MPEG_STREAM_PES_ID_AUDIO V4L2_CID_CODEC_STREAM_PES_ID_AUDIO +#define V4L2_CID_MPEG_STREAM_PES_ID_VIDEO V4L2_CID_CODEC_STREAM_PES_ID_VIDEO +#define V4L2_CID_MPEG_STREAM_VBI_FMT V4L2_CID_CODEC_STREAM_VBI_FMT +#define V4L2_CID_MPEG_AUDIO_SAMPLING_FREQ V4L2_CID_CODEC_AUDIO_SAMPLING_FREQ +#define V4L2_CID_MPEG_AUDIO_ENCODING V4L2_CID_CODEC_AUDIO_ENCODING +#define V4L2_CID_MPEG_AUDIO_L1_BITRATE V4L2_CID_CODEC_AUDIO_L1_BITRATE +#define V4L2_CID_MPEG_AUDIO_L2_BITRATE V4L2_CID_CODEC_AUDIO_L2_BITRATE +#define V4L2_CID_MPEG_AUDIO_L3_BITRATE V4L2_CID_CODEC_AUDIO_L3_BITRATE +#define V4L2_CID_MPEG_AUDIO_MODE V4L2_CID_CODEC_AUDIO_MODE +#define V4L2_CID_MPEG_AUDIO_MODE_EXTENSION V4L2_CID_CODEC_AUDIO_MODE_EXTENSION +#define V4L2_CID_MPEG_AUDIO_EMPHASIS V4L2_CID_CODEC_AUDIO_EMPHASIS +#define V4L2_CID_MPEG_AUDIO_CRC V4L2_CID_CODEC_AUDIO_CRC +#define V4L2_CID_MPEG_AUDIO_MUTE V4L2_CID_CODEC_AUDIO_MUTE +#define V4L2_CID_MPEG_AUDIO_AAC_BITRATE V4L2_CID_CODEC_AUDIO_AAC_BITRATE +#define V4L2_CID_MPEG_AUDIO_AC3_BITRATE V4L2_CID_CODEC_AUDIO_AC3_BITRATE +#define V4L2_CID_MPEG_AUDIO_DEC_PLAYBACK V4L2_CID_CODEC_AUDIO_DEC_PLAYBACK +#define V4L2_CID_MPEG_AUDIO_DEC_MULTILINGUAL_PLAYBACK V4L2_CID_CODEC_AUDIO_DEC_MULTILINGUAL_PLAYBACK +#define V4L2_CID_MPEG_VIDEO_ENCODING V4L2_CID_CODEC_VIDEO_ENCODING +#define V4L2_CID_MPEG_VIDEO_ASPECT V4L2_CID_CODEC_VIDEO_ASPECT +#define V4L2_CID_MPEG_VIDEO_B_FRAMES V4L2_CID_CODEC_VIDEO_B_FRAMES +#define V4L2_CID_MPEG_VIDEO_GOP_SIZE V4L2_CID_CODEC_VIDEO_GOP_SIZE +#define V4L2_CID_MPEG_VIDEO_GOP_CLOSURE V4L2_CID_CODEC_VIDEO_GOP_CLOSURE +#define V4L2_CID_MPEG_VIDEO_PULLDOWN V4L2_CID_CODEC_VIDEO_PULLDOWN +#define V4L2_CID_MPEG_VIDEO_BITRATE_MODE V4L2_CID_CODEC_VIDEO_BITRATE_MODE +#define V4L2_CID_MPEG_VIDEO_BITRATE V4L2_CID_CODEC_VIDEO_BITRATE +#define V4L2_CID_MPEG_VIDEO_BITRATE_PEAK V4L2_CID_CODEC_VIDEO_BITRATE_PEAK +#define V4L2_CID_MPEG_VIDEO_TEMPORAL_DECIMATION V4L2_CID_CODEC_VIDEO_TEMPORAL_DECIMATION +#define V4L2_CID_MPEG_VIDEO_MUTE V4L2_CID_CODEC_VIDEO_MUTE +#define V4L2_CID_MPEG_VIDEO_MUTE_YUV V4L2_CID_CODEC_VIDEO_MUTE_YUV +#define V4L2_CID_MPEG_VIDEO_DECODER_SLICE_INTERFACE V4L2_CID_CODEC_VIDEO_DECODER_SLICE_INTERFACE +#define V4L2_CID_MPEG_VIDEO_DECODER_MPEG4_DEBLOCK_FILTER V4L2_CID_CODEC_VIDEO_DECODER_MPEG4_DEBLOCK_FILTER +#define V4L2_CID_MPEG_VIDEO_CYCLIC_INTRA_REFRESH_MB V4L2_CID_CODEC_VIDEO_CYCLIC_INTRA_REFRESH_MB +#define V4L2_CID_MPEG_VIDEO_FRAME_RC_ENABLE V4L2_CID_CODEC_VIDEO_FRAME_RC_ENABLE +#define V4L2_CID_MPEG_VIDEO_HEADER_MODE V4L2_CID_CODEC_VIDEO_HEADER_MODE +#define V4L2_CID_MPEG_VIDEO_MAX_REF_PIC V4L2_CID_CODEC_VIDEO_MAX_REF_PIC +#define V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE V4L2_CID_CODEC_VIDEO_MB_RC_ENABLE +#define V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MAX_BYTES V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MAX_BYTES +#define V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MAX_MB V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MAX_MB +#define V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MODE V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MODE +#define V4L2_CID_MPEG_VIDEO_VBV_SIZE V4L2_CID_CODEC_VIDEO_VBV_SIZE +#define V4L2_CID_MPEG_VIDEO_DEC_PTS V4L2_CID_CODEC_VIDEO_DEC_PTS +#define V4L2_CID_MPEG_VIDEO_DEC_FRAME V4L2_CID_CODEC_VIDEO_DEC_FRAME +#define V4L2_CID_MPEG_VIDEO_VBV_DELAY V4L2_CID_CODEC_VIDEO_VBV_DELAY +#define V4L2_CID_MPEG_VIDEO_REPEAT_SEQ_HEADER V4L2_CID_CODEC_VIDEO_REPEAT_SEQ_HEADER +#define V4L2_CID_MPEG_VIDEO_MV_H_SEARCH_RANGE V4L2_CID_CODEC_VIDEO_MV_H_SEARCH_RANGE +#define V4L2_CID_MPEG_VIDEO_MV_V_SEARCH_RANGE V4L2_CID_CODEC_VIDEO_MV_V_SEARCH_RANGE +#define V4L2_CID_MPEG_VIDEO_FORCE_KEY_FRAME V4L2_CID_CODEC_VIDEO_FORCE_KEY_FRAME +#define V4L2_CID_MPEG_VIDEO_BASELAYER_PRIORITY_ID V4L2_CID_CODEC_VIDEO_BASELAYER_PRIORITY_ID +#define V4L2_CID_MPEG_VIDEO_MPEG2_LEVEL V4L2_CID_CODEC_VIDEO_MPEG2_LEVEL +#define V4L2_CID_MPEG_VIDEO_MPEG2_PROFILE V4L2_CID_CODEC_VIDEO_MPEG2_PROFILE +#define V4L2_CID_MPEG_VIDEO_H263_I_FRAME_QP V4L2_CID_CODEC_VIDEO_H263_I_FRAME_QP +#define V4L2_CID_MPEG_VIDEO_H263_P_FRAME_QP V4L2_CID_CODEC_VIDEO_H263_P_FRAME_QP +#define V4L2_CID_MPEG_VIDEO_H263_B_FRAME_QP V4L2_CID_CODEC_VIDEO_H263_B_FRAME_QP +#define V4L2_CID_MPEG_VIDEO_H263_MIN_QP V4L2_CID_CODEC_VIDEO_H263_MIN_QP +#define V4L2_CID_MPEG_VIDEO_H263_MAX_QP V4L2_CID_CODEC_VIDEO_H263_MAX_QP +#define V4L2_CID_MPEG_VIDEO_H264_I_FRAME_QP V4L2_CID_CODEC_VIDEO_H264_I_FRAME_QP +#define V4L2_CID_MPEG_VIDEO_H264_P_FRAME_QP V4L2_CID_CODEC_VIDEO_H264_P_FRAME_QP +#define V4L2_CID_MPEG_VIDEO_H264_B_FRAME_QP V4L2_CID_CODEC_VIDEO_H264_B_FRAME_QP +#define V4L2_CID_MPEG_VIDEO_H264_MIN_QP V4L2_CID_CODEC_VIDEO_H264_MIN_QP +#define V4L2_CID_MPEG_VIDEO_H264_MAX_QP V4L2_CID_CODEC_VIDEO_H264_MAX_QP +#define V4L2_CID_MPEG_VIDEO_H264_8X8_TRANSFORM V4L2_CID_CODEC_VIDEO_H264_8X8_TRANSFORM +#define V4L2_CID_MPEG_VIDEO_H264_CPB_SIZE V4L2_CID_CODEC_VIDEO_H264_CPB_SIZE +#define V4L2_CID_MPEG_VIDEO_H264_ENTROPY_MODE V4L2_CID_CODEC_VIDEO_H264_ENTROPY_MODE +#define V4L2_CID_MPEG_VIDEO_H264_I_PERIOD V4L2_CID_CODEC_VIDEO_H264_I_PERIOD +#define V4L2_CID_MPEG_VIDEO_H264_LEVEL V4L2_CID_CODEC_VIDEO_H264_LEVEL +#define V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_ALPHA V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_ALPHA +#define V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_BETA V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_BETA +#define V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_MODE V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_MODE +#define V4L2_CID_MPEG_VIDEO_H264_PROFILE V4L2_CID_CODEC_VIDEO_H264_PROFILE +#define V4L2_CID_MPEG_VIDEO_H264_VUI_EXT_SAR_HEIGHT V4L2_CID_CODEC_VIDEO_H264_VUI_EXT_SAR_HEIGHT +#define V4L2_CID_MPEG_VIDEO_H264_VUI_EXT_SAR_WIDTH V4L2_CID_CODEC_VIDEO_H264_VUI_EXT_SAR_WIDTH +#define V4L2_CID_MPEG_VIDEO_H264_VUI_SAR_ENABLE V4L2_CID_CODEC_VIDEO_H264_VUI_SAR_ENABLE +#define V4L2_CID_MPEG_VIDEO_H264_VUI_SAR_IDC V4L2_CID_CODEC_VIDEO_H264_VUI_SAR_IDC +#define V4L2_CID_MPEG_VIDEO_H264_SEI_FRAME_PACKING V4L2_CID_CODEC_VIDEO_H264_SEI_FRAME_PACKING +#define V4L2_CID_MPEG_VIDEO_H264_SEI_FP_CURRENT_FRAME_0 V4L2_CID_CODEC_VIDEO_H264_SEI_FP_CURRENT_FRAME_0 +#define V4L2_CID_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE V4L2_CID_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE +#define V4L2_CID_MPEG_VIDEO_H264_FMO V4L2_CID_CODEC_VIDEO_H264_FMO +#define V4L2_CID_MPEG_VIDEO_H264_FMO_MAP_TYPE V4L2_CID_CODEC_VIDEO_H264_FMO_MAP_TYPE +#define V4L2_CID_MPEG_VIDEO_H264_FMO_SLICE_GROUP V4L2_CID_CODEC_VIDEO_H264_FMO_SLICE_GROUP +#define V4L2_CID_MPEG_VIDEO_H264_FMO_CHANGE_DIRECTION V4L2_CID_CODEC_VIDEO_H264_FMO_CHANGE_DIRECTION +#define V4L2_CID_MPEG_VIDEO_H264_FMO_CHANGE_RATE V4L2_CID_CODEC_VIDEO_H264_FMO_CHANGE_RATE +#define V4L2_CID_MPEG_VIDEO_H264_FMO_RUN_LENGTH V4L2_CID_CODEC_VIDEO_H264_FMO_RUN_LENGTH +#define V4L2_CID_MPEG_VIDEO_H264_ASO V4L2_CID_CODEC_VIDEO_H264_ASO +#define V4L2_CID_MPEG_VIDEO_H264_ASO_SLICE_ORDER V4L2_CID_CODEC_VIDEO_H264_ASO_SLICE_ORDER +#define V4L2_CID_MPEG_VIDEO_H264_HIERARCHICAL_CODING V4L2_CID_CODEC_VIDEO_H264_HIERARCHICAL_CODING +#define V4L2_CID_MPEG_VIDEO_H264_HIERARCHICAL_CODING_TYPE V4L2_CID_CODEC_VIDEO_H264_HIERARCHICAL_CODING_TYPE +#define V4L2_CID_MPEG_VIDEO_H264_HIERARCHICAL_CODING_LAYER V4L2_CID_CODEC_VIDEO_H264_HIERARCHICAL_CODING_LAYER +#define V4L2_CID_MPEG_VIDEO_H264_HIERARCHICAL_CODING_LAYER_QP V4L2_CID_CODEC_VIDEO_H264_HIERARCHICAL_CODING_LAYER_QP +#define V4L2_CID_MPEG_VIDEO_H264_CONSTRAINED_INTRA_PREDICTION V4L2_CID_CODEC_VIDEO_H264_CONSTRAINED_INTRA_PREDICTION +#define V4L2_CID_MPEG_VIDEO_H264_CHROMA_QP_INDEX_OFFSET V4L2_CID_CODEC_VIDEO_H264_CHROMA_QP_INDEX_OFFSET +#define V4L2_CID_MPEG_VIDEO_H264_I_FRAME_MIN_QP V4L2_CID_CODEC_VIDEO_H264_I_FRAME_MIN_QP +#define V4L2_CID_MPEG_VIDEO_H264_I_FRAME_MAX_QP V4L2_CID_CODEC_VIDEO_H264_I_FRAME_MAX_QP +#define V4L2_CID_MPEG_VIDEO_H264_P_FRAME_MIN_QP V4L2_CID_CODEC_VIDEO_H264_P_FRAME_MIN_QP +#define V4L2_CID_MPEG_VIDEO_H264_P_FRAME_MAX_QP V4L2_CID_CODEC_VIDEO_H264_P_FRAME_MAX_QP +#define V4L2_CID_MPEG_VIDEO_H264_B_FRAME_MIN_QP V4L2_CID_CODEC_VIDEO_H264_B_FRAME_MIN_QP +#define V4L2_CID_MPEG_VIDEO_H264_B_FRAME_MAX_QP V4L2_CID_CODEC_VIDEO_H264_B_FRAME_MAX_QP +#define V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L0_BR V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L0_BR +#define V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L1_BR V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L1_BR +#define V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L2_BR V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L2_BR +#define V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L3_BR V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L3_BR +#define V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L4_BR V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L4_BR +#define V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L5_BR V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L5_BR +#define V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L6_BR V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L6_BR +#define V4L2_CID_MPEG_VIDEO_MPEG4_I_FRAME_QP V4L2_CID_CODEC_VIDEO_MPEG4_I_FRAME_QP +#define V4L2_CID_MPEG_VIDEO_MPEG4_P_FRAME_QP V4L2_CID_CODEC_VIDEO_MPEG4_P_FRAME_QP +#define V4L2_CID_MPEG_VIDEO_MPEG4_B_FRAME_QP V4L2_CID_CODEC_VIDEO_MPEG4_B_FRAME_QP +#define V4L2_CID_MPEG_VIDEO_MPEG4_MIN_QP V4L2_CID_CODEC_VIDEO_MPEG4_MIN_QP +#define V4L2_CID_MPEG_VIDEO_MPEG4_MAX_QP V4L2_CID_CODEC_VIDEO_MPEG4_MAX_QP +#define V4L2_CID_MPEG_VIDEO_MPEG4_LEVEL V4L2_CID_CODEC_VIDEO_MPEG4_LEVEL +#define V4L2_CID_MPEG_VIDEO_MPEG4_PROFILE V4L2_CID_CODEC_VIDEO_MPEG4_PROFILE +#define V4L2_CID_MPEG_VIDEO_MPEG4_QPEL V4L2_CID_CODEC_VIDEO_MPEG4_QPEL +#define V4L2_CID_MPEG_VIDEO_VPX_NUM_PARTITIONS V4L2_CID_CODEC_VIDEO_VPX_NUM_PARTITIONS +#define V4L2_CID_MPEG_VIDEO_VPX_1_PARTITION V4L2_CID_CODEC_VIDEO_VPX_1_PARTITION +#define V4L2_CID_MPEG_VIDEO_VPX_2_PARTITIONS V4L2_CID_CODEC_VIDEO_VPX_2_PARTITIONS +#define V4L2_CID_MPEG_VIDEO_VPX_4_PARTITIONS V4L2_CID_CODEC_VIDEO_VPX_4_PARTITIONS +#define V4L2_CID_MPEG_VIDEO_VPX_8_PARTITIONS V4L2_CID_CODEC_VIDEO_VPX_8_PARTITIONS +#define V4L2_CID_MPEG_VIDEO_VPX_IMD_DISABLE_4X4 V4L2_CID_CODEC_VIDEO_VPX_IMD_DISABLE_4X4 +#define V4L2_CID_MPEG_VIDEO_VPX_NUM_REF_FRAMES V4L2_CID_CODEC_VIDEO_VPX_NUM_REF_FRAMES +#define V4L2_CID_MPEG_VIDEO_VPX_1_REF_FRAME V4L2_CID_CODEC_VIDEO_VPX_1_REF_FRAME +#define V4L2_CID_MPEG_VIDEO_VPX_2_REF_FRAME V4L2_CID_CODEC_VIDEO_VPX_2_REF_FRAME +#define V4L2_CID_MPEG_VIDEO_VPX_3_REF_FRAME V4L2_CID_CODEC_VIDEO_VPX_3_REF_FRAME +#define V4L2_CID_MPEG_VIDEO_VPX_FILTER_LEVEL V4L2_CID_CODEC_VIDEO_VPX_FILTER_LEVEL +#define V4L2_CID_MPEG_VIDEO_VPX_FILTER_SHARPNESS V4L2_CID_CODEC_VIDEO_VPX_FILTER_SHARPNESS +#define V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_REF_PERIOD V4L2_CID_CODEC_VIDEO_VPX_GOLDEN_FRAME_REF_PERIOD +#define V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_SEL V4L2_CID_CODEC_VIDEO_VPX_GOLDEN_FRAME_SEL +#define V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_USE_PREV V4L2_CID_CODEC_VIDEO_VPX_GOLDEN_FRAME_USE_PREV +#define V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_USE_REF_PERIOD V4L2_CID_CODEC_VIDEO_VPX_GOLDEN_FRAME_USE_REF_PERIOD +#define V4L2_CID_MPEG_VIDEO_VPX_MIN_QP V4L2_CID_CODEC_VIDEO_VPX_MIN_QP +#define V4L2_CID_MPEG_VIDEO_VPX_MAX_QP V4L2_CID_CODEC_VIDEO_VPX_MAX_QP +#define V4L2_CID_MPEG_VIDEO_VPX_I_FRAME_QP V4L2_CID_CODEC_VIDEO_VPX_I_FRAME_QP +#define V4L2_CID_MPEG_VIDEO_VPX_P_FRAME_QP V4L2_CID_CODEC_VIDEO_VPX_P_FRAME_QP +#define V4L2_CID_MPEG_VIDEO_VP8_PROFILE V4L2_CID_CODEC_VIDEO_VP8_PROFILE +#define V4L2_CID_MPEG_VIDEO_VPX_PROFILE V4L2_CID_CODEC_VIDEO_VPX_PROFILE +#define V4L2_CID_MPEG_VIDEO_VP9_PROFILE V4L2_CID_CODEC_VIDEO_VP9_PROFILE +#define V4L2_CID_MPEG_VIDEO_VP9_LEVEL V4L2_CID_CODEC_VIDEO_VP9_LEVEL +#define V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP V4L2_CID_CODEC_VIDEO_HEVC_MIN_QP +#define V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP V4L2_CID_CODEC_VIDEO_HEVC_MAX_QP +#define V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_QP V4L2_CID_CODEC_VIDEO_HEVC_I_FRAME_QP +#define V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_QP V4L2_CID_CODEC_VIDEO_HEVC_P_FRAME_QP +#define V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_QP V4L2_CID_CODEC_VIDEO_HEVC_B_FRAME_QP +#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_QP V4L2_CID_CODEC_VIDEO_HEVC_HIER_QP +#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_TYPE V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_TYPE +#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_LAYER V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_LAYER +#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L0_QP V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L0_QP +#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L1_QP V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L1_QP +#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L2_QP V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L2_QP +#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L3_QP V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L3_QP +#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L4_QP V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L4_QP +#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L5_QP V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L5_QP +#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L6_QP V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L6_QP +#define V4L2_CID_MPEG_VIDEO_HEVC_PROFILE V4L2_CID_CODEC_VIDEO_HEVC_PROFILE +#define V4L2_CID_MPEG_VIDEO_HEVC_LEVEL V4L2_CID_CODEC_VIDEO_HEVC_LEVEL +#define V4L2_CID_MPEG_VIDEO_HEVC_FRAME_RATE_RESOLUTION V4L2_CID_CODEC_VIDEO_HEVC_FRAME_RATE_RESOLUTION +#define V4L2_CID_MPEG_VIDEO_HEVC_TIER V4L2_CID_CODEC_VIDEO_HEVC_TIER +#define V4L2_CID_MPEG_VIDEO_HEVC_MAX_PARTITION_DEPTH V4L2_CID_CODEC_VIDEO_HEVC_MAX_PARTITION_DEPTH +#define V4L2_CID_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE V4L2_CID_CODEC_VIDEO_HEVC_LOOP_FILTER_MODE +#define V4L2_CID_MPEG_VIDEO_HEVC_LF_BETA_OFFSET_DIV2 V4L2_CID_CODEC_VIDEO_HEVC_LF_BETA_OFFSET_DIV2 +#define V4L2_CID_MPEG_VIDEO_HEVC_LF_TC_OFFSET_DIV2 V4L2_CID_CODEC_VIDEO_HEVC_LF_TC_OFFSET_DIV2 +#define V4L2_CID_MPEG_VIDEO_HEVC_REFRESH_TYPE V4L2_CID_CODEC_VIDEO_HEVC_REFRESH_TYPE +#define V4L2_CID_MPEG_VIDEO_HEVC_REFRESH_PERIOD V4L2_CID_CODEC_VIDEO_HEVC_REFRESH_PERIOD +#define V4L2_CID_MPEG_VIDEO_HEVC_LOSSLESS_CU V4L2_CID_CODEC_VIDEO_HEVC_LOSSLESS_CU +#define V4L2_CID_MPEG_VIDEO_HEVC_CONST_INTRA_PRED V4L2_CID_CODEC_VIDEO_HEVC_CONST_INTRA_PRED +#define V4L2_CID_MPEG_VIDEO_HEVC_WAVEFRONT V4L2_CID_CODEC_VIDEO_HEVC_WAVEFRONT +#define V4L2_CID_MPEG_VIDEO_HEVC_GENERAL_PB V4L2_CID_CODEC_VIDEO_HEVC_GENERAL_PB +#define V4L2_CID_MPEG_VIDEO_HEVC_TEMPORAL_ID V4L2_CID_CODEC_VIDEO_HEVC_TEMPORAL_ID +#define V4L2_CID_MPEG_VIDEO_HEVC_STRONG_SMOOTHING V4L2_CID_CODEC_VIDEO_HEVC_STRONG_SMOOTHING +#define V4L2_CID_MPEG_VIDEO_HEVC_MAX_NUM_MERGE_MV_MINUS1 V4L2_CID_CODEC_VIDEO_HEVC_MAX_NUM_MERGE_MV_MINUS1 +#define V4L2_CID_MPEG_VIDEO_HEVC_INTRA_PU_SPLIT V4L2_CID_CODEC_VIDEO_HEVC_INTRA_PU_SPLIT +#define V4L2_CID_MPEG_VIDEO_HEVC_TMV_PREDICTION V4L2_CID_CODEC_VIDEO_HEVC_TMV_PREDICTION +#define V4L2_CID_MPEG_VIDEO_HEVC_WITHOUT_STARTCODE V4L2_CID_CODEC_VIDEO_HEVC_WITHOUT_STARTCODE +#define V4L2_CID_MPEG_VIDEO_HEVC_SIZE_OF_LENGTH_FIELD V4L2_CID_CODEC_VIDEO_HEVC_SIZE_OF_LENGTH_FIELD +#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L0_BR V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L0_BR +#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L1_BR V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L1_BR +#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L2_BR V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L2_BR +#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L3_BR V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L3_BR +#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L4_BR V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L4_BR +#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L5_BR V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L5_BR +#define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L6_BR V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L6_BR +#define V4L2_CID_MPEG_VIDEO_REF_NUMBER_FOR_PFRAMES V4L2_CID_CODEC_VIDEO_REF_NUMBER_FOR_PFRAMES +#define V4L2_CID_MPEG_VIDEO_PREPEND_SPSPPS_TO_IDR V4L2_CID_CODEC_VIDEO_PREPEND_SPSPPS_TO_IDR +#define V4L2_CID_MPEG_VIDEO_CONSTANT_QUALITY V4L2_CID_CODEC_VIDEO_CONSTANT_QUALITY +#define V4L2_CID_MPEG_VIDEO_FRAME_SKIP_MODE V4L2_CID_CODEC_VIDEO_FRAME_SKIP_MODE +#define V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_MIN_QP V4L2_CID_CODEC_VIDEO_HEVC_I_FRAME_MIN_QP +#define V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_MAX_QP V4L2_CID_CODEC_VIDEO_HEVC_I_FRAME_MAX_QP +#define V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_MIN_QP V4L2_CID_CODEC_VIDEO_HEVC_P_FRAME_MIN_QP +#define V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_MAX_QP V4L2_CID_CODEC_VIDEO_HEVC_P_FRAME_MAX_QP +#define V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_MIN_QP V4L2_CID_CODEC_VIDEO_HEVC_B_FRAME_MIN_QP +#define V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_MAX_QP V4L2_CID_CODEC_VIDEO_HEVC_B_FRAME_MAX_QP +#define V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE +#define V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER +#define V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE +#define V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE +#define V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE +#define V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER +#define V4L2_CID_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE V4L2_CID_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE +#define V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM +#define V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP +#define V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM +#define V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP +#define V4L2_CID_MPEG_CX2341X_STREAM_INSERT_NAV_PACKETS V4L2_CID_CODEC_CX2341X_STREAM_INSERT_NAV_PACKETS +#define V4L2_CID_MPEG_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY V4L2_CID_CODEC_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY +#define V4L2_CID_MPEG_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY_ENABLE V4L2_CID_CODEC_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY_ENABLE +#define V4L2_CID_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE V4L2_CID_CODEC_MFC51_VIDEO_FRAME_SKIP_MODE +#define V4L2_CID_MPEG_MFC51_VIDEO_FORCE_FRAME_TYPE V4L2_CID_CODEC_MFC51_VIDEO_FORCE_FRAME_TYPE +#define V4L2_CID_MPEG_MFC51_VIDEO_PADDING V4L2_CID_CODEC_MFC51_VIDEO_PADDING +#define V4L2_CID_MPEG_MFC51_VIDEO_PADDING_YUV V4L2_CID_CODEC_MFC51_VIDEO_PADDING_YUV +#define V4L2_CID_MPEG_MFC51_VIDEO_RC_FIXED_TARGET_BIT V4L2_CID_CODEC_MFC51_VIDEO_RC_FIXED_TARGET_BIT +#define V4L2_CID_MPEG_MFC51_VIDEO_RC_REACTION_COEFF V4L2_CID_CODEC_MFC51_VIDEO_RC_REACTION_COEFF +#define V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_ACTIVITY V4L2_CID_CODEC_MFC51_VIDEO_H264_ADAPTIVE_RC_ACTIVITY +#define V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_DARK V4L2_CID_CODEC_MFC51_VIDEO_H264_ADAPTIVE_RC_DARK +#define V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_SMOOTH V4L2_CID_CODEC_MFC51_VIDEO_H264_ADAPTIVE_RC_SMOOTH +#define V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_STATIC V4L2_CID_CODEC_MFC51_VIDEO_H264_ADAPTIVE_RC_STATIC +#define v4l2_cid_mpeg_video_hevc_loop_filter_mode v4l2_codec_video_hevc_loop_filter_mode +#define v4l2_cid_mpeg_video_hevc_refresh_type v4l2_codec_video_hevc_refresh_type +#define v4l2_cid_mpeg_video_hevc_size_of_length_field v4l2_codec_video_hevc_size_of_length_field + #endif From patchwork Sat Mar 13 14:43:11 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans Verkuil X-Patchwork-Id: 400249 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-18.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER, INCLUDES_PATCH, MAILING_LIST_MULTI, SPF_HELO_NONE, SPF_PASS, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 9226BC4332D for ; Sat, 13 Mar 2021 14:44:26 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 562E964F21 for ; Sat, 13 Mar 2021 14:44:26 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234056AbhCMOnu (ORCPT ); Sat, 13 Mar 2021 09:43:50 -0500 Received: from lb3-smtp-cloud9.xs4all.net ([194.109.24.30]:58243 "EHLO lb3-smtp-cloud9.xs4all.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234019AbhCMOn3 (ORCPT ); Sat, 13 Mar 2021 09:43:29 -0500 Received: from cust-b5b5937f ([IPv6:fc0c:c16d:66b8:757f:c639:739b:9d66:799d]) by smtp-cloud9.xs4all.net with ESMTPA id L5UBljyoWC40pL5UFlV5d0; Sat, 13 Mar 2021 15:43:28 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=xs4all.nl; s=s2; t=1615646608; bh=eS0c2i6pG9mlnDwOALMpxpc1i3HkuI9BSF+0nAO5sLo=; h=From:To:Subject:Date:Message-Id:MIME-Version:From:Subject; b=CcsENmZtYDANHZ+o5zM9mlwuptj2LSr8urwg7fPZhN94jLDq69yj4x2cgdto4twbg LPPX00TItphlw+qOLlH1udWHJ5x4etLW4gTZNNUx0/tLVXym+p9a2GtQZcgafbd1p6 cugZau9yMqc/hRVTO5EqkkO4sn4V8CCVQGBqQrgg0k26I1YLwZwg+8a6kGld1A2ka9 hdbVElBo4OGZTPQs6vs3CzUzABty3YLQoVG5xIW9P6QGPOvLn3qAa9YTsMy11GNHG2 D84n6nfUfQq38wd1qly6oAyEc8IUjfaK1X1ijFAX091KOeoUjJchPrjPbVWftFXdmO IqmlLbT+6op9A== From: Hans Verkuil To: linux-media@vger.kernel.org Cc: Ezequiel Garcia , Nicolas Dufresne , Tomasz Figa , Alexandre Courbot , Hans Verkuil Subject: [PATCH 03/15] Documentation/*/media: rename MPEG to CODEC Date: Sat, 13 Mar 2021 15:43:11 +0100 Message-Id: <20210313144323.143600-4-hverkuil-cisco@xs4all.nl> X-Mailer: git-send-email 2.30.1 In-Reply-To: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> References: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> MIME-Version: 1.0 X-CMAE-Envelope: MS4xfLSx1V09vdOsiIy3BaNZdQmR/AETmlTZLgNQ9scdnGUt0EyBA5i0DQ6Ct0+d9egLK+97qvH87Wx78NNmwDGQSId51MO4xwmSM4nX0MFUXNzHT4mEtDo5 FedObq0D2z1LmGMi8iAH3j1/wChCPGUS+GNnSpfyMSicQMH4O6MZhu6GlpsUE6rY+K+RhwCmBIXUpWwW3CBWhGxjIlqHy1QnLG5cg1al5i+JvOMijy214ozU moQjxHrL4nUZhoDqmrKNTv/6lBm39Dvwv/3dqOs4j4iFKXyW9BmCRzEo05tIjgAoix2BCxj68IvhCYVAKve93f2bxsyXAPFPRDAcCsvJSYLNR4LRq68oCZk1 VwLXYKFU31VmWtxk87Ldo6kNGQwopg== Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Historically all codec-related data structures and defines used the MPEG prefix. This is confusing. Rename MPEG to CODEC to make it clear that the MPEG prefix isn't MPEG specific. Signed-off-by: Hans Verkuil --- .../driver-api/media/v4l2-controls.rst | 2 +- .../media/drivers/cx2341x-uapi.rst | 8 +- .../dvb/audio-bilingual-channel-select.rst | 2 +- .../media/dvb/audio-channel-select.rst | 2 +- .../media/dvb/video-get-frame-count.rst | 2 +- .../userspace-api/media/dvb/video-get-pts.rst | 2 +- .../media/v4l/dev-sliced-vbi.rst | 14 +- .../media/v4l/ext-ctrls-codec.rst | 1250 ++++++++--------- .../userspace-api/media/v4l/hist-v4l2.rst | 6 +- .../media/v4l/pixfmt-compressed.rst | 18 +- .../userspace-api/media/v4l/v4l2.rst | 4 +- 11 files changed, 655 insertions(+), 655 deletions(-) diff --git a/Documentation/driver-api/media/v4l2-controls.rst b/Documentation/driver-api/media/v4l2-controls.rst index b2e91804829b..3f89d8d5a3ce 100644 --- a/Documentation/driver-api/media/v4l2-controls.rst +++ b/Documentation/driver-api/media/v4l2-controls.rst @@ -456,7 +456,7 @@ Driver specific controls can be created using v4l2_ctrl_new_custom(): static const struct v4l2_ctrl_config ctrl_filter = { .ops = &ctrl_custom_ops, - .id = V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER, + .id = V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER, .name = "Spatial Filter", .type = V4L2_CTRL_TYPE_INTEGER, .flags = V4L2_CTRL_FLAG_SLIDER, diff --git a/Documentation/userspace-api/media/drivers/cx2341x-uapi.rst b/Documentation/userspace-api/media/drivers/cx2341x-uapi.rst index 8a7977af79d5..49d19ab70abd 100644 --- a/Documentation/userspace-api/media/drivers/cx2341x-uapi.rst +++ b/Documentation/userspace-api/media/drivers/cx2341x-uapi.rst @@ -129,13 +129,13 @@ Raw format c example } -Format of embedded V4L2_MPEG_STREAM_VBI_FMT_IVTV VBI data ---------------------------------------------------------- +Format of embedded V4L2_CODEC_STREAM_VBI_FMT_IVTV VBI data +---------------------------------------------------------- Author: Hans Verkuil -This section describes the V4L2_MPEG_STREAM_VBI_FMT_IVTV format of the VBI data +This section describes the V4L2_CODEC_STREAM_VBI_FMT_IVTV format of the VBI data embedded in an MPEG-2 program stream. This format is in part dictated by some hardware limitations of the ivtv driver (the driver for the Conexant cx23415/6 chips), in particular a maximum size for the VBI data. Anything longer is cut @@ -149,7 +149,7 @@ The stream ID of the VBI data is 0xBD. The maximum size of the embedded data is header and a 42 bytes payload each. Anything beyond this limit is cut off by the cx23415/6 firmware. Besides the data for the VBI lines we also need 36 bits for a bitmask determining which lines are captured and 4 bytes for a magic cookie, -signifying that this data package contains V4L2_MPEG_STREAM_VBI_FMT_IVTV VBI data. +signifying that this data package contains V4L2_CODEC_STREAM_VBI_FMT_IVTV VBI data. If all lines are used, then there is no longer room for the bitmask. To solve this two different magic numbers were introduced: diff --git a/Documentation/userspace-api/media/dvb/audio-bilingual-channel-select.rst b/Documentation/userspace-api/media/dvb/audio-bilingual-channel-select.rst index 33b5363317f1..5bcc22196329 100644 --- a/Documentation/userspace-api/media/dvb/audio-bilingual-channel-select.rst +++ b/Documentation/userspace-api/media/dvb/audio-bilingual-channel-select.rst @@ -44,7 +44,7 @@ Description ----------- This ioctl is obsolete. Do not use in new drivers. It has been replaced -by the V4L2 ``V4L2_CID_MPEG_AUDIO_DEC_MULTILINGUAL_PLAYBACK`` control +by the V4L2 ``V4L2_CID_CODEC_AUDIO_DEC_MULTILINGUAL_PLAYBACK`` control for MPEG decoders controlled through V4L2. This ioctl call asks the Audio Device to select the requested channel diff --git a/Documentation/userspace-api/media/dvb/audio-channel-select.rst b/Documentation/userspace-api/media/dvb/audio-channel-select.rst index 74093df92a68..13c761ad539e 100644 --- a/Documentation/userspace-api/media/dvb/audio-channel-select.rst +++ b/Documentation/userspace-api/media/dvb/audio-channel-select.rst @@ -44,7 +44,7 @@ Description ----------- This ioctl is for Digital TV devices only. To control a V4L2 decoder use the -V4L2 ``V4L2_CID_MPEG_AUDIO_DEC_PLAYBACK`` control instead. +V4L2 ``V4L2_CID_CODEC_AUDIO_DEC_PLAYBACK`` control instead. This ioctl call asks the Audio Device to select the requested channel if possible. diff --git a/Documentation/userspace-api/media/dvb/video-get-frame-count.rst b/Documentation/userspace-api/media/dvb/video-get-frame-count.rst index b48ac8c58a41..aaa97912528b 100644 --- a/Documentation/userspace-api/media/dvb/video-get-frame-count.rst +++ b/Documentation/userspace-api/media/dvb/video-get-frame-count.rst @@ -51,7 +51,7 @@ Description ----------- This ioctl is obsolete. Do not use in new drivers. For V4L2 decoders -this ioctl has been replaced by the ``V4L2_CID_MPEG_VIDEO_DEC_FRAME`` +this ioctl has been replaced by the ``V4L2_CID_CODEC_VIDEO_DEC_FRAME`` control. This ioctl call asks the Video Device to return the number of displayed diff --git a/Documentation/userspace-api/media/dvb/video-get-pts.rst b/Documentation/userspace-api/media/dvb/video-get-pts.rst index fedaff41be0b..b3b12ea942d4 100644 --- a/Documentation/userspace-api/media/dvb/video-get-pts.rst +++ b/Documentation/userspace-api/media/dvb/video-get-pts.rst @@ -55,7 +55,7 @@ Description ----------- This ioctl is obsolete. Do not use in new drivers. For V4L2 decoders -this ioctl has been replaced by the ``V4L2_CID_MPEG_VIDEO_DEC_PTS`` +this ioctl has been replaced by the ``V4L2_CID_CODEC_VIDEO_DEC_PTS`` control. This ioctl call asks the Video Device to return the current PTS diff --git a/Documentation/userspace-api/media/v4l/dev-sliced-vbi.rst b/Documentation/userspace-api/media/v4l/dev-sliced-vbi.rst index 97ec2b115c71..8fb01605990e 100644 --- a/Documentation/userspace-api/media/v4l/dev-sliced-vbi.rst +++ b/Documentation/userspace-api/media/v4l/dev-sliced-vbi.rst @@ -380,17 +380,17 @@ providing :ref:`negotiated sliced VBI services ` as data embedded in the MPEG stream. Users or applications control this sliced VBI data insertion with the -:ref:`V4L2_CID_MPEG_STREAM_VBI_FMT ` +:ref:`V4L2_CID_CODEC_STREAM_VBI_FMT ` control. If the driver does not provide the -:ref:`V4L2_CID_MPEG_STREAM_VBI_FMT ` +:ref:`V4L2_CID_CODEC_STREAM_VBI_FMT ` control, or only allows that control to be set to -:ref:`V4L2_MPEG_STREAM_VBI_FMT_NONE `, +:ref:`V4L2_CODEC_STREAM_VBI_FMT_NONE `, then the device cannot embed sliced VBI data in the MPEG stream. The -:ref:`V4L2_CID_MPEG_STREAM_VBI_FMT ` +:ref:`V4L2_CID_CODEC_STREAM_VBI_FMT ` control does not implicitly set the device driver to capture nor cease capturing sliced VBI data. The control only indicates to embed sliced VBI data in the MPEG stream, if an application has negotiated sliced VBI @@ -410,7 +410,7 @@ MPEG Stream Embedded, Sliced VBI Data Format: NONE -------------------------------------------------- The -:ref:`V4L2_MPEG_STREAM_VBI_FMT_NONE ` +:ref:`V4L2_CODEC_STREAM_VBI_FMT_NONE ` embedded sliced VBI format shall be interpreted by drivers as a control to cease embedding sliced VBI data in MPEG streams. Neither the device nor driver shall insert "empty" embedded sliced VBI data packets in the @@ -421,7 +421,7 @@ MPEG Stream Embedded, Sliced VBI Data Format: IVTV -------------------------------------------------- The -:ref:`V4L2_MPEG_STREAM_VBI_FMT_IVTV ` +:ref:`V4L2_CODEC_STREAM_VBI_FMT_IVTV ` embedded sliced VBI format, when supported, indicates to the driver to embed up to 36 lines of sliced VBI data per frame in an MPEG-2 *Private Stream 1 PES* packet encapsulated in an MPEG-2 *Program Pack* in the @@ -444,7 +444,7 @@ this format as well. The following definitions specify the payload of the MPEG-2 *Private Stream 1 PES* packets that contain sliced VBI data when -:ref:`V4L2_MPEG_STREAM_VBI_FMT_IVTV ` +:ref:`V4L2_CODEC_STREAM_VBI_FMT_IVTV ` is set. (The MPEG-2 *Private Stream 1 PES* packet header and encapsulating MPEG-2 *Program Pack* header are not detailed here. Please refer to the MPEG-2 specifications for details on those packet headers.) diff --git a/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst b/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst index e2d7c4a87fea..34884a785d76 100644 --- a/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst +++ b/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst @@ -34,10 +34,10 @@ Codec Control IDs .. _v4l2-mpeg-stream-type: -``V4L2_CID_MPEG_STREAM_TYPE`` +``V4L2_CID_CODEC_STREAM_TYPE`` (enum) -enum v4l2_mpeg_stream_type - +enum v4l2_codec_stream_type - The MPEG-1, -2 or -4 output stream type. One cannot assume anything here. Each hardware MPEG encoder tends to support different subsets of the available MPEG stream types. This control is specific to @@ -49,47 +49,47 @@ enum v4l2_mpeg_stream_type - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_STREAM_TYPE_MPEG2_PS`` + * - ``V4L2_CODEC_STREAM_TYPE_MPEG2_PS`` - MPEG-2 program stream - * - ``V4L2_MPEG_STREAM_TYPE_MPEG2_TS`` + * - ``V4L2_CODEC_STREAM_TYPE_MPEG2_TS`` - MPEG-2 transport stream - * - ``V4L2_MPEG_STREAM_TYPE_MPEG1_SS`` + * - ``V4L2_CODEC_STREAM_TYPE_MPEG1_SS`` - MPEG-1 system stream - * - ``V4L2_MPEG_STREAM_TYPE_MPEG2_DVD`` + * - ``V4L2_CODEC_STREAM_TYPE_MPEG2_DVD`` - MPEG-2 DVD-compatible stream - * - ``V4L2_MPEG_STREAM_TYPE_MPEG1_VCD`` + * - ``V4L2_CODEC_STREAM_TYPE_MPEG1_VCD`` - MPEG-1 VCD-compatible stream - * - ``V4L2_MPEG_STREAM_TYPE_MPEG2_SVCD`` + * - ``V4L2_CODEC_STREAM_TYPE_MPEG2_SVCD`` - MPEG-2 SVCD-compatible stream -``V4L2_CID_MPEG_STREAM_PID_PMT (integer)`` +``V4L2_CID_CODEC_STREAM_PID_PMT (integer)`` Program Map Table Packet ID for the MPEG transport stream (default 16) -``V4L2_CID_MPEG_STREAM_PID_AUDIO (integer)`` +``V4L2_CID_CODEC_STREAM_PID_AUDIO (integer)`` Audio Packet ID for the MPEG transport stream (default 256) -``V4L2_CID_MPEG_STREAM_PID_VIDEO (integer)`` +``V4L2_CID_CODEC_STREAM_PID_VIDEO (integer)`` Video Packet ID for the MPEG transport stream (default 260) -``V4L2_CID_MPEG_STREAM_PID_PCR (integer)`` +``V4L2_CID_CODEC_STREAM_PID_PCR (integer)`` Packet ID for the MPEG transport stream carrying PCR fields (default 259) -``V4L2_CID_MPEG_STREAM_PES_ID_AUDIO (integer)`` +``V4L2_CID_CODEC_STREAM_PES_ID_AUDIO (integer)`` Audio ID for MPEG PES -``V4L2_CID_MPEG_STREAM_PES_ID_VIDEO (integer)`` +``V4L2_CID_CODEC_STREAM_PES_ID_VIDEO (integer)`` Video ID for MPEG PES .. _v4l2-mpeg-stream-vbi-fmt: -``V4L2_CID_MPEG_STREAM_VBI_FMT`` +``V4L2_CID_CODEC_STREAM_VBI_FMT`` (enum) -enum v4l2_mpeg_stream_vbi_fmt - +enum v4l2_codec_stream_vbi_fmt - Some cards can embed VBI data (e. g. Closed Caption, Teletext) into the MPEG stream. This control selects whether VBI data should be embedded, and if so, what embedding method should be used. The list @@ -104,9 +104,9 @@ enum v4l2_mpeg_stream_vbi_fmt - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_STREAM_VBI_FMT_NONE`` + * - ``V4L2_CODEC_STREAM_VBI_FMT_NONE`` - No VBI in the MPEG stream - * - ``V4L2_MPEG_STREAM_VBI_FMT_IVTV`` + * - ``V4L2_CODEC_STREAM_VBI_FMT_IVTV`` - VBI in private packets, IVTV format (documented in the kernel sources in the file ``Documentation/userspace-api/media/drivers/cx2341x-uapi.rst``) @@ -115,10 +115,10 @@ enum v4l2_mpeg_stream_vbi_fmt - .. _v4l2-mpeg-audio-sampling-freq: -``V4L2_CID_MPEG_AUDIO_SAMPLING_FREQ`` +``V4L2_CID_CODEC_AUDIO_SAMPLING_FREQ`` (enum) -enum v4l2_mpeg_audio_sampling_freq - +enum v4l2_codec_audio_sampling_freq - MPEG Audio sampling frequency. Possible values are: @@ -127,21 +127,21 @@ enum v4l2_mpeg_audio_sampling_freq - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_AUDIO_SAMPLING_FREQ_44100`` + * - ``V4L2_CODEC_AUDIO_SAMPLING_FREQ_44100`` - 44.1 kHz - * - ``V4L2_MPEG_AUDIO_SAMPLING_FREQ_48000`` + * - ``V4L2_CODEC_AUDIO_SAMPLING_FREQ_48000`` - 48 kHz - * - ``V4L2_MPEG_AUDIO_SAMPLING_FREQ_32000`` + * - ``V4L2_CODEC_AUDIO_SAMPLING_FREQ_32000`` - 32 kHz .. _v4l2-mpeg-audio-encoding: -``V4L2_CID_MPEG_AUDIO_ENCODING`` +``V4L2_CID_CODEC_AUDIO_ENCODING`` (enum) -enum v4l2_mpeg_audio_encoding - +enum v4l2_codec_audio_encoding - MPEG Audio encoding. This control is specific to multiplexed MPEG streams. Possible values are: @@ -151,25 +151,25 @@ enum v4l2_mpeg_audio_encoding - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_AUDIO_ENCODING_LAYER_1`` + * - ``V4L2_CODEC_AUDIO_ENCODING_LAYER_1`` - MPEG-1/2 Layer I encoding - * - ``V4L2_MPEG_AUDIO_ENCODING_LAYER_2`` + * - ``V4L2_CODEC_AUDIO_ENCODING_LAYER_2`` - MPEG-1/2 Layer II encoding - * - ``V4L2_MPEG_AUDIO_ENCODING_LAYER_3`` + * - ``V4L2_CODEC_AUDIO_ENCODING_LAYER_3`` - MPEG-1/2 Layer III encoding - * - ``V4L2_MPEG_AUDIO_ENCODING_AAC`` + * - ``V4L2_CODEC_AUDIO_ENCODING_AAC`` - MPEG-2/4 AAC (Advanced Audio Coding) - * - ``V4L2_MPEG_AUDIO_ENCODING_AC3`` + * - ``V4L2_CODEC_AUDIO_ENCODING_AC3`` - AC-3 aka ATSC A/52 encoding .. _v4l2-mpeg-audio-l1-bitrate: -``V4L2_CID_MPEG_AUDIO_L1_BITRATE`` +``V4L2_CID_CODEC_AUDIO_L1_BITRATE`` (enum) -enum v4l2_mpeg_audio_l1_bitrate - +enum v4l2_codec_audio_l1_bitrate - MPEG-1/2 Layer I bitrate. Possible values are: @@ -178,43 +178,43 @@ enum v4l2_mpeg_audio_l1_bitrate - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_AUDIO_L1_BITRATE_32K`` + * - ``V4L2_CODEC_AUDIO_L1_BITRATE_32K`` - 32 kbit/s - * - ``V4L2_MPEG_AUDIO_L1_BITRATE_64K`` + * - ``V4L2_CODEC_AUDIO_L1_BITRATE_64K`` - 64 kbit/s - * - ``V4L2_MPEG_AUDIO_L1_BITRATE_96K`` + * - ``V4L2_CODEC_AUDIO_L1_BITRATE_96K`` - 96 kbit/s - * - ``V4L2_MPEG_AUDIO_L1_BITRATE_128K`` + * - ``V4L2_CODEC_AUDIO_L1_BITRATE_128K`` - 128 kbit/s - * - ``V4L2_MPEG_AUDIO_L1_BITRATE_160K`` + * - ``V4L2_CODEC_AUDIO_L1_BITRATE_160K`` - 160 kbit/s - * - ``V4L2_MPEG_AUDIO_L1_BITRATE_192K`` + * - ``V4L2_CODEC_AUDIO_L1_BITRATE_192K`` - 192 kbit/s - * - ``V4L2_MPEG_AUDIO_L1_BITRATE_224K`` + * - ``V4L2_CODEC_AUDIO_L1_BITRATE_224K`` - 224 kbit/s - * - ``V4L2_MPEG_AUDIO_L1_BITRATE_256K`` + * - ``V4L2_CODEC_AUDIO_L1_BITRATE_256K`` - 256 kbit/s - * - ``V4L2_MPEG_AUDIO_L1_BITRATE_288K`` + * - ``V4L2_CODEC_AUDIO_L1_BITRATE_288K`` - 288 kbit/s - * - ``V4L2_MPEG_AUDIO_L1_BITRATE_320K`` + * - ``V4L2_CODEC_AUDIO_L1_BITRATE_320K`` - 320 kbit/s - * - ``V4L2_MPEG_AUDIO_L1_BITRATE_352K`` + * - ``V4L2_CODEC_AUDIO_L1_BITRATE_352K`` - 352 kbit/s - * - ``V4L2_MPEG_AUDIO_L1_BITRATE_384K`` + * - ``V4L2_CODEC_AUDIO_L1_BITRATE_384K`` - 384 kbit/s - * - ``V4L2_MPEG_AUDIO_L1_BITRATE_416K`` + * - ``V4L2_CODEC_AUDIO_L1_BITRATE_416K`` - 416 kbit/s - * - ``V4L2_MPEG_AUDIO_L1_BITRATE_448K`` + * - ``V4L2_CODEC_AUDIO_L1_BITRATE_448K`` - 448 kbit/s .. _v4l2-mpeg-audio-l2-bitrate: -``V4L2_CID_MPEG_AUDIO_L2_BITRATE`` +``V4L2_CID_CODEC_AUDIO_L2_BITRATE`` (enum) -enum v4l2_mpeg_audio_l2_bitrate - +enum v4l2_codec_audio_l2_bitrate - MPEG-1/2 Layer II bitrate. Possible values are: @@ -223,43 +223,43 @@ enum v4l2_mpeg_audio_l2_bitrate - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_AUDIO_L2_BITRATE_32K`` + * - ``V4L2_CODEC_AUDIO_L2_BITRATE_32K`` - 32 kbit/s - * - ``V4L2_MPEG_AUDIO_L2_BITRATE_48K`` + * - ``V4L2_CODEC_AUDIO_L2_BITRATE_48K`` - 48 kbit/s - * - ``V4L2_MPEG_AUDIO_L2_BITRATE_56K`` + * - ``V4L2_CODEC_AUDIO_L2_BITRATE_56K`` - 56 kbit/s - * - ``V4L2_MPEG_AUDIO_L2_BITRATE_64K`` + * - ``V4L2_CODEC_AUDIO_L2_BITRATE_64K`` - 64 kbit/s - * - ``V4L2_MPEG_AUDIO_L2_BITRATE_80K`` + * - ``V4L2_CODEC_AUDIO_L2_BITRATE_80K`` - 80 kbit/s - * - ``V4L2_MPEG_AUDIO_L2_BITRATE_96K`` + * - ``V4L2_CODEC_AUDIO_L2_BITRATE_96K`` - 96 kbit/s - * - ``V4L2_MPEG_AUDIO_L2_BITRATE_112K`` + * - ``V4L2_CODEC_AUDIO_L2_BITRATE_112K`` - 112 kbit/s - * - ``V4L2_MPEG_AUDIO_L2_BITRATE_128K`` + * - ``V4L2_CODEC_AUDIO_L2_BITRATE_128K`` - 128 kbit/s - * - ``V4L2_MPEG_AUDIO_L2_BITRATE_160K`` + * - ``V4L2_CODEC_AUDIO_L2_BITRATE_160K`` - 160 kbit/s - * - ``V4L2_MPEG_AUDIO_L2_BITRATE_192K`` + * - ``V4L2_CODEC_AUDIO_L2_BITRATE_192K`` - 192 kbit/s - * - ``V4L2_MPEG_AUDIO_L2_BITRATE_224K`` + * - ``V4L2_CODEC_AUDIO_L2_BITRATE_224K`` - 224 kbit/s - * - ``V4L2_MPEG_AUDIO_L2_BITRATE_256K`` + * - ``V4L2_CODEC_AUDIO_L2_BITRATE_256K`` - 256 kbit/s - * - ``V4L2_MPEG_AUDIO_L2_BITRATE_320K`` + * - ``V4L2_CODEC_AUDIO_L2_BITRATE_320K`` - 320 kbit/s - * - ``V4L2_MPEG_AUDIO_L2_BITRATE_384K`` + * - ``V4L2_CODEC_AUDIO_L2_BITRATE_384K`` - 384 kbit/s .. _v4l2-mpeg-audio-l3-bitrate: -``V4L2_CID_MPEG_AUDIO_L3_BITRATE`` +``V4L2_CID_CODEC_AUDIO_L3_BITRATE`` (enum) -enum v4l2_mpeg_audio_l3_bitrate - +enum v4l2_codec_audio_l3_bitrate - MPEG-1/2 Layer III bitrate. Possible values are: @@ -268,46 +268,46 @@ enum v4l2_mpeg_audio_l3_bitrate - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_AUDIO_L3_BITRATE_32K`` + * - ``V4L2_CODEC_AUDIO_L3_BITRATE_32K`` - 32 kbit/s - * - ``V4L2_MPEG_AUDIO_L3_BITRATE_40K`` + * - ``V4L2_CODEC_AUDIO_L3_BITRATE_40K`` - 40 kbit/s - * - ``V4L2_MPEG_AUDIO_L3_BITRATE_48K`` + * - ``V4L2_CODEC_AUDIO_L3_BITRATE_48K`` - 48 kbit/s - * - ``V4L2_MPEG_AUDIO_L3_BITRATE_56K`` + * - ``V4L2_CODEC_AUDIO_L3_BITRATE_56K`` - 56 kbit/s - * - ``V4L2_MPEG_AUDIO_L3_BITRATE_64K`` + * - ``V4L2_CODEC_AUDIO_L3_BITRATE_64K`` - 64 kbit/s - * - ``V4L2_MPEG_AUDIO_L3_BITRATE_80K`` + * - ``V4L2_CODEC_AUDIO_L3_BITRATE_80K`` - 80 kbit/s - * - ``V4L2_MPEG_AUDIO_L3_BITRATE_96K`` + * - ``V4L2_CODEC_AUDIO_L3_BITRATE_96K`` - 96 kbit/s - * - ``V4L2_MPEG_AUDIO_L3_BITRATE_112K`` + * - ``V4L2_CODEC_AUDIO_L3_BITRATE_112K`` - 112 kbit/s - * - ``V4L2_MPEG_AUDIO_L3_BITRATE_128K`` + * - ``V4L2_CODEC_AUDIO_L3_BITRATE_128K`` - 128 kbit/s - * - ``V4L2_MPEG_AUDIO_L3_BITRATE_160K`` + * - ``V4L2_CODEC_AUDIO_L3_BITRATE_160K`` - 160 kbit/s - * - ``V4L2_MPEG_AUDIO_L3_BITRATE_192K`` + * - ``V4L2_CODEC_AUDIO_L3_BITRATE_192K`` - 192 kbit/s - * - ``V4L2_MPEG_AUDIO_L3_BITRATE_224K`` + * - ``V4L2_CODEC_AUDIO_L3_BITRATE_224K`` - 224 kbit/s - * - ``V4L2_MPEG_AUDIO_L3_BITRATE_256K`` + * - ``V4L2_CODEC_AUDIO_L3_BITRATE_256K`` - 256 kbit/s - * - ``V4L2_MPEG_AUDIO_L3_BITRATE_320K`` + * - ``V4L2_CODEC_AUDIO_L3_BITRATE_320K`` - 320 kbit/s -``V4L2_CID_MPEG_AUDIO_AAC_BITRATE (integer)`` +``V4L2_CID_CODEC_AUDIO_AAC_BITRATE (integer)`` AAC bitrate in bits per second. .. _v4l2-mpeg-audio-ac3-bitrate: -``V4L2_CID_MPEG_AUDIO_AC3_BITRATE`` +``V4L2_CID_CODEC_AUDIO_AC3_BITRATE`` (enum) -enum v4l2_mpeg_audio_ac3_bitrate - +enum v4l2_codec_audio_ac3_bitrate - AC-3 bitrate. Possible values are: @@ -316,53 +316,53 @@ enum v4l2_mpeg_audio_ac3_bitrate - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_32K`` + * - ``V4L2_CODEC_AUDIO_AC3_BITRATE_32K`` - 32 kbit/s - * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_40K`` + * - ``V4L2_CODEC_AUDIO_AC3_BITRATE_40K`` - 40 kbit/s - * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_48K`` + * - ``V4L2_CODEC_AUDIO_AC3_BITRATE_48K`` - 48 kbit/s - * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_56K`` + * - ``V4L2_CODEC_AUDIO_AC3_BITRATE_56K`` - 56 kbit/s - * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_64K`` + * - ``V4L2_CODEC_AUDIO_AC3_BITRATE_64K`` - 64 kbit/s - * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_80K`` + * - ``V4L2_CODEC_AUDIO_AC3_BITRATE_80K`` - 80 kbit/s - * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_96K`` + * - ``V4L2_CODEC_AUDIO_AC3_BITRATE_96K`` - 96 kbit/s - * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_112K`` + * - ``V4L2_CODEC_AUDIO_AC3_BITRATE_112K`` - 112 kbit/s - * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_128K`` + * - ``V4L2_CODEC_AUDIO_AC3_BITRATE_128K`` - 128 kbit/s - * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_160K`` + * - ``V4L2_CODEC_AUDIO_AC3_BITRATE_160K`` - 160 kbit/s - * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_192K`` + * - ``V4L2_CODEC_AUDIO_AC3_BITRATE_192K`` - 192 kbit/s - * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_224K`` + * - ``V4L2_CODEC_AUDIO_AC3_BITRATE_224K`` - 224 kbit/s - * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_256K`` + * - ``V4L2_CODEC_AUDIO_AC3_BITRATE_256K`` - 256 kbit/s - * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_320K`` + * - ``V4L2_CODEC_AUDIO_AC3_BITRATE_320K`` - 320 kbit/s - * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_384K`` + * - ``V4L2_CODEC_AUDIO_AC3_BITRATE_384K`` - 384 kbit/s - * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_448K`` + * - ``V4L2_CODEC_AUDIO_AC3_BITRATE_448K`` - 448 kbit/s - * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_512K`` + * - ``V4L2_CODEC_AUDIO_AC3_BITRATE_512K`` - 512 kbit/s - * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_576K`` + * - ``V4L2_CODEC_AUDIO_AC3_BITRATE_576K`` - 576 kbit/s - * - ``V4L2_MPEG_AUDIO_AC3_BITRATE_640K`` + * - ``V4L2_CODEC_AUDIO_AC3_BITRATE_640K`` - 640 kbit/s .. _v4l2-mpeg-audio-mode: -``V4L2_CID_MPEG_AUDIO_MODE`` +``V4L2_CID_CODEC_AUDIO_MODE`` (enum) -enum v4l2_mpeg_audio_mode - +enum v4l2_codec_audio_mode - MPEG Audio mode. Possible values are: @@ -371,23 +371,23 @@ enum v4l2_mpeg_audio_mode - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_AUDIO_MODE_STEREO`` + * - ``V4L2_CODEC_AUDIO_MODE_STEREO`` - Stereo - * - ``V4L2_MPEG_AUDIO_MODE_JOINT_STEREO`` + * - ``V4L2_CODEC_AUDIO_MODE_JOINT_STEREO`` - Joint Stereo - * - ``V4L2_MPEG_AUDIO_MODE_DUAL`` + * - ``V4L2_CODEC_AUDIO_MODE_DUAL`` - Bilingual - * - ``V4L2_MPEG_AUDIO_MODE_MONO`` + * - ``V4L2_CODEC_AUDIO_MODE_MONO`` - Mono .. _v4l2-mpeg-audio-mode-extension: -``V4L2_CID_MPEG_AUDIO_MODE_EXTENSION`` +``V4L2_CID_CODEC_AUDIO_MODE_EXTENSION`` (enum) -enum v4l2_mpeg_audio_mode_extension - +enum v4l2_codec_audio_mode_extension - Joint Stereo audio mode extension. In Layer I and II they indicate which subbands are in intensity stereo. All other subbands are coded in stereo. Layer III is not (yet) supported. Possible values are: @@ -398,23 +398,23 @@ enum v4l2_mpeg_audio_mode_extension - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_4`` + * - ``V4L2_CODEC_AUDIO_MODE_EXTENSION_BOUND_4`` - Subbands 4-31 in intensity stereo - * - ``V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_8`` + * - ``V4L2_CODEC_AUDIO_MODE_EXTENSION_BOUND_8`` - Subbands 8-31 in intensity stereo - * - ``V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_12`` + * - ``V4L2_CODEC_AUDIO_MODE_EXTENSION_BOUND_12`` - Subbands 12-31 in intensity stereo - * - ``V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_16`` + * - ``V4L2_CODEC_AUDIO_MODE_EXTENSION_BOUND_16`` - Subbands 16-31 in intensity stereo .. _v4l2-mpeg-audio-emphasis: -``V4L2_CID_MPEG_AUDIO_EMPHASIS`` +``V4L2_CID_CODEC_AUDIO_EMPHASIS`` (enum) -enum v4l2_mpeg_audio_emphasis - +enum v4l2_codec_audio_emphasis - Audio Emphasis. Possible values are: @@ -423,21 +423,21 @@ enum v4l2_mpeg_audio_emphasis - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_AUDIO_EMPHASIS_NONE`` + * - ``V4L2_CODEC_AUDIO_EMPHASIS_NONE`` - None - * - ``V4L2_MPEG_AUDIO_EMPHASIS_50_DIV_15_uS`` + * - ``V4L2_CODEC_AUDIO_EMPHASIS_50_DIV_15_uS`` - 50/15 microsecond emphasis - * - ``V4L2_MPEG_AUDIO_EMPHASIS_CCITT_J17`` + * - ``V4L2_CODEC_AUDIO_EMPHASIS_CCITT_J17`` - CCITT J.17 .. _v4l2-mpeg-audio-crc: -``V4L2_CID_MPEG_AUDIO_CRC`` +``V4L2_CID_CODEC_AUDIO_CRC`` (enum) -enum v4l2_mpeg_audio_crc - +enum v4l2_codec_audio_crc - CRC method. Possible values are: @@ -446,14 +446,14 @@ enum v4l2_mpeg_audio_crc - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_AUDIO_CRC_NONE`` + * - ``V4L2_CODEC_AUDIO_CRC_NONE`` - None - * - ``V4L2_MPEG_AUDIO_CRC_CRC16`` + * - ``V4L2_CODEC_AUDIO_CRC_CRC16`` - 16 bit parity check -``V4L2_CID_MPEG_AUDIO_MUTE (boolean)`` +``V4L2_CID_CODEC_AUDIO_MUTE (boolean)`` Mutes the audio when capturing. This is not done by muting audio hardware, which can still produce a slight hiss, but in the encoder itself, guaranteeing a fixed and reproducible audio bitstream. 0 = @@ -461,10 +461,10 @@ enum v4l2_mpeg_audio_crc - .. _v4l2-mpeg-audio-dec-playback: -``V4L2_CID_MPEG_AUDIO_DEC_PLAYBACK`` +``V4L2_CID_CODEC_AUDIO_DEC_PLAYBACK`` (enum) -enum v4l2_mpeg_audio_dec_playback - +enum v4l2_codec_audio_dec_playback - Determines how monolingual audio should be played back. Possible values are: @@ -476,35 +476,35 @@ enum v4l2_mpeg_audio_dec_playback - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_AUDIO_DEC_PLAYBACK_AUTO`` + * - ``V4L2_CODEC_AUDIO_DEC_PLAYBACK_AUTO`` - Automatically determines the best playback mode. - * - ``V4L2_MPEG_AUDIO_DEC_PLAYBACK_STEREO`` + * - ``V4L2_CODEC_AUDIO_DEC_PLAYBACK_STEREO`` - Stereo playback. - * - ``V4L2_MPEG_AUDIO_DEC_PLAYBACK_LEFT`` + * - ``V4L2_CODEC_AUDIO_DEC_PLAYBACK_LEFT`` - Left channel playback. - * - ``V4L2_MPEG_AUDIO_DEC_PLAYBACK_RIGHT`` + * - ``V4L2_CODEC_AUDIO_DEC_PLAYBACK_RIGHT`` - Right channel playback. - * - ``V4L2_MPEG_AUDIO_DEC_PLAYBACK_MONO`` + * - ``V4L2_CODEC_AUDIO_DEC_PLAYBACK_MONO`` - Mono playback. - * - ``V4L2_MPEG_AUDIO_DEC_PLAYBACK_SWAPPED_STEREO`` + * - ``V4L2_CODEC_AUDIO_DEC_PLAYBACK_SWAPPED_STEREO`` - Stereo playback with swapped left and right channels. .. _v4l2-mpeg-audio-dec-multilingual-playback: -``V4L2_CID_MPEG_AUDIO_DEC_MULTILINGUAL_PLAYBACK`` +``V4L2_CID_CODEC_AUDIO_DEC_MULTILINGUAL_PLAYBACK`` (enum) -enum v4l2_mpeg_audio_dec_playback - +enum v4l2_codec_audio_dec_playback - Determines how multilingual audio should be played back. .. _v4l2-mpeg-video-encoding: -``V4L2_CID_MPEG_VIDEO_ENCODING`` +``V4L2_CID_CODEC_VIDEO_ENCODING`` (enum) -enum v4l2_mpeg_video_encoding - +enum v4l2_codec_video_encoding - MPEG Video encoding method. This control is specific to multiplexed MPEG streams. Possible values are: @@ -514,21 +514,21 @@ enum v4l2_mpeg_video_encoding - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_ENCODING_MPEG_1`` + * - ``V4L2_CODEC_VIDEO_ENCODING_MPEG_1`` - MPEG-1 Video encoding - * - ``V4L2_MPEG_VIDEO_ENCODING_MPEG_2`` + * - ``V4L2_CODEC_VIDEO_ENCODING_MPEG_2`` - MPEG-2 Video encoding - * - ``V4L2_MPEG_VIDEO_ENCODING_MPEG_4_AVC`` + * - ``V4L2_CODEC_VIDEO_ENCODING_MPEG_4_AVC`` - MPEG-4 AVC (H.264) Video encoding .. _v4l2-mpeg-video-aspect: -``V4L2_CID_MPEG_VIDEO_ASPECT`` +``V4L2_CID_CODEC_VIDEO_ASPECT`` (enum) -enum v4l2_mpeg_video_aspect - +enum v4l2_codec_video_aspect - Video aspect. Possible values are: @@ -537,31 +537,31 @@ enum v4l2_mpeg_video_aspect - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_ASPECT_1x1`` - * - ``V4L2_MPEG_VIDEO_ASPECT_4x3`` - * - ``V4L2_MPEG_VIDEO_ASPECT_16x9`` - * - ``V4L2_MPEG_VIDEO_ASPECT_221x100`` + * - ``V4L2_CODEC_VIDEO_ASPECT_1x1`` + * - ``V4L2_CODEC_VIDEO_ASPECT_4x3`` + * - ``V4L2_CODEC_VIDEO_ASPECT_16x9`` + * - ``V4L2_CODEC_VIDEO_ASPECT_221x100`` -``V4L2_CID_MPEG_VIDEO_B_FRAMES (integer)`` +``V4L2_CID_CODEC_VIDEO_B_FRAMES (integer)`` Number of B-Frames (default 2) -``V4L2_CID_MPEG_VIDEO_GOP_SIZE (integer)`` +``V4L2_CID_CODEC_VIDEO_GOP_SIZE (integer)`` GOP size (default 12) -``V4L2_CID_MPEG_VIDEO_GOP_CLOSURE (boolean)`` +``V4L2_CID_CODEC_VIDEO_GOP_CLOSURE (boolean)`` GOP closure (default 1) -``V4L2_CID_MPEG_VIDEO_PULLDOWN (boolean)`` +``V4L2_CID_CODEC_VIDEO_PULLDOWN (boolean)`` Enable 3:2 pulldown (default 0) .. _v4l2-mpeg-video-bitrate-mode: -``V4L2_CID_MPEG_VIDEO_BITRATE_MODE`` +``V4L2_CID_CODEC_VIDEO_BITRATE_MODE`` (enum) -enum v4l2_mpeg_video_bitrate_mode - +enum v4l2_codec_video_bitrate_mode - Video bitrate mode. Possible values are: @@ -570,35 +570,35 @@ enum v4l2_mpeg_video_bitrate_mode - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_BITRATE_MODE_VBR`` + * - ``V4L2_CODEC_VIDEO_BITRATE_MODE_VBR`` - Variable bitrate - * - ``V4L2_MPEG_VIDEO_BITRATE_MODE_CBR`` + * - ``V4L2_CODEC_VIDEO_BITRATE_MODE_CBR`` - Constant bitrate - * - ``V4L2_MPEG_VIDEO_BITRATE_MODE_CQ`` + * - ``V4L2_CODEC_VIDEO_BITRATE_MODE_CQ`` - Constant quality -``V4L2_CID_MPEG_VIDEO_BITRATE (integer)`` +``V4L2_CID_CODEC_VIDEO_BITRATE (integer)`` Video bitrate in bits per second. -``V4L2_CID_MPEG_VIDEO_BITRATE_PEAK (integer)`` +``V4L2_CID_CODEC_VIDEO_BITRATE_PEAK (integer)`` Peak video bitrate in bits per second. Must be larger or equal to the average video bitrate. It is ignored if the video bitrate mode is set to constant bitrate. -``V4L2_CID_MPEG_VIDEO_CONSTANT_QUALITY (integer)`` +``V4L2_CID_CODEC_VIDEO_CONSTANT_QUALITY (integer)`` Constant quality level control. This control is applicable when - ``V4L2_CID_MPEG_VIDEO_BITRATE_MODE`` value is - ``V4L2_MPEG_VIDEO_BITRATE_MODE_CQ``. Valid range is 1 to 100 + ``V4L2_CID_CODEC_VIDEO_BITRATE_MODE`` value is + ``V4L2_CODEC_VIDEO_BITRATE_MODE_CQ``. Valid range is 1 to 100 where 1 indicates lowest quality and 100 indicates highest quality. Encoder will decide the appropriate quantization parameter and bitrate to produce requested frame quality. -``V4L2_CID_MPEG_VIDEO_FRAME_SKIP_MODE (enum)`` +``V4L2_CID_CODEC_VIDEO_FRAME_SKIP_MODE (enum)`` -enum v4l2_mpeg_video_frame_skip_mode - +enum v4l2_codec_video_frame_skip_mode - Indicates in what conditions the encoder should skip frames. If encoding a frame would cause the encoded stream to be larger then a chosen data limit then the frame will be skipped. Possible values @@ -615,12 +615,12 @@ enum v4l2_mpeg_video_frame_skip_mode - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_DISABLED`` + * - ``V4L2_CODEC_VIDEO_FRAME_SKIP_MODE_DISABLED`` - Frame skip mode is disabled. - * - ``V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_LEVEL_LIMIT`` + * - ``V4L2_CODEC_VIDEO_FRAME_SKIP_MODE_LEVEL_LIMIT`` - Frame skip mode enabled and buffer limit is set by the chosen level and is defined by the standard. - * - ``V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT`` + * - ``V4L2_CODEC_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT`` - Frame skip mode enabled and buffer limit is set by the :ref:`VBV (MPEG1/2/4) ` or :ref:`CPB (H264) buffer size ` control. @@ -629,16 +629,16 @@ enum v4l2_mpeg_video_frame_skip_mode - \normalsize -``V4L2_CID_MPEG_VIDEO_TEMPORAL_DECIMATION (integer)`` +``V4L2_CID_CODEC_VIDEO_TEMPORAL_DECIMATION (integer)`` For every captured frame, skip this many subsequent frames (default 0). -``V4L2_CID_MPEG_VIDEO_MUTE (boolean)`` +``V4L2_CID_CODEC_VIDEO_MUTE (boolean)`` "Mutes" the video to a fixed color when capturing. This is useful for testing, to produce a fixed video bitstream. 0 = unmuted, 1 = muted. -``V4L2_CID_MPEG_VIDEO_MUTE_YUV (integer)`` +``V4L2_CID_CODEC_VIDEO_MUTE_YUV (integer)`` Sets the "mute" color of the video. The supplied 32-bit integer is interpreted as follows (bit 0 = least significant bit): @@ -661,7 +661,7 @@ enum v4l2_mpeg_video_frame_skip_mode - .. _v4l2-mpeg-video-dec-pts: -``V4L2_CID_MPEG_VIDEO_DEC_PTS (integer64)`` +``V4L2_CID_CODEC_VIDEO_DEC_PTS (integer64)`` This read-only control returns the 33-bit video Presentation Time Stamp as defined in ITU T-REC-H.222.0 and ISO/IEC 13818-1 of the currently displayed frame. This is the same PTS as is used in @@ -669,26 +669,26 @@ enum v4l2_mpeg_video_frame_skip_mode - .. _v4l2-mpeg-video-dec-frame: -``V4L2_CID_MPEG_VIDEO_DEC_FRAME (integer64)`` +``V4L2_CID_CODEC_VIDEO_DEC_FRAME (integer64)`` This read-only control returns the frame counter of the frame that is currently displayed (decoded). This value is reset to 0 whenever the decoder is started. -``V4L2_CID_MPEG_VIDEO_DECODER_SLICE_INTERFACE (boolean)`` +``V4L2_CID_CODEC_VIDEO_DECODER_SLICE_INTERFACE (boolean)`` If enabled the decoder expects to receive a single slice per buffer, otherwise the decoder expects a single frame in per buffer. Applicable to the decoder, all codecs. -``V4L2_CID_MPEG_VIDEO_H264_VUI_SAR_ENABLE (boolean)`` +``V4L2_CID_CODEC_VIDEO_H264_VUI_SAR_ENABLE (boolean)`` Enable writing sample aspect ratio in the Video Usability Information. Applicable to the H264 encoder. .. _v4l2-mpeg-video-h264-vui-sar-idc: -``V4L2_CID_MPEG_VIDEO_H264_VUI_SAR_IDC`` +``V4L2_CID_CODEC_VIDEO_H264_VUI_SAR_IDC`` (enum) -enum v4l2_mpeg_video_h264_vui_sar_idc - +enum v4l2_codec_video_h264_vui_sar_idc - VUI sample aspect ratio indicator for H.264 encoding. The value is defined in the table E-1 in the standard. Applicable to the H264 encoder. @@ -699,59 +699,59 @@ enum v4l2_mpeg_video_h264_vui_sar_idc - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_UNSPECIFIED`` + * - ``V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_UNSPECIFIED`` - Unspecified - * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_1x1`` + * - ``V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_1x1`` - 1x1 - * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_12x11`` + * - ``V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_12x11`` - 12x11 - * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_10x11`` + * - ``V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_10x11`` - 10x11 - * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_16x11`` + * - ``V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_16x11`` - 16x11 - * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_40x33`` + * - ``V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_40x33`` - 40x33 - * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_24x11`` + * - ``V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_24x11`` - 24x11 - * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_20x11`` + * - ``V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_20x11`` - 20x11 - * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_32x11`` + * - ``V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_32x11`` - 32x11 - * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_80x33`` + * - ``V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_80x33`` - 80x33 - * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_18x11`` + * - ``V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_18x11`` - 18x11 - * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_15x11`` + * - ``V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_15x11`` - 15x11 - * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_64x33`` + * - ``V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_64x33`` - 64x33 - * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_160x99`` + * - ``V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_160x99`` - 160x99 - * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_4x3`` + * - ``V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_4x3`` - 4x3 - * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_3x2`` + * - ``V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_3x2`` - 3x2 - * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_2x1`` + * - ``V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_2x1`` - 2x1 - * - ``V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_EXTENDED`` + * - ``V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_EXTENDED`` - Extended SAR -``V4L2_CID_MPEG_VIDEO_H264_VUI_EXT_SAR_WIDTH (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_VUI_EXT_SAR_WIDTH (integer)`` Extended sample aspect ratio width for H.264 VUI encoding. Applicable to the H264 encoder. -``V4L2_CID_MPEG_VIDEO_H264_VUI_EXT_SAR_HEIGHT (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_VUI_EXT_SAR_HEIGHT (integer)`` Extended sample aspect ratio height for H.264 VUI encoding. Applicable to the H264 encoder. .. _v4l2-mpeg-video-h264-level: -``V4L2_CID_MPEG_VIDEO_H264_LEVEL`` +``V4L2_CID_CODEC_VIDEO_H264_LEVEL`` (enum) -enum v4l2_mpeg_video_h264_level - +enum v4l2_codec_video_h264_level - The level information for the H264 video elementary stream. Applicable to the H264 encoder. Possible values are: @@ -761,55 +761,55 @@ enum v4l2_mpeg_video_h264_level - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_H264_LEVEL_1_0`` + * - ``V4L2_CODEC_VIDEO_H264_LEVEL_1_0`` - Level 1.0 - * - ``V4L2_MPEG_VIDEO_H264_LEVEL_1B`` + * - ``V4L2_CODEC_VIDEO_H264_LEVEL_1B`` - Level 1B - * - ``V4L2_MPEG_VIDEO_H264_LEVEL_1_1`` + * - ``V4L2_CODEC_VIDEO_H264_LEVEL_1_1`` - Level 1.1 - * - ``V4L2_MPEG_VIDEO_H264_LEVEL_1_2`` + * - ``V4L2_CODEC_VIDEO_H264_LEVEL_1_2`` - Level 1.2 - * - ``V4L2_MPEG_VIDEO_H264_LEVEL_1_3`` + * - ``V4L2_CODEC_VIDEO_H264_LEVEL_1_3`` - Level 1.3 - * - ``V4L2_MPEG_VIDEO_H264_LEVEL_2_0`` + * - ``V4L2_CODEC_VIDEO_H264_LEVEL_2_0`` - Level 2.0 - * - ``V4L2_MPEG_VIDEO_H264_LEVEL_2_1`` + * - ``V4L2_CODEC_VIDEO_H264_LEVEL_2_1`` - Level 2.1 - * - ``V4L2_MPEG_VIDEO_H264_LEVEL_2_2`` + * - ``V4L2_CODEC_VIDEO_H264_LEVEL_2_2`` - Level 2.2 - * - ``V4L2_MPEG_VIDEO_H264_LEVEL_3_0`` + * - ``V4L2_CODEC_VIDEO_H264_LEVEL_3_0`` - Level 3.0 - * - ``V4L2_MPEG_VIDEO_H264_LEVEL_3_1`` + * - ``V4L2_CODEC_VIDEO_H264_LEVEL_3_1`` - Level 3.1 - * - ``V4L2_MPEG_VIDEO_H264_LEVEL_3_2`` + * - ``V4L2_CODEC_VIDEO_H264_LEVEL_3_2`` - Level 3.2 - * - ``V4L2_MPEG_VIDEO_H264_LEVEL_4_0`` + * - ``V4L2_CODEC_VIDEO_H264_LEVEL_4_0`` - Level 4.0 - * - ``V4L2_MPEG_VIDEO_H264_LEVEL_4_1`` + * - ``V4L2_CODEC_VIDEO_H264_LEVEL_4_1`` - Level 4.1 - * - ``V4L2_MPEG_VIDEO_H264_LEVEL_4_2`` + * - ``V4L2_CODEC_VIDEO_H264_LEVEL_4_2`` - Level 4.2 - * - ``V4L2_MPEG_VIDEO_H264_LEVEL_5_0`` + * - ``V4L2_CODEC_VIDEO_H264_LEVEL_5_0`` - Level 5.0 - * - ``V4L2_MPEG_VIDEO_H264_LEVEL_5_1`` + * - ``V4L2_CODEC_VIDEO_H264_LEVEL_5_1`` - Level 5.1 - * - ``V4L2_MPEG_VIDEO_H264_LEVEL_5_2`` + * - ``V4L2_CODEC_VIDEO_H264_LEVEL_5_2`` - Level 5.2 - * - ``V4L2_MPEG_VIDEO_H264_LEVEL_6_0`` + * - ``V4L2_CODEC_VIDEO_H264_LEVEL_6_0`` - Level 6.0 - * - ``V4L2_MPEG_VIDEO_H264_LEVEL_6_1`` + * - ``V4L2_CODEC_VIDEO_H264_LEVEL_6_1`` - Level 6.1 - * - ``V4L2_MPEG_VIDEO_H264_LEVEL_6_2`` + * - ``V4L2_CODEC_VIDEO_H264_LEVEL_6_2`` - Level 6.2 .. _v4l2-mpeg-video-mpeg2-level: -``V4L2_CID_MPEG_VIDEO_MPEG2_LEVEL`` +``V4L2_CID_CODEC_VIDEO_MPEG2_LEVEL`` (enum) -enum v4l2_mpeg_video_mpeg2_level - +enum v4l2_codec_video_mpeg2_level - The level information for the MPEG2 elementary stream. Applicable to MPEG2 codecs. Possible values are: @@ -819,23 +819,23 @@ enum v4l2_mpeg_video_mpeg2_level - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_MPEG2_LEVEL_LOW`` + * - ``V4L2_CODEC_VIDEO_MPEG2_LEVEL_LOW`` - Low Level (LL) - * - ``V4L2_MPEG_VIDEO_MPEG2_LEVEL_MAIN`` + * - ``V4L2_CODEC_VIDEO_MPEG2_LEVEL_MAIN`` - Main Level (ML) - * - ``V4L2_MPEG_VIDEO_MPEG2_LEVEL_HIGH_1440`` + * - ``V4L2_CODEC_VIDEO_MPEG2_LEVEL_HIGH_1440`` - High-1440 Level (H-14) - * - ``V4L2_MPEG_VIDEO_MPEG2_LEVEL_HIGH`` + * - ``V4L2_CODEC_VIDEO_MPEG2_LEVEL_HIGH`` - High Level (HL) .. _v4l2-mpeg-video-mpeg4-level: -``V4L2_CID_MPEG_VIDEO_MPEG4_LEVEL`` +``V4L2_CID_CODEC_VIDEO_MPEG4_LEVEL`` (enum) -enum v4l2_mpeg_video_mpeg4_level - +enum v4l2_codec_video_mpeg4_level - The level information for the MPEG4 elementary stream. Applicable to the MPEG4 encoder. Possible values are: @@ -845,31 +845,31 @@ enum v4l2_mpeg_video_mpeg4_level - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_MPEG4_LEVEL_0`` + * - ``V4L2_CODEC_VIDEO_MPEG4_LEVEL_0`` - Level 0 - * - ``V4L2_MPEG_VIDEO_MPEG4_LEVEL_0B`` + * - ``V4L2_CODEC_VIDEO_MPEG4_LEVEL_0B`` - Level 0b - * - ``V4L2_MPEG_VIDEO_MPEG4_LEVEL_1`` + * - ``V4L2_CODEC_VIDEO_MPEG4_LEVEL_1`` - Level 1 - * - ``V4L2_MPEG_VIDEO_MPEG4_LEVEL_2`` + * - ``V4L2_CODEC_VIDEO_MPEG4_LEVEL_2`` - Level 2 - * - ``V4L2_MPEG_VIDEO_MPEG4_LEVEL_3`` + * - ``V4L2_CODEC_VIDEO_MPEG4_LEVEL_3`` - Level 3 - * - ``V4L2_MPEG_VIDEO_MPEG4_LEVEL_3B`` + * - ``V4L2_CODEC_VIDEO_MPEG4_LEVEL_3B`` - Level 3b - * - ``V4L2_MPEG_VIDEO_MPEG4_LEVEL_4`` + * - ``V4L2_CODEC_VIDEO_MPEG4_LEVEL_4`` - Level 4 - * - ``V4L2_MPEG_VIDEO_MPEG4_LEVEL_5`` + * - ``V4L2_CODEC_VIDEO_MPEG4_LEVEL_5`` - Level 5 .. _v4l2-mpeg-video-h264-profile: -``V4L2_CID_MPEG_VIDEO_H264_PROFILE`` +``V4L2_CID_CODEC_VIDEO_H264_PROFILE`` (enum) -enum v4l2_mpeg_video_h264_profile - +enum v4l2_codec_video_h264_profile - The profile information for H264. Applicable to the H264 encoder. Possible values are: @@ -883,41 +883,41 @@ enum v4l2_mpeg_video_h264_profile - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE`` + * - ``V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE`` - Baseline profile - * - ``V4L2_MPEG_VIDEO_H264_PROFILE_CONSTRAINED_BASELINE`` + * - ``V4L2_CODEC_VIDEO_H264_PROFILE_CONSTRAINED_BASELINE`` - Constrained Baseline profile - * - ``V4L2_MPEG_VIDEO_H264_PROFILE_MAIN`` + * - ``V4L2_CODEC_VIDEO_H264_PROFILE_MAIN`` - Main profile - * - ``V4L2_MPEG_VIDEO_H264_PROFILE_EXTENDED`` + * - ``V4L2_CODEC_VIDEO_H264_PROFILE_EXTENDED`` - Extended profile - * - ``V4L2_MPEG_VIDEO_H264_PROFILE_HIGH`` + * - ``V4L2_CODEC_VIDEO_H264_PROFILE_HIGH`` - High profile - * - ``V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_10`` + * - ``V4L2_CODEC_VIDEO_H264_PROFILE_HIGH_10`` - High 10 profile - * - ``V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_422`` + * - ``V4L2_CODEC_VIDEO_H264_PROFILE_HIGH_422`` - High 422 profile - * - ``V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_444_PREDICTIVE`` + * - ``V4L2_CODEC_VIDEO_H264_PROFILE_HIGH_444_PREDICTIVE`` - High 444 Predictive profile - * - ``V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_10_INTRA`` + * - ``V4L2_CODEC_VIDEO_H264_PROFILE_HIGH_10_INTRA`` - High 10 Intra profile - * - ``V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_422_INTRA`` + * - ``V4L2_CODEC_VIDEO_H264_PROFILE_HIGH_422_INTRA`` - High 422 Intra profile - * - ``V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_444_INTRA`` + * - ``V4L2_CODEC_VIDEO_H264_PROFILE_HIGH_444_INTRA`` - High 444 Intra profile - * - ``V4L2_MPEG_VIDEO_H264_PROFILE_CAVLC_444_INTRA`` + * - ``V4L2_CODEC_VIDEO_H264_PROFILE_CAVLC_444_INTRA`` - CAVLC 444 Intra profile - * - ``V4L2_MPEG_VIDEO_H264_PROFILE_SCALABLE_BASELINE`` + * - ``V4L2_CODEC_VIDEO_H264_PROFILE_SCALABLE_BASELINE`` - Scalable Baseline profile - * - ``V4L2_MPEG_VIDEO_H264_PROFILE_SCALABLE_HIGH`` + * - ``V4L2_CODEC_VIDEO_H264_PROFILE_SCALABLE_HIGH`` - Scalable High profile - * - ``V4L2_MPEG_VIDEO_H264_PROFILE_SCALABLE_HIGH_INTRA`` + * - ``V4L2_CODEC_VIDEO_H264_PROFILE_SCALABLE_HIGH_INTRA`` - Scalable High Intra profile - * - ``V4L2_MPEG_VIDEO_H264_PROFILE_STEREO_HIGH`` + * - ``V4L2_CODEC_VIDEO_H264_PROFILE_STEREO_HIGH`` - Stereo High profile - * - ``V4L2_MPEG_VIDEO_H264_PROFILE_MULTIVIEW_HIGH`` + * - ``V4L2_CODEC_VIDEO_H264_PROFILE_MULTIVIEW_HIGH`` - Multiview High profile - * - ``V4L2_MPEG_VIDEO_H264_PROFILE_CONSTRAINED_HIGH`` + * - ``V4L2_CODEC_VIDEO_H264_PROFILE_CONSTRAINED_HIGH`` - Constrained High profile .. raw:: latex @@ -926,10 +926,10 @@ enum v4l2_mpeg_video_h264_profile - .. _v4l2-mpeg-video-mpeg2-profile: -``V4L2_CID_MPEG_VIDEO_MPEG2_PROFILE`` +``V4L2_CID_CODEC_VIDEO_MPEG2_PROFILE`` (enum) -enum v4l2_mpeg_video_mpeg2_profile - +enum v4l2_codec_video_mpeg2_profile - The profile information for MPEG2. Applicable to MPEG2 codecs. Possible values are: @@ -943,17 +943,17 @@ enum v4l2_mpeg_video_mpeg2_profile - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_MPEG2_PROFILE_SIMPLE`` + * - ``V4L2_CODEC_VIDEO_MPEG2_PROFILE_SIMPLE`` - Simple profile (SP) - * - ``V4L2_MPEG_VIDEO_MPEG2_PROFILE_MAIN`` + * - ``V4L2_CODEC_VIDEO_MPEG2_PROFILE_MAIN`` - Main profile (MP) - * - ``V4L2_MPEG_VIDEO_MPEG2_PROFILE_SNR_SCALABLE`` + * - ``V4L2_CODEC_VIDEO_MPEG2_PROFILE_SNR_SCALABLE`` - SNR Scalable profile (SNR) - * - ``V4L2_MPEG_VIDEO_MPEG2_PROFILE_SPATIALLY_SCALABLE`` + * - ``V4L2_CODEC_VIDEO_MPEG2_PROFILE_SPATIALLY_SCALABLE`` - Spatially Scalable profile (Spt) - * - ``V4L2_MPEG_VIDEO_MPEG2_PROFILE_HIGH`` + * - ``V4L2_CODEC_VIDEO_MPEG2_PROFILE_HIGH`` - High profile (HP) - * - ``V4L2_MPEG_VIDEO_MPEG2_PROFILE_MULTIVIEW`` + * - ``V4L2_CODEC_VIDEO_MPEG2_PROFILE_MULTIVIEW`` - Multi-view profile (MVP) @@ -963,10 +963,10 @@ enum v4l2_mpeg_video_mpeg2_profile - .. _v4l2-mpeg-video-mpeg4-profile: -``V4L2_CID_MPEG_VIDEO_MPEG4_PROFILE`` +``V4L2_CID_CODEC_VIDEO_MPEG4_PROFILE`` (enum) -enum v4l2_mpeg_video_mpeg4_profile - +enum v4l2_codec_video_mpeg4_profile - The profile information for MPEG4. Applicable to the MPEG4 encoder. Possible values are: @@ -980,31 +980,31 @@ enum v4l2_mpeg_video_mpeg4_profile - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_MPEG4_PROFILE_SIMPLE`` + * - ``V4L2_CODEC_VIDEO_MPEG4_PROFILE_SIMPLE`` - Simple profile - * - ``V4L2_MPEG_VIDEO_MPEG4_PROFILE_ADVANCED_SIMPLE`` + * - ``V4L2_CODEC_VIDEO_MPEG4_PROFILE_ADVANCED_SIMPLE`` - Advanced Simple profile - * - ``V4L2_MPEG_VIDEO_MPEG4_PROFILE_CORE`` + * - ``V4L2_CODEC_VIDEO_MPEG4_PROFILE_CORE`` - Core profile - * - ``V4L2_MPEG_VIDEO_MPEG4_PROFILE_SIMPLE_SCALABLE`` + * - ``V4L2_CODEC_VIDEO_MPEG4_PROFILE_SIMPLE_SCALABLE`` - Simple Scalable profile - * - ``V4L2_MPEG_VIDEO_MPEG4_PROFILE_ADVANCED_CODING_EFFICIENCY`` + * - ``V4L2_CODEC_VIDEO_MPEG4_PROFILE_ADVANCED_CODING_EFFICIENCY`` - Advanced Coding Efficiency profile .. raw:: latex \normalsize -``V4L2_CID_MPEG_VIDEO_MAX_REF_PIC (integer)`` +``V4L2_CID_CODEC_VIDEO_MAX_REF_PIC (integer)`` The maximum number of reference pictures used for encoding. Applicable to the encoder. .. _v4l2-mpeg-video-multi-slice-mode: -``V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MODE`` +``V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MODE`` (enum) -enum v4l2_mpeg_video_multi_slice_mode - +enum v4l2_codec_video_multi_slice_mode - Determines how the encoder should handle division of frame into slices. Applicable to the encoder. Possible values are: @@ -1016,33 +1016,33 @@ enum v4l2_mpeg_video_multi_slice_mode - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_SINGLE`` + * - ``V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_SINGLE`` - Single slice per frame. - * - ``V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_MB`` + * - ``V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_MAX_MB`` - Multiple slices with set maximum number of macroblocks per slice. - * - ``V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_BYTES`` + * - ``V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_MAX_BYTES`` - Multiple slice with set maximum size in bytes per slice. -``V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MAX_MB (integer)`` +``V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MAX_MB (integer)`` The maximum number of macroblocks in a slice. Used when - ``V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MODE`` is set to - ``V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_MB``. Applicable to the + ``V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MODE`` is set to + ``V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_MAX_MB``. Applicable to the encoder. -``V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MAX_BYTES (integer)`` +``V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MAX_BYTES (integer)`` The maximum size of a slice in bytes. Used when - ``V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MODE`` is set to - ``V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_BYTES``. Applicable to the + ``V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MODE`` is set to + ``V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_MAX_BYTES``. Applicable to the encoder. .. _v4l2-mpeg-video-h264-loop-filter-mode: -``V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_MODE`` +``V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_MODE`` (enum) -enum v4l2_mpeg_video_h264_loop_filter_mode - +enum v4l2_codec_video_h264_loop_filter_mode - Loop filter mode for H264 encoder. Possible values are: .. raw:: latex @@ -1055,11 +1055,11 @@ enum v4l2_mpeg_video_h264_loop_filter_mode - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_ENABLED`` + * - ``V4L2_CODEC_VIDEO_H264_LOOP_FILTER_MODE_ENABLED`` - Loop filter is enabled. - * - ``V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_DISABLED`` + * - ``V4L2_CODEC_VIDEO_H264_LOOP_FILTER_MODE_DISABLED`` - Loop filter is disabled. - * - ``V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY`` + * - ``V4L2_CODEC_VIDEO_H264_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY`` - Loop filter is disabled at the slice boundary. .. raw:: latex @@ -1067,14 +1067,14 @@ enum v4l2_mpeg_video_h264_loop_filter_mode - \normalsize -``V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_ALPHA (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_ALPHA (integer)`` Loop filter alpha coefficient, defined in the H264 standard. This value corresponds to the slice_alpha_c0_offset_div2 slice header field, and should be in the range of -6 to +6, inclusive. The actual alpha offset FilterOffsetA is twice this value. Applicable to the H264 encoder. -``V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_BETA (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_BETA (integer)`` Loop filter beta coefficient, defined in the H264 standard. This corresponds to the slice_beta_offset_div2 slice header field, and should be in the range of -6 to +6, inclusive. The actual beta offset @@ -1083,10 +1083,10 @@ enum v4l2_mpeg_video_h264_loop_filter_mode - .. _v4l2-mpeg-video-h264-entropy-mode: -``V4L2_CID_MPEG_VIDEO_H264_ENTROPY_MODE`` +``V4L2_CID_CODEC_VIDEO_H264_ENTROPY_MODE`` (enum) -enum v4l2_mpeg_video_h264_entropy_mode - +enum v4l2_codec_video_h264_entropy_mode - Entropy coding mode for H264 - CABAC/CAVALC. Applicable to the H264 encoder. Possible values are: @@ -1098,142 +1098,142 @@ enum v4l2_mpeg_video_h264_entropy_mode - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_H264_ENTROPY_MODE_CAVLC`` + * - ``V4L2_CODEC_VIDEO_H264_ENTROPY_MODE_CAVLC`` - Use CAVLC entropy coding. - * - ``V4L2_MPEG_VIDEO_H264_ENTROPY_MODE_CABAC`` + * - ``V4L2_CODEC_VIDEO_H264_ENTROPY_MODE_CABAC`` - Use CABAC entropy coding. -``V4L2_CID_MPEG_VIDEO_H264_8X8_TRANSFORM (boolean)`` +``V4L2_CID_CODEC_VIDEO_H264_8X8_TRANSFORM (boolean)`` Enable 8X8 transform for H264. Applicable to the H264 encoder. -``V4L2_CID_MPEG_VIDEO_H264_CONSTRAINED_INTRA_PREDICTION (boolean)`` +``V4L2_CID_CODEC_VIDEO_H264_CONSTRAINED_INTRA_PREDICTION (boolean)`` Enable constrained intra prediction for H264. Applicable to the H264 encoder. -``V4L2_CID_MPEG_VIDEO_H264_CHROMA_QP_INDEX_OFFSET (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_CHROMA_QP_INDEX_OFFSET (integer)`` Specify the offset that should be added to the luma quantization parameter to determine the chroma quantization parameter. Applicable to the H264 encoder. -``V4L2_CID_MPEG_VIDEO_CYCLIC_INTRA_REFRESH_MB (integer)`` +``V4L2_CID_CODEC_VIDEO_CYCLIC_INTRA_REFRESH_MB (integer)`` Cyclic intra macroblock refresh. This is the number of continuous macroblocks refreshed every frame. Each frame a successive set of macroblocks is refreshed until the cycle completes and starts from the top of the frame. Applicable to H264, H263 and MPEG4 encoder. -``V4L2_CID_MPEG_VIDEO_FRAME_RC_ENABLE (boolean)`` +``V4L2_CID_CODEC_VIDEO_FRAME_RC_ENABLE (boolean)`` Frame level rate control enable. If this control is disabled then the quantization parameter for each frame type is constant and set with appropriate controls (e.g. - ``V4L2_CID_MPEG_VIDEO_H263_I_FRAME_QP``). If frame rate control is + ``V4L2_CID_CODEC_VIDEO_H263_I_FRAME_QP``). If frame rate control is enabled then quantization parameter is adjusted to meet the chosen bitrate. Minimum and maximum value for the quantization parameter can be set with appropriate controls (e.g. - ``V4L2_CID_MPEG_VIDEO_H263_MIN_QP``). Applicable to encoders. + ``V4L2_CID_CODEC_VIDEO_H263_MIN_QP``). Applicable to encoders. -``V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE (boolean)`` +``V4L2_CID_CODEC_VIDEO_MB_RC_ENABLE (boolean)`` Macroblock level rate control enable. Applicable to the MPEG4 and H264 encoders. -``V4L2_CID_MPEG_VIDEO_MPEG4_QPEL (boolean)`` +``V4L2_CID_CODEC_VIDEO_MPEG4_QPEL (boolean)`` Quarter pixel motion estimation for MPEG4. Applicable to the MPEG4 encoder. -``V4L2_CID_MPEG_VIDEO_H263_I_FRAME_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_H263_I_FRAME_QP (integer)`` Quantization parameter for an I frame for H263. Valid range: from 1 to 31. -``V4L2_CID_MPEG_VIDEO_H263_MIN_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_H263_MIN_QP (integer)`` Minimum quantization parameter for H263. Valid range: from 1 to 31. -``V4L2_CID_MPEG_VIDEO_H263_MAX_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_H263_MAX_QP (integer)`` Maximum quantization parameter for H263. Valid range: from 1 to 31. -``V4L2_CID_MPEG_VIDEO_H263_P_FRAME_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_H263_P_FRAME_QP (integer)`` Quantization parameter for an P frame for H263. Valid range: from 1 to 31. -``V4L2_CID_MPEG_VIDEO_H263_B_FRAME_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_H263_B_FRAME_QP (integer)`` Quantization parameter for an B frame for H263. Valid range: from 1 to 31. -``V4L2_CID_MPEG_VIDEO_H264_I_FRAME_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_I_FRAME_QP (integer)`` Quantization parameter for an I frame for H264. Valid range: from 0 to 51. -``V4L2_CID_MPEG_VIDEO_H264_MIN_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_MIN_QP (integer)`` Minimum quantization parameter for H264. Valid range: from 0 to 51. -``V4L2_CID_MPEG_VIDEO_H264_MAX_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_MAX_QP (integer)`` Maximum quantization parameter for H264. Valid range: from 0 to 51. -``V4L2_CID_MPEG_VIDEO_H264_P_FRAME_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_P_FRAME_QP (integer)`` Quantization parameter for an P frame for H264. Valid range: from 0 to 51. -``V4L2_CID_MPEG_VIDEO_H264_B_FRAME_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_B_FRAME_QP (integer)`` Quantization parameter for an B frame for H264. Valid range: from 0 to 51. -``V4L2_CID_MPEG_VIDEO_H264_I_FRAME_MIN_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_I_FRAME_MIN_QP (integer)`` Minimum quantization parameter for the H264 I frame to limit I frame quality to a range. Valid range: from 0 to 51. If - V4L2_CID_MPEG_VIDEO_H264_MIN_QP is also set, the quantization parameter + V4L2_CID_CODEC_VIDEO_H264_MIN_QP is also set, the quantization parameter should be chosen to meet both requirements. -``V4L2_CID_MPEG_VIDEO_H264_I_FRAME_MAX_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_I_FRAME_MAX_QP (integer)`` Maximum quantization parameter for the H264 I frame to limit I frame quality to a range. Valid range: from 0 to 51. If - V4L2_CID_MPEG_VIDEO_H264_MAX_QP is also set, the quantization parameter + V4L2_CID_CODEC_VIDEO_H264_MAX_QP is also set, the quantization parameter should be chosen to meet both requirements. -``V4L2_CID_MPEG_VIDEO_H264_P_FRAME_MIN_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_P_FRAME_MIN_QP (integer)`` Minimum quantization parameter for the H264 P frame to limit P frame quality to a range. Valid range: from 0 to 51. If - V4L2_CID_MPEG_VIDEO_H264_MIN_QP is also set, the quantization parameter + V4L2_CID_CODEC_VIDEO_H264_MIN_QP is also set, the quantization parameter should be chosen to meet both requirements. -``V4L2_CID_MPEG_VIDEO_H264_P_FRAME_MAX_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_P_FRAME_MAX_QP (integer)`` Maximum quantization parameter for the H264 P frame to limit P frame quality to a range. Valid range: from 0 to 51. If - V4L2_CID_MPEG_VIDEO_H264_MAX_QP is also set, the quantization parameter + V4L2_CID_CODEC_VIDEO_H264_MAX_QP is also set, the quantization parameter should be chosen to meet both requirements. -``V4L2_CID_MPEG_VIDEO_H264_B_FRAME_MIN_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_B_FRAME_MIN_QP (integer)`` Minimum quantization parameter for the H264 B frame to limit B frame quality to a range. Valid range: from 0 to 51. If - V4L2_CID_MPEG_VIDEO_H264_MIN_QP is also set, the quantization parameter + V4L2_CID_CODEC_VIDEO_H264_MIN_QP is also set, the quantization parameter should be chosen to meet both requirements. -``V4L2_CID_MPEG_VIDEO_H264_B_FRAME_MAX_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_B_FRAME_MAX_QP (integer)`` Maximum quantization parameter for the H264 B frame to limit B frame quality to a range. Valid range: from 0 to 51. If - V4L2_CID_MPEG_VIDEO_H264_MAX_QP is also set, the quantization parameter + V4L2_CID_CODEC_VIDEO_H264_MAX_QP is also set, the quantization parameter should be chosen to meet both requirements. -``V4L2_CID_MPEG_VIDEO_MPEG4_I_FRAME_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_MPEG4_I_FRAME_QP (integer)`` Quantization parameter for an I frame for MPEG4. Valid range: from 1 to 31. -``V4L2_CID_MPEG_VIDEO_MPEG4_MIN_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_MPEG4_MIN_QP (integer)`` Minimum quantization parameter for MPEG4. Valid range: from 1 to 31. -``V4L2_CID_MPEG_VIDEO_MPEG4_MAX_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_MPEG4_MAX_QP (integer)`` Maximum quantization parameter for MPEG4. Valid range: from 1 to 31. -``V4L2_CID_MPEG_VIDEO_MPEG4_P_FRAME_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_MPEG4_P_FRAME_QP (integer)`` Quantization parameter for an P frame for MPEG4. Valid range: from 1 to 31. -``V4L2_CID_MPEG_VIDEO_MPEG4_B_FRAME_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_MPEG4_B_FRAME_QP (integer)`` Quantization parameter for an B frame for MPEG4. Valid range: from 1 to 31. .. _v4l2-mpeg-video-vbv-size: -``V4L2_CID_MPEG_VIDEO_VBV_SIZE (integer)`` +``V4L2_CID_CODEC_VIDEO_VBV_SIZE (integer)`` The Video Buffer Verifier size in kilobytes, it is used as a limitation of frame skip. The VBV is defined in the standard as a mean to verify that the produced stream will be successfully @@ -1245,12 +1245,12 @@ enum v4l2_mpeg_video_h264_entropy_mode - .. _v4l2-mpeg-video-vbv-delay: -``V4L2_CID_MPEG_VIDEO_VBV_DELAY (integer)`` +``V4L2_CID_CODEC_VIDEO_VBV_DELAY (integer)`` Sets the initial delay in milliseconds for VBV buffer control. .. _v4l2-mpeg-video-hor-search-range: -``V4L2_CID_MPEG_VIDEO_MV_H_SEARCH_RANGE (integer)`` +``V4L2_CID_CODEC_VIDEO_MV_H_SEARCH_RANGE (integer)`` Horizontal search range defines maximum horizontal search area in pixels to search and match for the present Macroblock (MB) in the reference picture. This V4L2 control macro is used to set horizontal @@ -1258,7 +1258,7 @@ enum v4l2_mpeg_video_h264_entropy_mode - .. _v4l2-mpeg-video-vert-search-range: -``V4L2_CID_MPEG_VIDEO_MV_V_SEARCH_RANGE (integer)`` +``V4L2_CID_CODEC_VIDEO_MV_V_SEARCH_RANGE (integer)`` Vertical search range defines maximum vertical search area in pixels to search and match for the present Macroblock (MB) in the reference picture. This V4L2 control macro is used to set vertical search @@ -1266,19 +1266,19 @@ enum v4l2_mpeg_video_h264_entropy_mode - .. _v4l2-mpeg-video-force-key-frame: -``V4L2_CID_MPEG_VIDEO_FORCE_KEY_FRAME (button)`` +``V4L2_CID_CODEC_VIDEO_FORCE_KEY_FRAME (button)`` Force a key frame for the next queued buffer. Applicable to encoders. This is a general, codec-agnostic keyframe control. .. _v4l2-mpeg-video-h264-cpb-size: -``V4L2_CID_MPEG_VIDEO_H264_CPB_SIZE (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_CPB_SIZE (integer)`` The Coded Picture Buffer size in kilobytes, it is used as a limitation of frame skip. The CPB is defined in the H264 standard as a mean to verify that the produced stream will be successfully decoded. Applicable to the H264 encoder. -``V4L2_CID_MPEG_VIDEO_H264_I_PERIOD (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_I_PERIOD (integer)`` Period between I-frames in the open GOP for H264. In case of an open GOP this is the period between two I-frames. The period between IDR (Instantaneous Decoding Refresh) frames is taken from the GOP_SIZE @@ -1290,10 +1290,10 @@ enum v4l2_mpeg_video_h264_entropy_mode - .. _v4l2-mpeg-video-header-mode: -``V4L2_CID_MPEG_VIDEO_HEADER_MODE`` +``V4L2_CID_CODEC_VIDEO_HEADER_MODE`` (enum) -enum v4l2_mpeg_video_header_mode - +enum v4l2_codec_video_header_mode - Determines whether the header is returned as the first buffer or is it returned together with the first frame. Applicable to encoders. Possible values are: @@ -1308,9 +1308,9 @@ enum v4l2_mpeg_video_header_mode - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_HEADER_MODE_SEPARATE`` + * - ``V4L2_CODEC_VIDEO_HEADER_MODE_SEPARATE`` - The stream header is returned separately in the first buffer. - * - ``V4L2_MPEG_VIDEO_HEADER_MODE_JOINED_WITH_1ST_FRAME`` + * - ``V4L2_CODEC_VIDEO_HEADER_MODE_JOINED_WITH_1ST_FRAME`` - The stream header is returned together with the first encoded frame. @@ -1319,39 +1319,39 @@ enum v4l2_mpeg_video_header_mode - \normalsize -``V4L2_CID_MPEG_VIDEO_REPEAT_SEQ_HEADER (boolean)`` +``V4L2_CID_CODEC_VIDEO_REPEAT_SEQ_HEADER (boolean)`` Repeat the video sequence headers. Repeating these headers makes random access to the video stream easier. Applicable to the MPEG1, 2 and 4 encoder. -``V4L2_CID_MPEG_VIDEO_DECODER_MPEG4_DEBLOCK_FILTER (boolean)`` +``V4L2_CID_CODEC_VIDEO_DECODER_MPEG4_DEBLOCK_FILTER (boolean)`` Enabled the deblocking post processing filter for MPEG4 decoder. Applicable to the MPEG4 decoder. -``V4L2_CID_MPEG_VIDEO_MPEG4_VOP_TIME_RES (integer)`` +``V4L2_CID_CODEC_VIDEO_MPEG4_VOP_TIME_RES (integer)`` vop_time_increment_resolution value for MPEG4. Applicable to the MPEG4 encoder. -``V4L2_CID_MPEG_VIDEO_MPEG4_VOP_TIME_INC (integer)`` +``V4L2_CID_CODEC_VIDEO_MPEG4_VOP_TIME_INC (integer)`` vop_time_increment value for MPEG4. Applicable to the MPEG4 encoder. -``V4L2_CID_MPEG_VIDEO_H264_SEI_FRAME_PACKING (boolean)`` +``V4L2_CID_CODEC_VIDEO_H264_SEI_FRAME_PACKING (boolean)`` Enable generation of frame packing supplemental enhancement information in the encoded bitstream. The frame packing SEI message contains the arrangement of L and R planes for 3D viewing. Applicable to the H264 encoder. -``V4L2_CID_MPEG_VIDEO_H264_SEI_FP_CURRENT_FRAME_0 (boolean)`` +``V4L2_CID_CODEC_VIDEO_H264_SEI_FP_CURRENT_FRAME_0 (boolean)`` Sets current frame as frame0 in frame packing SEI. Applicable to the H264 encoder. .. _v4l2-mpeg-video-h264-sei-fp-arrangement-type: -``V4L2_CID_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE`` +``V4L2_CID_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE`` (enum) -enum v4l2_mpeg_video_h264_sei_fp_arrangement_type - +enum v4l2_codec_video_h264_sei_fp_arrangement_type - Frame packing arrangement type for H264 SEI. Applicable to the H264 encoder. Possible values are: @@ -1365,17 +1365,17 @@ enum v4l2_mpeg_video_h264_sei_fp_arrangement_type - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_CHEKERBOARD`` + * - ``V4L2_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_CHEKERBOARD`` - Pixels are alternatively from L and R. - * - ``V4L2_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_COLUMN`` + * - ``V4L2_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_COLUMN`` - L and R are interlaced by column. - * - ``V4L2_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_ROW`` + * - ``V4L2_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_ROW`` - L and R are interlaced by row. - * - ``V4L2_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_SIDE_BY_SIDE`` + * - ``V4L2_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_SIDE_BY_SIDE`` - L is on the left, R on the right. - * - ``V4L2_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_TOP_BOTTOM`` + * - ``V4L2_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_TOP_BOTTOM`` - L is on top, R on bottom. - * - ``V4L2_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_TEMPORAL`` + * - ``V4L2_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_TEMPORAL`` - One view per frame. .. raw:: latex @@ -1384,17 +1384,17 @@ enum v4l2_mpeg_video_h264_sei_fp_arrangement_type - -``V4L2_CID_MPEG_VIDEO_H264_FMO (boolean)`` +``V4L2_CID_CODEC_VIDEO_H264_FMO (boolean)`` Enables flexible macroblock ordering in the encoded bitstream. It is a technique used for restructuring the ordering of macroblocks in pictures. Applicable to the H264 encoder. .. _v4l2-mpeg-video-h264-fmo-map-type: -``V4L2_CID_MPEG_VIDEO_H264_FMO_MAP_TYPE`` +``V4L2_CID_CODEC_VIDEO_H264_FMO_MAP_TYPE`` (enum) -enum v4l2_mpeg_video_h264_fmo_map_type - +enum v4l2_codec_video_h264_fmo_map_type - When using FMO, the map type divides the image in different scan patterns of macroblocks. Applicable to the H264 encoder. Possible values are: @@ -1409,21 +1409,21 @@ enum v4l2_mpeg_video_h264_fmo_map_type - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_INTERLEAVED_SLICES`` + * - ``V4L2_CODEC_VIDEO_H264_FMO_MAP_TYPE_INTERLEAVED_SLICES`` - Slices are interleaved one after other with macroblocks in run length order. - * - ``V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_SCATTERED_SLICES`` + * - ``V4L2_CODEC_VIDEO_H264_FMO_MAP_TYPE_SCATTERED_SLICES`` - Scatters the macroblocks based on a mathematical function known to both encoder and decoder. - * - ``V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_FOREGROUND_WITH_LEFT_OVER`` + * - ``V4L2_CODEC_VIDEO_H264_FMO_MAP_TYPE_FOREGROUND_WITH_LEFT_OVER`` - Macroblocks arranged in rectangular areas or regions of interest. - * - ``V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_BOX_OUT`` + * - ``V4L2_CODEC_VIDEO_H264_FMO_MAP_TYPE_BOX_OUT`` - Slice groups grow in a cyclic way from centre to outwards. - * - ``V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_RASTER_SCAN`` + * - ``V4L2_CODEC_VIDEO_H264_FMO_MAP_TYPE_RASTER_SCAN`` - Slice groups grow in raster scan pattern from left to right. - * - ``V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_WIPE_SCAN`` + * - ``V4L2_CODEC_VIDEO_H264_FMO_MAP_TYPE_WIPE_SCAN`` - Slice groups grow in wipe scan pattern from top to bottom. - * - ``V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_EXPLICIT`` + * - ``V4L2_CODEC_VIDEO_H264_FMO_MAP_TYPE_EXPLICIT`` - User defined map type. .. raw:: latex @@ -1432,15 +1432,15 @@ enum v4l2_mpeg_video_h264_fmo_map_type - -``V4L2_CID_MPEG_VIDEO_H264_FMO_SLICE_GROUP (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_FMO_SLICE_GROUP (integer)`` Number of slice groups in FMO. Applicable to the H264 encoder. .. _v4l2-mpeg-video-h264-fmo-change-direction: -``V4L2_CID_MPEG_VIDEO_H264_FMO_CHANGE_DIRECTION`` +``V4L2_CID_CODEC_VIDEO_H264_FMO_CHANGE_DIRECTION`` (enum) -enum v4l2_mpeg_video_h264_fmo_change_dir - +enum v4l2_codec_video_h264_fmo_change_dir - Specifies a direction of the slice group change for raster and wipe maps. Applicable to the H264 encoder. Possible values are: @@ -1450,26 +1450,26 @@ enum v4l2_mpeg_video_h264_fmo_change_dir - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_H264_FMO_CHANGE_DIR_RIGHT`` + * - ``V4L2_CODEC_VIDEO_H264_FMO_CHANGE_DIR_RIGHT`` - Raster scan or wipe right. - * - ``V4L2_MPEG_VIDEO_H264_FMO_CHANGE_DIR_LEFT`` + * - ``V4L2_CODEC_VIDEO_H264_FMO_CHANGE_DIR_LEFT`` - Reverse raster scan or wipe left. -``V4L2_CID_MPEG_VIDEO_H264_FMO_CHANGE_RATE (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_FMO_CHANGE_RATE (integer)`` Specifies the size of the first slice group for raster and wipe map. Applicable to the H264 encoder. -``V4L2_CID_MPEG_VIDEO_H264_FMO_RUN_LENGTH (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_FMO_RUN_LENGTH (integer)`` Specifies the number of consecutive macroblocks for the interleaved map. Applicable to the H264 encoder. -``V4L2_CID_MPEG_VIDEO_H264_ASO (boolean)`` +``V4L2_CID_CODEC_VIDEO_H264_ASO (boolean)`` Enables arbitrary slice ordering in encoded bitstream. Applicable to the H264 encoder. -``V4L2_CID_MPEG_VIDEO_H264_ASO_SLICE_ORDER (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_ASO_SLICE_ORDER (integer)`` Specifies the slice order in ASO. Applicable to the H264 encoder. The supplied 32-bit integer is interpreted as follows (bit 0 = least significant bit): @@ -1487,15 +1487,15 @@ enum v4l2_mpeg_video_h264_fmo_change_dir - -``V4L2_CID_MPEG_VIDEO_H264_HIERARCHICAL_CODING (boolean)`` +``V4L2_CID_CODEC_VIDEO_H264_HIERARCHICAL_CODING (boolean)`` Enables H264 hierarchical coding. Applicable to the H264 encoder. .. _v4l2-mpeg-video-h264-hierarchical-coding-type: -``V4L2_CID_MPEG_VIDEO_H264_HIERARCHICAL_CODING_TYPE`` +``V4L2_CID_CODEC_VIDEO_H264_HIERARCHICAL_CODING_TYPE`` (enum) -enum v4l2_mpeg_video_h264_hierarchical_coding_type - +enum v4l2_codec_video_h264_hierarchical_coding_type - Specifies the hierarchical coding type. Applicable to the H264 encoder. Possible values are: @@ -1505,18 +1505,18 @@ enum v4l2_mpeg_video_h264_hierarchical_coding_type - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_H264_HIERARCHICAL_CODING_B`` + * - ``V4L2_CODEC_VIDEO_H264_HIERARCHICAL_CODING_B`` - Hierarchical B coding. - * - ``V4L2_MPEG_VIDEO_H264_HIERARCHICAL_CODING_P`` + * - ``V4L2_CODEC_VIDEO_H264_HIERARCHICAL_CODING_P`` - Hierarchical P coding. -``V4L2_CID_MPEG_VIDEO_H264_HIERARCHICAL_CODING_LAYER (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_HIERARCHICAL_CODING_LAYER (integer)`` Specifies the number of hierarchical coding layers. Applicable to the H264 encoder. -``V4L2_CID_MPEG_VIDEO_H264_HIERARCHICAL_CODING_LAYER_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_HIERARCHICAL_CODING_LAYER_QP (integer)`` Specifies a user defined QP for each layer. Applicable to the H264 encoder. The supplied 32-bit integer is interpreted as follows (bit 0 = least significant bit): @@ -1532,30 +1532,30 @@ enum v4l2_mpeg_video_h264_hierarchical_coding_type - * - Bit 16:32 - Layer number -``V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L0_BR (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L0_BR (integer)`` Indicates bit rate (bps) for hierarchical coding layer 0 for H264 encoder. -``V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L1_BR (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L1_BR (integer)`` Indicates bit rate (bps) for hierarchical coding layer 1 for H264 encoder. -``V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L2_BR (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L2_BR (integer)`` Indicates bit rate (bps) for hierarchical coding layer 2 for H264 encoder. -``V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L3_BR (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L3_BR (integer)`` Indicates bit rate (bps) for hierarchical coding layer 3 for H264 encoder. -``V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L4_BR (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L4_BR (integer)`` Indicates bit rate (bps) for hierarchical coding layer 4 for H264 encoder. -``V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L5_BR (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L5_BR (integer)`` Indicates bit rate (bps) for hierarchical coding layer 5 for H264 encoder. -``V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L6_BR (integer)`` +``V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L6_BR (integer)`` Indicates bit rate (bps) for hierarchical coding layer 6 for H264 encoder. .. _v4l2-mpeg-mpeg2: -``V4L2_CID_MPEG_VIDEO_MPEG2_SLICE_PARAMS (struct)`` +``V4L2_CID_CODEC_VIDEO_MPEG2_SLICE_PARAMS (struct)`` Specifies the slice parameters (as extracted from the bitstream) for the associated MPEG-2 slice data. This includes the necessary parameters for configuring a stateless hardware decoding pipeline for MPEG-2. @@ -1702,7 +1702,7 @@ enum v4l2_mpeg_video_h264_hierarchical_coding_type - \normalsize -``V4L2_CID_MPEG_VIDEO_MPEG2_QUANTIZATION (struct)`` +``V4L2_CID_CODEC_VIDEO_MPEG2_QUANTIZATION (struct)`` Specifies quantization matrices (as extracted from the bitstream) for the associated MPEG-2 slice data. @@ -1780,7 +1780,7 @@ enum v4l2_mpeg_video_h264_hierarchical_coding_type - .. _v4l2-mpeg-vp8: -``V4L2_CID_MPEG_VIDEO_VP8_FRAME_HEADER (struct)`` +``V4L2_CID_CODEC_VIDEO_VP8_FRAME_HEADER (struct)`` Specifies the frame parameters for the associated VP8 parsed frame data. This includes the necessary parameters for configuring a stateless hardware decoding pipeline for VP8. @@ -2135,30 +2135,30 @@ in the S5P family of SoCs by Samsung. MFC 5.1 Control IDs ------------------- -``V4L2_CID_MPEG_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY_ENABLE (boolean)`` +``V4L2_CID_CODEC_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY_ENABLE (boolean)`` If the display delay is enabled then the decoder is forced to return a CAPTURE buffer (decoded frame) after processing a certain number of OUTPUT buffers. The delay can be set through - ``V4L2_CID_MPEG_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY``. This + ``V4L2_CID_CODEC_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY``. This feature can be used for example for generating thumbnails of videos. Applicable to the H264 decoder. -``V4L2_CID_MPEG_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY (integer)`` +``V4L2_CID_CODEC_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY (integer)`` Display delay value for H264 decoder. The decoder is forced to return a decoded frame after the set 'display delay' number of frames. If this number is low it may result in frames returned out of display order, in addition the hardware may still be using the returned buffer as a reference picture for subsequent frames. -``V4L2_CID_MPEG_MFC51_VIDEO_H264_NUM_REF_PIC_FOR_P (integer)`` +``V4L2_CID_CODEC_MFC51_VIDEO_H264_NUM_REF_PIC_FOR_P (integer)`` The number of reference pictures used for encoding a P picture. Applicable to the H264 encoder. -``V4L2_CID_MPEG_MFC51_VIDEO_PADDING (boolean)`` +``V4L2_CID_CODEC_MFC51_VIDEO_PADDING (boolean)`` Padding enable in the encoder - use a color instead of repeating border pixels. Applicable to encoders. -``V4L2_CID_MPEG_MFC51_VIDEO_PADDING_YUV (integer)`` +``V4L2_CID_CODEC_MFC51_VIDEO_PADDING_YUV (integer)`` Padding color in the encoder. Applicable to encoders. The supplied 32-bit integer is interpreted as follows (bit 0 = least significant bit): @@ -2180,7 +2180,7 @@ MFC 5.1 Control IDs -``V4L2_CID_MPEG_MFC51_VIDEO_RC_REACTION_COEFF (integer)`` +``V4L2_CID_CODEC_MFC51_VIDEO_RC_REACTION_COEFF (integer)`` Reaction coefficient for MFC rate control. Applicable to encoders. .. note:: @@ -2193,41 +2193,41 @@ MFC 5.1 Control IDs #. It is not recommended to use the greater number than FRAME_RATE * (10^9 / BIT_RATE). -``V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_DARK (boolean)`` +``V4L2_CID_CODEC_MFC51_VIDEO_H264_ADAPTIVE_RC_DARK (boolean)`` Adaptive rate control for dark region. Valid only when H.264 and macroblock level RC is enabled - (``V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE``). Applicable to the H264 + (``V4L2_CID_CODEC_VIDEO_MB_RC_ENABLE``). Applicable to the H264 encoder. -``V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_SMOOTH (boolean)`` +``V4L2_CID_CODEC_MFC51_VIDEO_H264_ADAPTIVE_RC_SMOOTH (boolean)`` Adaptive rate control for smooth region. Valid only when H.264 and macroblock level RC is enabled - (``V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE``). Applicable to the H264 + (``V4L2_CID_CODEC_VIDEO_MB_RC_ENABLE``). Applicable to the H264 encoder. -``V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_STATIC (boolean)`` +``V4L2_CID_CODEC_MFC51_VIDEO_H264_ADAPTIVE_RC_STATIC (boolean)`` Adaptive rate control for static region. Valid only when H.264 and macroblock level RC is enabled - (``V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE``). Applicable to the H264 + (``V4L2_CID_CODEC_VIDEO_MB_RC_ENABLE``). Applicable to the H264 encoder. -``V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_ACTIVITY (boolean)`` +``V4L2_CID_CODEC_MFC51_VIDEO_H264_ADAPTIVE_RC_ACTIVITY (boolean)`` Adaptive rate control for activity region. Valid only when H.264 and macroblock level RC is enabled - (``V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE``). Applicable to the H264 + (``V4L2_CID_CODEC_VIDEO_MB_RC_ENABLE``). Applicable to the H264 encoder. .. _v4l2-mpeg-mfc51-video-frame-skip-mode: -``V4L2_CID_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE`` +``V4L2_CID_CODEC_MFC51_VIDEO_FRAME_SKIP_MODE`` (enum) .. note:: This control is deprecated. Use the standard - ``V4L2_CID_MPEG_VIDEO_FRAME_SKIP_MODE`` control instead. + ``V4L2_CID_CODEC_VIDEO_FRAME_SKIP_MODE`` control instead. -enum v4l2_mpeg_mfc51_video_frame_skip_mode - +enum v4l2_codec_mfc51_video_frame_skip_mode - Indicates in what conditions the encoder should skip frames. If encoding a frame would cause the encoded stream to be larger then a chosen data limit then the frame will be skipped. Possible values @@ -2244,12 +2244,12 @@ enum v4l2_mpeg_mfc51_video_frame_skip_mode - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_DISABLED`` + * - ``V4L2_CODEC_MFC51_VIDEO_FRAME_SKIP_MODE_DISABLED`` - Frame skip mode is disabled. - * - ``V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_LEVEL_LIMIT`` + * - ``V4L2_CODEC_MFC51_VIDEO_FRAME_SKIP_MODE_LEVEL_LIMIT`` - Frame skip mode enabled and buffer limit is set by the chosen level and is defined by the standard. - * - ``V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT`` + * - ``V4L2_CODEC_MFC51_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT`` - Frame skip mode enabled and buffer limit is set by the VBV (MPEG1/2/4) or CPB (H264) buffer size control. @@ -2257,7 +2257,7 @@ enum v4l2_mpeg_mfc51_video_frame_skip_mode - \normalsize -``V4L2_CID_MPEG_MFC51_VIDEO_RC_FIXED_TARGET_BIT (integer)`` +``V4L2_CID_CODEC_MFC51_VIDEO_RC_FIXED_TARGET_BIT (integer)`` Enable rate-control with fixed target bit. If this setting is enabled, then the rate control logic of the encoder will calculate the average bitrate for a GOP and keep it below or equal the set @@ -2271,10 +2271,10 @@ enum v4l2_mpeg_mfc51_video_frame_skip_mode - .. _v4l2-mpeg-mfc51-video-force-frame-type: -``V4L2_CID_MPEG_MFC51_VIDEO_FORCE_FRAME_TYPE`` +``V4L2_CID_CODEC_MFC51_VIDEO_FORCE_FRAME_TYPE`` (enum) -enum v4l2_mpeg_mfc51_video_force_frame_type - +enum v4l2_codec_mfc51_video_force_frame_type - Force a frame type for the next queued buffer. Applicable to encoders. Possible values are: @@ -2284,11 +2284,11 @@ enum v4l2_mpeg_mfc51_video_force_frame_type - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_MFC51_FORCE_FRAME_TYPE_DISABLED`` + * - ``V4L2_CODEC_MFC51_VIDEO_FORCE_FRAME_TYPE_DISABLED`` - Forcing a specific frame type disabled. - * - ``V4L2_MPEG_MFC51_FORCE_FRAME_TYPE_I_FRAME`` + * - ``V4L2_CODEC_MFC51_VIDEO_FORCE_FRAME_TYPE_I_FRAME`` - Force an I-frame. - * - ``V4L2_MPEG_MFC51_FORCE_FRAME_TYPE_NOT_CODED`` + * - ``V4L2_CODEC_MFC51_VIDEO_FORCE_FRAME_TYPE_NOT_CODED`` - Force a non-coded frame. @@ -2306,10 +2306,10 @@ CX2341x Control IDs .. _v4l2-mpeg-cx2341x-video-spatial-filter-mode: -``V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE`` +``V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE`` (enum) -enum v4l2_mpeg_cx2341x_video_spatial_filter_mode - +enum v4l2_codec_cx2341x_video_spatial_filter_mode - Sets the Spatial Filter mode (default ``MANUAL``). Possible values are: @@ -2320,23 +2320,23 @@ enum v4l2_mpeg_cx2341x_video_spatial_filter_mode - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE_MANUAL`` + * - ``V4L2_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE_MANUAL`` - Choose the filter manually - * - ``V4L2_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE_AUTO`` + * - ``V4L2_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE_AUTO`` - Choose the filter automatically -``V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER (integer (0-15))`` +``V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER (integer (0-15))`` The setting for the Spatial Filter. 0 = off, 15 = maximum. (Default is 0.) .. _luma-spatial-filter-type: -``V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE`` +``V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE`` (enum) -enum v4l2_mpeg_cx2341x_video_luma_spatial_filter_type - +enum v4l2_codec_cx2341x_video_luma_spatial_filter_type - Select the algorithm to use for the Luma Spatial Filter (default ``1D_HOR``). Possible values: @@ -2350,15 +2350,15 @@ enum v4l2_mpeg_cx2341x_video_luma_spatial_filter_type - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_OFF`` + * - ``V4L2_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_OFF`` - No filter - * - ``V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_1D_HOR`` + * - ``V4L2_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_1D_HOR`` - One-dimensional horizontal - * - ``V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_1D_VERT`` + * - ``V4L2_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_1D_VERT`` - One-dimensional vertical - * - ``V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_2D_HV_SEPARABLE`` + * - ``V4L2_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_2D_HV_SEPARABLE`` - Two-dimensional separable - * - ``V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_2D_SYM_NON_SEPARABLE`` + * - ``V4L2_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_2D_SYM_NON_SEPARABLE`` - Two-dimensional symmetrical non-separable .. raw:: latex @@ -2367,10 +2367,10 @@ enum v4l2_mpeg_cx2341x_video_luma_spatial_filter_type - .. _chroma-spatial-filter-type: -``V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE`` +``V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE`` (enum) -enum v4l2_mpeg_cx2341x_video_chroma_spatial_filter_type - +enum v4l2_codec_cx2341x_video_chroma_spatial_filter_type - Select the algorithm for the Chroma Spatial Filter (default ``1D_HOR``). Possible values are: @@ -2384,9 +2384,9 @@ enum v4l2_mpeg_cx2341x_video_chroma_spatial_filter_type - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_OFF`` + * - ``V4L2_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_OFF`` - No filter - * - ``V4L2_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_1D_HOR`` + * - ``V4L2_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_1D_HOR`` - One-dimensional horizontal .. raw:: latex @@ -2395,10 +2395,10 @@ enum v4l2_mpeg_cx2341x_video_chroma_spatial_filter_type - .. _v4l2-mpeg-cx2341x-video-temporal-filter-mode: -``V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE`` +``V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE`` (enum) -enum v4l2_mpeg_cx2341x_video_temporal_filter_mode - +enum v4l2_codec_cx2341x_video_temporal_filter_mode - Sets the Temporal Filter mode (default ``MANUAL``). Possible values are: @@ -2410,25 +2410,25 @@ enum v4l2_mpeg_cx2341x_video_temporal_filter_mode - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_MANUAL`` + * - ``V4L2_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_MANUAL`` - Choose the filter manually - * - ``V4L2_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_AUTO`` + * - ``V4L2_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_AUTO`` - Choose the filter automatically .. raw:: latex \normalsize -``V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER (integer (0-31))`` +``V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER (integer (0-31))`` The setting for the Temporal Filter. 0 = off, 31 = maximum. (Default is 8 for full-scale capturing and 0 for scaled capturing.) .. _v4l2-mpeg-cx2341x-video-median-filter-type: -``V4L2_CID_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE`` +``V4L2_CID_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE`` (enum) -enum v4l2_mpeg_cx2341x_video_median_filter_type - +enum v4l2_codec_cx2341x_video_median_filter_type - Median Filter Type (default ``OFF``). Possible values are: @@ -2442,38 +2442,38 @@ enum v4l2_mpeg_cx2341x_video_median_filter_type - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF`` + * - ``V4L2_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF`` - No filter - * - ``V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_HOR`` + * - ``V4L2_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_HOR`` - Horizontal filter - * - ``V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_VERT`` + * - ``V4L2_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_VERT`` - Vertical filter - * - ``V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_HOR_VERT`` + * - ``V4L2_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_HOR_VERT`` - Horizontal and vertical filter - * - ``V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_DIAG`` + * - ``V4L2_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_DIAG`` - Diagonal filter .. raw:: latex \normalsize -``V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM (integer (0-255))`` +``V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM (integer (0-255))`` Threshold above which the luminance median filter is enabled (default 0) -``V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP (integer (0-255))`` +``V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP (integer (0-255))`` Threshold below which the luminance median filter is enabled (default 255) -``V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM (integer (0-255))`` +``V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM (integer (0-255))`` Threshold above which the chroma median filter is enabled (default 0) -``V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP (integer (0-255))`` +``V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP (integer (0-255))`` Threshold below which the chroma median filter is enabled (default 255) -``V4L2_CID_MPEG_CX2341X_STREAM_INSERT_NAV_PACKETS (boolean)`` +``V4L2_CID_CODEC_CX2341X_STREAM_INSERT_NAV_PACKETS (boolean)`` The CX2341X MPEG encoder can insert one empty MPEG-2 PES packet into the stream between every four video frames. The packet size is 2048 bytes, including the packet_start_code_prefix and stream_id @@ -2496,7 +2496,7 @@ VPX Control IDs .. _v4l2-vpx-num-partitions: -``V4L2_CID_MPEG_VIDEO_VPX_NUM_PARTITIONS`` +``V4L2_CID_CODEC_VIDEO_VPX_NUM_PARTITIONS`` (enum) enum v4l2_vp8_num_partitions - @@ -2509,23 +2509,23 @@ enum v4l2_vp8_num_partitions - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_CID_MPEG_VIDEO_VPX_1_PARTITION`` + * - ``V4L2_CID_CODEC_VIDEO_VPX_1_PARTITION`` - 1 coefficient partition - * - ``V4L2_CID_MPEG_VIDEO_VPX_2_PARTITIONS`` + * - ``V4L2_CID_CODEC_VIDEO_VPX_2_PARTITIONS`` - 2 coefficient partitions - * - ``V4L2_CID_MPEG_VIDEO_VPX_4_PARTITIONS`` + * - ``V4L2_CID_CODEC_VIDEO_VPX_4_PARTITIONS`` - 4 coefficient partitions - * - ``V4L2_CID_MPEG_VIDEO_VPX_8_PARTITIONS`` + * - ``V4L2_CID_CODEC_VIDEO_VPX_8_PARTITIONS`` - 8 coefficient partitions -``V4L2_CID_MPEG_VIDEO_VPX_IMD_DISABLE_4X4 (boolean)`` +``V4L2_CID_CODEC_VIDEO_VPX_IMD_DISABLE_4X4 (boolean)`` Setting this prevents intra 4x4 mode in the intra mode decision. .. _v4l2-vpx-num-ref-frames: -``V4L2_CID_MPEG_VIDEO_VPX_NUM_REF_FRAMES`` +``V4L2_CID_CODEC_VIDEO_VPX_NUM_REF_FRAMES`` (enum) enum v4l2_vp8_num_ref_frames - @@ -2542,13 +2542,13 @@ enum v4l2_vp8_num_ref_frames - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_CID_MPEG_VIDEO_VPX_1_REF_FRAME`` + * - ``V4L2_CID_CODEC_VIDEO_VPX_1_REF_FRAME`` - Last encoded frame will be searched - * - ``V4L2_CID_MPEG_VIDEO_VPX_2_REF_FRAME`` + * - ``V4L2_CID_CODEC_VIDEO_VPX_2_REF_FRAME`` - Two frames will be searched among the last encoded frame, the golden frame and the alternate reference (altref) frame. The encoder implementation will decide which two are chosen. - * - ``V4L2_CID_MPEG_VIDEO_VPX_3_REF_FRAME`` + * - ``V4L2_CID_CODEC_VIDEO_VPX_3_REF_FRAME`` - The last encoded frame, the golden frame and the altref frame will be searched. @@ -2558,16 +2558,16 @@ enum v4l2_vp8_num_ref_frames - -``V4L2_CID_MPEG_VIDEO_VPX_FILTER_LEVEL (integer)`` +``V4L2_CID_CODEC_VIDEO_VPX_FILTER_LEVEL (integer)`` Indicates the loop filter level. The adjustment of the loop filter level is done via a delta value against a baseline loop filter value. -``V4L2_CID_MPEG_VIDEO_VPX_FILTER_SHARPNESS (integer)`` +``V4L2_CID_CODEC_VIDEO_VPX_FILTER_SHARPNESS (integer)`` This parameter affects the loop filter. Anything above zero weakens the deblocking effect on the loop filter. -``V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_REF_PERIOD (integer)`` +``V4L2_CID_CODEC_VIDEO_VPX_GOLDEN_FRAME_REF_PERIOD (integer)`` Sets the refresh period for the golden frame. The period is defined in number of frames. For a value of 'n', every nth frame starting from the first key frame will be taken as a golden frame. For eg. @@ -2577,7 +2577,7 @@ enum v4l2_vp8_num_ref_frames - .. _v4l2-vpx-golden-frame-sel: -``V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_SEL`` +``V4L2_CID_CODEC_VIDEO_VPX_GOLDEN_FRAME_SEL`` (enum) enum v4l2_vp8_golden_frame_sel - @@ -2593,12 +2593,12 @@ enum v4l2_vp8_golden_frame_sel - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_USE_PREV`` + * - ``V4L2_CID_CODEC_VIDEO_VPX_GOLDEN_FRAME_USE_PREV`` - Use the (n-2)th frame as a golden frame, current frame index being 'n'. - * - ``V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_USE_REF_PERIOD`` + * - ``V4L2_CID_CODEC_VIDEO_VPX_GOLDEN_FRAME_USE_REF_PERIOD`` - Use the previous specific frame indicated by - ``V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_REF_PERIOD`` as a + ``V4L2_CID_CODEC_VIDEO_VPX_GOLDEN_FRAME_REF_PERIOD`` as a golden frame. .. raw:: latex @@ -2606,24 +2606,24 @@ enum v4l2_vp8_golden_frame_sel - \normalsize -``V4L2_CID_MPEG_VIDEO_VPX_MIN_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_VPX_MIN_QP (integer)`` Minimum quantization parameter for VP8. -``V4L2_CID_MPEG_VIDEO_VPX_MAX_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_VPX_MAX_QP (integer)`` Maximum quantization parameter for VP8. -``V4L2_CID_MPEG_VIDEO_VPX_I_FRAME_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_VPX_I_FRAME_QP (integer)`` Quantization parameter for an I frame for VP8. -``V4L2_CID_MPEG_VIDEO_VPX_P_FRAME_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_VPX_P_FRAME_QP (integer)`` Quantization parameter for a P frame for VP8. .. _v4l2-mpeg-video-vp8-profile: -``V4L2_CID_MPEG_VIDEO_VP8_PROFILE`` +``V4L2_CID_CODEC_VIDEO_VP8_PROFILE`` (enum) -enum v4l2_mpeg_video_vp8_profile - +enum v4l2_codec_video_vp8_profile - This control allows selecting the profile for VP8 encoder. This is also used to enumerate supported profiles by VP8 encoder or decoder. Possible values are: @@ -2632,21 +2632,21 @@ enum v4l2_mpeg_video_vp8_profile - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_VP8_PROFILE_0`` + * - ``V4L2_CODEC_VIDEO_VP8_PROFILE_0`` - Profile 0 - * - ``V4L2_MPEG_VIDEO_VP8_PROFILE_1`` + * - ``V4L2_CODEC_VIDEO_VP8_PROFILE_1`` - Profile 1 - * - ``V4L2_MPEG_VIDEO_VP8_PROFILE_2`` + * - ``V4L2_CODEC_VIDEO_VP8_PROFILE_2`` - Profile 2 - * - ``V4L2_MPEG_VIDEO_VP8_PROFILE_3`` + * - ``V4L2_CODEC_VIDEO_VP8_PROFILE_3`` - Profile 3 .. _v4l2-mpeg-video-vp9-profile: -``V4L2_CID_MPEG_VIDEO_VP9_PROFILE`` +``V4L2_CID_CODEC_VIDEO_VP9_PROFILE`` (enum) -enum v4l2_mpeg_video_vp9_profile - +enum v4l2_codec_video_vp9_profile - This control allows selecting the profile for VP9 encoder. This is also used to enumerate supported profiles by VP9 encoder or decoder. Possible values are: @@ -2655,20 +2655,20 @@ enum v4l2_mpeg_video_vp9_profile - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_VP9_PROFILE_0`` + * - ``V4L2_CODEC_VIDEO_VP9_PROFILE_0`` - Profile 0 - * - ``V4L2_MPEG_VIDEO_VP9_PROFILE_1`` + * - ``V4L2_CODEC_VIDEO_VP9_PROFILE_1`` - Profile 1 - * - ``V4L2_MPEG_VIDEO_VP9_PROFILE_2`` + * - ``V4L2_CODEC_VIDEO_VP9_PROFILE_2`` - Profile 2 - * - ``V4L2_MPEG_VIDEO_VP9_PROFILE_3`` + * - ``V4L2_CODEC_VIDEO_VP9_PROFILE_3`` - Profile 3 .. _v4l2-mpeg-video-vp9-level: -``V4L2_CID_MPEG_VIDEO_VP9_LEVEL (enum)`` +``V4L2_CID_CODEC_VIDEO_VP9_LEVEL (enum)`` -enum v4l2_mpeg_video_vp9_level - +enum v4l2_codec_video_vp9_level - This control allows selecting the level for VP9 encoder. This is also used to enumerate supported levels by VP9 encoder or decoder. More information can be found at @@ -2678,33 +2678,33 @@ enum v4l2_mpeg_video_vp9_level - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_1_0`` + * - ``V4L2_CODEC_VIDEO_VP9_LEVEL_1_0`` - Level 1 - * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_1_1`` + * - ``V4L2_CODEC_VIDEO_VP9_LEVEL_1_1`` - Level 1.1 - * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_2_0`` + * - ``V4L2_CODEC_VIDEO_VP9_LEVEL_2_0`` - Level 2 - * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_2_1`` + * - ``V4L2_CODEC_VIDEO_VP9_LEVEL_2_1`` - Level 2.1 - * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_3_0`` + * - ``V4L2_CODEC_VIDEO_VP9_LEVEL_3_0`` - Level 3 - * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_3_1`` + * - ``V4L2_CODEC_VIDEO_VP9_LEVEL_3_1`` - Level 3.1 - * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_4_0`` + * - ``V4L2_CODEC_VIDEO_VP9_LEVEL_4_0`` - Level 4 - * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_4_1`` + * - ``V4L2_CODEC_VIDEO_VP9_LEVEL_4_1`` - Level 4.1 - * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_5_0`` + * - ``V4L2_CODEC_VIDEO_VP9_LEVEL_5_0`` - Level 5 - * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_5_1`` + * - ``V4L2_CODEC_VIDEO_VP9_LEVEL_5_1`` - Level 5.1 - * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_5_2`` + * - ``V4L2_CODEC_VIDEO_VP9_LEVEL_5_2`` - Level 5.2 - * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_6_0`` + * - ``V4L2_CODEC_VIDEO_VP9_LEVEL_6_0`` - Level 6 - * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_6_1`` + * - ``V4L2_CODEC_VIDEO_VP9_LEVEL_6_1`` - Level 6.1 - * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_6_2`` + * - ``V4L2_CODEC_VIDEO_VP9_LEVEL_6_2`` - Level 6.2 @@ -2720,66 +2720,66 @@ video codec. HEVC/H.265 Control IDs ---------------------- -``V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_MIN_QP (integer)`` Minimum quantization parameter for HEVC. Valid range: from 0 to 51 for 8 bit and from 0 to 63 for 10 bit. -``V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_MAX_QP (integer)`` Maximum quantization parameter for HEVC. Valid range: from 0 to 51 for 8 bit and from 0 to 63 for 10 bit. -``V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_I_FRAME_QP (integer)`` Quantization parameter for an I frame for HEVC. - Valid range: [V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP, - V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP]. + Valid range: [V4L2_CID_CODEC_VIDEO_HEVC_MIN_QP, + V4L2_CID_CODEC_VIDEO_HEVC_MAX_QP]. -``V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_P_FRAME_QP (integer)`` Quantization parameter for a P frame for HEVC. - Valid range: [V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP, - V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP]. + Valid range: [V4L2_CID_CODEC_VIDEO_HEVC_MIN_QP, + V4L2_CID_CODEC_VIDEO_HEVC_MAX_QP]. -``V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_B_FRAME_QP (integer)`` Quantization parameter for a B frame for HEVC. - Valid range: [V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP, - V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP]. + Valid range: [V4L2_CID_CODEC_VIDEO_HEVC_MIN_QP, + V4L2_CID_CODEC_VIDEO_HEVC_MAX_QP]. -``V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_MIN_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_I_FRAME_MIN_QP (integer)`` Minimum quantization parameter for the HEVC I frame to limit I frame quality to a range. Valid range: from 0 to 51 for 8 bit and from 0 to 63 for 10 bit. - If V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP is also set, the quantization parameter + If V4L2_CID_CODEC_VIDEO_HEVC_MIN_QP is also set, the quantization parameter should be chosen to meet both requirements. -``V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_MAX_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_I_FRAME_MAX_QP (integer)`` Maximum quantization parameter for the HEVC I frame to limit I frame quality to a range. Valid range: from 0 to 51 for 8 bit and from 0 to 63 for 10 bit. - If V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP is also set, the quantization parameter + If V4L2_CID_CODEC_VIDEO_HEVC_MAX_QP is also set, the quantization parameter should be chosen to meet both requirements. -``V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_MIN_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_P_FRAME_MIN_QP (integer)`` Minimum quantization parameter for the HEVC P frame to limit P frame quality to a range. Valid range: from 0 to 51 for 8 bit and from 0 to 63 for 10 bit. - If V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP is also set, the quantization parameter + If V4L2_CID_CODEC_VIDEO_HEVC_MIN_QP is also set, the quantization parameter should be chosen to meet both requirements. -``V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_MAX_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_P_FRAME_MAX_QP (integer)`` Maximum quantization parameter for the HEVC P frame to limit P frame quality to a range. Valid range: from 0 to 51 for 8 bit and from 0 to 63 for 10 bit. - If V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP is also set, the quantization parameter + If V4L2_CID_CODEC_VIDEO_HEVC_MAX_QP is also set, the quantization parameter should be chosen to meet both requirements. -``V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_MIN_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_B_FRAME_MIN_QP (integer)`` Minimum quantization parameter for the HEVC B frame to limit B frame quality to a range. Valid range: from 0 to 51 for 8 bit and from 0 to 63 for 10 bit. - If V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP is also set, the quantization parameter + If V4L2_CID_CODEC_VIDEO_HEVC_MIN_QP is also set, the quantization parameter should be chosen to meet both requirements. -``V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_MAX_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_B_FRAME_MAX_QP (integer)`` Maximum quantization parameter for the HEVC B frame to limit B frame quality to a range. Valid range: from 0 to 51 for 8 bit and from 0 to 63 for 10 bit. - If V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP is also set, the quantization parameter + If V4L2_CID_CODEC_VIDEO_HEVC_MAX_QP is also set, the quantization parameter should be chosen to meet both requirements. -``V4L2_CID_MPEG_VIDEO_HEVC_HIER_QP (boolean)`` +``V4L2_CID_CODEC_VIDEO_HEVC_HIER_QP (boolean)`` HIERARCHICAL_QP allows the host to specify the quantization parameter values for each temporal layer through HIERARCHICAL_QP_LAYER. This is valid only if HIERARCHICAL_CODING_LAYER is greater than 1. Setting the @@ -2787,10 +2787,10 @@ HEVC/H.265 Control IDs .. _v4l2-hevc-hier-coding-type: -``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_TYPE`` +``V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_TYPE`` (enum) -enum v4l2_mpeg_video_hevc_hier_coding_type - +enum v4l2_codec_video_hevc_hier_coding_type - Selects the hierarchical coding type for encoding. Possible values are: .. raw:: latex @@ -2803,9 +2803,9 @@ enum v4l2_mpeg_video_hevc_hier_coding_type - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_HEVC_HIERARCHICAL_CODING_B`` + * - ``V4L2_CODEC_VIDEO_HEVC_HIERARCHICAL_CODING_B`` - Use the B frame for hierarchical coding. - * - ``V4L2_MPEG_VIDEO_HEVC_HIERARCHICAL_CODING_P`` + * - ``V4L2_CODEC_VIDEO_HEVC_HIERARCHICAL_CODING_P`` - Use the P frame for hierarchical coding. .. raw:: latex @@ -2813,53 +2813,53 @@ enum v4l2_mpeg_video_hevc_hier_coding_type - \normalsize -``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_LAYER (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_LAYER (integer)`` Selects the hierarchical coding layer. In normal encoding (non-hierarchial coding), it should be zero. Possible values are [0, 6]. 0 indicates HIERARCHICAL CODING LAYER 0, 1 indicates HIERARCHICAL CODING LAYER 1 and so on. -``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L0_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L0_QP (integer)`` Indicates quantization parameter for hierarchical coding layer 0. - Valid range: [V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP, - V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP]. + Valid range: [V4L2_CID_CODEC_VIDEO_HEVC_MIN_QP, + V4L2_CID_CODEC_VIDEO_HEVC_MAX_QP]. -``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L1_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L1_QP (integer)`` Indicates quantization parameter for hierarchical coding layer 1. - Valid range: [V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP, - V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP]. + Valid range: [V4L2_CID_CODEC_VIDEO_HEVC_MIN_QP, + V4L2_CID_CODEC_VIDEO_HEVC_MAX_QP]. -``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L2_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L2_QP (integer)`` Indicates quantization parameter for hierarchical coding layer 2. - Valid range: [V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP, - V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP]. + Valid range: [V4L2_CID_CODEC_VIDEO_HEVC_MIN_QP, + V4L2_CID_CODEC_VIDEO_HEVC_MAX_QP]. -``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L3_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L3_QP (integer)`` Indicates quantization parameter for hierarchical coding layer 3. - Valid range: [V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP, - V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP]. + Valid range: [V4L2_CID_CODEC_VIDEO_HEVC_MIN_QP, + V4L2_CID_CODEC_VIDEO_HEVC_MAX_QP]. -``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L4_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L4_QP (integer)`` Indicates quantization parameter for hierarchical coding layer 4. - Valid range: [V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP, - V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP]. + Valid range: [V4L2_CID_CODEC_VIDEO_HEVC_MIN_QP, + V4L2_CID_CODEC_VIDEO_HEVC_MAX_QP]. -``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L5_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L5_QP (integer)`` Indicates quantization parameter for hierarchical coding layer 5. - Valid range: [V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP, - V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP]. + Valid range: [V4L2_CID_CODEC_VIDEO_HEVC_MIN_QP, + V4L2_CID_CODEC_VIDEO_HEVC_MAX_QP]. -``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L6_QP (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L6_QP (integer)`` Indicates quantization parameter for hierarchical coding layer 6. - Valid range: [V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP, - V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP]. + Valid range: [V4L2_CID_CODEC_VIDEO_HEVC_MIN_QP, + V4L2_CID_CODEC_VIDEO_HEVC_MAX_QP]. .. _v4l2-hevc-profile: -``V4L2_CID_MPEG_VIDEO_HEVC_PROFILE`` +``V4L2_CID_CODEC_VIDEO_HEVC_PROFILE`` (enum) -enum v4l2_mpeg_video_hevc_profile - +enum v4l2_codec_video_hevc_profile - Select the desired profile for HEVC encoder. .. raw:: latex @@ -2872,11 +2872,11 @@ enum v4l2_mpeg_video_hevc_profile - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN`` + * - ``V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN`` - Main profile. - * - ``V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN_STILL_PICTURE`` + * - ``V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN_STILL_PICTURE`` - Main still picture profile. - * - ``V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN_10`` + * - ``V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN_10`` - Main 10 profile. .. raw:: latex @@ -2886,60 +2886,60 @@ enum v4l2_mpeg_video_hevc_profile - .. _v4l2-hevc-level: -``V4L2_CID_MPEG_VIDEO_HEVC_LEVEL`` +``V4L2_CID_CODEC_VIDEO_HEVC_LEVEL`` (enum) -enum v4l2_mpeg_video_hevc_level - +enum v4l2_codec_video_hevc_level - Selects the desired level for HEVC encoder. -================================== ========= -``V4L2_MPEG_VIDEO_HEVC_LEVEL_1`` Level 1.0 -``V4L2_MPEG_VIDEO_HEVC_LEVEL_2`` Level 2.0 -``V4L2_MPEG_VIDEO_HEVC_LEVEL_2_1`` Level 2.1 -``V4L2_MPEG_VIDEO_HEVC_LEVEL_3`` Level 3.0 -``V4L2_MPEG_VIDEO_HEVC_LEVEL_3_1`` Level 3.1 -``V4L2_MPEG_VIDEO_HEVC_LEVEL_4`` Level 4.0 -``V4L2_MPEG_VIDEO_HEVC_LEVEL_4_1`` Level 4.1 -``V4L2_MPEG_VIDEO_HEVC_LEVEL_5`` Level 5.0 -``V4L2_MPEG_VIDEO_HEVC_LEVEL_5_1`` Level 5.1 -``V4L2_MPEG_VIDEO_HEVC_LEVEL_5_2`` Level 5.2 -``V4L2_MPEG_VIDEO_HEVC_LEVEL_6`` Level 6.0 -``V4L2_MPEG_VIDEO_HEVC_LEVEL_6_1`` Level 6.1 -``V4L2_MPEG_VIDEO_HEVC_LEVEL_6_2`` Level 6.2 -================================== ========= - -``V4L2_CID_MPEG_VIDEO_HEVC_FRAME_RATE_RESOLUTION (integer)`` +=================================== ========= +``V4L2_CODEC_VIDEO_HEVC_LEVEL_1`` Level 1.0 +``V4L2_CODEC_VIDEO_HEVC_LEVEL_2`` Level 2.0 +``V4L2_CODEC_VIDEO_HEVC_LEVEL_2_1`` Level 2.1 +``V4L2_CODEC_VIDEO_HEVC_LEVEL_3`` Level 3.0 +``V4L2_CODEC_VIDEO_HEVC_LEVEL_3_1`` Level 3.1 +``V4L2_CODEC_VIDEO_HEVC_LEVEL_4`` Level 4.0 +``V4L2_CODEC_VIDEO_HEVC_LEVEL_4_1`` Level 4.1 +``V4L2_CODEC_VIDEO_HEVC_LEVEL_5`` Level 5.0 +``V4L2_CODEC_VIDEO_HEVC_LEVEL_5_1`` Level 5.1 +``V4L2_CODEC_VIDEO_HEVC_LEVEL_5_2`` Level 5.2 +``V4L2_CODEC_VIDEO_HEVC_LEVEL_6`` Level 6.0 +``V4L2_CODEC_VIDEO_HEVC_LEVEL_6_1`` Level 6.1 +``V4L2_CODEC_VIDEO_HEVC_LEVEL_6_2`` Level 6.2 +=================================== ========= + +``V4L2_CID_CODEC_VIDEO_HEVC_FRAME_RATE_RESOLUTION (integer)`` Indicates the number of evenly spaced subintervals, called ticks, within one second. This is a 16 bit unsigned integer and has a maximum value up to 0xffff and a minimum value of 1. .. _v4l2-hevc-tier: -``V4L2_CID_MPEG_VIDEO_HEVC_TIER`` +``V4L2_CID_CODEC_VIDEO_HEVC_TIER`` (enum) -enum v4l2_mpeg_video_hevc_tier - +enum v4l2_codec_video_hevc_tier - TIER_FLAG specifies tiers information of the HEVC encoded picture. Tier were made to deal with applications that differ in terms of maximum bit rate. Setting the flag to 0 selects HEVC tier as Main tier and setting this flag to 1 indicates High tier. High tier is for applications requiring high bit rates. -================================== ========== -``V4L2_MPEG_VIDEO_HEVC_TIER_MAIN`` Main tier. -``V4L2_MPEG_VIDEO_HEVC_TIER_HIGH`` High tier. -================================== ========== +=================================== ========== +``V4L2_CODEC_VIDEO_HEVC_TIER_MAIN`` Main tier. +``V4L2_CODEC_VIDEO_HEVC_TIER_HIGH`` High tier. +=================================== ========== -``V4L2_CID_MPEG_VIDEO_HEVC_MAX_PARTITION_DEPTH (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_MAX_PARTITION_DEPTH (integer)`` Selects HEVC maximum coding unit depth. .. _v4l2-hevc-loop-filter-mode: -``V4L2_CID_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE`` +``V4L2_CID_CODEC_VIDEO_HEVC_LOOP_FILTER_MODE`` (enum) -enum v4l2_mpeg_video_hevc_loop_filter_mode - +enum v4l2_codec_video_hevc_loop_filter_mode - Loop filter mode for HEVC encoder. Possible values are: .. raw:: latex @@ -2952,11 +2952,11 @@ enum v4l2_mpeg_video_hevc_loop_filter_mode - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE_DISABLED`` + * - ``V4L2_CODEC_VIDEO_HEVC_LOOP_FILTER_MODE_DISABLED`` - Loop filter is disabled. - * - ``V4L2_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE_ENABLED`` + * - ``V4L2_CODEC_VIDEO_HEVC_LOOP_FILTER_MODE_ENABLED`` - Loop filter is enabled. - * - ``V4L2_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY`` + * - ``V4L2_CODEC_VIDEO_HEVC_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY`` - Loop filter is disabled at the slice boundary. .. raw:: latex @@ -2964,21 +2964,21 @@ enum v4l2_mpeg_video_hevc_loop_filter_mode - \normalsize -``V4L2_CID_MPEG_VIDEO_HEVC_LF_BETA_OFFSET_DIV2 (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_LF_BETA_OFFSET_DIV2 (integer)`` Selects HEVC loop filter beta offset. The valid range is [-6, +6]. -``V4L2_CID_MPEG_VIDEO_HEVC_LF_TC_OFFSET_DIV2 (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_LF_TC_OFFSET_DIV2 (integer)`` Selects HEVC loop filter tc offset. The valid range is [-6, +6]. .. _v4l2-hevc-refresh-type: -``V4L2_CID_MPEG_VIDEO_HEVC_REFRESH_TYPE`` +``V4L2_CID_CODEC_VIDEO_HEVC_REFRESH_TYPE`` (enum) -enum v4l2_mpeg_video_hevc_hier_refresh_type - +enum v4l2_codec_video_hevc_hier_refresh_type - Selects refresh type for HEVC encoder. Host has to specify the period into - V4L2_CID_MPEG_VIDEO_HEVC_REFRESH_PERIOD. + V4L2_CID_CODEC_VIDEO_HEVC_REFRESH_PERIOD. .. raw:: latex @@ -2990,11 +2990,11 @@ enum v4l2_mpeg_video_hevc_hier_refresh_type - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_HEVC_REFRESH_NONE`` + * - ``V4L2_CODEC_VIDEO_HEVC_REFRESH_NONE`` - Use the B frame for hierarchical coding. - * - ``V4L2_MPEG_VIDEO_HEVC_REFRESH_CRA`` + * - ``V4L2_CODEC_VIDEO_HEVC_REFRESH_CRA`` - Use CRA (Clean Random Access Unit) picture encoding. - * - ``V4L2_MPEG_VIDEO_HEVC_REFRESH_IDR`` + * - ``V4L2_CODEC_VIDEO_HEVC_REFRESH_IDR`` - Use IDR (Instantaneous Decoding Refresh) picture encoding. .. raw:: latex @@ -3002,61 +3002,61 @@ enum v4l2_mpeg_video_hevc_hier_refresh_type - \normalsize -``V4L2_CID_MPEG_VIDEO_HEVC_REFRESH_PERIOD (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_REFRESH_PERIOD (integer)`` Selects the refresh period for HEVC encoder. This specifies the number of I pictures between two CRA/IDR pictures. This is valid only if REFRESH_TYPE is not 0. -``V4L2_CID_MPEG_VIDEO_HEVC_LOSSLESS_CU (boolean)`` +``V4L2_CID_CODEC_VIDEO_HEVC_LOSSLESS_CU (boolean)`` Indicates HEVC lossless encoding. Setting it to 0 disables lossless encoding. Setting it to 1 enables lossless encoding. -``V4L2_CID_MPEG_VIDEO_HEVC_CONST_INTRA_PRED (boolean)`` +``V4L2_CID_CODEC_VIDEO_HEVC_CONST_INTRA_PRED (boolean)`` Indicates constant intra prediction for HEVC encoder. Specifies the constrained intra prediction in which intra largest coding unit (LCU) prediction is performed by using residual data and decoded samples of neighboring intra LCU only. Setting the value to 1 enables constant intra prediction and setting the value to 0 disables constant intra prediction. -``V4L2_CID_MPEG_VIDEO_HEVC_WAVEFRONT (boolean)`` +``V4L2_CID_CODEC_VIDEO_HEVC_WAVEFRONT (boolean)`` Indicates wavefront parallel processing for HEVC encoder. Setting it to 0 disables the feature and setting it to 1 enables the wavefront parallel processing. -``V4L2_CID_MPEG_VIDEO_HEVC_GENERAL_PB (boolean)`` +``V4L2_CID_CODEC_VIDEO_HEVC_GENERAL_PB (boolean)`` Setting the value to 1 enables combination of P and B frame for HEVC encoder. -``V4L2_CID_MPEG_VIDEO_HEVC_TEMPORAL_ID (boolean)`` +``V4L2_CID_CODEC_VIDEO_HEVC_TEMPORAL_ID (boolean)`` Indicates temporal identifier for HEVC encoder which is enabled by setting the value to 1. -``V4L2_CID_MPEG_VIDEO_HEVC_STRONG_SMOOTHING (boolean)`` +``V4L2_CID_CODEC_VIDEO_HEVC_STRONG_SMOOTHING (boolean)`` Indicates bi-linear interpolation is conditionally used in the intra prediction filtering process in the CVS when set to 1. Indicates bi-linear interpolation is not used in the CVS when set to 0. -``V4L2_CID_MPEG_VIDEO_HEVC_MAX_NUM_MERGE_MV_MINUS1 (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_MAX_NUM_MERGE_MV_MINUS1 (integer)`` Indicates maximum number of merge candidate motion vectors. Values are from 0 to 4. -``V4L2_CID_MPEG_VIDEO_HEVC_TMV_PREDICTION (boolean)`` +``V4L2_CID_CODEC_VIDEO_HEVC_TMV_PREDICTION (boolean)`` Indicates temporal motion vector prediction for HEVC encoder. Setting it to 1 enables the prediction. Setting it to 0 disables the prediction. -``V4L2_CID_MPEG_VIDEO_HEVC_WITHOUT_STARTCODE (boolean)`` +``V4L2_CID_CODEC_VIDEO_HEVC_WITHOUT_STARTCODE (boolean)`` Specifies if HEVC generates a stream with a size of the length field instead of start code pattern. The size of the length field is configurable - through the V4L2_CID_MPEG_VIDEO_HEVC_SIZE_OF_LENGTH_FIELD control. Setting + through the V4L2_CID_CODEC_VIDEO_HEVC_SIZE_OF_LENGTH_FIELD control. Setting the value to 0 disables encoding without startcode pattern. Setting the value to 1 will enables encoding without startcode pattern. .. _v4l2-hevc-size-of-length-field: -``V4L2_CID_MPEG_VIDEO_HEVC_SIZE_OF_LENGTH_FIELD`` +``V4L2_CID_CODEC_VIDEO_HEVC_SIZE_OF_LENGTH_FIELD`` (enum) -enum v4l2_mpeg_video_hevc_size_of_length_field - +enum v4l2_codec_video_hevc_size_of_length_field - Indicates the size of length field. This is valid when encoding WITHOUT_STARTCODE_ENABLE is enabled. @@ -3070,52 +3070,52 @@ enum v4l2_mpeg_video_hevc_size_of_length_field - :header-rows: 0 :stub-columns: 0 - * - ``V4L2_MPEG_VIDEO_HEVC_SIZE_0`` + * - ``V4L2_CODEC_VIDEO_HEVC_SIZE_0`` - Generate start code pattern (Normal). - * - ``V4L2_MPEG_VIDEO_HEVC_SIZE_1`` + * - ``V4L2_CODEC_VIDEO_HEVC_SIZE_1`` - Generate size of length field instead of start code pattern and length is 1. - * - ``V4L2_MPEG_VIDEO_HEVC_SIZE_2`` + * - ``V4L2_CODEC_VIDEO_HEVC_SIZE_2`` - Generate size of length field instead of start code pattern and length is 2. - * - ``V4L2_MPEG_VIDEO_HEVC_SIZE_4`` + * - ``V4L2_CODEC_VIDEO_HEVC_SIZE_4`` - Generate size of length field instead of start code pattern and length is 4. .. raw:: latex \normalsize -``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L0_BR (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L0_BR (integer)`` Indicates bit rate for hierarchical coding layer 0 for HEVC encoder. -``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L1_BR (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L1_BR (integer)`` Indicates bit rate for hierarchical coding layer 1 for HEVC encoder. -``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L2_BR (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L2_BR (integer)`` Indicates bit rate for hierarchical coding layer 2 for HEVC encoder. -``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L3_BR (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L3_BR (integer)`` Indicates bit rate for hierarchical coding layer 3 for HEVC encoder. -``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L4_BR (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L4_BR (integer)`` Indicates bit rate for hierarchical coding layer 4 for HEVC encoder. -``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L5_BR (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L5_BR (integer)`` Indicates bit rate for hierarchical coding layer 5 for HEVC encoder. -``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L6_BR (integer)`` +``V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L6_BR (integer)`` Indicates bit rate for hierarchical coding layer 6 for HEVC encoder. -``V4L2_CID_MPEG_VIDEO_REF_NUMBER_FOR_PFRAMES (integer)`` +``V4L2_CID_CODEC_VIDEO_REF_NUMBER_FOR_PFRAMES (integer)`` Selects number of P reference pictures required for HEVC encoder. P-Frame can use 1 or 2 frames for reference. -``V4L2_CID_MPEG_VIDEO_PREPEND_SPSPPS_TO_IDR (integer)`` +``V4L2_CID_CODEC_VIDEO_PREPEND_SPSPPS_TO_IDR (integer)`` Indicates whether to generate SPS and PPS at every IDR. Setting it to 0 disables generating SPS and PPS at every IDR. Setting it to one enables generating SPS and PPS at every IDR. .. _v4l2-mpeg-hevc: -``V4L2_CID_MPEG_VIDEO_HEVC_SPS (struct)`` +``V4L2_CID_CODEC_VIDEO_HEVC_SPS (struct)`` Specifies the Sequence Parameter Set fields (as extracted from the bitstream) for the associated HEVC slice data. These bitstream parameters are defined according to :ref:`hevc`. @@ -3255,7 +3255,7 @@ enum v4l2_mpeg_video_hevc_size_of_length_field - \normalsize -``V4L2_CID_MPEG_VIDEO_HEVC_PPS (struct)`` +``V4L2_CID_CODEC_VIDEO_HEVC_PPS (struct)`` Specifies the Picture Parameter Set fields (as extracted from the bitstream) for the associated HEVC slice data. These bitstream parameters are defined according to :ref:`hevc`. @@ -3391,7 +3391,7 @@ enum v4l2_mpeg_video_hevc_size_of_length_field - \normalsize -``V4L2_CID_MPEG_VIDEO_HEVC_SLICE_PARAMS (struct)`` +``V4L2_CID_CODEC_VIDEO_HEVC_SLICE_PARAMS (struct)`` Specifies various slice-specific parameters, especially from the NAL unit header, general slice segment header and weighted prediction parameter parts of the bitstream. @@ -3651,7 +3651,7 @@ enum v4l2_mpeg_video_hevc_size_of_length_field - \normalsize -``V4L2_CID_MPEG_VIDEO_HEVC_DECODE_MODE (enum)`` +``V4L2_CID_CODEC_VIDEO_HEVC_DECODE_MODE (enum)`` Specifies the decoding mode to use. Currently exposes slice-based and frame-based decoding but new modes might be added later on. This control is used as a modifier for V4L2_PIX_FMT_HEVC_SLICE @@ -3666,7 +3666,7 @@ enum v4l2_mpeg_video_hevc_size_of_length_field - This menu control is not yet part of the public kernel API and it is expected to change. -.. c:type:: v4l2_mpeg_video_hevc_decode_mode +.. c:type:: v4l2_codec_video_hevc_decode_mode .. raw:: latex @@ -3679,11 +3679,11 @@ enum v4l2_mpeg_video_hevc_size_of_length_field - :stub-columns: 0 :widths: 1 1 2 - * - ``V4L2_MPEG_VIDEO_HEVC_DECODE_MODE_SLICE_BASED`` + * - ``V4L2_CODEC_VIDEO_HEVC_DECODE_MODE_SLICE_BASED`` - 0 - Decoding is done at the slice granularity. The OUTPUT buffer must contain a single slice. - * - ``V4L2_MPEG_VIDEO_HEVC_DECODE_MODE_FRAME_BASED`` + * - ``V4L2_CODEC_VIDEO_HEVC_DECODE_MODE_FRAME_BASED`` - 1 - Decoding is done at the frame granularity. The OUTPUT buffer must contain all slices needed to decode the @@ -3693,7 +3693,7 @@ enum v4l2_mpeg_video_hevc_size_of_length_field - \normalsize -``V4L2_CID_MPEG_VIDEO_HEVC_START_CODE (enum)`` +``V4L2_CID_CODEC_VIDEO_HEVC_START_CODE (enum)`` Specifies the HEVC slice start code expected for each slice. This control is used as a modifier for V4L2_PIX_FMT_HEVC_SLICE pixel format. Applications that support V4L2_PIX_FMT_HEVC_SLICE @@ -3707,7 +3707,7 @@ enum v4l2_mpeg_video_hevc_size_of_length_field - This menu control is not yet part of the public kernel API and it is expected to change. -.. c:type:: v4l2_mpeg_video_hevc_start_code +.. c:type:: v4l2_codec_video_hevc_start_code .. tabularcolumns:: |p{9.2cm}|p{0.6cm}|p{7.5cm}| @@ -3716,19 +3716,19 @@ enum v4l2_mpeg_video_hevc_size_of_length_field - :stub-columns: 0 :widths: 1 1 2 - * - ``V4L2_MPEG_VIDEO_HEVC_START_CODE_NONE`` + * - ``V4L2_CODEC_VIDEO_HEVC_START_CODE_NONE`` - 0 - Selecting this value specifies that HEVC slices are passed to the driver without any start code. The bitstream data should be according to :ref:`hevc` 7.3.1.1 General NAL unit syntax, hence contains emulation prevention bytes when required. - * - ``V4L2_MPEG_VIDEO_HEVC_START_CODE_ANNEX_B`` + * - ``V4L2_CODEC_VIDEO_HEVC_START_CODE_ANNEX_B`` - 1 - Selecting this value specifies that HEVC slices are expected to be prefixed by Annex B start codes. According to :ref:`hevc` valid start codes can be 3-bytes 0x000001 or 4-bytes 0x00000001. -``V4L2_CID_MPEG_VIDEO_BASELAYER_PRIORITY_ID (integer)`` +``V4L2_CID_CODEC_VIDEO_BASELAYER_PRIORITY_ID (integer)`` Specifies a priority identifier for the NAL unit, which will be applied to the base layer. By default this value is set to 0 for the base layer, and the next layer will have the priority ID assigned as 1, 2, 3 and so on. diff --git a/Documentation/userspace-api/media/v4l/hist-v4l2.rst b/Documentation/userspace-api/media/v4l/hist-v4l2.rst index 28a2750d5c8c..fe8f24d9c9f4 100644 --- a/Documentation/userspace-api/media/v4l/hist-v4l2.rst +++ b/Documentation/userspace-api/media/v4l/hist-v4l2.rst @@ -941,10 +941,10 @@ V4L2 in Linux 2.6.27 V4L2 in Linux 2.6.28 ==================== -1. Added ``V4L2_MPEG_AUDIO_ENCODING_AAC`` and - ``V4L2_MPEG_AUDIO_ENCODING_AC3`` MPEG audio encodings. +1. Added ``V4L2_CODEC_AUDIO_ENCODING_AAC`` and + ``V4L2_CODEC_AUDIO_ENCODING_AC3`` MPEG audio encodings. -2. Added ``V4L2_MPEG_VIDEO_ENCODING_MPEG_4_AVC`` MPEG video encoding. +2. Added ``V4L2_CODEC_VIDEO_ENCODING_MPEG_4_AVC`` MPEG video encoding. 3. The pixel formats ``V4L2_PIX_FMT_SGRBG10`` and ``V4L2_PIX_FMT_SGRBG10DPCM8`` were added. diff --git a/Documentation/userspace-api/media/v4l/pixfmt-compressed.rst b/Documentation/userspace-api/media/v4l/pixfmt-compressed.rst index ba6c0c961204..a50358da099d 100644 --- a/Documentation/userspace-api/media/v4l/pixfmt-compressed.rst +++ b/Documentation/userspace-api/media/v4l/pixfmt-compressed.rst @@ -34,7 +34,7 @@ Compressed Formats - ``V4L2_PIX_FMT_MPEG`` - 'MPEG' - MPEG multiplexed stream. The actual format is determined by - extended control ``V4L2_CID_MPEG_STREAM_TYPE``, see + extended control ``V4L2_CID_CODEC_STREAM_TYPE``, see :ref:`mpeg-control-id`. * .. _V4L2-PIX-FMT-H264: @@ -114,9 +114,9 @@ Compressed Formats This format is adapted for stateless video decoders that implement a MPEG-2 pipeline (using the :ref:`mem2mem` and :ref:`media-request-api`). Metadata associated with the frame to decode is required to be passed - through the ``V4L2_CID_MPEG_VIDEO_MPEG2_SLICE_PARAMS`` control and + through the ``V4L2_CID_CODEC_VIDEO_MPEG2_SLICE_PARAMS`` control and quantization matrices can optionally be specified through the - ``V4L2_CID_MPEG_VIDEO_MPEG2_QUANTIZATION`` control. + ``V4L2_CID_CODEC_VIDEO_MPEG2_QUANTIZATION`` control. See the :ref:`associated Codec Control IDs `. Exactly one output and one capture buffer must be provided for use with this pixel format. The output buffer must contain the appropriate number @@ -157,7 +157,7 @@ Compressed Formats This format is adapted for stateless video decoders that implement a VP8 pipeline (using the :ref:`mem2mem` and :ref:`media-request-api`). Metadata associated with the frame to decode is required to be passed - through the ``V4L2_CID_MPEG_VIDEO_VP8_FRAME_HEADER`` control. + through the ``V4L2_CID_CODEC_VIDEO_VP8_FRAME_HEADER`` control. See the :ref:`associated Codec Control IDs `. Exactly one output and one capture buffer must be provided for use with this pixel format. The output buffer must contain the appropriate number @@ -194,13 +194,13 @@ Compressed Formats This format is adapted for stateless video decoders that implement a HEVC pipeline (using the :ref:`mem2mem` and :ref:`media-request-api`). This pixelformat has two modifiers that must be set at least once - through the ``V4L2_CID_MPEG_VIDEO_HEVC_DECODE_MODE`` - and ``V4L2_CID_MPEG_VIDEO_HEVC_START_CODE`` controls. + through the ``V4L2_CID_CODEC_VIDEO_HEVC_DECODE_MODE`` + and ``V4L2_CID_CODEC_VIDEO_HEVC_START_CODE`` controls. Metadata associated with the frame to decode is required to be passed through the following controls: - ``V4L2_CID_MPEG_VIDEO_HEVC_SPS``, - ``V4L2_CID_MPEG_VIDEO_HEVC_PPS``, and - ``V4L2_CID_MPEG_VIDEO_HEVC_SLICE_PARAMS``. + ``V4L2_CID_CODEC_VIDEO_HEVC_SPS``, + ``V4L2_CID_CODEC_VIDEO_HEVC_PPS``, and + ``V4L2_CID_CODEC_VIDEO_HEVC_SLICE_PARAMS``. See the :ref:`associated Codec Control IDs `. Buffers associated with this pixel format must contain the appropriate number of macroblocks to decode a full corresponding frame. diff --git a/Documentation/userspace-api/media/v4l/v4l2.rst b/Documentation/userspace-api/media/v4l/v4l2.rst index ad7a2bf0cf26..e474b7e76be0 100644 --- a/Documentation/userspace-api/media/v4l/v4l2.rst +++ b/Documentation/userspace-api/media/v4l/v4l2.rst @@ -89,7 +89,7 @@ Authors, in alphabetical order: - Walls, Andy - - Documented the fielded V4L2_MPEG_STREAM_VBI_FMT_IVTV MPEG stream embedded, sliced VBI data format in this specification. + - Documented the fielded V4L2_CODEC_STREAM_VBI_FMT_IVTV MPEG stream embedded, sliced VBI data format in this specification. - Verkuil, Hans @@ -315,7 +315,7 @@ Documented V4L2_PIX_FMT_RGB444. :revision: 0.18 / 2006-10-18 (*mhs*) Added the description of extended controls by Hans Verkuil. Linked -V4L2_PIX_FMT_MPEG to V4L2_CID_MPEG_STREAM_TYPE. +V4L2_PIX_FMT_MPEG to V4L2_CID_CODEC_STREAM_TYPE. :revision: 0.17 / 2006-10-12 (*mhs*) From patchwork Sat Mar 13 14:43:12 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans Verkuil X-Patchwork-Id: 399848 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-15.9 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, UNWANTED_LANGUAGE_BODY,UPPERCASE_50_75,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 143C7C433E0 for ; Sat, 13 Mar 2021 14:44:26 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id BB7B664DFB for ; Sat, 13 Mar 2021 14:44:25 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234055AbhCMOnu (ORCPT ); Sat, 13 Mar 2021 09:43:50 -0500 Received: from lb2-smtp-cloud9.xs4all.net ([194.109.24.26]:58225 "EHLO lb2-smtp-cloud9.xs4all.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234021AbhCMOn3 (ORCPT ); Sat, 13 Mar 2021 09:43:29 -0500 Received: from cust-b5b5937f ([IPv6:fc0c:c16d:66b8:757f:c639:739b:9d66:799d]) by smtp-cloud9.xs4all.net with ESMTPA id L5UBljyoWC40pL5UGlV5dC; Sat, 13 Mar 2021 15:43:28 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=xs4all.nl; s=s2; t=1615646608; bh=mGDuzy6EETkTdKza2QhToB2GrKbr+7uk79zzaiX3Jl8=; h=From:To:Subject:Date:Message-Id:MIME-Version:From:Subject; b=hi3dwubSb71+YC9ZGj/ZR0VRkEnkr/QLB0nZKDN2WcJ9fOdJvQlW5Ha+Um1r7KpKg nXwE7A1oIbPeELuH8B5IYdy8vgguRKvcipVXW3FFVsHCu7mAvz+FBo3B4lh2+txGua i5C9gtyEhi1VF5oZqxNJe3TZoLIekg7nw4L6PG8ecJJS1xwlG5WqGL/qNLAH63uK4M SoiMiLhZadLgU54nFoj8RNVexA57FJASaPTtBPQjA+mZQnL4WlO4NslJSN/DUBhBjb Jsl5PVqxUVguH6mMVaKAmqvhUS7gzAIByj1cZvhxENVgR9P4jpVVSlTJOJmnr+0tTC E/1+L5OHAHAfA== From: Hans Verkuil To: linux-media@vger.kernel.org Cc: Ezequiel Garcia , Nicolas Dufresne , Tomasz Figa , Alexandre Courbot , Hans Verkuil Subject: [PATCH 04/15] media/common: rename MPEG to CODEC Date: Sat, 13 Mar 2021 15:43:12 +0100 Message-Id: <20210313144323.143600-5-hverkuil-cisco@xs4all.nl> X-Mailer: git-send-email 2.30.1 In-Reply-To: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> References: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> MIME-Version: 1.0 X-CMAE-Envelope: MS4xfLSx1V09vdOsiIy3BaNZdQmR/AETmlTZLgNQ9scdnGUt0EyBA5i0DQ6Ct0+d9egLK+97qvH87Wx78NNmwDGQSId51MO4xwmSM4nX0MFUXNzHT4mEtDo5 FedObq0D2z1LmGMi8iAH3j1/wChCPGUS+GNnSpfyMSicQMH4O6MZhu6GlpsUE6rY+K+RhwCmBIXUpWwW3CBWhGxjIlqHy1QnLG5cg1al5i+JvOMijy214ozU moQjxHrL4nUZhoDqmrKNTv/6lBm39Dvwv/3dqOs4j4iFKXyW9BmCRzEo05tIjgAoix2BCxj68IvhCYVAKve93f2bxsyXAPFPRDAcCsvJSYLNR4LRq68oCZk1 VwLXYKFU31VmWtxk87Ldo6kNGQwopg== Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Historically all codec-related data structures and defines used the MPEG prefix. This is confusing. Rename MPEG to CODEC to make it clear that the MPEG prefix isn't MPEG specific. Signed-off-by: Hans Verkuil --- drivers/media/common/cx2341x.c | 836 ++++++++++++++++----------------- 1 file changed, 418 insertions(+), 418 deletions(-) diff --git a/drivers/media/common/cx2341x.c b/drivers/media/common/cx2341x.c index 1392bd6b0026..1f172bc41cc6 100644 --- a/drivers/media/common/cx2341x.c +++ b/drivers/media/common/cx2341x.c @@ -35,29 +35,29 @@ MODULE_PARM_DESC(debug, "Debug level (0-1)"); static const char *cx2341x_get_name(u32 id) { switch (id) { - case V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE: + case V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE: return "Spatial Filter Mode"; - case V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER: + case V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER: return "Spatial Filter"; - case V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE: + case V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE: return "Spatial Luma Filter Type"; - case V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE: + case V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE: return "Spatial Chroma Filter Type"; - case V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE: + case V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE: return "Temporal Filter Mode"; - case V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER: + case V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER: return "Temporal Filter"; - case V4L2_CID_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE: + case V4L2_CID_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE: return "Median Filter Type"; - case V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP: + case V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP: return "Median Luma Filter Maximum"; - case V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM: + case V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM: return "Median Luma Filter Minimum"; - case V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP: + case V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP: return "Median Chroma Filter Maximum"; - case V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM: + case V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM: return "Median Chroma Filter Minimum"; - case V4L2_CID_MPEG_CX2341X_STREAM_INSERT_NAV_PACKETS: + case V4L2_CID_CODEC_CX2341X_STREAM_INSERT_NAV_PACKETS: return "Insert Navigation Packets"; } return NULL; @@ -102,15 +102,15 @@ static const char **cx2341x_get_menu(u32 id) }; switch (id) { - case V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE: + case V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE: return cx2341x_video_spatial_filter_mode_menu; - case V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE: + case V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE: return cx2341x_video_luma_spatial_filter_type_menu; - case V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE: + case V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE: return cx2341x_video_chroma_spatial_filter_type_menu; - case V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE: + case V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE: return cx2341x_video_temporal_filter_mode_menu; - case V4L2_CID_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE: + case V4L2_CID_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE: return cx2341x_video_median_filter_type_menu; } return NULL; @@ -123,16 +123,16 @@ static void cx2341x_ctrl_fill(u32 id, const char **name, enum v4l2_ctrl_type *ty *flags = 0; switch (id) { - case V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE: - case V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE: - case V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE: - case V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE: - case V4L2_CID_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE: + case V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE: + case V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE: + case V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE: + case V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE: + case V4L2_CID_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE: *type = V4L2_CTRL_TYPE_MENU; *min = 0; *step = 0; break; - case V4L2_CID_MPEG_CX2341X_STREAM_INSERT_NAV_PACKETS: + case V4L2_CID_CODEC_CX2341X_STREAM_INSERT_NAV_PACKETS: *type = V4L2_CTRL_TYPE_BOOLEAN; *min = 0; *max = *step = 1; @@ -142,20 +142,20 @@ static void cx2341x_ctrl_fill(u32 id, const char **name, enum v4l2_ctrl_type *ty break; } switch (id) { - case V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE: - case V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE: - case V4L2_CID_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE: + case V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE: + case V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE: + case V4L2_CID_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE: *flags |= V4L2_CTRL_FLAG_UPDATE; break; - case V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER: - case V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER: - case V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP: - case V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM: - case V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP: - case V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM: + case V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER: + case V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER: + case V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP: + case V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM: + case V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP: + case V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM: *flags |= V4L2_CTRL_FLAG_SLIDER; break; - case V4L2_CID_MPEG_VIDEO_ENCODING: + case V4L2_CID_CODEC_VIDEO_ENCODING: *flags |= V4L2_CTRL_FLAG_READ_ONLY; break; } @@ -167,40 +167,40 @@ static void cx2341x_ctrl_fill(u32 id, const char **name, enum v4l2_ctrl_type *ty /* Must be sorted from low to high control ID! */ const u32 cx2341x_mpeg_ctrls[] = { V4L2_CID_CODEC_CLASS, - V4L2_CID_MPEG_STREAM_TYPE, - V4L2_CID_MPEG_STREAM_VBI_FMT, - V4L2_CID_MPEG_AUDIO_SAMPLING_FREQ, - V4L2_CID_MPEG_AUDIO_ENCODING, - V4L2_CID_MPEG_AUDIO_L2_BITRATE, - V4L2_CID_MPEG_AUDIO_MODE, - V4L2_CID_MPEG_AUDIO_MODE_EXTENSION, - V4L2_CID_MPEG_AUDIO_EMPHASIS, - V4L2_CID_MPEG_AUDIO_CRC, - V4L2_CID_MPEG_AUDIO_MUTE, - V4L2_CID_MPEG_AUDIO_AC3_BITRATE, - V4L2_CID_MPEG_VIDEO_ENCODING, - V4L2_CID_MPEG_VIDEO_ASPECT, - V4L2_CID_MPEG_VIDEO_B_FRAMES, - V4L2_CID_MPEG_VIDEO_GOP_SIZE, - V4L2_CID_MPEG_VIDEO_GOP_CLOSURE, - V4L2_CID_MPEG_VIDEO_BITRATE_MODE, - V4L2_CID_MPEG_VIDEO_BITRATE, - V4L2_CID_MPEG_VIDEO_BITRATE_PEAK, - V4L2_CID_MPEG_VIDEO_TEMPORAL_DECIMATION, - V4L2_CID_MPEG_VIDEO_MUTE, - V4L2_CID_MPEG_VIDEO_MUTE_YUV, - V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE, - V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER, - V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE, - V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE, - V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE, - V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER, - V4L2_CID_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE, - V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM, - V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP, - V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM, - V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP, - V4L2_CID_MPEG_CX2341X_STREAM_INSERT_NAV_PACKETS, + V4L2_CID_CODEC_STREAM_TYPE, + V4L2_CID_CODEC_STREAM_VBI_FMT, + V4L2_CID_CODEC_AUDIO_SAMPLING_FREQ, + V4L2_CID_CODEC_AUDIO_ENCODING, + V4L2_CID_CODEC_AUDIO_L2_BITRATE, + V4L2_CID_CODEC_AUDIO_MODE, + V4L2_CID_CODEC_AUDIO_MODE_EXTENSION, + V4L2_CID_CODEC_AUDIO_EMPHASIS, + V4L2_CID_CODEC_AUDIO_CRC, + V4L2_CID_CODEC_AUDIO_MUTE, + V4L2_CID_CODEC_AUDIO_AC3_BITRATE, + V4L2_CID_CODEC_VIDEO_ENCODING, + V4L2_CID_CODEC_VIDEO_ASPECT, + V4L2_CID_CODEC_VIDEO_B_FRAMES, + V4L2_CID_CODEC_VIDEO_GOP_SIZE, + V4L2_CID_CODEC_VIDEO_GOP_CLOSURE, + V4L2_CID_CODEC_VIDEO_BITRATE_MODE, + V4L2_CID_CODEC_VIDEO_BITRATE, + V4L2_CID_CODEC_VIDEO_BITRATE_PEAK, + V4L2_CID_CODEC_VIDEO_TEMPORAL_DECIMATION, + V4L2_CID_CODEC_VIDEO_MUTE, + V4L2_CID_CODEC_VIDEO_MUTE_YUV, + V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE, + V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER, + V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE, + V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE, + V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE, + V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER, + V4L2_CID_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE, + V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM, + V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP, + V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM, + V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP, + V4L2_CID_CODEC_CX2341X_STREAM_INSERT_NAV_PACKETS, 0 }; EXPORT_SYMBOL(cx2341x_mpeg_ctrls); @@ -214,28 +214,28 @@ static const struct cx2341x_mpeg_params default_params = { .is_50hz = 0, /* stream */ - .stream_type = V4L2_MPEG_STREAM_TYPE_MPEG2_PS, - .stream_vbi_fmt = V4L2_MPEG_STREAM_VBI_FMT_NONE, + .stream_type = V4L2_CODEC_STREAM_TYPE_MPEG2_PS, + .stream_vbi_fmt = V4L2_CODEC_STREAM_VBI_FMT_NONE, .stream_insert_nav_packets = 0, /* audio */ - .audio_sampling_freq = V4L2_MPEG_AUDIO_SAMPLING_FREQ_48000, - .audio_encoding = V4L2_MPEG_AUDIO_ENCODING_LAYER_2, - .audio_l2_bitrate = V4L2_MPEG_AUDIO_L2_BITRATE_224K, - .audio_ac3_bitrate = V4L2_MPEG_AUDIO_AC3_BITRATE_224K, - .audio_mode = V4L2_MPEG_AUDIO_MODE_STEREO, - .audio_mode_extension = V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_4, - .audio_emphasis = V4L2_MPEG_AUDIO_EMPHASIS_NONE, - .audio_crc = V4L2_MPEG_AUDIO_CRC_NONE, + .audio_sampling_freq = V4L2_CODEC_AUDIO_SAMPLING_FREQ_48000, + .audio_encoding = V4L2_CODEC_AUDIO_ENCODING_LAYER_2, + .audio_l2_bitrate = V4L2_CODEC_AUDIO_L2_BITRATE_224K, + .audio_ac3_bitrate = V4L2_CODEC_AUDIO_AC3_BITRATE_224K, + .audio_mode = V4L2_CODEC_AUDIO_MODE_STEREO, + .audio_mode_extension = V4L2_CODEC_AUDIO_MODE_EXTENSION_BOUND_4, + .audio_emphasis = V4L2_CODEC_AUDIO_EMPHASIS_NONE, + .audio_crc = V4L2_CODEC_AUDIO_CRC_NONE, .audio_mute = 0, /* video */ - .video_encoding = V4L2_MPEG_VIDEO_ENCODING_MPEG_2, - .video_aspect = V4L2_MPEG_VIDEO_ASPECT_4x3, + .video_encoding = V4L2_CODEC_VIDEO_ENCODING_MPEG_2, + .video_aspect = V4L2_CODEC_VIDEO_ASPECT_4x3, .video_b_frames = 2, .video_gop_size = 12, .video_gop_closure = 1, - .video_bitrate_mode = V4L2_MPEG_VIDEO_BITRATE_MODE_VBR, + .video_bitrate_mode = V4L2_CODEC_VIDEO_BITRATE_MODE_VBR, .video_bitrate = 6000000, .video_bitrate_peak = 8000000, .video_temporal_decimation = 0, @@ -244,17 +244,17 @@ static const struct cx2341x_mpeg_params default_params = { /* encoding filters */ .video_spatial_filter_mode = - V4L2_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE_MANUAL, + V4L2_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE_MANUAL, .video_spatial_filter = 0, .video_luma_spatial_filter_type = - V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_1D_HOR, + V4L2_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_1D_HOR, .video_chroma_spatial_filter_type = - V4L2_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_1D_HOR, + V4L2_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_1D_HOR, .video_temporal_filter_mode = - V4L2_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_MANUAL, + V4L2_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_MANUAL, .video_temporal_filter = 8, .video_median_filter_type = - V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF, + V4L2_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF, .video_luma_median_filter_top = 255, .video_luma_median_filter_bottom = 0, .video_chroma_median_filter_top = 255, @@ -266,106 +266,106 @@ static int cx2341x_get_ctrl(const struct cx2341x_mpeg_params *params, struct v4l2_ext_control *ctrl) { switch (ctrl->id) { - case V4L2_CID_MPEG_AUDIO_SAMPLING_FREQ: + case V4L2_CID_CODEC_AUDIO_SAMPLING_FREQ: ctrl->value = params->audio_sampling_freq; break; - case V4L2_CID_MPEG_AUDIO_ENCODING: + case V4L2_CID_CODEC_AUDIO_ENCODING: ctrl->value = params->audio_encoding; break; - case V4L2_CID_MPEG_AUDIO_L2_BITRATE: + case V4L2_CID_CODEC_AUDIO_L2_BITRATE: ctrl->value = params->audio_l2_bitrate; break; - case V4L2_CID_MPEG_AUDIO_AC3_BITRATE: + case V4L2_CID_CODEC_AUDIO_AC3_BITRATE: ctrl->value = params->audio_ac3_bitrate; break; - case V4L2_CID_MPEG_AUDIO_MODE: + case V4L2_CID_CODEC_AUDIO_MODE: ctrl->value = params->audio_mode; break; - case V4L2_CID_MPEG_AUDIO_MODE_EXTENSION: + case V4L2_CID_CODEC_AUDIO_MODE_EXTENSION: ctrl->value = params->audio_mode_extension; break; - case V4L2_CID_MPEG_AUDIO_EMPHASIS: + case V4L2_CID_CODEC_AUDIO_EMPHASIS: ctrl->value = params->audio_emphasis; break; - case V4L2_CID_MPEG_AUDIO_CRC: + case V4L2_CID_CODEC_AUDIO_CRC: ctrl->value = params->audio_crc; break; - case V4L2_CID_MPEG_AUDIO_MUTE: + case V4L2_CID_CODEC_AUDIO_MUTE: ctrl->value = params->audio_mute; break; - case V4L2_CID_MPEG_VIDEO_ENCODING: + case V4L2_CID_CODEC_VIDEO_ENCODING: ctrl->value = params->video_encoding; break; - case V4L2_CID_MPEG_VIDEO_ASPECT: + case V4L2_CID_CODEC_VIDEO_ASPECT: ctrl->value = params->video_aspect; break; - case V4L2_CID_MPEG_VIDEO_B_FRAMES: + case V4L2_CID_CODEC_VIDEO_B_FRAMES: ctrl->value = params->video_b_frames; break; - case V4L2_CID_MPEG_VIDEO_GOP_SIZE: + case V4L2_CID_CODEC_VIDEO_GOP_SIZE: ctrl->value = params->video_gop_size; break; - case V4L2_CID_MPEG_VIDEO_GOP_CLOSURE: + case V4L2_CID_CODEC_VIDEO_GOP_CLOSURE: ctrl->value = params->video_gop_closure; break; - case V4L2_CID_MPEG_VIDEO_BITRATE_MODE: + case V4L2_CID_CODEC_VIDEO_BITRATE_MODE: ctrl->value = params->video_bitrate_mode; break; - case V4L2_CID_MPEG_VIDEO_BITRATE: + case V4L2_CID_CODEC_VIDEO_BITRATE: ctrl->value = params->video_bitrate; break; - case V4L2_CID_MPEG_VIDEO_BITRATE_PEAK: + case V4L2_CID_CODEC_VIDEO_BITRATE_PEAK: ctrl->value = params->video_bitrate_peak; break; - case V4L2_CID_MPEG_VIDEO_TEMPORAL_DECIMATION: + case V4L2_CID_CODEC_VIDEO_TEMPORAL_DECIMATION: ctrl->value = params->video_temporal_decimation; break; - case V4L2_CID_MPEG_VIDEO_MUTE: + case V4L2_CID_CODEC_VIDEO_MUTE: ctrl->value = params->video_mute; break; - case V4L2_CID_MPEG_VIDEO_MUTE_YUV: + case V4L2_CID_CODEC_VIDEO_MUTE_YUV: ctrl->value = params->video_mute_yuv; break; - case V4L2_CID_MPEG_STREAM_TYPE: + case V4L2_CID_CODEC_STREAM_TYPE: ctrl->value = params->stream_type; break; - case V4L2_CID_MPEG_STREAM_VBI_FMT: + case V4L2_CID_CODEC_STREAM_VBI_FMT: ctrl->value = params->stream_vbi_fmt; break; - case V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE: + case V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE: ctrl->value = params->video_spatial_filter_mode; break; - case V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER: + case V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER: ctrl->value = params->video_spatial_filter; break; - case V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE: + case V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE: ctrl->value = params->video_luma_spatial_filter_type; break; - case V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE: + case V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE: ctrl->value = params->video_chroma_spatial_filter_type; break; - case V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE: + case V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE: ctrl->value = params->video_temporal_filter_mode; break; - case V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER: + case V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER: ctrl->value = params->video_temporal_filter; break; - case V4L2_CID_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE: + case V4L2_CID_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE: ctrl->value = params->video_median_filter_type; break; - case V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP: + case V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP: ctrl->value = params->video_luma_median_filter_top; break; - case V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM: + case V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM: ctrl->value = params->video_luma_median_filter_bottom; break; - case V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP: + case V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP: ctrl->value = params->video_chroma_median_filter_top; break; - case V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM: + case V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM: ctrl->value = params->video_chroma_median_filter_bottom; break; - case V4L2_CID_MPEG_CX2341X_STREAM_INSERT_NAV_PACKETS: + case V4L2_CID_CODEC_CX2341X_STREAM_INSERT_NAV_PACKETS: ctrl->value = params->stream_insert_nav_packets; break; default: @@ -380,51 +380,51 @@ static int cx2341x_set_ctrl(struct cx2341x_mpeg_params *params, int busy, struct v4l2_ext_control *ctrl) { switch (ctrl->id) { - case V4L2_CID_MPEG_AUDIO_SAMPLING_FREQ: + case V4L2_CID_CODEC_AUDIO_SAMPLING_FREQ: if (busy) return -EBUSY; params->audio_sampling_freq = ctrl->value; break; - case V4L2_CID_MPEG_AUDIO_ENCODING: + case V4L2_CID_CODEC_AUDIO_ENCODING: if (busy) return -EBUSY; if (params->capabilities & CX2341X_CAP_HAS_AC3) - if (ctrl->value != V4L2_MPEG_AUDIO_ENCODING_LAYER_2 && - ctrl->value != V4L2_MPEG_AUDIO_ENCODING_AC3) + if (ctrl->value != V4L2_CODEC_AUDIO_ENCODING_LAYER_2 && + ctrl->value != V4L2_CODEC_AUDIO_ENCODING_AC3) return -ERANGE; params->audio_encoding = ctrl->value; break; - case V4L2_CID_MPEG_AUDIO_L2_BITRATE: + case V4L2_CID_CODEC_AUDIO_L2_BITRATE: if (busy) return -EBUSY; params->audio_l2_bitrate = ctrl->value; break; - case V4L2_CID_MPEG_AUDIO_AC3_BITRATE: + case V4L2_CID_CODEC_AUDIO_AC3_BITRATE: if (busy) return -EBUSY; if (!(params->capabilities & CX2341X_CAP_HAS_AC3)) return -EINVAL; params->audio_ac3_bitrate = ctrl->value; break; - case V4L2_CID_MPEG_AUDIO_MODE: + case V4L2_CID_CODEC_AUDIO_MODE: params->audio_mode = ctrl->value; break; - case V4L2_CID_MPEG_AUDIO_MODE_EXTENSION: + case V4L2_CID_CODEC_AUDIO_MODE_EXTENSION: params->audio_mode_extension = ctrl->value; break; - case V4L2_CID_MPEG_AUDIO_EMPHASIS: + case V4L2_CID_CODEC_AUDIO_EMPHASIS: params->audio_emphasis = ctrl->value; break; - case V4L2_CID_MPEG_AUDIO_CRC: + case V4L2_CID_CODEC_AUDIO_CRC: params->audio_crc = ctrl->value; break; - case V4L2_CID_MPEG_AUDIO_MUTE: + case V4L2_CID_CODEC_AUDIO_MUTE: params->audio_mute = ctrl->value; break; - case V4L2_CID_MPEG_VIDEO_ASPECT: + case V4L2_CID_CODEC_VIDEO_ASPECT: params->video_aspect = ctrl->value; break; - case V4L2_CID_MPEG_VIDEO_B_FRAMES: { + case V4L2_CID_CODEC_VIDEO_B_FRAMES: { int b = ctrl->value + 1; int gop = params->video_gop_size; params->video_b_frames = ctrl->value; @@ -434,7 +434,7 @@ static int cx2341x_set_ctrl(struct cx2341x_mpeg_params *params, int busy, params->video_gop_size -= b; break; } - case V4L2_CID_MPEG_VIDEO_GOP_SIZE: { + case V4L2_CID_CODEC_VIDEO_GOP_SIZE: { int b = params->video_b_frames + 1; int gop = ctrl->value; params->video_gop_size = b * ((gop + b - 1) / b); @@ -444,88 +444,88 @@ static int cx2341x_set_ctrl(struct cx2341x_mpeg_params *params, int busy, ctrl->value = params->video_gop_size; break; } - case V4L2_CID_MPEG_VIDEO_GOP_CLOSURE: + case V4L2_CID_CODEC_VIDEO_GOP_CLOSURE: params->video_gop_closure = ctrl->value; break; - case V4L2_CID_MPEG_VIDEO_BITRATE_MODE: + case V4L2_CID_CODEC_VIDEO_BITRATE_MODE: if (busy) return -EBUSY; /* MPEG-1 only allows CBR */ - if (params->video_encoding == V4L2_MPEG_VIDEO_ENCODING_MPEG_1 && - ctrl->value != V4L2_MPEG_VIDEO_BITRATE_MODE_CBR) + if (params->video_encoding == V4L2_CODEC_VIDEO_ENCODING_MPEG_1 && + ctrl->value != V4L2_CODEC_VIDEO_BITRATE_MODE_CBR) return -EINVAL; params->video_bitrate_mode = ctrl->value; break; - case V4L2_CID_MPEG_VIDEO_BITRATE: + case V4L2_CID_CODEC_VIDEO_BITRATE: if (busy) return -EBUSY; params->video_bitrate = ctrl->value; break; - case V4L2_CID_MPEG_VIDEO_BITRATE_PEAK: + case V4L2_CID_CODEC_VIDEO_BITRATE_PEAK: if (busy) return -EBUSY; params->video_bitrate_peak = ctrl->value; break; - case V4L2_CID_MPEG_VIDEO_TEMPORAL_DECIMATION: + case V4L2_CID_CODEC_VIDEO_TEMPORAL_DECIMATION: params->video_temporal_decimation = ctrl->value; break; - case V4L2_CID_MPEG_VIDEO_MUTE: + case V4L2_CID_CODEC_VIDEO_MUTE: params->video_mute = (ctrl->value != 0); break; - case V4L2_CID_MPEG_VIDEO_MUTE_YUV: + case V4L2_CID_CODEC_VIDEO_MUTE_YUV: params->video_mute_yuv = ctrl->value; break; - case V4L2_CID_MPEG_STREAM_TYPE: + case V4L2_CID_CODEC_STREAM_TYPE: if (busy) return -EBUSY; params->stream_type = ctrl->value; params->video_encoding = - (params->stream_type == V4L2_MPEG_STREAM_TYPE_MPEG1_SS || - params->stream_type == V4L2_MPEG_STREAM_TYPE_MPEG1_VCD) ? - V4L2_MPEG_VIDEO_ENCODING_MPEG_1 : - V4L2_MPEG_VIDEO_ENCODING_MPEG_2; - if (params->video_encoding == V4L2_MPEG_VIDEO_ENCODING_MPEG_1) + (params->stream_type == V4L2_CODEC_STREAM_TYPE_MPEG1_SS || + params->stream_type == V4L2_CODEC_STREAM_TYPE_MPEG1_VCD) ? + V4L2_CODEC_VIDEO_ENCODING_MPEG_1 : + V4L2_CODEC_VIDEO_ENCODING_MPEG_2; + if (params->video_encoding == V4L2_CODEC_VIDEO_ENCODING_MPEG_1) /* MPEG-1 implies CBR */ params->video_bitrate_mode = - V4L2_MPEG_VIDEO_BITRATE_MODE_CBR; + V4L2_CODEC_VIDEO_BITRATE_MODE_CBR; break; - case V4L2_CID_MPEG_STREAM_VBI_FMT: + case V4L2_CID_CODEC_STREAM_VBI_FMT: params->stream_vbi_fmt = ctrl->value; break; - case V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE: + case V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE: params->video_spatial_filter_mode = ctrl->value; break; - case V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER: + case V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER: params->video_spatial_filter = ctrl->value; break; - case V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE: + case V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE: params->video_luma_spatial_filter_type = ctrl->value; break; - case V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE: + case V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE: params->video_chroma_spatial_filter_type = ctrl->value; break; - case V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE: + case V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE: params->video_temporal_filter_mode = ctrl->value; break; - case V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER: + case V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER: params->video_temporal_filter = ctrl->value; break; - case V4L2_CID_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE: + case V4L2_CID_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE: params->video_median_filter_type = ctrl->value; break; - case V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP: + case V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP: params->video_luma_median_filter_top = ctrl->value; break; - case V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM: + case V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM: params->video_luma_median_filter_bottom = ctrl->value; break; - case V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP: + case V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP: params->video_chroma_median_filter_top = ctrl->value; break; - case V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM: + case V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM: params->video_chroma_median_filter_bottom = ctrl->value; break; - case V4L2_CID_MPEG_CX2341X_STREAM_INSERT_NAV_PACKETS: + case V4L2_CID_CODEC_CX2341X_STREAM_INSERT_NAV_PACKETS: params->stream_insert_nav_packets = ctrl->value; break; default: @@ -541,18 +541,18 @@ static int cx2341x_ctrl_query_fill(struct v4l2_queryctrl *qctrl, switch (qctrl->id) { /* MPEG controls */ - case V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE: - case V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER: - case V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE: - case V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE: - case V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE: - case V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER: - case V4L2_CID_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE: - case V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP: - case V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM: - case V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP: - case V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM: - case V4L2_CID_MPEG_CX2341X_STREAM_INSERT_NAV_PACKETS: + case V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE: + case V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER: + case V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE: + case V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE: + case V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE: + case V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER: + case V4L2_CID_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE: + case V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP: + case V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM: + case V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP: + case V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM: + case V4L2_CID_CODEC_CX2341X_STREAM_INSERT_NAV_PACKETS: cx2341x_ctrl_fill(qctrl->id, &name, &qctrl->type, &min, &max, &step, &def, &qctrl->flags); qctrl->minimum = min; @@ -576,260 +576,260 @@ int cx2341x_ctrl_query(const struct cx2341x_mpeg_params *params, switch (qctrl->id) { case V4L2_CID_CODEC_CLASS: return v4l2_ctrl_query_fill(qctrl, 0, 0, 0, 0); - case V4L2_CID_MPEG_STREAM_TYPE: + case V4L2_CID_CODEC_STREAM_TYPE: return v4l2_ctrl_query_fill(qctrl, - V4L2_MPEG_STREAM_TYPE_MPEG2_PS, - V4L2_MPEG_STREAM_TYPE_MPEG2_SVCD, 1, - V4L2_MPEG_STREAM_TYPE_MPEG2_PS); + V4L2_CODEC_STREAM_TYPE_MPEG2_PS, + V4L2_CODEC_STREAM_TYPE_MPEG2_SVCD, 1, + V4L2_CODEC_STREAM_TYPE_MPEG2_PS); - case V4L2_CID_MPEG_STREAM_VBI_FMT: + case V4L2_CID_CODEC_STREAM_VBI_FMT: if (params->capabilities & CX2341X_CAP_HAS_SLICED_VBI) return v4l2_ctrl_query_fill(qctrl, - V4L2_MPEG_STREAM_VBI_FMT_NONE, - V4L2_MPEG_STREAM_VBI_FMT_IVTV, 1, - V4L2_MPEG_STREAM_VBI_FMT_NONE); + V4L2_CODEC_STREAM_VBI_FMT_NONE, + V4L2_CODEC_STREAM_VBI_FMT_IVTV, 1, + V4L2_CODEC_STREAM_VBI_FMT_NONE); return cx2341x_ctrl_query_fill(qctrl, - V4L2_MPEG_STREAM_VBI_FMT_NONE, - V4L2_MPEG_STREAM_VBI_FMT_NONE, 1, + V4L2_CODEC_STREAM_VBI_FMT_NONE, + V4L2_CODEC_STREAM_VBI_FMT_NONE, 1, default_params.stream_vbi_fmt); - case V4L2_CID_MPEG_AUDIO_SAMPLING_FREQ: + case V4L2_CID_CODEC_AUDIO_SAMPLING_FREQ: return v4l2_ctrl_query_fill(qctrl, - V4L2_MPEG_AUDIO_SAMPLING_FREQ_44100, - V4L2_MPEG_AUDIO_SAMPLING_FREQ_32000, 1, - V4L2_MPEG_AUDIO_SAMPLING_FREQ_48000); + V4L2_CODEC_AUDIO_SAMPLING_FREQ_44100, + V4L2_CODEC_AUDIO_SAMPLING_FREQ_32000, 1, + V4L2_CODEC_AUDIO_SAMPLING_FREQ_48000); - case V4L2_CID_MPEG_AUDIO_ENCODING: + case V4L2_CID_CODEC_AUDIO_ENCODING: if (params->capabilities & CX2341X_CAP_HAS_AC3) { /* * The state of L2 & AC3 bitrate controls can change * when this control changes, but v4l2_ctrl_query_fill() * already sets V4L2_CTRL_FLAG_UPDATE for - * V4L2_CID_MPEG_AUDIO_ENCODING, so we don't here. + * V4L2_CID_CODEC_AUDIO_ENCODING, so we don't here. */ return v4l2_ctrl_query_fill(qctrl, - V4L2_MPEG_AUDIO_ENCODING_LAYER_2, - V4L2_MPEG_AUDIO_ENCODING_AC3, 1, + V4L2_CODEC_AUDIO_ENCODING_LAYER_2, + V4L2_CODEC_AUDIO_ENCODING_AC3, 1, default_params.audio_encoding); } return v4l2_ctrl_query_fill(qctrl, - V4L2_MPEG_AUDIO_ENCODING_LAYER_2, - V4L2_MPEG_AUDIO_ENCODING_LAYER_2, 1, + V4L2_CODEC_AUDIO_ENCODING_LAYER_2, + V4L2_CODEC_AUDIO_ENCODING_LAYER_2, 1, default_params.audio_encoding); - case V4L2_CID_MPEG_AUDIO_L2_BITRATE: + case V4L2_CID_CODEC_AUDIO_L2_BITRATE: err = v4l2_ctrl_query_fill(qctrl, - V4L2_MPEG_AUDIO_L2_BITRATE_192K, - V4L2_MPEG_AUDIO_L2_BITRATE_384K, 1, + V4L2_CODEC_AUDIO_L2_BITRATE_192K, + V4L2_CODEC_AUDIO_L2_BITRATE_384K, 1, default_params.audio_l2_bitrate); if (err) return err; if (params->capabilities & CX2341X_CAP_HAS_AC3 && - params->audio_encoding != V4L2_MPEG_AUDIO_ENCODING_LAYER_2) + params->audio_encoding != V4L2_CODEC_AUDIO_ENCODING_LAYER_2) qctrl->flags |= V4L2_CTRL_FLAG_INACTIVE; return 0; - case V4L2_CID_MPEG_AUDIO_MODE: + case V4L2_CID_CODEC_AUDIO_MODE: return v4l2_ctrl_query_fill(qctrl, - V4L2_MPEG_AUDIO_MODE_STEREO, - V4L2_MPEG_AUDIO_MODE_MONO, 1, - V4L2_MPEG_AUDIO_MODE_STEREO); + V4L2_CODEC_AUDIO_MODE_STEREO, + V4L2_CODEC_AUDIO_MODE_MONO, 1, + V4L2_CODEC_AUDIO_MODE_STEREO); - case V4L2_CID_MPEG_AUDIO_MODE_EXTENSION: + case V4L2_CID_CODEC_AUDIO_MODE_EXTENSION: err = v4l2_ctrl_query_fill(qctrl, - V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_4, - V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_16, 1, - V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_4); + V4L2_CODEC_AUDIO_MODE_EXTENSION_BOUND_4, + V4L2_CODEC_AUDIO_MODE_EXTENSION_BOUND_16, 1, + V4L2_CODEC_AUDIO_MODE_EXTENSION_BOUND_4); if (err == 0 && - params->audio_mode != V4L2_MPEG_AUDIO_MODE_JOINT_STEREO) + params->audio_mode != V4L2_CODEC_AUDIO_MODE_JOINT_STEREO) qctrl->flags |= V4L2_CTRL_FLAG_INACTIVE; return err; - case V4L2_CID_MPEG_AUDIO_EMPHASIS: + case V4L2_CID_CODEC_AUDIO_EMPHASIS: return v4l2_ctrl_query_fill(qctrl, - V4L2_MPEG_AUDIO_EMPHASIS_NONE, - V4L2_MPEG_AUDIO_EMPHASIS_CCITT_J17, 1, - V4L2_MPEG_AUDIO_EMPHASIS_NONE); + V4L2_CODEC_AUDIO_EMPHASIS_NONE, + V4L2_CODEC_AUDIO_EMPHASIS_CCITT_J17, 1, + V4L2_CODEC_AUDIO_EMPHASIS_NONE); - case V4L2_CID_MPEG_AUDIO_CRC: + case V4L2_CID_CODEC_AUDIO_CRC: return v4l2_ctrl_query_fill(qctrl, - V4L2_MPEG_AUDIO_CRC_NONE, - V4L2_MPEG_AUDIO_CRC_CRC16, 1, - V4L2_MPEG_AUDIO_CRC_NONE); + V4L2_CODEC_AUDIO_CRC_NONE, + V4L2_CODEC_AUDIO_CRC_CRC16, 1, + V4L2_CODEC_AUDIO_CRC_NONE); - case V4L2_CID_MPEG_AUDIO_MUTE: + case V4L2_CID_CODEC_AUDIO_MUTE: return v4l2_ctrl_query_fill(qctrl, 0, 1, 1, 0); - case V4L2_CID_MPEG_AUDIO_AC3_BITRATE: + case V4L2_CID_CODEC_AUDIO_AC3_BITRATE: err = v4l2_ctrl_query_fill(qctrl, - V4L2_MPEG_AUDIO_AC3_BITRATE_48K, - V4L2_MPEG_AUDIO_AC3_BITRATE_448K, 1, + V4L2_CODEC_AUDIO_AC3_BITRATE_48K, + V4L2_CODEC_AUDIO_AC3_BITRATE_448K, 1, default_params.audio_ac3_bitrate); if (err) return err; if (params->capabilities & CX2341X_CAP_HAS_AC3) { if (params->audio_encoding != - V4L2_MPEG_AUDIO_ENCODING_AC3) + V4L2_CODEC_AUDIO_ENCODING_AC3) qctrl->flags |= V4L2_CTRL_FLAG_INACTIVE; } else qctrl->flags |= V4L2_CTRL_FLAG_DISABLED; return 0; - case V4L2_CID_MPEG_VIDEO_ENCODING: + case V4L2_CID_CODEC_VIDEO_ENCODING: /* this setting is read-only for the cx2341x since the - V4L2_CID_MPEG_STREAM_TYPE really determines the + V4L2_CID_CODEC_STREAM_TYPE really determines the MPEG-1/2 setting */ err = v4l2_ctrl_query_fill(qctrl, - V4L2_MPEG_VIDEO_ENCODING_MPEG_1, - V4L2_MPEG_VIDEO_ENCODING_MPEG_2, 1, - V4L2_MPEG_VIDEO_ENCODING_MPEG_2); + V4L2_CODEC_VIDEO_ENCODING_MPEG_1, + V4L2_CODEC_VIDEO_ENCODING_MPEG_2, 1, + V4L2_CODEC_VIDEO_ENCODING_MPEG_2); if (err == 0) qctrl->flags |= V4L2_CTRL_FLAG_READ_ONLY; return err; - case V4L2_CID_MPEG_VIDEO_ASPECT: + case V4L2_CID_CODEC_VIDEO_ASPECT: return v4l2_ctrl_query_fill(qctrl, - V4L2_MPEG_VIDEO_ASPECT_1x1, - V4L2_MPEG_VIDEO_ASPECT_221x100, 1, - V4L2_MPEG_VIDEO_ASPECT_4x3); + V4L2_CODEC_VIDEO_ASPECT_1x1, + V4L2_CODEC_VIDEO_ASPECT_221x100, 1, + V4L2_CODEC_VIDEO_ASPECT_4x3); - case V4L2_CID_MPEG_VIDEO_B_FRAMES: + case V4L2_CID_CODEC_VIDEO_B_FRAMES: return v4l2_ctrl_query_fill(qctrl, 0, 33, 1, 2); - case V4L2_CID_MPEG_VIDEO_GOP_SIZE: + case V4L2_CID_CODEC_VIDEO_GOP_SIZE: return v4l2_ctrl_query_fill(qctrl, 1, 34, 1, params->is_50hz ? 12 : 15); - case V4L2_CID_MPEG_VIDEO_GOP_CLOSURE: + case V4L2_CID_CODEC_VIDEO_GOP_CLOSURE: return v4l2_ctrl_query_fill(qctrl, 0, 1, 1, 1); - case V4L2_CID_MPEG_VIDEO_BITRATE_MODE: + case V4L2_CID_CODEC_VIDEO_BITRATE_MODE: err = v4l2_ctrl_query_fill(qctrl, - V4L2_MPEG_VIDEO_BITRATE_MODE_VBR, - V4L2_MPEG_VIDEO_BITRATE_MODE_CBR, 1, - V4L2_MPEG_VIDEO_BITRATE_MODE_VBR); + V4L2_CODEC_VIDEO_BITRATE_MODE_VBR, + V4L2_CODEC_VIDEO_BITRATE_MODE_CBR, 1, + V4L2_CODEC_VIDEO_BITRATE_MODE_VBR); if (err == 0 && - params->video_encoding == V4L2_MPEG_VIDEO_ENCODING_MPEG_1) + params->video_encoding == V4L2_CODEC_VIDEO_ENCODING_MPEG_1) qctrl->flags |= V4L2_CTRL_FLAG_INACTIVE; return err; - case V4L2_CID_MPEG_VIDEO_BITRATE: + case V4L2_CID_CODEC_VIDEO_BITRATE: return v4l2_ctrl_query_fill(qctrl, 0, 27000000, 1, 6000000); - case V4L2_CID_MPEG_VIDEO_BITRATE_PEAK: + case V4L2_CID_CODEC_VIDEO_BITRATE_PEAK: err = v4l2_ctrl_query_fill(qctrl, 0, 27000000, 1, 8000000); if (err == 0 && params->video_bitrate_mode == - V4L2_MPEG_VIDEO_BITRATE_MODE_CBR) + V4L2_CODEC_VIDEO_BITRATE_MODE_CBR) qctrl->flags |= V4L2_CTRL_FLAG_INACTIVE; return err; - case V4L2_CID_MPEG_VIDEO_TEMPORAL_DECIMATION: + case V4L2_CID_CODEC_VIDEO_TEMPORAL_DECIMATION: return v4l2_ctrl_query_fill(qctrl, 0, 255, 1, 0); - case V4L2_CID_MPEG_VIDEO_MUTE: + case V4L2_CID_CODEC_VIDEO_MUTE: return v4l2_ctrl_query_fill(qctrl, 0, 1, 1, 0); - case V4L2_CID_MPEG_VIDEO_MUTE_YUV: /* Init YUV (really YCbCr) to black */ + case V4L2_CID_CODEC_VIDEO_MUTE_YUV: /* Init YUV (really YCbCr) to black */ return v4l2_ctrl_query_fill(qctrl, 0, 0xffffff, 1, 0x008080); /* CX23415/6 specific */ - case V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE: + case V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE: return cx2341x_ctrl_query_fill(qctrl, - V4L2_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE_MANUAL, - V4L2_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE_AUTO, 1, + V4L2_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE_MANUAL, + V4L2_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE_AUTO, 1, default_params.video_spatial_filter_mode); - case V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER: + case V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER: cx2341x_ctrl_query_fill(qctrl, 0, 15, 1, default_params.video_spatial_filter); qctrl->flags |= V4L2_CTRL_FLAG_SLIDER; if (params->video_spatial_filter_mode == - V4L2_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE_AUTO) + V4L2_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE_AUTO) qctrl->flags |= V4L2_CTRL_FLAG_INACTIVE; return 0; - case V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE: + case V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE: cx2341x_ctrl_query_fill(qctrl, - V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_OFF, - V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_2D_SYM_NON_SEPARABLE, + V4L2_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_OFF, + V4L2_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_2D_SYM_NON_SEPARABLE, 1, default_params.video_luma_spatial_filter_type); if (params->video_spatial_filter_mode == - V4L2_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE_AUTO) + V4L2_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE_AUTO) qctrl->flags |= V4L2_CTRL_FLAG_INACTIVE; return 0; - case V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE: + case V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE: cx2341x_ctrl_query_fill(qctrl, - V4L2_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_OFF, - V4L2_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_1D_HOR, + V4L2_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_OFF, + V4L2_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_1D_HOR, 1, default_params.video_chroma_spatial_filter_type); if (params->video_spatial_filter_mode == - V4L2_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE_AUTO) + V4L2_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE_AUTO) qctrl->flags |= V4L2_CTRL_FLAG_INACTIVE; return 0; - case V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE: + case V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE: return cx2341x_ctrl_query_fill(qctrl, - V4L2_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_MANUAL, - V4L2_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_AUTO, 1, + V4L2_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_MANUAL, + V4L2_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_AUTO, 1, default_params.video_temporal_filter_mode); - case V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER: + case V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER: cx2341x_ctrl_query_fill(qctrl, 0, 31, 1, default_params.video_temporal_filter); qctrl->flags |= V4L2_CTRL_FLAG_SLIDER; if (params->video_temporal_filter_mode == - V4L2_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_AUTO) + V4L2_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_AUTO) qctrl->flags |= V4L2_CTRL_FLAG_INACTIVE; return 0; - case V4L2_CID_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE: + case V4L2_CID_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE: return cx2341x_ctrl_query_fill(qctrl, - V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF, - V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_DIAG, 1, + V4L2_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF, + V4L2_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_DIAG, 1, default_params.video_median_filter_type); - case V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP: + case V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP: cx2341x_ctrl_query_fill(qctrl, 0, 255, 1, default_params.video_luma_median_filter_top); qctrl->flags |= V4L2_CTRL_FLAG_SLIDER; if (params->video_median_filter_type == - V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF) + V4L2_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF) qctrl->flags |= V4L2_CTRL_FLAG_INACTIVE; return 0; - case V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM: + case V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM: cx2341x_ctrl_query_fill(qctrl, 0, 255, 1, default_params.video_luma_median_filter_bottom); qctrl->flags |= V4L2_CTRL_FLAG_SLIDER; if (params->video_median_filter_type == - V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF) + V4L2_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF) qctrl->flags |= V4L2_CTRL_FLAG_INACTIVE; return 0; - case V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP: + case V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP: cx2341x_ctrl_query_fill(qctrl, 0, 255, 1, default_params.video_chroma_median_filter_top); qctrl->flags |= V4L2_CTRL_FLAG_SLIDER; if (params->video_median_filter_type == - V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF) + V4L2_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF) qctrl->flags |= V4L2_CTRL_FLAG_INACTIVE; return 0; - case V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM: + case V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM: cx2341x_ctrl_query_fill(qctrl, 0, 255, 1, default_params.video_chroma_median_filter_bottom); qctrl->flags |= V4L2_CTRL_FLAG_SLIDER; if (params->video_median_filter_type == - V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF) + V4L2_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF) qctrl->flags |= V4L2_CTRL_FLAG_INACTIVE; return 0; - case V4L2_CID_MPEG_CX2341X_STREAM_INSERT_NAV_PACKETS: + case V4L2_CID_CODEC_CX2341X_STREAM_INSERT_NAV_PACKETS: return cx2341x_ctrl_query_fill(qctrl, 0, 1, 1, default_params.stream_insert_nav_packets); @@ -872,20 +872,20 @@ const char * const *cx2341x_ctrl_get_menu(const struct cx2341x_mpeg_params *p, u }; switch (id) { - case V4L2_CID_MPEG_STREAM_TYPE: + case V4L2_CID_CODEC_STREAM_TYPE: return (p->capabilities & CX2341X_CAP_HAS_TS) ? mpeg_stream_type_with_ts : mpeg_stream_type_without_ts; - case V4L2_CID_MPEG_AUDIO_ENCODING: + case V4L2_CID_CODEC_AUDIO_ENCODING: return (p->capabilities & CX2341X_CAP_HAS_AC3) ? mpeg_audio_encoding_l2_ac3 : v4l2_ctrl_get_menu(id); - case V4L2_CID_MPEG_AUDIO_L1_BITRATE: - case V4L2_CID_MPEG_AUDIO_L3_BITRATE: + case V4L2_CID_CODEC_AUDIO_L1_BITRATE: + case V4L2_CID_CODEC_AUDIO_L3_BITRATE: return NULL; - case V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE: - case V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE: - case V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE: - case V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE: - case V4L2_CID_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE: + case V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE: + case V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE: + case V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE: + case V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE: + case V4L2_CID_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE: return cx2341x_get_menu(id); default: return v4l2_ctrl_get_menu(id); @@ -899,15 +899,15 @@ static void cx2341x_calc_audio_properties(struct cx2341x_mpeg_params *params) (params->audio_sampling_freq << 0) | (params->audio_mode << 8) | (params->audio_mode_extension << 10) | - (((params->audio_emphasis == V4L2_MPEG_AUDIO_EMPHASIS_CCITT_J17) + (((params->audio_emphasis == V4L2_CODEC_AUDIO_EMPHASIS_CCITT_J17) ? 3 : params->audio_emphasis) << 12) | (params->audio_crc << 14); if ((params->capabilities & CX2341X_CAP_HAS_AC3) && - params->audio_encoding == V4L2_MPEG_AUDIO_ENCODING_AC3) { + params->audio_encoding == V4L2_CODEC_AUDIO_ENCODING_AC3) { params->audio_properties |= /* Not sure if this MPEG Layer II setting is required */ - ((3 - V4L2_MPEG_AUDIO_ENCODING_LAYER_2) << 2) | + ((3 - V4L2_CODEC_AUDIO_ENCODING_LAYER_2) << 2) | (params->audio_ac3_bitrate << 4) | (CX2341X_AUDIO_ENCODING_METHOD_AC3 << 28); } else { @@ -984,7 +984,7 @@ int cx2341x_ext_ctrls(struct cx2341x_mpeg_params *params, int busy, break; } if (err == 0 && - params->video_bitrate_mode == V4L2_MPEG_VIDEO_BITRATE_MODE_VBR && + params->video_bitrate_mode == V4L2_CODEC_VIDEO_BITRATE_MODE_VBR && params->video_bitrate_peak < params->video_bitrate) { err = -ERANGE; ctrls->error_idx = ctrls->count; @@ -1052,7 +1052,7 @@ int cx2341x_update(void *priv, cx2341x_mbox_func func, u16 w = new->width; u16 h = new->height; - if (new->video_encoding == V4L2_MPEG_VIDEO_ENCODING_MPEG_1) { + if (new->video_encoding == V4L2_CODEC_VIDEO_ENCODING_MPEG_1) { w /= 2; h /= 2; } @@ -1205,18 +1205,18 @@ static const char *cx2341x_menu_item(const struct cx2341x_mpeg_params *p, u32 id void cx2341x_log_status(const struct cx2341x_mpeg_params *p, const char *prefix) { - int is_mpeg1 = p->video_encoding == V4L2_MPEG_VIDEO_ENCODING_MPEG_1; + int is_mpeg1 = p->video_encoding == V4L2_CODEC_VIDEO_ENCODING_MPEG_1; /* Stream */ printk(KERN_INFO "%s: Stream: %s", prefix, - cx2341x_menu_item(p, V4L2_CID_MPEG_STREAM_TYPE)); + cx2341x_menu_item(p, V4L2_CID_CODEC_STREAM_TYPE)); if (p->stream_insert_nav_packets) printk(KERN_CONT " (with navigation packets)"); printk(KERN_CONT "\n"); printk(KERN_INFO "%s: VBI Format: %s\n", prefix, - cx2341x_menu_item(p, V4L2_CID_MPEG_STREAM_VBI_FMT)); + cx2341x_menu_item(p, V4L2_CID_CODEC_STREAM_VBI_FMT)); /* Video */ printk(KERN_INFO "%s: Video: %dx%d, %d fps%s\n", @@ -1226,11 +1226,11 @@ void cx2341x_log_status(const struct cx2341x_mpeg_params *p, const char *prefix) (p->video_mute) ? " (muted)" : ""); printk(KERN_INFO "%s: Video: %s, %s, %s, %d", prefix, - cx2341x_menu_item(p, V4L2_CID_MPEG_VIDEO_ENCODING), - cx2341x_menu_item(p, V4L2_CID_MPEG_VIDEO_ASPECT), - cx2341x_menu_item(p, V4L2_CID_MPEG_VIDEO_BITRATE_MODE), + cx2341x_menu_item(p, V4L2_CID_CODEC_VIDEO_ENCODING), + cx2341x_menu_item(p, V4L2_CID_CODEC_VIDEO_ASPECT), + cx2341x_menu_item(p, V4L2_CID_CODEC_VIDEO_BITRATE_MODE), p->video_bitrate); - if (p->video_bitrate_mode == V4L2_MPEG_VIDEO_BITRATE_MODE_VBR) + if (p->video_bitrate_mode == V4L2_CODEC_VIDEO_BITRATE_MODE_VBR) printk(KERN_CONT ", Peak %d", p->video_bitrate_peak); printk(KERN_CONT "\n"); printk(KERN_INFO @@ -1245,42 +1245,42 @@ void cx2341x_log_status(const struct cx2341x_mpeg_params *p, const char *prefix) /* Audio */ printk(KERN_INFO "%s: Audio: %s, %s, %s, %s%s", prefix, - cx2341x_menu_item(p, V4L2_CID_MPEG_AUDIO_SAMPLING_FREQ), - cx2341x_menu_item(p, V4L2_CID_MPEG_AUDIO_ENCODING), + cx2341x_menu_item(p, V4L2_CID_CODEC_AUDIO_SAMPLING_FREQ), + cx2341x_menu_item(p, V4L2_CID_CODEC_AUDIO_ENCODING), cx2341x_menu_item(p, - p->audio_encoding == V4L2_MPEG_AUDIO_ENCODING_AC3 - ? V4L2_CID_MPEG_AUDIO_AC3_BITRATE - : V4L2_CID_MPEG_AUDIO_L2_BITRATE), - cx2341x_menu_item(p, V4L2_CID_MPEG_AUDIO_MODE), + p->audio_encoding == V4L2_CODEC_AUDIO_ENCODING_AC3 + ? V4L2_CID_CODEC_AUDIO_AC3_BITRATE + : V4L2_CID_CODEC_AUDIO_L2_BITRATE), + cx2341x_menu_item(p, V4L2_CID_CODEC_AUDIO_MODE), p->audio_mute ? " (muted)" : ""); - if (p->audio_mode == V4L2_MPEG_AUDIO_MODE_JOINT_STEREO) + if (p->audio_mode == V4L2_CODEC_AUDIO_MODE_JOINT_STEREO) printk(KERN_CONT ", %s", cx2341x_menu_item(p, - V4L2_CID_MPEG_AUDIO_MODE_EXTENSION)); + V4L2_CID_CODEC_AUDIO_MODE_EXTENSION)); printk(KERN_CONT ", %s, %s\n", - cx2341x_menu_item(p, V4L2_CID_MPEG_AUDIO_EMPHASIS), - cx2341x_menu_item(p, V4L2_CID_MPEG_AUDIO_CRC)); + cx2341x_menu_item(p, V4L2_CID_CODEC_AUDIO_EMPHASIS), + cx2341x_menu_item(p, V4L2_CID_CODEC_AUDIO_CRC)); /* Encoding filters */ printk(KERN_INFO "%s: Spatial Filter: %s, Luma %s, Chroma %s, %d\n", prefix, cx2341x_menu_item(p, - V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE), + V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE), cx2341x_menu_item(p, - V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE), + V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE), cx2341x_menu_item(p, - V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE), + V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE), p->video_spatial_filter); printk(KERN_INFO "%s: Temporal Filter: %s, %d\n", prefix, cx2341x_menu_item(p, - V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE), + V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE), p->video_temporal_filter); printk(KERN_INFO "%s: Median Filter: %s, Luma [%d, %d], Chroma [%d, %d]\n", prefix, cx2341x_menu_item(p, - V4L2_CID_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE), + V4L2_CID_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE), p->video_luma_median_filter_bottom, p->video_luma_median_filter_top, p->video_chroma_median_filter_bottom, @@ -1324,7 +1324,7 @@ static int cx2341x_try_ctrl(struct v4l2_ctrl *ctrl) s32 val = ctrl->val; switch (ctrl->id) { - case V4L2_CID_MPEG_VIDEO_B_FRAMES: { + case V4L2_CID_CODEC_VIDEO_B_FRAMES: { /* video gop cluster */ int b = val + 1; int gop = hdl->video_gop_size->val; @@ -1338,19 +1338,19 @@ static int cx2341x_try_ctrl(struct v4l2_ctrl *ctrl) break; } - case V4L2_CID_MPEG_STREAM_TYPE: + case V4L2_CID_CODEC_STREAM_TYPE: /* stream type cluster */ hdl->video_encoding->val = - (hdl->stream_type->val == V4L2_MPEG_STREAM_TYPE_MPEG1_SS || - hdl->stream_type->val == V4L2_MPEG_STREAM_TYPE_MPEG1_VCD) ? - V4L2_MPEG_VIDEO_ENCODING_MPEG_1 : - V4L2_MPEG_VIDEO_ENCODING_MPEG_2; - if (hdl->video_encoding->val == V4L2_MPEG_VIDEO_ENCODING_MPEG_1) + (hdl->stream_type->val == V4L2_CODEC_STREAM_TYPE_MPEG1_SS || + hdl->stream_type->val == V4L2_CODEC_STREAM_TYPE_MPEG1_VCD) ? + V4L2_CODEC_VIDEO_ENCODING_MPEG_1 : + V4L2_CODEC_VIDEO_ENCODING_MPEG_2; + if (hdl->video_encoding->val == V4L2_CODEC_VIDEO_ENCODING_MPEG_1) /* MPEG-1 implies CBR */ hdl->video_bitrate_mode->val = - V4L2_MPEG_VIDEO_BITRATE_MODE_CBR; + V4L2_CODEC_VIDEO_BITRATE_MODE_CBR; /* peak bitrate shall be >= normal bitrate */ - if (hdl->video_bitrate_mode->val == V4L2_MPEG_VIDEO_BITRATE_MODE_VBR && + if (hdl->video_bitrate_mode->val == V4L2_CODEC_VIDEO_BITRATE_MODE_VBR && hdl->video_bitrate_peak->val < hdl->video_bitrate->val) hdl->video_bitrate_peak->val = hdl->video_bitrate->val; break; @@ -1374,44 +1374,44 @@ static int cx2341x_s_ctrl(struct v4l2_ctrl *ctrl) int err; switch (ctrl->id) { - case V4L2_CID_MPEG_STREAM_VBI_FMT: + case V4L2_CID_CODEC_STREAM_VBI_FMT: if (hdl->ops && hdl->ops->s_stream_vbi_fmt) return hdl->ops->s_stream_vbi_fmt(hdl, val); return 0; - case V4L2_CID_MPEG_VIDEO_ASPECT: + case V4L2_CID_CODEC_VIDEO_ASPECT: return cx2341x_hdl_api(hdl, CX2341X_ENC_SET_ASPECT_RATIO, 1, val + 1); - case V4L2_CID_MPEG_VIDEO_GOP_CLOSURE: + case V4L2_CID_CODEC_VIDEO_GOP_CLOSURE: return cx2341x_hdl_api(hdl, CX2341X_ENC_SET_GOP_CLOSURE, 1, val); - case V4L2_CID_MPEG_AUDIO_MUTE: + case V4L2_CID_CODEC_AUDIO_MUTE: return cx2341x_hdl_api(hdl, CX2341X_ENC_MUTE_AUDIO, 1, val); - case V4L2_CID_MPEG_VIDEO_TEMPORAL_DECIMATION: + case V4L2_CID_CODEC_VIDEO_TEMPORAL_DECIMATION: return cx2341x_hdl_api(hdl, CX2341X_ENC_SET_FRAME_DROP_RATE, 1, val); - case V4L2_CID_MPEG_CX2341X_STREAM_INSERT_NAV_PACKETS: + case V4L2_CID_CODEC_CX2341X_STREAM_INSERT_NAV_PACKETS: return cx2341x_hdl_api(hdl, CX2341X_ENC_MISC, 2, 7, val); - case V4L2_CID_MPEG_AUDIO_SAMPLING_FREQ: + case V4L2_CID_CODEC_AUDIO_SAMPLING_FREQ: /* audio properties cluster */ props = (hdl->audio_sampling_freq->val << 0) | (hdl->audio_mode->val << 8) | (hdl->audio_mode_extension->val << 10) | (hdl->audio_crc->val << 14); - if (hdl->audio_emphasis->val == V4L2_MPEG_AUDIO_EMPHASIS_CCITT_J17) + if (hdl->audio_emphasis->val == V4L2_CODEC_AUDIO_EMPHASIS_CCITT_J17) props |= 3 << 12; else props |= hdl->audio_emphasis->val << 12; - if (hdl->audio_encoding->val == V4L2_MPEG_AUDIO_ENCODING_AC3) { + if (hdl->audio_encoding->val == V4L2_CODEC_AUDIO_ENCODING_AC3) { props |= #if 1 /* Not sure if this MPEG Layer II setting is required */ - ((3 - V4L2_MPEG_AUDIO_ENCODING_LAYER_2) << 2) | + ((3 - V4L2_CODEC_AUDIO_ENCODING_LAYER_2) << 2) | #endif (hdl->audio_ac3_bitrate->val << 4) | (CX2341X_AUDIO_ENCODING_METHOD_AC3 << 28); @@ -1429,13 +1429,13 @@ static int cx2341x_s_ctrl(struct v4l2_ctrl *ctrl) hdl->audio_properties = props; if (hdl->audio_ac3_bitrate) { int is_ac3 = hdl->audio_encoding->val == - V4L2_MPEG_AUDIO_ENCODING_AC3; + V4L2_CODEC_AUDIO_ENCODING_AC3; v4l2_ctrl_activate(hdl->audio_ac3_bitrate, is_ac3); v4l2_ctrl_activate(hdl->audio_l2_bitrate, !is_ac3); } v4l2_ctrl_activate(hdl->audio_mode_extension, - hdl->audio_mode->val == V4L2_MPEG_AUDIO_MODE_JOINT_STEREO); + hdl->audio_mode->val == V4L2_CODEC_AUDIO_MODE_JOINT_STEREO); if (cx2341x_neq(hdl->audio_sampling_freq) && hdl->ops && hdl->ops->s_audio_sampling_freq) return hdl->ops->s_audio_sampling_freq(hdl, hdl->audio_sampling_freq->val); @@ -1444,13 +1444,13 @@ static int cx2341x_s_ctrl(struct v4l2_ctrl *ctrl) return hdl->ops->s_audio_mode(hdl, hdl->audio_mode->val); return 0; - case V4L2_CID_MPEG_VIDEO_B_FRAMES: + case V4L2_CID_CODEC_VIDEO_B_FRAMES: /* video gop cluster */ return cx2341x_hdl_api(hdl, CX2341X_ENC_SET_GOP_PROPERTIES, 2, hdl->video_gop_size->val, hdl->video_b_frames->val + 1); - case V4L2_CID_MPEG_STREAM_TYPE: + case V4L2_CID_CODEC_STREAM_TYPE: /* stream type cluster */ err = cx2341x_hdl_api(hdl, CX2341X_ENC_SET_STREAM_TYPE, 1, mpeg_stream_type[val]); @@ -1465,21 +1465,21 @@ static int cx2341x_s_ctrl(struct v4l2_ctrl *ctrl) return err; v4l2_ctrl_activate(hdl->video_bitrate_mode, - hdl->video_encoding->val != V4L2_MPEG_VIDEO_ENCODING_MPEG_1); + hdl->video_encoding->val != V4L2_CODEC_VIDEO_ENCODING_MPEG_1); v4l2_ctrl_activate(hdl->video_bitrate_peak, - hdl->video_bitrate_mode->val != V4L2_MPEG_VIDEO_BITRATE_MODE_CBR); + hdl->video_bitrate_mode->val != V4L2_CODEC_VIDEO_BITRATE_MODE_CBR); if (cx2341x_neq(hdl->video_encoding) && hdl->ops && hdl->ops->s_video_encoding) return hdl->ops->s_video_encoding(hdl, hdl->video_encoding->val); return 0; - case V4L2_CID_MPEG_VIDEO_MUTE: + case V4L2_CID_CODEC_VIDEO_MUTE: /* video mute cluster */ return cx2341x_hdl_api(hdl, CX2341X_ENC_MUTE_VIDEO, 1, hdl->video_mute->val | (hdl->video_mute_yuv->val << 8)); - case V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE: { + case V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE: { int active_filter; /* video filter mode */ @@ -1491,15 +1491,15 @@ static int cx2341x_s_ctrl(struct v4l2_ctrl *ctrl) return err; active_filter = hdl->video_spatial_filter_mode->val != - V4L2_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE_AUTO; + V4L2_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE_AUTO; v4l2_ctrl_activate(hdl->video_spatial_filter, active_filter); v4l2_ctrl_activate(hdl->video_luma_spatial_filter_type, active_filter); v4l2_ctrl_activate(hdl->video_chroma_spatial_filter_type, active_filter); active_filter = hdl->video_temporal_filter_mode->val != - V4L2_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_AUTO; + V4L2_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_AUTO; v4l2_ctrl_activate(hdl->video_temporal_filter, active_filter); active_filter = hdl->video_median_filter_type->val != - V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF; + V4L2_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF; v4l2_ctrl_activate(hdl->video_luma_median_filter_bottom, active_filter); v4l2_ctrl_activate(hdl->video_luma_median_filter_top, active_filter); v4l2_ctrl_activate(hdl->video_chroma_median_filter_bottom, active_filter); @@ -1507,20 +1507,20 @@ static int cx2341x_s_ctrl(struct v4l2_ctrl *ctrl) return 0; } - case V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE: + case V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE: /* video filter type cluster */ return cx2341x_hdl_api(hdl, CX2341X_ENC_SET_SPATIAL_FILTER_TYPE, 2, hdl->video_luma_spatial_filter_type->val, hdl->video_chroma_spatial_filter_type->val); - case V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER: + case V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER: /* video filter cluster */ return cx2341x_hdl_api(hdl, CX2341X_ENC_SET_DNR_FILTER_PROPS, 2, hdl->video_spatial_filter->val, hdl->video_temporal_filter->val); - case V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP: + case V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP: /* video median cluster */ return cx2341x_hdl_api(hdl, CX2341X_ENC_SET_CORING_LEVELS, 4, hdl->video_luma_median_filter_bottom->val, @@ -1588,128 +1588,128 @@ int cx2341x_handler_init(struct cx2341x_handler *cxhdl, /* Add controls in ascending control ID order for fastest insertion time. */ cxhdl->stream_type = cx2341x_ctrl_new_menu(hdl, - V4L2_CID_MPEG_STREAM_TYPE, - V4L2_MPEG_STREAM_TYPE_MPEG2_SVCD, has_ts ? 0 : 2, - V4L2_MPEG_STREAM_TYPE_MPEG2_PS); + V4L2_CID_CODEC_STREAM_TYPE, + V4L2_CODEC_STREAM_TYPE_MPEG2_SVCD, has_ts ? 0 : 2, + V4L2_CODEC_STREAM_TYPE_MPEG2_PS); cxhdl->stream_vbi_fmt = cx2341x_ctrl_new_menu(hdl, - V4L2_CID_MPEG_STREAM_VBI_FMT, - V4L2_MPEG_STREAM_VBI_FMT_IVTV, has_sliced_vbi ? 0 : 2, - V4L2_MPEG_STREAM_VBI_FMT_NONE); + V4L2_CID_CODEC_STREAM_VBI_FMT, + V4L2_CODEC_STREAM_VBI_FMT_IVTV, has_sliced_vbi ? 0 : 2, + V4L2_CODEC_STREAM_VBI_FMT_NONE); cxhdl->audio_sampling_freq = cx2341x_ctrl_new_menu(hdl, - V4L2_CID_MPEG_AUDIO_SAMPLING_FREQ, - V4L2_MPEG_AUDIO_SAMPLING_FREQ_32000, 0, - V4L2_MPEG_AUDIO_SAMPLING_FREQ_48000); + V4L2_CID_CODEC_AUDIO_SAMPLING_FREQ, + V4L2_CODEC_AUDIO_SAMPLING_FREQ_32000, 0, + V4L2_CODEC_AUDIO_SAMPLING_FREQ_48000); cxhdl->audio_encoding = cx2341x_ctrl_new_menu(hdl, - V4L2_CID_MPEG_AUDIO_ENCODING, - V4L2_MPEG_AUDIO_ENCODING_AC3, has_ac3 ? ~0x12 : ~0x2, - V4L2_MPEG_AUDIO_ENCODING_LAYER_2); + V4L2_CID_CODEC_AUDIO_ENCODING, + V4L2_CODEC_AUDIO_ENCODING_AC3, has_ac3 ? ~0x12 : ~0x2, + V4L2_CODEC_AUDIO_ENCODING_LAYER_2); cxhdl->audio_l2_bitrate = cx2341x_ctrl_new_menu(hdl, - V4L2_CID_MPEG_AUDIO_L2_BITRATE, - V4L2_MPEG_AUDIO_L2_BITRATE_384K, 0x1ff, - V4L2_MPEG_AUDIO_L2_BITRATE_224K); + V4L2_CID_CODEC_AUDIO_L2_BITRATE, + V4L2_CODEC_AUDIO_L2_BITRATE_384K, 0x1ff, + V4L2_CODEC_AUDIO_L2_BITRATE_224K); cxhdl->audio_mode = cx2341x_ctrl_new_menu(hdl, - V4L2_CID_MPEG_AUDIO_MODE, - V4L2_MPEG_AUDIO_MODE_MONO, 0, - V4L2_MPEG_AUDIO_MODE_STEREO); + V4L2_CID_CODEC_AUDIO_MODE, + V4L2_CODEC_AUDIO_MODE_MONO, 0, + V4L2_CODEC_AUDIO_MODE_STEREO); cxhdl->audio_mode_extension = cx2341x_ctrl_new_menu(hdl, - V4L2_CID_MPEG_AUDIO_MODE_EXTENSION, - V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_16, 0, - V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_4); + V4L2_CID_CODEC_AUDIO_MODE_EXTENSION, + V4L2_CODEC_AUDIO_MODE_EXTENSION_BOUND_16, 0, + V4L2_CODEC_AUDIO_MODE_EXTENSION_BOUND_4); cxhdl->audio_emphasis = cx2341x_ctrl_new_menu(hdl, - V4L2_CID_MPEG_AUDIO_EMPHASIS, - V4L2_MPEG_AUDIO_EMPHASIS_CCITT_J17, 0, - V4L2_MPEG_AUDIO_EMPHASIS_NONE); + V4L2_CID_CODEC_AUDIO_EMPHASIS, + V4L2_CODEC_AUDIO_EMPHASIS_CCITT_J17, 0, + V4L2_CODEC_AUDIO_EMPHASIS_NONE); cxhdl->audio_crc = cx2341x_ctrl_new_menu(hdl, - V4L2_CID_MPEG_AUDIO_CRC, - V4L2_MPEG_AUDIO_CRC_CRC16, 0, - V4L2_MPEG_AUDIO_CRC_NONE); + V4L2_CID_CODEC_AUDIO_CRC, + V4L2_CODEC_AUDIO_CRC_CRC16, 0, + V4L2_CODEC_AUDIO_CRC_NONE); - cx2341x_ctrl_new_std(hdl, V4L2_CID_MPEG_AUDIO_MUTE, 0, 1, 1, 0); + cx2341x_ctrl_new_std(hdl, V4L2_CID_CODEC_AUDIO_MUTE, 0, 1, 1, 0); if (has_ac3) cxhdl->audio_ac3_bitrate = cx2341x_ctrl_new_menu(hdl, - V4L2_CID_MPEG_AUDIO_AC3_BITRATE, - V4L2_MPEG_AUDIO_AC3_BITRATE_448K, 0x03, - V4L2_MPEG_AUDIO_AC3_BITRATE_224K); + V4L2_CID_CODEC_AUDIO_AC3_BITRATE, + V4L2_CODEC_AUDIO_AC3_BITRATE_448K, 0x03, + V4L2_CODEC_AUDIO_AC3_BITRATE_224K); cxhdl->video_encoding = cx2341x_ctrl_new_menu(hdl, - V4L2_CID_MPEG_VIDEO_ENCODING, - V4L2_MPEG_VIDEO_ENCODING_MPEG_2, 0, - V4L2_MPEG_VIDEO_ENCODING_MPEG_2); + V4L2_CID_CODEC_VIDEO_ENCODING, + V4L2_CODEC_VIDEO_ENCODING_MPEG_2, 0, + V4L2_CODEC_VIDEO_ENCODING_MPEG_2); cx2341x_ctrl_new_menu(hdl, - V4L2_CID_MPEG_VIDEO_ASPECT, - V4L2_MPEG_VIDEO_ASPECT_221x100, 0, - V4L2_MPEG_VIDEO_ASPECT_4x3); + V4L2_CID_CODEC_VIDEO_ASPECT, + V4L2_CODEC_VIDEO_ASPECT_221x100, 0, + V4L2_CODEC_VIDEO_ASPECT_4x3); cxhdl->video_b_frames = cx2341x_ctrl_new_std(hdl, - V4L2_CID_MPEG_VIDEO_B_FRAMES, 0, 33, 1, 2); + V4L2_CID_CODEC_VIDEO_B_FRAMES, 0, 33, 1, 2); cxhdl->video_gop_size = cx2341x_ctrl_new_std(hdl, - V4L2_CID_MPEG_VIDEO_GOP_SIZE, + V4L2_CID_CODEC_VIDEO_GOP_SIZE, 1, 34, 1, cxhdl->is_50hz ? 12 : 15); - cx2341x_ctrl_new_std(hdl, V4L2_CID_MPEG_VIDEO_GOP_CLOSURE, 0, 1, 1, 1); + cx2341x_ctrl_new_std(hdl, V4L2_CID_CODEC_VIDEO_GOP_CLOSURE, 0, 1, 1, 1); cxhdl->video_bitrate_mode = cx2341x_ctrl_new_menu(hdl, - V4L2_CID_MPEG_VIDEO_BITRATE_MODE, - V4L2_MPEG_VIDEO_BITRATE_MODE_CBR, 0, - V4L2_MPEG_VIDEO_BITRATE_MODE_VBR); + V4L2_CID_CODEC_VIDEO_BITRATE_MODE, + V4L2_CODEC_VIDEO_BITRATE_MODE_CBR, 0, + V4L2_CODEC_VIDEO_BITRATE_MODE_VBR); cxhdl->video_bitrate = cx2341x_ctrl_new_std(hdl, - V4L2_CID_MPEG_VIDEO_BITRATE, + V4L2_CID_CODEC_VIDEO_BITRATE, 0, 27000000, 1, 6000000); cxhdl->video_bitrate_peak = cx2341x_ctrl_new_std(hdl, - V4L2_CID_MPEG_VIDEO_BITRATE_PEAK, + V4L2_CID_CODEC_VIDEO_BITRATE_PEAK, 0, 27000000, 1, 8000000); cx2341x_ctrl_new_std(hdl, - V4L2_CID_MPEG_VIDEO_TEMPORAL_DECIMATION, 0, 255, 1, 0); + V4L2_CID_CODEC_VIDEO_TEMPORAL_DECIMATION, 0, 255, 1, 0); cxhdl->video_mute = cx2341x_ctrl_new_std(hdl, - V4L2_CID_MPEG_VIDEO_MUTE, 0, 1, 1, 0); + V4L2_CID_CODEC_VIDEO_MUTE, 0, 1, 1, 0); cxhdl->video_mute_yuv = cx2341x_ctrl_new_std(hdl, - V4L2_CID_MPEG_VIDEO_MUTE_YUV, 0, 0xffffff, 1, 0x008080); + V4L2_CID_CODEC_VIDEO_MUTE_YUV, 0, 0xffffff, 1, 0x008080); /* CX23415/6 specific */ cxhdl->video_spatial_filter_mode = cx2341x_ctrl_new_custom(hdl, - V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE, - V4L2_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE_MANUAL, - V4L2_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE_AUTO, 0, - V4L2_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE_MANUAL); + V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE, + V4L2_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE_MANUAL, + V4L2_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE_AUTO, 0, + V4L2_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE_MANUAL); cxhdl->video_spatial_filter = cx2341x_ctrl_new_custom(hdl, - V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER, + V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER, 0, 15, 1, 0); cxhdl->video_luma_spatial_filter_type = cx2341x_ctrl_new_custom(hdl, - V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE, - V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_OFF, - V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_2D_SYM_NON_SEPARABLE, + V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE, + V4L2_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_OFF, + V4L2_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_2D_SYM_NON_SEPARABLE, 0, - V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_1D_HOR); + V4L2_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_1D_HOR); cxhdl->video_chroma_spatial_filter_type = cx2341x_ctrl_new_custom(hdl, - V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE, - V4L2_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_OFF, - V4L2_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_1D_HOR, + V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE, + V4L2_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_OFF, + V4L2_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_1D_HOR, 0, - V4L2_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_1D_HOR); + V4L2_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_1D_HOR); cxhdl->video_temporal_filter_mode = cx2341x_ctrl_new_custom(hdl, - V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE, - V4L2_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_MANUAL, - V4L2_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_AUTO, + V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE, + V4L2_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_MANUAL, + V4L2_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_AUTO, 0, - V4L2_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_MANUAL); + V4L2_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_MANUAL); cxhdl->video_temporal_filter = cx2341x_ctrl_new_custom(hdl, - V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER, + V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER, 0, 31, 1, 8); cxhdl->video_median_filter_type = cx2341x_ctrl_new_custom(hdl, - V4L2_CID_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE, - V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF, - V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_DIAG, + V4L2_CID_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE, + V4L2_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF, + V4L2_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_DIAG, 0, - V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF); + V4L2_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF); cxhdl->video_luma_median_filter_bottom = cx2341x_ctrl_new_custom(hdl, - V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM, + V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM, 0, 255, 1, 0); cxhdl->video_luma_median_filter_top = cx2341x_ctrl_new_custom(hdl, - V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP, + V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP, 0, 255, 1, 255); cxhdl->video_chroma_median_filter_bottom = cx2341x_ctrl_new_custom(hdl, - V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM, + V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM, 0, 255, 1, 0); cxhdl->video_chroma_median_filter_top = cx2341x_ctrl_new_custom(hdl, - V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP, + V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP, 0, 255, 1, 255); - cx2341x_ctrl_new_custom(hdl, V4L2_CID_MPEG_CX2341X_STREAM_INSERT_NAV_PACKETS, + cx2341x_ctrl_new_custom(hdl, V4L2_CID_CODEC_CX2341X_STREAM_INSERT_NAV_PACKETS, 0, 1, 1, 0); if (hdl->error) { @@ -1752,7 +1752,7 @@ int cx2341x_handler_setup(struct cx2341x_handler *cxhdl) if (err) return err; - if (v4l2_ctrl_g_ctrl(cxhdl->video_encoding) == V4L2_MPEG_VIDEO_ENCODING_MPEG_1) { + if (v4l2_ctrl_g_ctrl(cxhdl->video_encoding) == V4L2_CODEC_VIDEO_ENCODING_MPEG_1) { w /= 2; h /= 2; } From patchwork Sat Mar 13 14:43:13 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans Verkuil X-Patchwork-Id: 400255 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-18.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER, INCLUDES_PATCH, MAILING_LIST_MULTI, SPF_HELO_NONE, SPF_PASS, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5EA51C4332B for ; Sat, 13 Mar 2021 14:44:26 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 2D25364F19 for ; Sat, 13 Mar 2021 14:44:26 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234059AbhCMOnv (ORCPT ); Sat, 13 Mar 2021 09:43:51 -0500 Received: from lb1-smtp-cloud9.xs4all.net ([194.109.24.22]:39887 "EHLO lb1-smtp-cloud9.xs4all.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234020AbhCMOn3 (ORCPT ); Sat, 13 Mar 2021 09:43:29 -0500 Received: from cust-b5b5937f ([IPv6:fc0c:c16d:66b8:757f:c639:739b:9d66:799d]) by smtp-cloud9.xs4all.net with ESMTPA id L5UBljyoWC40pL5UGlV5dP; Sat, 13 Mar 2021 15:43:28 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=xs4all.nl; s=s2; t=1615646608; bh=a748ORnM9/QTfJ2i54TMjx61l3IV0+MMa/JWC43JzhY=; h=From:To:Subject:Date:Message-Id:MIME-Version:From:Subject; b=m/4p7hFcKa9XkVRKm6R2uHcg/Zfq0qaEbqM4GVvPTZfVFIMp1rlArUX7DTc9P4+JV 6vwvI1nCLxv1Z7sSvzLVpdVLy+sL5Pg1kc3S/IMjGjH+qdjNBQ1hFxbJKabbpQ6mfK j0PelE7IUnXq8Em3zAnTACKX7VcI6wY5z0wp1V6dfC86iPp8Ob44laN4mstYGYLeu7 oB1sNZdvzm9o15n+gIzWO6Q4DOT7fmaN3oLIiCaoa/yubtCu+BiYUuNHLHSWnNq2QH LVWPOOpqM3Qy0P5zW3TP8jOHfH5x48a6aLh3v4DL/wdv32HJJQtExKXNLCjqC4tcpH 90XI1xd9GG+mg== From: Hans Verkuil To: linux-media@vger.kernel.org Cc: Ezequiel Garcia , Nicolas Dufresne , Tomasz Figa , Alexandre Courbot , Hans Verkuil Subject: [PATCH 05/15] media/i2c: rename MPEG to CODEC Date: Sat, 13 Mar 2021 15:43:13 +0100 Message-Id: <20210313144323.143600-6-hverkuil-cisco@xs4all.nl> X-Mailer: git-send-email 2.30.1 In-Reply-To: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> References: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> MIME-Version: 1.0 X-CMAE-Envelope: MS4xfLSx1V09vdOsiIy3BaNZdQmR/AETmlTZLgNQ9scdnGUt0EyBA5i0DQ6Ct0+d9egLK+97qvH87Wx78NNmwDGQSId51MO4xwmSM4nX0MFUXNzHT4mEtDo5 FedObq0D2z1LmGMi8iAH3j1/wChCPGUS+GNnSpfyMSicQMH4O6MZhu6GlpsUE6rY+K+RhwCmBIXUpWwW3CBWhGxjIlqHy1QnLG5cg1al5i+JvOMijy214ozU moQjxHrL4nUZhoDqmrKNTv/6lBm39Dvwv/3dqOs4j4iFKXyW9BmCRzEo05tIjgAoix2BCxj68IvhCYVAKve93f2bxsyXAPFPRDAcCsvJSYLNR4LRq68oCZk1 VwLXYKFU31VmWtxk87Ldo6kNGQwopg== Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Historically all codec-related data structures and defines used the MPEG prefix. This is confusing. Rename MPEG to CODEC to make it clear that the MPEG prefix isn't MPEG specific. Signed-off-by: Hans Verkuil --- drivers/media/i2c/saa6752hs.c | 144 +++++++++++++++++----------------- 1 file changed, 72 insertions(+), 72 deletions(-) diff --git a/drivers/media/i2c/saa6752hs.c b/drivers/media/i2c/saa6752hs.c index 6171ced809bb..8c4731495739 100644 --- a/drivers/media/i2c/saa6752hs.c +++ b/drivers/media/i2c/saa6752hs.c @@ -53,13 +53,13 @@ struct saa6752hs_mpeg_params { __u16 ts_pid_pcr; /* audio */ - enum v4l2_mpeg_audio_encoding au_encoding; - enum v4l2_mpeg_audio_l2_bitrate au_l2_bitrate; - enum v4l2_mpeg_audio_ac3_bitrate au_ac3_bitrate; + enum v4l2_codec_audio_encoding au_encoding; + enum v4l2_codec_audio_l2_bitrate au_l2_bitrate; + enum v4l2_codec_audio_ac3_bitrate au_ac3_bitrate; /* video */ - enum v4l2_mpeg_video_aspect vi_aspect; - enum v4l2_mpeg_video_bitrate_mode vi_bitrate_mode; + enum v4l2_codec_video_aspect vi_aspect; + enum v4l2_codec_video_bitrate_mode vi_bitrate_mode; __u32 vi_bitrate; __u32 vi_bitrate_peak; }; @@ -207,14 +207,14 @@ static const struct saa6752hs_mpeg_params param_defaults = .ts_pid_audio = 256, .ts_pid_pcr = 259, - .vi_aspect = V4L2_MPEG_VIDEO_ASPECT_4x3, + .vi_aspect = V4L2_CODEC_VIDEO_ASPECT_4x3, .vi_bitrate = 4000, .vi_bitrate_peak = 6000, - .vi_bitrate_mode = V4L2_MPEG_VIDEO_BITRATE_MODE_VBR, + .vi_bitrate_mode = V4L2_CODEC_VIDEO_BITRATE_MODE_VBR, - .au_encoding = V4L2_MPEG_AUDIO_ENCODING_LAYER_2, - .au_l2_bitrate = V4L2_MPEG_AUDIO_L2_BITRATE_256K, - .au_ac3_bitrate = V4L2_MPEG_AUDIO_AC3_BITRATE_256K, + .au_encoding = V4L2_CODEC_AUDIO_ENCODING_LAYER_2, + .au_l2_bitrate = V4L2_CODEC_AUDIO_L2_BITRATE_256K, + .au_ac3_bitrate = V4L2_CODEC_AUDIO_AC3_BITRATE_256K, }; /* ---------------------------------------------------------------------- */ @@ -314,10 +314,10 @@ static int saa6752hs_set_bitrate(struct i2c_client *client, /* set the bitrate mode */ set_reg8(client, 0x71, - params->vi_bitrate_mode != V4L2_MPEG_VIDEO_BITRATE_MODE_VBR); + params->vi_bitrate_mode != V4L2_CODEC_VIDEO_BITRATE_MODE_VBR); /* set the video bitrate */ - if (params->vi_bitrate_mode == V4L2_MPEG_VIDEO_BITRATE_MODE_VBR) { + if (params->vi_bitrate_mode == V4L2_CODEC_VIDEO_BITRATE_MODE_VBR) { /* set the target bitrate */ set_reg16(client, 0x80, params->vi_bitrate); @@ -332,13 +332,13 @@ static int saa6752hs_set_bitrate(struct i2c_client *client, /* set the audio encoding */ set_reg8(client, 0x93, - params->au_encoding == V4L2_MPEG_AUDIO_ENCODING_AC3); + params->au_encoding == V4L2_CODEC_AUDIO_ENCODING_AC3); /* set the audio bitrate */ - if (params->au_encoding == V4L2_MPEG_AUDIO_ENCODING_AC3) - is_384k = V4L2_MPEG_AUDIO_AC3_BITRATE_384K == params->au_ac3_bitrate; + if (params->au_encoding == V4L2_CODEC_AUDIO_ENCODING_AC3) + is_384k = V4L2_CODEC_AUDIO_AC3_BITRATE_384K == params->au_ac3_bitrate; else - is_384k = V4L2_MPEG_AUDIO_L2_BITRATE_384K == params->au_l2_bitrate; + is_384k = V4L2_CODEC_AUDIO_L2_BITRATE_384K == params->au_l2_bitrate; set_reg8(client, 0x94, is_384k); tot_bitrate += is_384k ? 384 : 256; @@ -361,9 +361,9 @@ static int saa6752hs_try_ctrl(struct v4l2_ctrl *ctrl) container_of(ctrl->handler, struct saa6752hs_state, hdl); switch (ctrl->id) { - case V4L2_CID_MPEG_VIDEO_BITRATE_MODE: + case V4L2_CID_CODEC_VIDEO_BITRATE_MODE: /* peak bitrate shall be >= normal bitrate */ - if (ctrl->val == V4L2_MPEG_VIDEO_BITRATE_MODE_VBR && + if (ctrl->val == V4L2_CODEC_VIDEO_BITRATE_MODE_VBR && h->video_bitrate_peak->val < h->video_bitrate->val) h->video_bitrate_peak->val = h->video_bitrate->val; break; @@ -378,42 +378,42 @@ static int saa6752hs_s_ctrl(struct v4l2_ctrl *ctrl) struct saa6752hs_mpeg_params *params = &h->params; switch (ctrl->id) { - case V4L2_CID_MPEG_STREAM_TYPE: + case V4L2_CID_CODEC_STREAM_TYPE: break; - case V4L2_CID_MPEG_STREAM_PID_PMT: + case V4L2_CID_CODEC_STREAM_PID_PMT: params->ts_pid_pmt = ctrl->val; break; - case V4L2_CID_MPEG_STREAM_PID_AUDIO: + case V4L2_CID_CODEC_STREAM_PID_AUDIO: params->ts_pid_audio = ctrl->val; break; - case V4L2_CID_MPEG_STREAM_PID_VIDEO: + case V4L2_CID_CODEC_STREAM_PID_VIDEO: params->ts_pid_video = ctrl->val; break; - case V4L2_CID_MPEG_STREAM_PID_PCR: + case V4L2_CID_CODEC_STREAM_PID_PCR: params->ts_pid_pcr = ctrl->val; break; - case V4L2_CID_MPEG_AUDIO_ENCODING: + case V4L2_CID_CODEC_AUDIO_ENCODING: params->au_encoding = ctrl->val; break; - case V4L2_CID_MPEG_AUDIO_L2_BITRATE: + case V4L2_CID_CODEC_AUDIO_L2_BITRATE: params->au_l2_bitrate = ctrl->val; break; - case V4L2_CID_MPEG_AUDIO_AC3_BITRATE: + case V4L2_CID_CODEC_AUDIO_AC3_BITRATE: params->au_ac3_bitrate = ctrl->val; break; - case V4L2_CID_MPEG_AUDIO_SAMPLING_FREQ: + case V4L2_CID_CODEC_AUDIO_SAMPLING_FREQ: break; - case V4L2_CID_MPEG_VIDEO_ENCODING: + case V4L2_CID_CODEC_VIDEO_ENCODING: break; - case V4L2_CID_MPEG_VIDEO_ASPECT: + case V4L2_CID_CODEC_VIDEO_ASPECT: params->vi_aspect = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_BITRATE_MODE: + case V4L2_CID_CODEC_VIDEO_BITRATE_MODE: params->vi_bitrate_mode = ctrl->val; params->vi_bitrate = h->video_bitrate->val / 1000; params->vi_bitrate_peak = h->video_bitrate_peak->val / 1000; v4l2_ctrl_activate(h->video_bitrate_peak, - ctrl->val == V4L2_MPEG_VIDEO_BITRATE_MODE_VBR); + ctrl->val == V4L2_CODEC_VIDEO_BITRATE_MODE_VBR); break; default: return -EINVAL; @@ -469,7 +469,7 @@ static int saa6752hs_init(struct v4l2_subdev *sd, u32 leading_null_bytes) localPAT[sizeof(PAT) - 1] = crc & 0xFF; /* compute PMT */ - if (h->params.au_encoding == V4L2_MPEG_AUDIO_ENCODING_AC3) { + if (h->params.au_encoding == V4L2_CODEC_AUDIO_ENCODING_AC3) { size = sizeof(PMT_AC3); memcpy(localPMT, PMT_AC3, size); } else { @@ -527,10 +527,10 @@ static int saa6752hs_init(struct v4l2_subdev *sd, u32 leading_null_bytes) buf[4] = 0xB0; buf[5] = buf2[0]; switch (h->params.vi_aspect) { - case V4L2_MPEG_VIDEO_ASPECT_16x9: + case V4L2_CODEC_VIDEO_ASPECT_16x9: buf[6] = buf2[1] | 0x40; break; - case V4L2_MPEG_VIDEO_ASPECT_4x3: + case V4L2_CODEC_VIDEO_ASPECT_4x3: default: buf[6] = buf2[1] & 0xBF; break; @@ -690,67 +690,67 @@ static int saa6752hs_probe(struct i2c_client *client, hdl = &h->hdl; v4l2_ctrl_handler_init(hdl, 14); v4l2_ctrl_new_std_menu(hdl, &saa6752hs_ctrl_ops, - V4L2_CID_MPEG_AUDIO_ENCODING, - h->has_ac3 ? V4L2_MPEG_AUDIO_ENCODING_AC3 : - V4L2_MPEG_AUDIO_ENCODING_LAYER_2, - 0x0d, V4L2_MPEG_AUDIO_ENCODING_LAYER_2); + V4L2_CID_CODEC_AUDIO_ENCODING, + h->has_ac3 ? V4L2_CODEC_AUDIO_ENCODING_AC3 : + V4L2_CODEC_AUDIO_ENCODING_LAYER_2, + 0x0d, V4L2_CODEC_AUDIO_ENCODING_LAYER_2); v4l2_ctrl_new_std_menu(hdl, &saa6752hs_ctrl_ops, - V4L2_CID_MPEG_AUDIO_L2_BITRATE, - V4L2_MPEG_AUDIO_L2_BITRATE_384K, - ~((1 << V4L2_MPEG_AUDIO_L2_BITRATE_256K) | - (1 << V4L2_MPEG_AUDIO_L2_BITRATE_384K)), - V4L2_MPEG_AUDIO_L2_BITRATE_256K); + V4L2_CID_CODEC_AUDIO_L2_BITRATE, + V4L2_CODEC_AUDIO_L2_BITRATE_384K, + ~((1 << V4L2_CODEC_AUDIO_L2_BITRATE_256K) | + (1 << V4L2_CODEC_AUDIO_L2_BITRATE_384K)), + V4L2_CODEC_AUDIO_L2_BITRATE_256K); if (h->has_ac3) v4l2_ctrl_new_std_menu(hdl, &saa6752hs_ctrl_ops, - V4L2_CID_MPEG_AUDIO_AC3_BITRATE, - V4L2_MPEG_AUDIO_AC3_BITRATE_384K, - ~((1 << V4L2_MPEG_AUDIO_AC3_BITRATE_256K) | - (1 << V4L2_MPEG_AUDIO_AC3_BITRATE_384K)), - V4L2_MPEG_AUDIO_AC3_BITRATE_256K); + V4L2_CID_CODEC_AUDIO_AC3_BITRATE, + V4L2_CODEC_AUDIO_AC3_BITRATE_384K, + ~((1 << V4L2_CODEC_AUDIO_AC3_BITRATE_256K) | + (1 << V4L2_CODEC_AUDIO_AC3_BITRATE_384K)), + V4L2_CODEC_AUDIO_AC3_BITRATE_256K); v4l2_ctrl_new_std_menu(hdl, &saa6752hs_ctrl_ops, - V4L2_CID_MPEG_AUDIO_SAMPLING_FREQ, - V4L2_MPEG_AUDIO_SAMPLING_FREQ_48000, - ~(1 << V4L2_MPEG_AUDIO_SAMPLING_FREQ_48000), - V4L2_MPEG_AUDIO_SAMPLING_FREQ_48000); + V4L2_CID_CODEC_AUDIO_SAMPLING_FREQ, + V4L2_CODEC_AUDIO_SAMPLING_FREQ_48000, + ~(1 << V4L2_CODEC_AUDIO_SAMPLING_FREQ_48000), + V4L2_CODEC_AUDIO_SAMPLING_FREQ_48000); v4l2_ctrl_new_std_menu(hdl, &saa6752hs_ctrl_ops, - V4L2_CID_MPEG_VIDEO_ENCODING, - V4L2_MPEG_VIDEO_ENCODING_MPEG_2, - ~(1 << V4L2_MPEG_VIDEO_ENCODING_MPEG_2), - V4L2_MPEG_VIDEO_ENCODING_MPEG_2); + V4L2_CID_CODEC_VIDEO_ENCODING, + V4L2_CODEC_VIDEO_ENCODING_MPEG_2, + ~(1 << V4L2_CODEC_VIDEO_ENCODING_MPEG_2), + V4L2_CODEC_VIDEO_ENCODING_MPEG_2); v4l2_ctrl_new_std_menu(hdl, &saa6752hs_ctrl_ops, - V4L2_CID_MPEG_VIDEO_ASPECT, - V4L2_MPEG_VIDEO_ASPECT_16x9, 0x01, - V4L2_MPEG_VIDEO_ASPECT_4x3); + V4L2_CID_CODEC_VIDEO_ASPECT, + V4L2_CODEC_VIDEO_ASPECT_16x9, 0x01, + V4L2_CODEC_VIDEO_ASPECT_4x3); h->video_bitrate_peak = v4l2_ctrl_new_std(hdl, &saa6752hs_ctrl_ops, - V4L2_CID_MPEG_VIDEO_BITRATE_PEAK, + V4L2_CID_CODEC_VIDEO_BITRATE_PEAK, 1000000, 27000000, 1000, 8000000); v4l2_ctrl_new_std_menu(hdl, &saa6752hs_ctrl_ops, - V4L2_CID_MPEG_STREAM_TYPE, - V4L2_MPEG_STREAM_TYPE_MPEG2_TS, - ~(1 << V4L2_MPEG_STREAM_TYPE_MPEG2_TS), - V4L2_MPEG_STREAM_TYPE_MPEG2_TS); + V4L2_CID_CODEC_STREAM_TYPE, + V4L2_CODEC_STREAM_TYPE_MPEG2_TS, + ~(1 << V4L2_CODEC_STREAM_TYPE_MPEG2_TS), + V4L2_CODEC_STREAM_TYPE_MPEG2_TS); h->video_bitrate_mode = v4l2_ctrl_new_std_menu(hdl, &saa6752hs_ctrl_ops, - V4L2_CID_MPEG_VIDEO_BITRATE_MODE, - V4L2_MPEG_VIDEO_BITRATE_MODE_CBR, 0, - V4L2_MPEG_VIDEO_BITRATE_MODE_VBR); + V4L2_CID_CODEC_VIDEO_BITRATE_MODE, + V4L2_CODEC_VIDEO_BITRATE_MODE_CBR, 0, + V4L2_CODEC_VIDEO_BITRATE_MODE_VBR); h->video_bitrate = v4l2_ctrl_new_std(hdl, &saa6752hs_ctrl_ops, - V4L2_CID_MPEG_VIDEO_BITRATE, 1000000, 27000000, 1000, 6000000); + V4L2_CID_CODEC_VIDEO_BITRATE, 1000000, 27000000, 1000, 6000000); v4l2_ctrl_new_std(hdl, &saa6752hs_ctrl_ops, - V4L2_CID_MPEG_STREAM_PID_PMT, 0, (1 << 14) - 1, 1, 16); + V4L2_CID_CODEC_STREAM_PID_PMT, 0, (1 << 14) - 1, 1, 16); v4l2_ctrl_new_std(hdl, &saa6752hs_ctrl_ops, - V4L2_CID_MPEG_STREAM_PID_AUDIO, 0, (1 << 14) - 1, 1, 260); + V4L2_CID_CODEC_STREAM_PID_AUDIO, 0, (1 << 14) - 1, 1, 260); v4l2_ctrl_new_std(hdl, &saa6752hs_ctrl_ops, - V4L2_CID_MPEG_STREAM_PID_VIDEO, 0, (1 << 14) - 1, 1, 256); + V4L2_CID_CODEC_STREAM_PID_VIDEO, 0, (1 << 14) - 1, 1, 256); v4l2_ctrl_new_std(hdl, &saa6752hs_ctrl_ops, - V4L2_CID_MPEG_STREAM_PID_PCR, 0, (1 << 14) - 1, 1, 259); + V4L2_CID_CODEC_STREAM_PID_PCR, 0, (1 << 14) - 1, 1, 259); sd->ctrl_handler = hdl; if (hdl->error) { int err = hdl->error; From patchwork Sat Mar 13 14:43:14 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans Verkuil X-Patchwork-Id: 400250 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-18.7 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER, INCLUDES_PATCH, MAILING_LIST_MULTI, SPF_HELO_NONE, SPF_PASS, UPPERCASE_50_75, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0CAB1C4321A for ; Sat, 13 Mar 2021 14:44:27 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id EB26064F2A for ; Sat, 13 Mar 2021 14:44:26 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234070AbhCMOnw (ORCPT ); Sat, 13 Mar 2021 09:43:52 -0500 Received: from lb1-smtp-cloud9.xs4all.net ([194.109.24.22]:38955 "EHLO lb1-smtp-cloud9.xs4all.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234028AbhCMOna (ORCPT ); Sat, 13 Mar 2021 09:43:30 -0500 Received: from cust-b5b5937f ([IPv6:fc0c:c16d:66b8:757f:c639:739b:9d66:799d]) by smtp-cloud9.xs4all.net with ESMTPA id L5UBljyoWC40pL5UGlV5de; Sat, 13 Mar 2021 15:43:29 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=xs4all.nl; s=s2; t=1615646609; bh=X67Pp9EBvQGjLRQjuUmeI/5BUyi0LEGUEfAn5dV5FaU=; h=From:To:Subject:Date:Message-Id:MIME-Version:From:Subject; b=eoQKxbnN6BBYjNLU7aYqtGHKNccZt4xigDf05tY/UgaH6FYcsqiNTZXRZDfZwiDVi uIEn1/VvdlqtBskJpF9AqDubU9d7S+bOqG+BEmhnIIVJkL/irKIYuuYvTrDfrJnePR k8kx6yZjtfPgn3zcSci0dnHIDrBt/AmbXP0rVW7URbtVyvXbx7DmgAl87OnKo/OsP+ 6/vSYGuvXpmZp32lQNX53jPJ0L7dZqSbjDwmOuJByI8IuOjmVRR7/v/VRrDBY6gEYq jx2+gbebx9rymCmv11MGwr9RWAly8HfGIQqQBGpY3Acn8yYSAN/INzWfn2UALA3Wxj 0VvtVDvDEioWg== From: Hans Verkuil To: linux-media@vger.kernel.org Cc: Ezequiel Garcia , Nicolas Dufresne , Tomasz Figa , Alexandre Courbot , Hans Verkuil Subject: [PATCH 06/15] media/v4l2-core: rename MPEG to CODEC Date: Sat, 13 Mar 2021 15:43:14 +0100 Message-Id: <20210313144323.143600-7-hverkuil-cisco@xs4all.nl> X-Mailer: git-send-email 2.30.1 In-Reply-To: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> References: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> MIME-Version: 1.0 X-CMAE-Envelope: MS4xfHB20MmtF5ZcYetgXeMEMm916KOLGm4CPZp4loUBMb4p735IcJ67kybPCw6oLhk36CkLiIbYkSy/XTsGdBZMReFwjEZwC922p9K7bU4wslAFdYlR5M7M dSkvAl5oCD5Eps37hYkSc/INvgFdyL4ayp75pW0RWxRN/Z/GeWD0y44I5Z6D3gjTM1DNgK8JVcV1YCXHdjsBOf8B04vYoJ0zC1OJxDZyC37ES+VumK3BGuT/ ltuj5UhuoVVT+uDCgWcfNEMHd0uyQkpT4M6455DHwYFyIuqnsgELwMnEsa2IXyDbrGlTq7uUo+FzIbApU+9/N4hUTW8pPXf5/TpnS5hxCbmTwr1qpBizIMEK jFUhB5vxbxvJ6+r+NOgJr8jCvLWy1g== Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Historically all codec-related data structures and defines used the MPEG prefix. This is confusing. Rename MPEG to CODEC to make it clear that the MPEG prefix isn't MPEG specific. Signed-off-by: Hans Verkuil --- drivers/media/v4l2-core/v4l2-ctrls.c | 640 +++++++++++++-------------- 1 file changed, 320 insertions(+), 320 deletions(-) diff --git a/drivers/media/v4l2-core/v4l2-ctrls.c b/drivers/media/v4l2-core/v4l2-ctrls.c index 016cf6204cbb..0ec174a74346 100644 --- a/drivers/media/v4l2-core/v4l2-ctrls.c +++ b/drivers/media/v4l2-core/v4l2-ctrls.c @@ -616,38 +616,38 @@ const char * const *v4l2_ctrl_get_menu(u32 id) }; switch (id) { - case V4L2_CID_MPEG_AUDIO_SAMPLING_FREQ: + case V4L2_CID_CODEC_AUDIO_SAMPLING_FREQ: return mpeg_audio_sampling_freq; - case V4L2_CID_MPEG_AUDIO_ENCODING: + case V4L2_CID_CODEC_AUDIO_ENCODING: return mpeg_audio_encoding; - case V4L2_CID_MPEG_AUDIO_L1_BITRATE: + case V4L2_CID_CODEC_AUDIO_L1_BITRATE: return mpeg_audio_l1_bitrate; - case V4L2_CID_MPEG_AUDIO_L2_BITRATE: + case V4L2_CID_CODEC_AUDIO_L2_BITRATE: return mpeg_audio_l2_bitrate; - case V4L2_CID_MPEG_AUDIO_L3_BITRATE: + case V4L2_CID_CODEC_AUDIO_L3_BITRATE: return mpeg_audio_l3_bitrate; - case V4L2_CID_MPEG_AUDIO_AC3_BITRATE: + case V4L2_CID_CODEC_AUDIO_AC3_BITRATE: return mpeg_audio_ac3_bitrate; - case V4L2_CID_MPEG_AUDIO_MODE: + case V4L2_CID_CODEC_AUDIO_MODE: return mpeg_audio_mode; - case V4L2_CID_MPEG_AUDIO_MODE_EXTENSION: + case V4L2_CID_CODEC_AUDIO_MODE_EXTENSION: return mpeg_audio_mode_extension; - case V4L2_CID_MPEG_AUDIO_EMPHASIS: + case V4L2_CID_CODEC_AUDIO_EMPHASIS: return mpeg_audio_emphasis; - case V4L2_CID_MPEG_AUDIO_CRC: + case V4L2_CID_CODEC_AUDIO_CRC: return mpeg_audio_crc; - case V4L2_CID_MPEG_AUDIO_DEC_PLAYBACK: - case V4L2_CID_MPEG_AUDIO_DEC_MULTILINGUAL_PLAYBACK: + case V4L2_CID_CODEC_AUDIO_DEC_PLAYBACK: + case V4L2_CID_CODEC_AUDIO_DEC_MULTILINGUAL_PLAYBACK: return mpeg_audio_dec_playback; - case V4L2_CID_MPEG_VIDEO_ENCODING: + case V4L2_CID_CODEC_VIDEO_ENCODING: return mpeg_video_encoding; - case V4L2_CID_MPEG_VIDEO_ASPECT: + case V4L2_CID_CODEC_VIDEO_ASPECT: return mpeg_video_aspect; - case V4L2_CID_MPEG_VIDEO_BITRATE_MODE: + case V4L2_CID_CODEC_VIDEO_BITRATE_MODE: return mpeg_video_bitrate_mode; - case V4L2_CID_MPEG_STREAM_TYPE: + case V4L2_CID_CODEC_STREAM_TYPE: return mpeg_stream_type; - case V4L2_CID_MPEG_STREAM_VBI_FMT: + case V4L2_CID_CODEC_STREAM_VBI_FMT: return mpeg_stream_vbi_fmt; case V4L2_CID_POWER_LINE_FREQUENCY: return camera_power_line_frequency; @@ -673,45 +673,45 @@ const char * const *v4l2_ctrl_get_menu(u32 id) return flash_led_mode; case V4L2_CID_FLASH_STROBE_SOURCE: return flash_strobe_source; - case V4L2_CID_MPEG_VIDEO_HEADER_MODE: + case V4L2_CID_CODEC_VIDEO_HEADER_MODE: return header_mode; - case V4L2_CID_MPEG_VIDEO_FRAME_SKIP_MODE: + case V4L2_CID_CODEC_VIDEO_FRAME_SKIP_MODE: return mpeg_video_frame_skip; - case V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MODE: + case V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MODE: return multi_slice; - case V4L2_CID_MPEG_VIDEO_H264_ENTROPY_MODE: + case V4L2_CID_CODEC_VIDEO_H264_ENTROPY_MODE: return entropy_mode; - case V4L2_CID_MPEG_VIDEO_H264_LEVEL: + case V4L2_CID_CODEC_VIDEO_H264_LEVEL: return mpeg_h264_level; - case V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_MODE: + case V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_MODE: return h264_loop_filter; - case V4L2_CID_MPEG_VIDEO_H264_PROFILE: + case V4L2_CID_CODEC_VIDEO_H264_PROFILE: return h264_profile; - case V4L2_CID_MPEG_VIDEO_H264_VUI_SAR_IDC: + case V4L2_CID_CODEC_VIDEO_H264_VUI_SAR_IDC: return vui_sar_idc; - case V4L2_CID_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE: + case V4L2_CID_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE: return h264_fp_arrangement_type; - case V4L2_CID_MPEG_VIDEO_H264_FMO_MAP_TYPE: + case V4L2_CID_CODEC_VIDEO_H264_FMO_MAP_TYPE: return h264_fmo_map_type; case V4L2_CID_STATELESS_H264_DECODE_MODE: return h264_decode_mode; case V4L2_CID_STATELESS_H264_START_CODE: return h264_start_code; - case V4L2_CID_MPEG_VIDEO_MPEG2_LEVEL: + case V4L2_CID_CODEC_VIDEO_MPEG2_LEVEL: return mpeg_mpeg2_level; - case V4L2_CID_MPEG_VIDEO_MPEG2_PROFILE: + case V4L2_CID_CODEC_VIDEO_MPEG2_PROFILE: return mpeg2_profile; - case V4L2_CID_MPEG_VIDEO_MPEG4_LEVEL: + case V4L2_CID_CODEC_VIDEO_MPEG4_LEVEL: return mpeg_mpeg4_level; - case V4L2_CID_MPEG_VIDEO_MPEG4_PROFILE: + case V4L2_CID_CODEC_VIDEO_MPEG4_PROFILE: return mpeg4_profile; - case V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_SEL: + case V4L2_CID_CODEC_VIDEO_VPX_GOLDEN_FRAME_SEL: return vpx_golden_frame_sel; - case V4L2_CID_MPEG_VIDEO_VP8_PROFILE: + case V4L2_CID_CODEC_VIDEO_VP8_PROFILE: return vp8_profile; - case V4L2_CID_MPEG_VIDEO_VP9_PROFILE: + case V4L2_CID_CODEC_VIDEO_VP9_PROFILE: return vp9_profile; - case V4L2_CID_MPEG_VIDEO_VP9_LEVEL: + case V4L2_CID_CODEC_VIDEO_VP9_LEVEL: return vp9_level; case V4L2_CID_JPEG_CHROMA_SUBSAMPLING: return jpeg_chroma_subsampling; @@ -725,23 +725,23 @@ const char * const *v4l2_ctrl_get_menu(u32 id) return dv_it_content_type; case V4L2_CID_DETECT_MD_MODE: return detect_md_mode; - case V4L2_CID_MPEG_VIDEO_HEVC_PROFILE: + case V4L2_CID_CODEC_VIDEO_HEVC_PROFILE: return hevc_profile; - case V4L2_CID_MPEG_VIDEO_HEVC_LEVEL: + case V4L2_CID_CODEC_VIDEO_HEVC_LEVEL: return hevc_level; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_TYPE: + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_TYPE: return hevc_hierarchial_coding_type; - case V4L2_CID_MPEG_VIDEO_HEVC_REFRESH_TYPE: + case V4L2_CID_CODEC_VIDEO_HEVC_REFRESH_TYPE: return hevc_refresh_type; - case V4L2_CID_MPEG_VIDEO_HEVC_SIZE_OF_LENGTH_FIELD: + case V4L2_CID_CODEC_VIDEO_HEVC_SIZE_OF_LENGTH_FIELD: return hevc_size_of_length_field; - case V4L2_CID_MPEG_VIDEO_HEVC_TIER: + case V4L2_CID_CODEC_VIDEO_HEVC_TIER: return hevc_tier; - case V4L2_CID_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE: + case V4L2_CID_CODEC_VIDEO_HEVC_LOOP_FILTER_MODE: return hevc_loop_filter_mode; - case V4L2_CID_MPEG_VIDEO_HEVC_DECODE_MODE: + case V4L2_CID_CODEC_VIDEO_HEVC_DECODE_MODE: return hevc_decode_mode; - case V4L2_CID_MPEG_VIDEO_HEVC_START_CODE: + case V4L2_CID_CODEC_VIDEO_HEVC_START_CODE: return hevc_start_code; case V4L2_CID_CAMERA_ORIENTATION: return camera_orientation; @@ -767,9 +767,9 @@ const s64 *v4l2_ctrl_get_int_menu(u32 id, u32 *len) }; switch (id) { - case V4L2_CID_MPEG_VIDEO_VPX_NUM_PARTITIONS: + case V4L2_CID_CODEC_VIDEO_VPX_NUM_PARTITIONS: return __v4l2_qmenu_int_len(qmenu_int_vpx_num_partitions, len); - case V4L2_CID_MPEG_VIDEO_VPX_NUM_REF_FRAMES: + case V4L2_CID_CODEC_VIDEO_VPX_NUM_REF_FRAMES: return __v4l2_qmenu_int_len(qmenu_int_vpx_num_ref_frames, len); default: *len = 0; @@ -831,205 +831,205 @@ const char *v4l2_ctrl_get_name(u32 id) * and the 'MPEG' part of the define is historical */ /* Keep the order of the 'case's the same as in videodev2.h! */ case V4L2_CID_CODEC_CLASS: return "Codec Controls"; - case V4L2_CID_MPEG_STREAM_TYPE: return "Stream Type"; - case V4L2_CID_MPEG_STREAM_PID_PMT: return "Stream PMT Program ID"; - case V4L2_CID_MPEG_STREAM_PID_AUDIO: return "Stream Audio Program ID"; - case V4L2_CID_MPEG_STREAM_PID_VIDEO: return "Stream Video Program ID"; - case V4L2_CID_MPEG_STREAM_PID_PCR: return "Stream PCR Program ID"; - case V4L2_CID_MPEG_STREAM_PES_ID_AUDIO: return "Stream PES Audio ID"; - case V4L2_CID_MPEG_STREAM_PES_ID_VIDEO: return "Stream PES Video ID"; - case V4L2_CID_MPEG_STREAM_VBI_FMT: return "Stream VBI Format"; - case V4L2_CID_MPEG_AUDIO_SAMPLING_FREQ: return "Audio Sampling Frequency"; - case V4L2_CID_MPEG_AUDIO_ENCODING: return "Audio Encoding"; - case V4L2_CID_MPEG_AUDIO_L1_BITRATE: return "Audio Layer I Bitrate"; - case V4L2_CID_MPEG_AUDIO_L2_BITRATE: return "Audio Layer II Bitrate"; - case V4L2_CID_MPEG_AUDIO_L3_BITRATE: return "Audio Layer III Bitrate"; - case V4L2_CID_MPEG_AUDIO_MODE: return "Audio Stereo Mode"; - case V4L2_CID_MPEG_AUDIO_MODE_EXTENSION: return "Audio Stereo Mode Extension"; - case V4L2_CID_MPEG_AUDIO_EMPHASIS: return "Audio Emphasis"; - case V4L2_CID_MPEG_AUDIO_CRC: return "Audio CRC"; - case V4L2_CID_MPEG_AUDIO_MUTE: return "Audio Mute"; - case V4L2_CID_MPEG_AUDIO_AAC_BITRATE: return "Audio AAC Bitrate"; - case V4L2_CID_MPEG_AUDIO_AC3_BITRATE: return "Audio AC-3 Bitrate"; - case V4L2_CID_MPEG_AUDIO_DEC_PLAYBACK: return "Audio Playback"; - case V4L2_CID_MPEG_AUDIO_DEC_MULTILINGUAL_PLAYBACK: return "Audio Multilingual Playback"; - case V4L2_CID_MPEG_VIDEO_ENCODING: return "Video Encoding"; - case V4L2_CID_MPEG_VIDEO_ASPECT: return "Video Aspect"; - case V4L2_CID_MPEG_VIDEO_B_FRAMES: return "Video B Frames"; - case V4L2_CID_MPEG_VIDEO_GOP_SIZE: return "Video GOP Size"; - case V4L2_CID_MPEG_VIDEO_GOP_CLOSURE: return "Video GOP Closure"; - case V4L2_CID_MPEG_VIDEO_PULLDOWN: return "Video Pulldown"; - case V4L2_CID_MPEG_VIDEO_BITRATE_MODE: return "Video Bitrate Mode"; - case V4L2_CID_MPEG_VIDEO_CONSTANT_QUALITY: return "Constant Quality"; - case V4L2_CID_MPEG_VIDEO_BITRATE: return "Video Bitrate"; - case V4L2_CID_MPEG_VIDEO_BITRATE_PEAK: return "Video Peak Bitrate"; - case V4L2_CID_MPEG_VIDEO_TEMPORAL_DECIMATION: return "Video Temporal Decimation"; - case V4L2_CID_MPEG_VIDEO_MUTE: return "Video Mute"; - case V4L2_CID_MPEG_VIDEO_MUTE_YUV: return "Video Mute YUV"; - case V4L2_CID_MPEG_VIDEO_DECODER_SLICE_INTERFACE: return "Decoder Slice Interface"; - case V4L2_CID_MPEG_VIDEO_DECODER_MPEG4_DEBLOCK_FILTER: return "MPEG4 Loop Filter Enable"; - case V4L2_CID_MPEG_VIDEO_CYCLIC_INTRA_REFRESH_MB: return "Number of Intra Refresh MBs"; - case V4L2_CID_MPEG_VIDEO_FRAME_RC_ENABLE: return "Frame Level Rate Control Enable"; - case V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE: return "H264 MB Level Rate Control"; - case V4L2_CID_MPEG_VIDEO_HEADER_MODE: return "Sequence Header Mode"; - case V4L2_CID_MPEG_VIDEO_MAX_REF_PIC: return "Max Number of Reference Pics"; - case V4L2_CID_MPEG_VIDEO_FRAME_SKIP_MODE: return "Frame Skip Mode"; - case V4L2_CID_MPEG_VIDEO_H263_I_FRAME_QP: return "H263 I-Frame QP Value"; - case V4L2_CID_MPEG_VIDEO_H263_P_FRAME_QP: return "H263 P-Frame QP Value"; - case V4L2_CID_MPEG_VIDEO_H263_B_FRAME_QP: return "H263 B-Frame QP Value"; - case V4L2_CID_MPEG_VIDEO_H263_MIN_QP: return "H263 Minimum QP Value"; - case V4L2_CID_MPEG_VIDEO_H263_MAX_QP: return "H263 Maximum QP Value"; - case V4L2_CID_MPEG_VIDEO_H264_I_FRAME_QP: return "H264 I-Frame QP Value"; - case V4L2_CID_MPEG_VIDEO_H264_P_FRAME_QP: return "H264 P-Frame QP Value"; - case V4L2_CID_MPEG_VIDEO_H264_B_FRAME_QP: return "H264 B-Frame QP Value"; - case V4L2_CID_MPEG_VIDEO_H264_MAX_QP: return "H264 Maximum QP Value"; - case V4L2_CID_MPEG_VIDEO_H264_MIN_QP: return "H264 Minimum QP Value"; - case V4L2_CID_MPEG_VIDEO_H264_8X8_TRANSFORM: return "H264 8x8 Transform Enable"; - case V4L2_CID_MPEG_VIDEO_H264_CPB_SIZE: return "H264 CPB Buffer Size"; - case V4L2_CID_MPEG_VIDEO_H264_ENTROPY_MODE: return "H264 Entropy Mode"; - case V4L2_CID_MPEG_VIDEO_H264_I_PERIOD: return "H264 I-Frame Period"; - case V4L2_CID_MPEG_VIDEO_H264_LEVEL: return "H264 Level"; - case V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_ALPHA: return "H264 Loop Filter Alpha Offset"; - case V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_BETA: return "H264 Loop Filter Beta Offset"; - case V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_MODE: return "H264 Loop Filter Mode"; - case V4L2_CID_MPEG_VIDEO_H264_PROFILE: return "H264 Profile"; - case V4L2_CID_MPEG_VIDEO_H264_VUI_EXT_SAR_HEIGHT: return "Vertical Size of SAR"; - case V4L2_CID_MPEG_VIDEO_H264_VUI_EXT_SAR_WIDTH: return "Horizontal Size of SAR"; - case V4L2_CID_MPEG_VIDEO_H264_VUI_SAR_ENABLE: return "Aspect Ratio VUI Enable"; - case V4L2_CID_MPEG_VIDEO_H264_VUI_SAR_IDC: return "VUI Aspect Ratio IDC"; - case V4L2_CID_MPEG_VIDEO_H264_SEI_FRAME_PACKING: return "H264 Enable Frame Packing SEI"; - case V4L2_CID_MPEG_VIDEO_H264_SEI_FP_CURRENT_FRAME_0: return "H264 Set Curr. Frame as Frame0"; - case V4L2_CID_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE: return "H264 FP Arrangement Type"; - case V4L2_CID_MPEG_VIDEO_H264_FMO: return "H264 Flexible MB Ordering"; - case V4L2_CID_MPEG_VIDEO_H264_FMO_MAP_TYPE: return "H264 Map Type for FMO"; - case V4L2_CID_MPEG_VIDEO_H264_FMO_SLICE_GROUP: return "H264 FMO Number of Slice Groups"; - case V4L2_CID_MPEG_VIDEO_H264_FMO_CHANGE_DIRECTION: return "H264 FMO Direction of Change"; - case V4L2_CID_MPEG_VIDEO_H264_FMO_CHANGE_RATE: return "H264 FMO Size of 1st Slice Grp"; - case V4L2_CID_MPEG_VIDEO_H264_FMO_RUN_LENGTH: return "H264 FMO No. of Consecutive MBs"; - case V4L2_CID_MPEG_VIDEO_H264_ASO: return "H264 Arbitrary Slice Ordering"; - case V4L2_CID_MPEG_VIDEO_H264_ASO_SLICE_ORDER: return "H264 ASO Slice Order"; - case V4L2_CID_MPEG_VIDEO_H264_HIERARCHICAL_CODING: return "Enable H264 Hierarchical Coding"; - case V4L2_CID_MPEG_VIDEO_H264_HIERARCHICAL_CODING_TYPE: return "H264 Hierarchical Coding Type"; - case V4L2_CID_MPEG_VIDEO_H264_HIERARCHICAL_CODING_LAYER:return "H264 Number of HC Layers"; - case V4L2_CID_MPEG_VIDEO_H264_HIERARCHICAL_CODING_LAYER_QP: + case V4L2_CID_CODEC_STREAM_TYPE: return "Stream Type"; + case V4L2_CID_CODEC_STREAM_PID_PMT: return "Stream PMT Program ID"; + case V4L2_CID_CODEC_STREAM_PID_AUDIO: return "Stream Audio Program ID"; + case V4L2_CID_CODEC_STREAM_PID_VIDEO: return "Stream Video Program ID"; + case V4L2_CID_CODEC_STREAM_PID_PCR: return "Stream PCR Program ID"; + case V4L2_CID_CODEC_STREAM_PES_ID_AUDIO: return "Stream PES Audio ID"; + case V4L2_CID_CODEC_STREAM_PES_ID_VIDEO: return "Stream PES Video ID"; + case V4L2_CID_CODEC_STREAM_VBI_FMT: return "Stream VBI Format"; + case V4L2_CID_CODEC_AUDIO_SAMPLING_FREQ: return "Audio Sampling Frequency"; + case V4L2_CID_CODEC_AUDIO_ENCODING: return "Audio Encoding"; + case V4L2_CID_CODEC_AUDIO_L1_BITRATE: return "Audio Layer I Bitrate"; + case V4L2_CID_CODEC_AUDIO_L2_BITRATE: return "Audio Layer II Bitrate"; + case V4L2_CID_CODEC_AUDIO_L3_BITRATE: return "Audio Layer III Bitrate"; + case V4L2_CID_CODEC_AUDIO_MODE: return "Audio Stereo Mode"; + case V4L2_CID_CODEC_AUDIO_MODE_EXTENSION: return "Audio Stereo Mode Extension"; + case V4L2_CID_CODEC_AUDIO_EMPHASIS: return "Audio Emphasis"; + case V4L2_CID_CODEC_AUDIO_CRC: return "Audio CRC"; + case V4L2_CID_CODEC_AUDIO_MUTE: return "Audio Mute"; + case V4L2_CID_CODEC_AUDIO_AAC_BITRATE: return "Audio AAC Bitrate"; + case V4L2_CID_CODEC_AUDIO_AC3_BITRATE: return "Audio AC-3 Bitrate"; + case V4L2_CID_CODEC_AUDIO_DEC_PLAYBACK: return "Audio Playback"; + case V4L2_CID_CODEC_AUDIO_DEC_MULTILINGUAL_PLAYBACK: return "Audio Multilingual Playback"; + case V4L2_CID_CODEC_VIDEO_ENCODING: return "Video Encoding"; + case V4L2_CID_CODEC_VIDEO_ASPECT: return "Video Aspect"; + case V4L2_CID_CODEC_VIDEO_B_FRAMES: return "Video B Frames"; + case V4L2_CID_CODEC_VIDEO_GOP_SIZE: return "Video GOP Size"; + case V4L2_CID_CODEC_VIDEO_GOP_CLOSURE: return "Video GOP Closure"; + case V4L2_CID_CODEC_VIDEO_PULLDOWN: return "Video Pulldown"; + case V4L2_CID_CODEC_VIDEO_BITRATE_MODE: return "Video Bitrate Mode"; + case V4L2_CID_CODEC_VIDEO_CONSTANT_QUALITY: return "Constant Quality"; + case V4L2_CID_CODEC_VIDEO_BITRATE: return "Video Bitrate"; + case V4L2_CID_CODEC_VIDEO_BITRATE_PEAK: return "Video Peak Bitrate"; + case V4L2_CID_CODEC_VIDEO_TEMPORAL_DECIMATION: return "Video Temporal Decimation"; + case V4L2_CID_CODEC_VIDEO_MUTE: return "Video Mute"; + case V4L2_CID_CODEC_VIDEO_MUTE_YUV: return "Video Mute YUV"; + case V4L2_CID_CODEC_VIDEO_DECODER_SLICE_INTERFACE: return "Decoder Slice Interface"; + case V4L2_CID_CODEC_VIDEO_DECODER_MPEG4_DEBLOCK_FILTER: return "MPEG4 Loop Filter Enable"; + case V4L2_CID_CODEC_VIDEO_CYCLIC_INTRA_REFRESH_MB: return "Number of Intra Refresh MBs"; + case V4L2_CID_CODEC_VIDEO_FRAME_RC_ENABLE: return "Frame Level Rate Control Enable"; + case V4L2_CID_CODEC_VIDEO_MB_RC_ENABLE: return "H264 MB Level Rate Control"; + case V4L2_CID_CODEC_VIDEO_HEADER_MODE: return "Sequence Header Mode"; + case V4L2_CID_CODEC_VIDEO_MAX_REF_PIC: return "Max Number of Reference Pics"; + case V4L2_CID_CODEC_VIDEO_FRAME_SKIP_MODE: return "Frame Skip Mode"; + case V4L2_CID_CODEC_VIDEO_H263_I_FRAME_QP: return "H263 I-Frame QP Value"; + case V4L2_CID_CODEC_VIDEO_H263_P_FRAME_QP: return "H263 P-Frame QP Value"; + case V4L2_CID_CODEC_VIDEO_H263_B_FRAME_QP: return "H263 B-Frame QP Value"; + case V4L2_CID_CODEC_VIDEO_H263_MIN_QP: return "H263 Minimum QP Value"; + case V4L2_CID_CODEC_VIDEO_H263_MAX_QP: return "H263 Maximum QP Value"; + case V4L2_CID_CODEC_VIDEO_H264_I_FRAME_QP: return "H264 I-Frame QP Value"; + case V4L2_CID_CODEC_VIDEO_H264_P_FRAME_QP: return "H264 P-Frame QP Value"; + case V4L2_CID_CODEC_VIDEO_H264_B_FRAME_QP: return "H264 B-Frame QP Value"; + case V4L2_CID_CODEC_VIDEO_H264_MAX_QP: return "H264 Maximum QP Value"; + case V4L2_CID_CODEC_VIDEO_H264_MIN_QP: return "H264 Minimum QP Value"; + case V4L2_CID_CODEC_VIDEO_H264_8X8_TRANSFORM: return "H264 8x8 Transform Enable"; + case V4L2_CID_CODEC_VIDEO_H264_CPB_SIZE: return "H264 CPB Buffer Size"; + case V4L2_CID_CODEC_VIDEO_H264_ENTROPY_MODE: return "H264 Entropy Mode"; + case V4L2_CID_CODEC_VIDEO_H264_I_PERIOD: return "H264 I-Frame Period"; + case V4L2_CID_CODEC_VIDEO_H264_LEVEL: return "H264 Level"; + case V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_ALPHA: return "H264 Loop Filter Alpha Offset"; + case V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_BETA: return "H264 Loop Filter Beta Offset"; + case V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_MODE: return "H264 Loop Filter Mode"; + case V4L2_CID_CODEC_VIDEO_H264_PROFILE: return "H264 Profile"; + case V4L2_CID_CODEC_VIDEO_H264_VUI_EXT_SAR_HEIGHT: return "Vertical Size of SAR"; + case V4L2_CID_CODEC_VIDEO_H264_VUI_EXT_SAR_WIDTH: return "Horizontal Size of SAR"; + case V4L2_CID_CODEC_VIDEO_H264_VUI_SAR_ENABLE: return "Aspect Ratio VUI Enable"; + case V4L2_CID_CODEC_VIDEO_H264_VUI_SAR_IDC: return "VUI Aspect Ratio IDC"; + case V4L2_CID_CODEC_VIDEO_H264_SEI_FRAME_PACKING: return "H264 Enable Frame Packing SEI"; + case V4L2_CID_CODEC_VIDEO_H264_SEI_FP_CURRENT_FRAME_0: return "H264 Set Curr. Frame as Frame0"; + case V4L2_CID_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE: return "H264 FP Arrangement Type"; + case V4L2_CID_CODEC_VIDEO_H264_FMO: return "H264 Flexible MB Ordering"; + case V4L2_CID_CODEC_VIDEO_H264_FMO_MAP_TYPE: return "H264 Map Type for FMO"; + case V4L2_CID_CODEC_VIDEO_H264_FMO_SLICE_GROUP: return "H264 FMO Number of Slice Groups"; + case V4L2_CID_CODEC_VIDEO_H264_FMO_CHANGE_DIRECTION: return "H264 FMO Direction of Change"; + case V4L2_CID_CODEC_VIDEO_H264_FMO_CHANGE_RATE: return "H264 FMO Size of 1st Slice Grp"; + case V4L2_CID_CODEC_VIDEO_H264_FMO_RUN_LENGTH: return "H264 FMO No. of Consecutive MBs"; + case V4L2_CID_CODEC_VIDEO_H264_ASO: return "H264 Arbitrary Slice Ordering"; + case V4L2_CID_CODEC_VIDEO_H264_ASO_SLICE_ORDER: return "H264 ASO Slice Order"; + case V4L2_CID_CODEC_VIDEO_H264_HIERARCHICAL_CODING: return "Enable H264 Hierarchical Coding"; + case V4L2_CID_CODEC_VIDEO_H264_HIERARCHICAL_CODING_TYPE:return "H264 Hierarchical Coding Type"; + case V4L2_CID_CODEC_VIDEO_H264_HIERARCHICAL_CODING_LAYER:return "H264 Number of HC Layers"; + case V4L2_CID_CODEC_VIDEO_H264_HIERARCHICAL_CODING_LAYER_QP: return "H264 Set QP Value for HC Layers"; - case V4L2_CID_MPEG_VIDEO_H264_CONSTRAINED_INTRA_PREDICTION: + case V4L2_CID_CODEC_VIDEO_H264_CONSTRAINED_INTRA_PREDICTION: return "H264 Constrained Intra Pred"; - case V4L2_CID_MPEG_VIDEO_H264_CHROMA_QP_INDEX_OFFSET: return "H264 Chroma QP Index Offset"; - case V4L2_CID_MPEG_VIDEO_H264_I_FRAME_MIN_QP: return "H264 I-Frame Minimum QP Value"; - case V4L2_CID_MPEG_VIDEO_H264_I_FRAME_MAX_QP: return "H264 I-Frame Maximum QP Value"; - case V4L2_CID_MPEG_VIDEO_H264_P_FRAME_MIN_QP: return "H264 P-Frame Minimum QP Value"; - case V4L2_CID_MPEG_VIDEO_H264_P_FRAME_MAX_QP: return "H264 P-Frame Maximum QP Value"; - case V4L2_CID_MPEG_VIDEO_H264_B_FRAME_MIN_QP: return "H264 B-Frame Minimum QP Value"; - case V4L2_CID_MPEG_VIDEO_H264_B_FRAME_MAX_QP: return "H264 B-Frame Maximum QP Value"; - case V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L0_BR: return "H264 Hierarchical Lay 0 Bitrate"; - case V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L1_BR: return "H264 Hierarchical Lay 1 Bitrate"; - case V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L2_BR: return "H264 Hierarchical Lay 2 Bitrate"; - case V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L3_BR: return "H264 Hierarchical Lay 3 Bitrate"; - case V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L4_BR: return "H264 Hierarchical Lay 4 Bitrate"; - case V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L5_BR: return "H264 Hierarchical Lay 5 Bitrate"; - case V4L2_CID_MPEG_VIDEO_H264_HIER_CODING_L6_BR: return "H264 Hierarchical Lay 6 Bitrate"; - case V4L2_CID_MPEG_VIDEO_MPEG2_LEVEL: return "MPEG2 Level"; - case V4L2_CID_MPEG_VIDEO_MPEG2_PROFILE: return "MPEG2 Profile"; - case V4L2_CID_MPEG_VIDEO_MPEG4_I_FRAME_QP: return "MPEG4 I-Frame QP Value"; - case V4L2_CID_MPEG_VIDEO_MPEG4_P_FRAME_QP: return "MPEG4 P-Frame QP Value"; - case V4L2_CID_MPEG_VIDEO_MPEG4_B_FRAME_QP: return "MPEG4 B-Frame QP Value"; - case V4L2_CID_MPEG_VIDEO_MPEG4_MIN_QP: return "MPEG4 Minimum QP Value"; - case V4L2_CID_MPEG_VIDEO_MPEG4_MAX_QP: return "MPEG4 Maximum QP Value"; - case V4L2_CID_MPEG_VIDEO_MPEG4_LEVEL: return "MPEG4 Level"; - case V4L2_CID_MPEG_VIDEO_MPEG4_PROFILE: return "MPEG4 Profile"; - case V4L2_CID_MPEG_VIDEO_MPEG4_QPEL: return "Quarter Pixel Search Enable"; - case V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MAX_BYTES: return "Maximum Bytes in a Slice"; - case V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MAX_MB: return "Number of MBs in a Slice"; - case V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MODE: return "Slice Partitioning Method"; - case V4L2_CID_MPEG_VIDEO_VBV_SIZE: return "VBV Buffer Size"; - case V4L2_CID_MPEG_VIDEO_DEC_PTS: return "Video Decoder PTS"; - case V4L2_CID_MPEG_VIDEO_DEC_FRAME: return "Video Decoder Frame Count"; - case V4L2_CID_MPEG_VIDEO_VBV_DELAY: return "Initial Delay for VBV Control"; - case V4L2_CID_MPEG_VIDEO_MV_H_SEARCH_RANGE: return "Horizontal MV Search Range"; - case V4L2_CID_MPEG_VIDEO_MV_V_SEARCH_RANGE: return "Vertical MV Search Range"; - case V4L2_CID_MPEG_VIDEO_REPEAT_SEQ_HEADER: return "Repeat Sequence Header"; - case V4L2_CID_MPEG_VIDEO_FORCE_KEY_FRAME: return "Force Key Frame"; - case V4L2_CID_MPEG_VIDEO_BASELAYER_PRIORITY_ID: return "Base Layer Priority ID"; - case V4L2_CID_MPEG_VIDEO_MPEG2_SLICE_PARAMS: return "MPEG-2 Slice Parameters"; - case V4L2_CID_MPEG_VIDEO_MPEG2_QUANTIZATION: return "MPEG-2 Quantization Matrices"; + case V4L2_CID_CODEC_VIDEO_H264_CHROMA_QP_INDEX_OFFSET: return "H264 Chroma QP Index Offset"; + case V4L2_CID_CODEC_VIDEO_H264_I_FRAME_MIN_QP: return "H264 I-Frame Minimum QP Value"; + case V4L2_CID_CODEC_VIDEO_H264_I_FRAME_MAX_QP: return "H264 I-Frame Maximum QP Value"; + case V4L2_CID_CODEC_VIDEO_H264_P_FRAME_MIN_QP: return "H264 P-Frame Minimum QP Value"; + case V4L2_CID_CODEC_VIDEO_H264_P_FRAME_MAX_QP: return "H264 P-Frame Maximum QP Value"; + case V4L2_CID_CODEC_VIDEO_H264_B_FRAME_MIN_QP: return "H264 B-Frame Minimum QP Value"; + case V4L2_CID_CODEC_VIDEO_H264_B_FRAME_MAX_QP: return "H264 B-Frame Maximum QP Value"; + case V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L0_BR: return "H264 Hierarchical Lay 0 Bitrate"; + case V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L1_BR: return "H264 Hierarchical Lay 1 Bitrate"; + case V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L2_BR: return "H264 Hierarchical Lay 2 Bitrate"; + case V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L3_BR: return "H264 Hierarchical Lay 3 Bitrate"; + case V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L4_BR: return "H264 Hierarchical Lay 4 Bitrate"; + case V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L5_BR: return "H264 Hierarchical Lay 5 Bitrate"; + case V4L2_CID_CODEC_VIDEO_H264_HIER_CODING_L6_BR: return "H264 Hierarchical Lay 6 Bitrate"; + case V4L2_CID_CODEC_VIDEO_MPEG2_LEVEL: return "MPEG2 Level"; + case V4L2_CID_CODEC_VIDEO_MPEG2_PROFILE: return "MPEG2 Profile"; + case V4L2_CID_CODEC_VIDEO_MPEG4_I_FRAME_QP: return "MPEG4 I-Frame QP Value"; + case V4L2_CID_CODEC_VIDEO_MPEG4_P_FRAME_QP: return "MPEG4 P-Frame QP Value"; + case V4L2_CID_CODEC_VIDEO_MPEG4_B_FRAME_QP: return "MPEG4 B-Frame QP Value"; + case V4L2_CID_CODEC_VIDEO_MPEG4_MIN_QP: return "MPEG4 Minimum QP Value"; + case V4L2_CID_CODEC_VIDEO_MPEG4_MAX_QP: return "MPEG4 Maximum QP Value"; + case V4L2_CID_CODEC_VIDEO_MPEG4_LEVEL: return "MPEG4 Level"; + case V4L2_CID_CODEC_VIDEO_MPEG4_PROFILE: return "MPEG4 Profile"; + case V4L2_CID_CODEC_VIDEO_MPEG4_QPEL: return "Quarter Pixel Search Enable"; + case V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MAX_BYTES: return "Maximum Bytes in a Slice"; + case V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MAX_MB: return "Number of MBs in a Slice"; + case V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MODE: return "Slice Partitioning Method"; + case V4L2_CID_CODEC_VIDEO_VBV_SIZE: return "VBV Buffer Size"; + case V4L2_CID_CODEC_VIDEO_DEC_PTS: return "Video Decoder PTS"; + case V4L2_CID_CODEC_VIDEO_DEC_FRAME: return "Video Decoder Frame Count"; + case V4L2_CID_CODEC_VIDEO_VBV_DELAY: return "Initial Delay for VBV Control"; + case V4L2_CID_CODEC_VIDEO_MV_H_SEARCH_RANGE: return "Horizontal MV Search Range"; + case V4L2_CID_CODEC_VIDEO_MV_V_SEARCH_RANGE: return "Vertical MV Search Range"; + case V4L2_CID_CODEC_VIDEO_REPEAT_SEQ_HEADER: return "Repeat Sequence Header"; + case V4L2_CID_CODEC_VIDEO_FORCE_KEY_FRAME: return "Force Key Frame"; + case V4L2_CID_CODEC_VIDEO_BASELAYER_PRIORITY_ID: return "Base Layer Priority ID"; + case V4L2_CID_CODEC_VIDEO_MPEG2_SLICE_PARAMS: return "MPEG-2 Slice Parameters"; + case V4L2_CID_CODEC_VIDEO_MPEG2_QUANTIZATION: return "MPEG-2 Quantization Matrices"; case V4L2_CID_FWHT_I_FRAME_QP: return "FWHT I-Frame QP Value"; case V4L2_CID_FWHT_P_FRAME_QP: return "FWHT P-Frame QP Value"; /* VPX controls */ - case V4L2_CID_MPEG_VIDEO_VPX_NUM_PARTITIONS: return "VPX Number of Partitions"; - case V4L2_CID_MPEG_VIDEO_VPX_IMD_DISABLE_4X4: return "VPX Intra Mode Decision Disable"; - case V4L2_CID_MPEG_VIDEO_VPX_NUM_REF_FRAMES: return "VPX No. of Refs for P Frame"; - case V4L2_CID_MPEG_VIDEO_VPX_FILTER_LEVEL: return "VPX Loop Filter Level Range"; - case V4L2_CID_MPEG_VIDEO_VPX_FILTER_SHARPNESS: return "VPX Deblocking Effect Control"; - case V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_REF_PERIOD: return "VPX Golden Frame Refresh Period"; - case V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_SEL: return "VPX Golden Frame Indicator"; - case V4L2_CID_MPEG_VIDEO_VPX_MIN_QP: return "VPX Minimum QP Value"; - case V4L2_CID_MPEG_VIDEO_VPX_MAX_QP: return "VPX Maximum QP Value"; - case V4L2_CID_MPEG_VIDEO_VPX_I_FRAME_QP: return "VPX I-Frame QP Value"; - case V4L2_CID_MPEG_VIDEO_VPX_P_FRAME_QP: return "VPX P-Frame QP Value"; - case V4L2_CID_MPEG_VIDEO_VP8_PROFILE: return "VP8 Profile"; - case V4L2_CID_MPEG_VIDEO_VP9_PROFILE: return "VP9 Profile"; - case V4L2_CID_MPEG_VIDEO_VP9_LEVEL: return "VP9 Level"; - case V4L2_CID_MPEG_VIDEO_VP8_FRAME_HEADER: return "VP8 Frame Header"; + case V4L2_CID_CODEC_VIDEO_VPX_NUM_PARTITIONS: return "VPX Number of Partitions"; + case V4L2_CID_CODEC_VIDEO_VPX_IMD_DISABLE_4X4: return "VPX Intra Mode Decision Disable"; + case V4L2_CID_CODEC_VIDEO_VPX_NUM_REF_FRAMES: return "VPX No. of Refs for P Frame"; + case V4L2_CID_CODEC_VIDEO_VPX_FILTER_LEVEL: return "VPX Loop Filter Level Range"; + case V4L2_CID_CODEC_VIDEO_VPX_FILTER_SHARPNESS: return "VPX Deblocking Effect Control"; + case V4L2_CID_CODEC_VIDEO_VPX_GOLDEN_FRAME_REF_PERIOD: return "VPX Golden Frame Refresh Period"; + case V4L2_CID_CODEC_VIDEO_VPX_GOLDEN_FRAME_SEL: return "VPX Golden Frame Indicator"; + case V4L2_CID_CODEC_VIDEO_VPX_MIN_QP: return "VPX Minimum QP Value"; + case V4L2_CID_CODEC_VIDEO_VPX_MAX_QP: return "VPX Maximum QP Value"; + case V4L2_CID_CODEC_VIDEO_VPX_I_FRAME_QP: return "VPX I-Frame QP Value"; + case V4L2_CID_CODEC_VIDEO_VPX_P_FRAME_QP: return "VPX P-Frame QP Value"; + case V4L2_CID_CODEC_VIDEO_VP8_PROFILE: return "VP8 Profile"; + case V4L2_CID_CODEC_VIDEO_VP9_PROFILE: return "VP9 Profile"; + case V4L2_CID_CODEC_VIDEO_VP9_LEVEL: return "VP9 Level"; + case V4L2_CID_CODEC_VIDEO_VP8_FRAME_HEADER: return "VP8 Frame Header"; /* HEVC controls */ - case V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_QP: return "HEVC I-Frame QP Value"; - case V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_QP: return "HEVC P-Frame QP Value"; - case V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_QP: return "HEVC B-Frame QP Value"; - case V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP: return "HEVC Minimum QP Value"; - case V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP: return "HEVC Maximum QP Value"; - case V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_MIN_QP: return "HEVC I-Frame Minimum QP Value"; - case V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_MAX_QP: return "HEVC I-Frame Maximum QP Value"; - case V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_MIN_QP: return "HEVC P-Frame Minimum QP Value"; - case V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_MAX_QP: return "HEVC P-Frame Maximum QP Value"; - case V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_MIN_QP: return "HEVC B-Frame Minimum QP Value"; - case V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_MAX_QP: return "HEVC B-Frame Maximum QP Value"; - case V4L2_CID_MPEG_VIDEO_HEVC_PROFILE: return "HEVC Profile"; - case V4L2_CID_MPEG_VIDEO_HEVC_LEVEL: return "HEVC Level"; - case V4L2_CID_MPEG_VIDEO_HEVC_TIER: return "HEVC Tier"; - case V4L2_CID_MPEG_VIDEO_HEVC_FRAME_RATE_RESOLUTION: return "HEVC Frame Rate Resolution"; - case V4L2_CID_MPEG_VIDEO_HEVC_MAX_PARTITION_DEPTH: return "HEVC Maximum Coding Unit Depth"; - case V4L2_CID_MPEG_VIDEO_HEVC_REFRESH_TYPE: return "HEVC Refresh Type"; - case V4L2_CID_MPEG_VIDEO_HEVC_CONST_INTRA_PRED: return "HEVC Constant Intra Prediction"; - case V4L2_CID_MPEG_VIDEO_HEVC_LOSSLESS_CU: return "HEVC Lossless Encoding"; - case V4L2_CID_MPEG_VIDEO_HEVC_WAVEFRONT: return "HEVC Wavefront"; - case V4L2_CID_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE: return "HEVC Loop Filter"; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_QP: return "HEVC QP Values"; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_TYPE: return "HEVC Hierarchical Coding Type"; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_LAYER: return "HEVC Hierarchical Coding Layer"; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L0_QP: return "HEVC Hierarchical Layer 0 QP"; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L1_QP: return "HEVC Hierarchical Layer 1 QP"; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L2_QP: return "HEVC Hierarchical Layer 2 QP"; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L3_QP: return "HEVC Hierarchical Layer 3 QP"; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L4_QP: return "HEVC Hierarchical Layer 4 QP"; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L5_QP: return "HEVC Hierarchical Layer 5 QP"; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L6_QP: return "HEVC Hierarchical Layer 6 QP"; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L0_BR: return "HEVC Hierarchical Lay 0 BitRate"; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L1_BR: return "HEVC Hierarchical Lay 1 BitRate"; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L2_BR: return "HEVC Hierarchical Lay 2 BitRate"; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L3_BR: return "HEVC Hierarchical Lay 3 BitRate"; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L4_BR: return "HEVC Hierarchical Lay 4 BitRate"; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L5_BR: return "HEVC Hierarchical Lay 5 BitRate"; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L6_BR: return "HEVC Hierarchical Lay 6 BitRate"; - case V4L2_CID_MPEG_VIDEO_HEVC_GENERAL_PB: return "HEVC General PB"; - case V4L2_CID_MPEG_VIDEO_HEVC_TEMPORAL_ID: return "HEVC Temporal ID"; - case V4L2_CID_MPEG_VIDEO_HEVC_STRONG_SMOOTHING: return "HEVC Strong Intra Smoothing"; - case V4L2_CID_MPEG_VIDEO_HEVC_INTRA_PU_SPLIT: return "HEVC Intra PU Split"; - case V4L2_CID_MPEG_VIDEO_HEVC_TMV_PREDICTION: return "HEVC TMV Prediction"; - case V4L2_CID_MPEG_VIDEO_HEVC_MAX_NUM_MERGE_MV_MINUS1: return "HEVC Max Num of Candidate MVs"; - case V4L2_CID_MPEG_VIDEO_HEVC_WITHOUT_STARTCODE: return "HEVC ENC Without Startcode"; - case V4L2_CID_MPEG_VIDEO_HEVC_REFRESH_PERIOD: return "HEVC Num of I-Frame b/w 2 IDR"; - case V4L2_CID_MPEG_VIDEO_HEVC_LF_BETA_OFFSET_DIV2: return "HEVC Loop Filter Beta Offset"; - case V4L2_CID_MPEG_VIDEO_HEVC_LF_TC_OFFSET_DIV2: return "HEVC Loop Filter TC Offset"; - case V4L2_CID_MPEG_VIDEO_HEVC_SIZE_OF_LENGTH_FIELD: return "HEVC Size of Length Field"; - case V4L2_CID_MPEG_VIDEO_REF_NUMBER_FOR_PFRAMES: return "Reference Frames for a P-Frame"; - case V4L2_CID_MPEG_VIDEO_PREPEND_SPSPPS_TO_IDR: return "Prepend SPS and PPS to IDR"; - case V4L2_CID_MPEG_VIDEO_HEVC_SPS: return "HEVC Sequence Parameter Set"; - case V4L2_CID_MPEG_VIDEO_HEVC_PPS: return "HEVC Picture Parameter Set"; - case V4L2_CID_MPEG_VIDEO_HEVC_SLICE_PARAMS: return "HEVC Slice Parameters"; - case V4L2_CID_MPEG_VIDEO_HEVC_DECODE_MODE: return "HEVC Decode Mode"; - case V4L2_CID_MPEG_VIDEO_HEVC_START_CODE: return "HEVC Start Code"; + case V4L2_CID_CODEC_VIDEO_HEVC_I_FRAME_QP: return "HEVC I-Frame QP Value"; + case V4L2_CID_CODEC_VIDEO_HEVC_P_FRAME_QP: return "HEVC P-Frame QP Value"; + case V4L2_CID_CODEC_VIDEO_HEVC_B_FRAME_QP: return "HEVC B-Frame QP Value"; + case V4L2_CID_CODEC_VIDEO_HEVC_MIN_QP: return "HEVC Minimum QP Value"; + case V4L2_CID_CODEC_VIDEO_HEVC_MAX_QP: return "HEVC Maximum QP Value"; + case V4L2_CID_CODEC_VIDEO_HEVC_I_FRAME_MIN_QP: return "HEVC I-Frame Minimum QP Value"; + case V4L2_CID_CODEC_VIDEO_HEVC_I_FRAME_MAX_QP: return "HEVC I-Frame Maximum QP Value"; + case V4L2_CID_CODEC_VIDEO_HEVC_P_FRAME_MIN_QP: return "HEVC P-Frame Minimum QP Value"; + case V4L2_CID_CODEC_VIDEO_HEVC_P_FRAME_MAX_QP: return "HEVC P-Frame Maximum QP Value"; + case V4L2_CID_CODEC_VIDEO_HEVC_B_FRAME_MIN_QP: return "HEVC B-Frame Minimum QP Value"; + case V4L2_CID_CODEC_VIDEO_HEVC_B_FRAME_MAX_QP: return "HEVC B-Frame Maximum QP Value"; + case V4L2_CID_CODEC_VIDEO_HEVC_PROFILE: return "HEVC Profile"; + case V4L2_CID_CODEC_VIDEO_HEVC_LEVEL: return "HEVC Level"; + case V4L2_CID_CODEC_VIDEO_HEVC_TIER: return "HEVC Tier"; + case V4L2_CID_CODEC_VIDEO_HEVC_FRAME_RATE_RESOLUTION: return "HEVC Frame Rate Resolution"; + case V4L2_CID_CODEC_VIDEO_HEVC_MAX_PARTITION_DEPTH: return "HEVC Maximum Coding Unit Depth"; + case V4L2_CID_CODEC_VIDEO_HEVC_REFRESH_TYPE: return "HEVC Refresh Type"; + case V4L2_CID_CODEC_VIDEO_HEVC_CONST_INTRA_PRED: return "HEVC Constant Intra Prediction"; + case V4L2_CID_CODEC_VIDEO_HEVC_LOSSLESS_CU: return "HEVC Lossless Encoding"; + case V4L2_CID_CODEC_VIDEO_HEVC_WAVEFRONT: return "HEVC Wavefront"; + case V4L2_CID_CODEC_VIDEO_HEVC_LOOP_FILTER_MODE: return "HEVC Loop Filter"; + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_QP: return "HEVC QP Values"; + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_TYPE: return "HEVC Hierarchical Coding Type"; + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_LAYER: return "HEVC Hierarchical Coding Layer"; + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L0_QP: return "HEVC Hierarchical Layer 0 QP"; + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L1_QP: return "HEVC Hierarchical Layer 1 QP"; + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L2_QP: return "HEVC Hierarchical Layer 2 QP"; + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L3_QP: return "HEVC Hierarchical Layer 3 QP"; + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L4_QP: return "HEVC Hierarchical Layer 4 QP"; + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L5_QP: return "HEVC Hierarchical Layer 5 QP"; + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L6_QP: return "HEVC Hierarchical Layer 6 QP"; + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L0_BR: return "HEVC Hierarchical Lay 0 BitRate"; + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L1_BR: return "HEVC Hierarchical Lay 1 BitRate"; + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L2_BR: return "HEVC Hierarchical Lay 2 BitRate"; + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L3_BR: return "HEVC Hierarchical Lay 3 BitRate"; + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L4_BR: return "HEVC Hierarchical Lay 4 BitRate"; + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L5_BR: return "HEVC Hierarchical Lay 5 BitRate"; + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L6_BR: return "HEVC Hierarchical Lay 6 BitRate"; + case V4L2_CID_CODEC_VIDEO_HEVC_GENERAL_PB: return "HEVC General PB"; + case V4L2_CID_CODEC_VIDEO_HEVC_TEMPORAL_ID: return "HEVC Temporal ID"; + case V4L2_CID_CODEC_VIDEO_HEVC_STRONG_SMOOTHING: return "HEVC Strong Intra Smoothing"; + case V4L2_CID_CODEC_VIDEO_HEVC_INTRA_PU_SPLIT: return "HEVC Intra PU Split"; + case V4L2_CID_CODEC_VIDEO_HEVC_TMV_PREDICTION: return "HEVC TMV Prediction"; + case V4L2_CID_CODEC_VIDEO_HEVC_MAX_NUM_MERGE_MV_MINUS1: return "HEVC Max Num of Candidate MVs"; + case V4L2_CID_CODEC_VIDEO_HEVC_WITHOUT_STARTCODE: return "HEVC ENC Without Startcode"; + case V4L2_CID_CODEC_VIDEO_HEVC_REFRESH_PERIOD: return "HEVC Num of I-Frame b/w 2 IDR"; + case V4L2_CID_CODEC_VIDEO_HEVC_LF_BETA_OFFSET_DIV2: return "HEVC Loop Filter Beta Offset"; + case V4L2_CID_CODEC_VIDEO_HEVC_LF_TC_OFFSET_DIV2: return "HEVC Loop Filter TC Offset"; + case V4L2_CID_CODEC_VIDEO_HEVC_SIZE_OF_LENGTH_FIELD: return "HEVC Size of Length Field"; + case V4L2_CID_CODEC_VIDEO_REF_NUMBER_FOR_PFRAMES: return "Reference Frames for a P-Frame"; + case V4L2_CID_CODEC_VIDEO_PREPEND_SPSPPS_TO_IDR: return "Prepend SPS and PPS to IDR"; + case V4L2_CID_CODEC_VIDEO_HEVC_SPS: return "HEVC Sequence Parameter Set"; + case V4L2_CID_CODEC_VIDEO_HEVC_PPS: return "HEVC Picture Parameter Set"; + case V4L2_CID_CODEC_VIDEO_HEVC_SLICE_PARAMS: return "HEVC Slice Parameters"; + case V4L2_CID_CODEC_VIDEO_HEVC_DECODE_MODE: return "HEVC Decode Mode"; + case V4L2_CID_CODEC_VIDEO_HEVC_START_CODE: return "HEVC Start Code"; /* CAMERA controls */ /* Keep the order of the 'case's the same as in v4l2-controls.h! */ @@ -1192,15 +1192,15 @@ const char *v4l2_ctrl_get_name(u32 id) /* Stateless Codec controls */ /* Keep the order of the 'case's the same as in v4l2-controls.h! */ case V4L2_CID_CODEC_STATELESS_CLASS: return "Stateless Codec Controls"; - case V4L2_CID_STATELESS_H264_DECODE_MODE: return "H264 Decode Mode"; - case V4L2_CID_STATELESS_H264_START_CODE: return "H264 Start Code"; - case V4L2_CID_STATELESS_H264_SPS: return "H264 Sequence Parameter Set"; - case V4L2_CID_STATELESS_H264_PPS: return "H264 Picture Parameter Set"; - case V4L2_CID_STATELESS_H264_SCALING_MATRIX: return "H264 Scaling Matrix"; - case V4L2_CID_STATELESS_H264_PRED_WEIGHTS: return "H264 Prediction Weight Table"; - case V4L2_CID_STATELESS_H264_SLICE_PARAMS: return "H264 Slice Parameters"; - case V4L2_CID_STATELESS_H264_DECODE_PARAMS: return "H264 Decode Parameters"; - case V4L2_CID_STATELESS_FWHT_PARAMS: return "FWHT Stateless Parameters"; + case V4L2_CID_STATELESS_H264_DECODE_MODE: return "H264 Decode Mode"; + case V4L2_CID_STATELESS_H264_START_CODE: return "H264 Start Code"; + case V4L2_CID_STATELESS_H264_SPS: return "H264 Sequence Parameter Set"; + case V4L2_CID_STATELESS_H264_PPS: return "H264 Picture Parameter Set"; + case V4L2_CID_STATELESS_H264_SCALING_MATRIX: return "H264 Scaling Matrix"; + case V4L2_CID_STATELESS_H264_PRED_WEIGHTS: return "H264 Prediction Weight Table"; + case V4L2_CID_STATELESS_H264_SLICE_PARAMS: return "H264 Slice Parameters"; + case V4L2_CID_STATELESS_H264_DECODE_PARAMS: return "H264 Decode Parameters"; + case V4L2_CID_STATELESS_FWHT_PARAMS: return "FWHT Stateless Parameters"; default: return NULL; } @@ -1224,10 +1224,10 @@ void v4l2_ctrl_fill(u32 id, const char **name, enum v4l2_ctrl_type *type, case V4L2_CID_CHROMA_AGC: case V4L2_CID_COLOR_KILLER: case V4L2_CID_AUTOBRIGHTNESS: - case V4L2_CID_MPEG_AUDIO_MUTE: - case V4L2_CID_MPEG_VIDEO_MUTE: - case V4L2_CID_MPEG_VIDEO_GOP_CLOSURE: - case V4L2_CID_MPEG_VIDEO_PULLDOWN: + case V4L2_CID_CODEC_AUDIO_MUTE: + case V4L2_CID_CODEC_VIDEO_MUTE: + case V4L2_CID_CODEC_VIDEO_GOP_CLOSURE: + case V4L2_CID_CODEC_VIDEO_PULLDOWN: case V4L2_CID_EXPOSURE_AUTO_PRIORITY: case V4L2_CID_FOCUS_AUTO: case V4L2_CID_PRIVACY: @@ -1239,14 +1239,14 @@ void v4l2_ctrl_fill(u32 id, const char **name, enum v4l2_ctrl_type *type, case V4L2_CID_FLASH_STROBE_STATUS: case V4L2_CID_FLASH_CHARGE: case V4L2_CID_FLASH_READY: - case V4L2_CID_MPEG_VIDEO_DECODER_MPEG4_DEBLOCK_FILTER: - case V4L2_CID_MPEG_VIDEO_DECODER_SLICE_INTERFACE: - case V4L2_CID_MPEG_VIDEO_FRAME_RC_ENABLE: - case V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE: - case V4L2_CID_MPEG_VIDEO_H264_8X8_TRANSFORM: - case V4L2_CID_MPEG_VIDEO_H264_VUI_SAR_ENABLE: - case V4L2_CID_MPEG_VIDEO_MPEG4_QPEL: - case V4L2_CID_MPEG_VIDEO_REPEAT_SEQ_HEADER: + case V4L2_CID_CODEC_VIDEO_DECODER_MPEG4_DEBLOCK_FILTER: + case V4L2_CID_CODEC_VIDEO_DECODER_SLICE_INTERFACE: + case V4L2_CID_CODEC_VIDEO_FRAME_RC_ENABLE: + case V4L2_CID_CODEC_VIDEO_MB_RC_ENABLE: + case V4L2_CID_CODEC_VIDEO_H264_8X8_TRANSFORM: + case V4L2_CID_CODEC_VIDEO_H264_VUI_SAR_ENABLE: + case V4L2_CID_CODEC_VIDEO_MPEG4_QPEL: + case V4L2_CID_CODEC_VIDEO_REPEAT_SEQ_HEADER: case V4L2_CID_WIDE_DYNAMIC_RANGE: case V4L2_CID_IMAGE_STABILIZATION: case V4L2_CID_RDS_RECEPTION: @@ -1274,11 +1274,11 @@ void v4l2_ctrl_fill(u32 id, const char **name, enum v4l2_ctrl_type *type, *type = V4L2_CTRL_TYPE_INTEGER; *flags |= V4L2_CTRL_FLAG_MODIFY_LAYOUT; break; - case V4L2_CID_MPEG_VIDEO_MV_H_SEARCH_RANGE: - case V4L2_CID_MPEG_VIDEO_MV_V_SEARCH_RANGE: + case V4L2_CID_CODEC_VIDEO_MV_H_SEARCH_RANGE: + case V4L2_CID_CODEC_VIDEO_MV_V_SEARCH_RANGE: *type = V4L2_CTRL_TYPE_INTEGER; break; - case V4L2_CID_MPEG_VIDEO_FORCE_KEY_FRAME: + case V4L2_CID_CODEC_VIDEO_FORCE_KEY_FRAME: case V4L2_CID_PAN_RESET: case V4L2_CID_TILT_RESET: case V4L2_CID_FLASH_STROBE: @@ -1292,23 +1292,23 @@ void v4l2_ctrl_fill(u32 id, const char **name, enum v4l2_ctrl_type *type, *min = *max = *step = *def = 0; break; case V4L2_CID_POWER_LINE_FREQUENCY: - case V4L2_CID_MPEG_AUDIO_SAMPLING_FREQ: - case V4L2_CID_MPEG_AUDIO_ENCODING: - case V4L2_CID_MPEG_AUDIO_L1_BITRATE: - case V4L2_CID_MPEG_AUDIO_L2_BITRATE: - case V4L2_CID_MPEG_AUDIO_L3_BITRATE: - case V4L2_CID_MPEG_AUDIO_AC3_BITRATE: - case V4L2_CID_MPEG_AUDIO_MODE: - case V4L2_CID_MPEG_AUDIO_MODE_EXTENSION: - case V4L2_CID_MPEG_AUDIO_EMPHASIS: - case V4L2_CID_MPEG_AUDIO_CRC: - case V4L2_CID_MPEG_AUDIO_DEC_PLAYBACK: - case V4L2_CID_MPEG_AUDIO_DEC_MULTILINGUAL_PLAYBACK: - case V4L2_CID_MPEG_VIDEO_ENCODING: - case V4L2_CID_MPEG_VIDEO_ASPECT: - case V4L2_CID_MPEG_VIDEO_BITRATE_MODE: - case V4L2_CID_MPEG_STREAM_TYPE: - case V4L2_CID_MPEG_STREAM_VBI_FMT: + case V4L2_CID_CODEC_AUDIO_SAMPLING_FREQ: + case V4L2_CID_CODEC_AUDIO_ENCODING: + case V4L2_CID_CODEC_AUDIO_L1_BITRATE: + case V4L2_CID_CODEC_AUDIO_L2_BITRATE: + case V4L2_CID_CODEC_AUDIO_L3_BITRATE: + case V4L2_CID_CODEC_AUDIO_AC3_BITRATE: + case V4L2_CID_CODEC_AUDIO_MODE: + case V4L2_CID_CODEC_AUDIO_MODE_EXTENSION: + case V4L2_CID_CODEC_AUDIO_EMPHASIS: + case V4L2_CID_CODEC_AUDIO_CRC: + case V4L2_CID_CODEC_AUDIO_DEC_PLAYBACK: + case V4L2_CID_CODEC_AUDIO_DEC_MULTILINGUAL_PLAYBACK: + case V4L2_CID_CODEC_VIDEO_ENCODING: + case V4L2_CID_CODEC_VIDEO_ASPECT: + case V4L2_CID_CODEC_VIDEO_BITRATE_MODE: + case V4L2_CID_CODEC_STREAM_TYPE: + case V4L2_CID_CODEC_STREAM_VBI_FMT: case V4L2_CID_EXPOSURE_AUTO: case V4L2_CID_AUTO_FOCUS_RANGE: case V4L2_CID_COLORFX: @@ -1316,20 +1316,20 @@ void v4l2_ctrl_fill(u32 id, const char **name, enum v4l2_ctrl_type *type, case V4L2_CID_TUNE_PREEMPHASIS: case V4L2_CID_FLASH_LED_MODE: case V4L2_CID_FLASH_STROBE_SOURCE: - case V4L2_CID_MPEG_VIDEO_HEADER_MODE: - case V4L2_CID_MPEG_VIDEO_FRAME_SKIP_MODE: - case V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MODE: - case V4L2_CID_MPEG_VIDEO_H264_ENTROPY_MODE: - case V4L2_CID_MPEG_VIDEO_H264_LEVEL: - case V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_MODE: - case V4L2_CID_MPEG_VIDEO_H264_PROFILE: - case V4L2_CID_MPEG_VIDEO_H264_VUI_SAR_IDC: - case V4L2_CID_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE: - case V4L2_CID_MPEG_VIDEO_H264_FMO_MAP_TYPE: - case V4L2_CID_MPEG_VIDEO_MPEG2_LEVEL: - case V4L2_CID_MPEG_VIDEO_MPEG2_PROFILE: - case V4L2_CID_MPEG_VIDEO_MPEG4_LEVEL: - case V4L2_CID_MPEG_VIDEO_MPEG4_PROFILE: + case V4L2_CID_CODEC_VIDEO_HEADER_MODE: + case V4L2_CID_CODEC_VIDEO_FRAME_SKIP_MODE: + case V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MODE: + case V4L2_CID_CODEC_VIDEO_H264_ENTROPY_MODE: + case V4L2_CID_CODEC_VIDEO_H264_LEVEL: + case V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_MODE: + case V4L2_CID_CODEC_VIDEO_H264_PROFILE: + case V4L2_CID_CODEC_VIDEO_H264_VUI_SAR_IDC: + case V4L2_CID_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE: + case V4L2_CID_CODEC_VIDEO_H264_FMO_MAP_TYPE: + case V4L2_CID_CODEC_VIDEO_MPEG2_LEVEL: + case V4L2_CID_CODEC_VIDEO_MPEG2_PROFILE: + case V4L2_CID_CODEC_VIDEO_MPEG4_LEVEL: + case V4L2_CID_CODEC_VIDEO_MPEG4_PROFILE: case V4L2_CID_JPEG_CHROMA_SUBSAMPLING: case V4L2_CID_ISO_SENSITIVITY_AUTO: case V4L2_CID_EXPOSURE_METERING: @@ -1342,20 +1342,20 @@ void v4l2_ctrl_fill(u32 id, const char **name, enum v4l2_ctrl_type *type, case V4L2_CID_TEST_PATTERN: case V4L2_CID_DEINTERLACING_MODE: case V4L2_CID_TUNE_DEEMPHASIS: - case V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_SEL: - case V4L2_CID_MPEG_VIDEO_VP8_PROFILE: - case V4L2_CID_MPEG_VIDEO_VP9_PROFILE: - case V4L2_CID_MPEG_VIDEO_VP9_LEVEL: + case V4L2_CID_CODEC_VIDEO_VPX_GOLDEN_FRAME_SEL: + case V4L2_CID_CODEC_VIDEO_VP8_PROFILE: + case V4L2_CID_CODEC_VIDEO_VP9_PROFILE: + case V4L2_CID_CODEC_VIDEO_VP9_LEVEL: case V4L2_CID_DETECT_MD_MODE: - case V4L2_CID_MPEG_VIDEO_HEVC_PROFILE: - case V4L2_CID_MPEG_VIDEO_HEVC_LEVEL: - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_TYPE: - case V4L2_CID_MPEG_VIDEO_HEVC_REFRESH_TYPE: - case V4L2_CID_MPEG_VIDEO_HEVC_SIZE_OF_LENGTH_FIELD: - case V4L2_CID_MPEG_VIDEO_HEVC_TIER: - case V4L2_CID_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE: - case V4L2_CID_MPEG_VIDEO_HEVC_DECODE_MODE: - case V4L2_CID_MPEG_VIDEO_HEVC_START_CODE: + case V4L2_CID_CODEC_VIDEO_HEVC_PROFILE: + case V4L2_CID_CODEC_VIDEO_HEVC_LEVEL: + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_TYPE: + case V4L2_CID_CODEC_VIDEO_HEVC_REFRESH_TYPE: + case V4L2_CID_CODEC_VIDEO_HEVC_SIZE_OF_LENGTH_FIELD: + case V4L2_CID_CODEC_VIDEO_HEVC_TIER: + case V4L2_CID_CODEC_VIDEO_HEVC_LOOP_FILTER_MODE: + case V4L2_CID_CODEC_VIDEO_HEVC_DECODE_MODE: + case V4L2_CID_CODEC_VIDEO_HEVC_START_CODE: case V4L2_CID_STATELESS_H264_DECODE_MODE: case V4L2_CID_STATELESS_H264_START_CODE: case V4L2_CID_CAMERA_ORIENTATION: @@ -1372,8 +1372,8 @@ void v4l2_ctrl_fill(u32 id, const char **name, enum v4l2_ctrl_type *type, break; case V4L2_CID_ISO_SENSITIVITY: case V4L2_CID_AUTO_EXPOSURE_BIAS: - case V4L2_CID_MPEG_VIDEO_VPX_NUM_PARTITIONS: - case V4L2_CID_MPEG_VIDEO_VPX_NUM_REF_FRAMES: + case V4L2_CID_CODEC_VIDEO_VPX_NUM_PARTITIONS: + case V4L2_CID_CODEC_VIDEO_VPX_NUM_REF_FRAMES: *type = V4L2_CTRL_TYPE_INTEGER_MENU; break; case V4L2_CID_USER_CLASS: @@ -1416,14 +1416,14 @@ void v4l2_ctrl_fill(u32 id, const char **name, enum v4l2_ctrl_type *type, *type = V4L2_CTRL_TYPE_INTEGER; *flags |= V4L2_CTRL_FLAG_READ_ONLY; break; - case V4L2_CID_MPEG_VIDEO_DEC_PTS: + case V4L2_CID_CODEC_VIDEO_DEC_PTS: *type = V4L2_CTRL_TYPE_INTEGER64; *flags |= V4L2_CTRL_FLAG_VOLATILE | V4L2_CTRL_FLAG_READ_ONLY; *min = *def = 0; *max = 0x1ffffffffLL; *step = 1; break; - case V4L2_CID_MPEG_VIDEO_DEC_FRAME: + case V4L2_CID_CODEC_VIDEO_DEC_FRAME: *type = V4L2_CTRL_TYPE_INTEGER64; *flags |= V4L2_CTRL_FLAG_VOLATILE | V4L2_CTRL_FLAG_READ_ONLY; *min = *def = 0; @@ -1443,10 +1443,10 @@ void v4l2_ctrl_fill(u32 id, const char **name, enum v4l2_ctrl_type *type, case V4L2_CID_RDS_TX_ALT_FREQS: *type = V4L2_CTRL_TYPE_U32; break; - case V4L2_CID_MPEG_VIDEO_MPEG2_SLICE_PARAMS: + case V4L2_CID_CODEC_VIDEO_MPEG2_SLICE_PARAMS: *type = V4L2_CTRL_TYPE_MPEG2_SLICE_PARAMS; break; - case V4L2_CID_MPEG_VIDEO_MPEG2_QUANTIZATION: + case V4L2_CID_CODEC_VIDEO_MPEG2_QUANTIZATION: *type = V4L2_CTRL_TYPE_MPEG2_QUANTIZATION; break; case V4L2_CID_STATELESS_FWHT_PARAMS: @@ -1470,16 +1470,16 @@ void v4l2_ctrl_fill(u32 id, const char **name, enum v4l2_ctrl_type *type, case V4L2_CID_STATELESS_H264_PRED_WEIGHTS: *type = V4L2_CTRL_TYPE_H264_PRED_WEIGHTS; break; - case V4L2_CID_MPEG_VIDEO_VP8_FRAME_HEADER: + case V4L2_CID_CODEC_VIDEO_VP8_FRAME_HEADER: *type = V4L2_CTRL_TYPE_VP8_FRAME_HEADER; break; - case V4L2_CID_MPEG_VIDEO_HEVC_SPS: + case V4L2_CID_CODEC_VIDEO_HEVC_SPS: *type = V4L2_CTRL_TYPE_HEVC_SPS; break; - case V4L2_CID_MPEG_VIDEO_HEVC_PPS: + case V4L2_CID_CODEC_VIDEO_HEVC_PPS: *type = V4L2_CTRL_TYPE_HEVC_PPS; break; - case V4L2_CID_MPEG_VIDEO_HEVC_SLICE_PARAMS: + case V4L2_CID_CODEC_VIDEO_HEVC_SLICE_PARAMS: *type = V4L2_CTRL_TYPE_HEVC_SLICE_PARAMS; break; case V4L2_CID_UNIT_CELL_SIZE: @@ -1491,11 +1491,11 @@ void v4l2_ctrl_fill(u32 id, const char **name, enum v4l2_ctrl_type *type, break; } switch (id) { - case V4L2_CID_MPEG_AUDIO_ENCODING: - case V4L2_CID_MPEG_AUDIO_MODE: - case V4L2_CID_MPEG_VIDEO_BITRATE_MODE: - case V4L2_CID_MPEG_VIDEO_B_FRAMES: - case V4L2_CID_MPEG_STREAM_TYPE: + case V4L2_CID_CODEC_AUDIO_ENCODING: + case V4L2_CID_CODEC_AUDIO_MODE: + case V4L2_CID_CODEC_VIDEO_BITRATE_MODE: + case V4L2_CID_CODEC_VIDEO_B_FRAMES: + case V4L2_CID_CODEC_STREAM_TYPE: *flags |= V4L2_CTRL_FLAG_UPDATE; break; case V4L2_CID_AUDIO_VOLUME: From patchwork Sat Mar 13 14:43:15 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans Verkuil X-Patchwork-Id: 399851 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-18.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER, INCLUDES_PATCH, MAILING_LIST_MULTI, SPF_HELO_NONE, SPF_PASS, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 518D7C433E9 for ; Sat, 13 Mar 2021 14:44:26 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 19C2464F2C for ; Sat, 13 Mar 2021 14:44:26 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234060AbhCMOnv (ORCPT ); Sat, 13 Mar 2021 09:43:51 -0500 Received: from lb1-smtp-cloud9.xs4all.net ([194.109.24.22]:39887 "EHLO lb1-smtp-cloud9.xs4all.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234027AbhCMOna (ORCPT ); Sat, 13 Mar 2021 09:43:30 -0500 Received: from cust-b5b5937f ([IPv6:fc0c:c16d:66b8:757f:c639:739b:9d66:799d]) by smtp-cloud9.xs4all.net with ESMTPA id L5UBljyoWC40pL5UHlV5du; Sat, 13 Mar 2021 15:43:29 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=xs4all.nl; s=s2; t=1615646609; bh=5lh8UlrGuZur8aSXMkUT5J4qg/w3bG+Jd8ePEczq+jg=; h=From:To:Subject:Date:Message-Id:MIME-Version:From:Subject; b=m8md+8mlZqzE2kZfDLprd0OekA/ue6t9lSRN18Qmvsw46EQoSl3WYXc1YlWIYGSyD GuryXtFFV9T6N9tcEKmm71Q2i7gLY+Nig2fsGXc91iBIJIZp6bcfnNl0vrk8j1zgob sveI0EkiVuzvfA0jvotKm7H+EljzOwfpb5Kwh2PVVPUv3R7dT337qg0d8pScjjF9Yn E20gAC0BUlYtMNVLxZz1WvMJwWaCW+As14Px1CHPwyXzGd36LQBDiBD4s7LWOPro2U gukIhX+9Xh6lL0sJxexP5HAEHHMPHCaL7uD3j4h8F32h2M0BQ2Dp4bdOFGEyOuVlAy ecuUD/VASQaDw== From: Hans Verkuil To: linux-media@vger.kernel.org Cc: Ezequiel Garcia , Nicolas Dufresne , Tomasz Figa , Alexandre Courbot , Hans Verkuil Subject: [PATCH 07/15] media/pci: rename MPEG to CODEC Date: Sat, 13 Mar 2021 15:43:15 +0100 Message-Id: <20210313144323.143600-8-hverkuil-cisco@xs4all.nl> X-Mailer: git-send-email 2.30.1 In-Reply-To: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> References: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> MIME-Version: 1.0 X-CMAE-Envelope: MS4xfHB20MmtF5ZcYetgXeMEMm916KOLGm4CPZp4loUBMb4p735IcJ67kybPCw6oLhk36CkLiIbYkSy/XTsGdBZMReFwjEZwC922p9K7bU4wslAFdYlR5M7M dSkvAl5oCD5Eps37hYkSc/INvgFdyL4ayp75pW0RWxRN/Z/GeWD0y44I5Z6D3gjTM1DNgK8JVcV1YCXHdjsBOf8B04vYoJ0zC1OJxDZyC37ES+VumK3BGuT/ ltuj5UhuoVVT+uDCgWcfNEMHd0uyQkpT4M6455DHwYFyIuqnsgELwMnEsa2IXyDbrGlTq7uUo+FzIbApU+9/N4hUTW8pPXf5/TpnS5hxCbmTwr1qpBizIMEK jFUhB5vxbxvJ6+r+NOgJr8jCvLWy1g== Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Historically all codec-related data structures and defines used the MPEG prefix. This is confusing. Rename MPEG to CODEC to make it clear that the MPEG prefix isn't MPEG specific. Signed-off-by: Hans Verkuil --- drivers/media/pci/cx18/cx18-controls.c | 14 ++--- drivers/media/pci/ivtv/ivtv-controls.c | 10 ++-- drivers/media/pci/ivtv/ivtv-driver.c | 22 ++++---- drivers/media/pci/ivtv/ivtv-ioctl.c | 4 +- drivers/media/pci/saa7164/saa7164-api.c | 12 ++--- drivers/media/pci/saa7164/saa7164-core.c | 4 +- drivers/media/pci/saa7164/saa7164-encoder.c | 52 +++++++++---------- drivers/media/pci/saa7164/saa7164.h | 4 +- .../media/pci/solo6x10/solo6x10-v4l2-enc.c | 8 +-- drivers/media/pci/tw5864/tw5864-video.c | 8 +-- 10 files changed, 69 insertions(+), 69 deletions(-) diff --git a/drivers/media/pci/cx18/cx18-controls.c b/drivers/media/pci/cx18/cx18-controls.c index bb5fc120473c..71d319bd23b4 100644 --- a/drivers/media/pci/cx18/cx18-controls.c +++ b/drivers/media/pci/cx18/cx18-controls.c @@ -24,12 +24,12 @@ static int cx18_s_stream_vbi_fmt(struct cx2341x_handler *cxhdl, u32 fmt) if (atomic_read(&cx->ana_capturing) > 0) return -EBUSY; - if (fmt != V4L2_MPEG_STREAM_VBI_FMT_IVTV || - !(type == V4L2_MPEG_STREAM_TYPE_MPEG2_PS || - type == V4L2_MPEG_STREAM_TYPE_MPEG2_DVD || - type == V4L2_MPEG_STREAM_TYPE_MPEG2_SVCD)) { + if (fmt != V4L2_CODEC_STREAM_VBI_FMT_IVTV || + !(type == V4L2_CODEC_STREAM_TYPE_MPEG2_PS || + type == V4L2_CODEC_STREAM_TYPE_MPEG2_DVD || + type == V4L2_CODEC_STREAM_TYPE_MPEG2_SVCD)) { /* Only IVTV fmt VBI insertion & only MPEG-2 PS type streams */ - cx->vbi.insert_mpeg = V4L2_MPEG_STREAM_VBI_FMT_NONE; + cx->vbi.insert_mpeg = V4L2_CODEC_STREAM_VBI_FMT_NONE; CX18_DEBUG_INFO("disabled insertion of sliced VBI data into the MPEG stream\n"); return 0; } @@ -47,7 +47,7 @@ static int cx18_s_stream_vbi_fmt(struct cx2341x_handler *cxhdl, u32 fmt) cx->vbi.sliced_mpeg_data[i] = NULL; } cx->vbi.insert_mpeg = - V4L2_MPEG_STREAM_VBI_FMT_NONE; + V4L2_CODEC_STREAM_VBI_FMT_NONE; CX18_WARN("Unable to allocate buffers for sliced VBI data insertion\n"); return -ENOMEM; } @@ -75,7 +75,7 @@ static int cx18_s_stream_vbi_fmt(struct cx2341x_handler *cxhdl, u32 fmt) static int cx18_s_video_encoding(struct cx2341x_handler *cxhdl, u32 val) { struct cx18 *cx = container_of(cxhdl, struct cx18, cxhdl); - int is_mpeg1 = val == V4L2_MPEG_VIDEO_ENCODING_MPEG_1; + int is_mpeg1 = val == V4L2_CODEC_VIDEO_ENCODING_MPEG_1; struct v4l2_subdev_format format = { .which = V4L2_SUBDEV_FORMAT_ACTIVE, }; diff --git a/drivers/media/pci/ivtv/ivtv-controls.c b/drivers/media/pci/ivtv/ivtv-controls.c index a0b9a5a5c7f1..684afe4f34a4 100644 --- a/drivers/media/pci/ivtv/ivtv-controls.c +++ b/drivers/media/pci/ivtv/ivtv-controls.c @@ -51,7 +51,7 @@ static int ivtv_s_stream_vbi_fmt(struct cx2341x_handler *cxhdl, u32 fmt) static int ivtv_s_video_encoding(struct cx2341x_handler *cxhdl, u32 val) { struct ivtv *itv = container_of(cxhdl, struct ivtv, cxhdl); - int is_mpeg1 = val == V4L2_MPEG_VIDEO_ENCODING_MPEG_1; + int is_mpeg1 = val == V4L2_CODEC_VIDEO_ENCODING_MPEG_1; struct v4l2_subdev_format format = { .which = V4L2_SUBDEV_FORMAT_ACTIVE, }; @@ -122,9 +122,9 @@ static int ivtv_g_volatile_ctrl(struct v4l2_ctrl *ctrl) struct ivtv *itv = container_of(ctrl->handler, struct ivtv, cxhdl.hdl); switch (ctrl->id) { - /* V4L2_CID_MPEG_VIDEO_DEC_PTS and V4L2_CID_MPEG_VIDEO_DEC_FRAME + /* V4L2_CID_CODEC_VIDEO_DEC_PTS and V4L2_CID_CODEC_VIDEO_DEC_FRAME control cluster */ - case V4L2_CID_MPEG_VIDEO_DEC_PTS: + case V4L2_CID_CODEC_VIDEO_DEC_PTS: return ivtv_g_pts_frame(itv, itv->ctrl_pts->p_new.p_s64, itv->ctrl_frame->p_new.p_s64); } @@ -136,9 +136,9 @@ static int ivtv_s_ctrl(struct v4l2_ctrl *ctrl) struct ivtv *itv = container_of(ctrl->handler, struct ivtv, cxhdl.hdl); switch (ctrl->id) { - /* V4L2_CID_MPEG_AUDIO_DEC_PLAYBACK and MULTILINGUAL_PLAYBACK + /* V4L2_CID_CODEC_AUDIO_DEC_PLAYBACK and MULTILINGUAL_PLAYBACK control cluster */ - case V4L2_CID_MPEG_AUDIO_DEC_PLAYBACK: + case V4L2_CID_CODEC_AUDIO_DEC_PLAYBACK: itv->audio_stereo_mode = itv->ctrl_audio_playback->val - 1; itv->audio_bilingual_mode = itv->ctrl_audio_multilingual_playback->val - 1; ivtv_vapi(itv, CX2341X_DEC_SET_AUDIO_MODE, 2, itv->audio_bilingual_mode, itv->audio_stereo_mode); diff --git a/drivers/media/pci/ivtv/ivtv-driver.c b/drivers/media/pci/ivtv/ivtv-driver.c index c4a069b3b9d1..fe19e8f28599 100644 --- a/drivers/media/pci/ivtv/ivtv-driver.c +++ b/drivers/media/pci/ivtv/ivtv-driver.c @@ -1216,23 +1216,23 @@ static int ivtv_probe(struct pci_dev *pdev, const struct pci_device_id *pci_id) struct v4l2_ctrl_handler *hdl = itv->v4l2_dev.ctrl_handler; itv->ctrl_pts = v4l2_ctrl_new_std(hdl, &ivtv_hdl_out_ops, - V4L2_CID_MPEG_VIDEO_DEC_PTS, 0, 0, 0, 0); + V4L2_CID_CODEC_VIDEO_DEC_PTS, 0, 0, 0, 0); itv->ctrl_frame = v4l2_ctrl_new_std(hdl, &ivtv_hdl_out_ops, - V4L2_CID_MPEG_VIDEO_DEC_FRAME, 0, 0, 0, 0); - /* Note: V4L2_MPEG_AUDIO_DEC_PLAYBACK_AUTO is not supported, + V4L2_CID_CODEC_VIDEO_DEC_FRAME, 0, 0, 0, 0); + /* Note: V4L2_CODEC_AUDIO_DEC_PLAYBACK_AUTO is not supported, mask that menu item. */ itv->ctrl_audio_playback = v4l2_ctrl_new_std_menu(hdl, &ivtv_hdl_out_ops, - V4L2_CID_MPEG_AUDIO_DEC_PLAYBACK, - V4L2_MPEG_AUDIO_DEC_PLAYBACK_SWAPPED_STEREO, - 1 << V4L2_MPEG_AUDIO_DEC_PLAYBACK_AUTO, - V4L2_MPEG_AUDIO_DEC_PLAYBACK_STEREO); + V4L2_CID_CODEC_AUDIO_DEC_PLAYBACK, + V4L2_CODEC_AUDIO_DEC_PLAYBACK_SWAPPED_STEREO, + 1 << V4L2_CODEC_AUDIO_DEC_PLAYBACK_AUTO, + V4L2_CODEC_AUDIO_DEC_PLAYBACK_STEREO); itv->ctrl_audio_multilingual_playback = v4l2_ctrl_new_std_menu(hdl, &ivtv_hdl_out_ops, - V4L2_CID_MPEG_AUDIO_DEC_MULTILINGUAL_PLAYBACK, - V4L2_MPEG_AUDIO_DEC_PLAYBACK_SWAPPED_STEREO, - 1 << V4L2_MPEG_AUDIO_DEC_PLAYBACK_AUTO, - V4L2_MPEG_AUDIO_DEC_PLAYBACK_LEFT); + V4L2_CID_CODEC_AUDIO_DEC_MULTILINGUAL_PLAYBACK, + V4L2_CODEC_AUDIO_DEC_PLAYBACK_SWAPPED_STEREO, + 1 << V4L2_CODEC_AUDIO_DEC_PLAYBACK_AUTO, + V4L2_CODEC_AUDIO_DEC_PLAYBACK_LEFT); if (hdl->error) { retval = hdl->error; goto free_i2c; diff --git a/drivers/media/pci/ivtv/ivtv-ioctl.c b/drivers/media/pci/ivtv/ivtv-ioctl.c index 35dccb31174c..fc815a175be6 100644 --- a/drivers/media/pci/ivtv/ivtv-ioctl.c +++ b/drivers/media/pci/ivtv/ivtv-ioctl.c @@ -591,7 +591,7 @@ static int ivtv_s_fmt_vid_cap(struct file *file, void *fh, struct v4l2_format *f itv->cxhdl.width = w; itv->cxhdl.height = h; - if (v4l2_ctrl_g_ctrl(itv->cxhdl.video_encoding) == V4L2_MPEG_VIDEO_ENCODING_MPEG_1) + if (v4l2_ctrl_g_ctrl(itv->cxhdl.video_encoding) == V4L2_CODEC_VIDEO_ENCODING_MPEG_1) fmt->fmt.pix.width /= 2; format.format.width = fmt->fmt.pix.width; format.format.height = h; @@ -1517,7 +1517,7 @@ static int ivtv_log_status(struct file *file, void *fh) ivtv_get_audio_input(itv, itv->audio_input, &audin); IVTV_INFO("Video Input: %s\n", vidin.name); IVTV_INFO("Audio Input: %s%s\n", audin.name, - itv->dualwatch_stereo_mode == V4L2_MPEG_AUDIO_MODE_DUAL ? + itv->dualwatch_stereo_mode == V4L2_CODEC_AUDIO_MODE_DUAL ? " (Bilingual)" : ""); if (has_output) { struct v4l2_output vidout; diff --git a/drivers/media/pci/saa7164/saa7164-api.c b/drivers/media/pci/saa7164/saa7164-api.c index 4ddd0f5b50f1..1a60b228c796 100644 --- a/drivers/media/pci/saa7164/saa7164-api.c +++ b/drivers/media/pci/saa7164/saa7164-api.c @@ -180,7 +180,7 @@ int saa7164_api_set_encoder(struct saa7164_port *port) dprintk(DBGLVL_ENC, "%s() unitid=0x%x\n", __func__, port->hwcfg.sourceid); - if (port->encoder_params.stream_type == V4L2_MPEG_STREAM_TYPE_MPEG2_PS) + if (port->encoder_params.stream_type == V4L2_CODEC_STREAM_TYPE_MPEG2_PS) port->encoder_profile = EU_PROFILE_PS_DVD; else port->encoder_profile = EU_PROFILE_TS_HQ; @@ -198,7 +198,7 @@ int saa7164_api_set_encoder(struct saa7164_port *port) /* Establish video bitrates */ if (port->encoder_params.bitrate_mode == - V4L2_MPEG_VIDEO_BITRATE_MODE_CBR) + V4L2_CODEC_VIDEO_BITRATE_MODE_CBR) vb.ucVideoBitRateMode = EU_VIDEO_BIT_RATE_MODE_CONSTANT; else vb.ucVideoBitRateMode = EU_VIDEO_BIT_RATE_MODE_VARIABLE_PEAK; @@ -317,19 +317,19 @@ int saa7164_api_set_aspect_ratio(struct saa7164_port *port) port->encoder_params.ctl_aspect); switch (port->encoder_params.ctl_aspect) { - case V4L2_MPEG_VIDEO_ASPECT_1x1: + case V4L2_CODEC_VIDEO_ASPECT_1x1: ar.width = 1; ar.height = 1; break; - case V4L2_MPEG_VIDEO_ASPECT_4x3: + case V4L2_CODEC_VIDEO_ASPECT_4x3: ar.width = 4; ar.height = 3; break; - case V4L2_MPEG_VIDEO_ASPECT_16x9: + case V4L2_CODEC_VIDEO_ASPECT_16x9: ar.width = 16; ar.height = 9; break; - case V4L2_MPEG_VIDEO_ASPECT_221x100: + case V4L2_CODEC_VIDEO_ASPECT_221x100: ar.width = 221; ar.height = 100; break; diff --git a/drivers/media/pci/saa7164/saa7164-core.c b/drivers/media/pci/saa7164/saa7164-core.c index 7973ae42873a..29b9276579bd 100644 --- a/drivers/media/pci/saa7164/saa7164-core.c +++ b/drivers/media/pci/saa7164/saa7164-core.c @@ -292,9 +292,9 @@ static void saa7164_work_enchandler_helper(struct saa7164_port *port, int bufnr) if ((port->nr != SAA7164_PORT_VBI1) && (port->nr != SAA7164_PORT_VBI2)) { /* Validate the incoming buffer content */ - if (port->encoder_params.stream_type == V4L2_MPEG_STREAM_TYPE_MPEG2_TS) + if (port->encoder_params.stream_type == V4L2_CODEC_STREAM_TYPE_MPEG2_TS) saa7164_ts_verifier(buf); - else if (port->encoder_params.stream_type == V4L2_MPEG_STREAM_TYPE_MPEG2_PS) + else if (port->encoder_params.stream_type == V4L2_CODEC_STREAM_TYPE_MPEG2_PS) saa7164_pack_verifier(buf); } diff --git a/drivers/media/pci/saa7164/saa7164-encoder.c b/drivers/media/pci/saa7164/saa7164-encoder.c index 11e1eb6a6809..e4fc5a9b539d 100644 --- a/drivers/media/pci/saa7164/saa7164-encoder.c +++ b/drivers/media/pci/saa7164/saa7164-encoder.c @@ -106,9 +106,9 @@ static int saa7164_encoder_buffers_alloc(struct saa7164_port *port) dprintk(DBGLVL_ENC, "%s()\n", __func__); if (port->encoder_params.stream_type == - V4L2_MPEG_STREAM_TYPE_MPEG2_PS) { + V4L2_CODEC_STREAM_TYPE_MPEG2_PS) { dprintk(DBGLVL_ENC, - "%s() type=V4L2_MPEG_STREAM_TYPE_MPEG2_PS\n", + "%s() type=V4L2_CODEC_STREAM_TYPE_MPEG2_PS\n", __func__); params->samplesperline = 128; params->numberoflines = 256; @@ -117,9 +117,9 @@ static int saa7164_encoder_buffers_alloc(struct saa7164_port *port) ((SAA7164_PS_NUMBER_OF_LINES * 128) / PAGE_SIZE); } else if (port->encoder_params.stream_type == - V4L2_MPEG_STREAM_TYPE_MPEG2_TS) { + V4L2_CODEC_STREAM_TYPE_MPEG2_TS) { dprintk(DBGLVL_ENC, - "%s() type=V4L2_MPEG_STREAM_TYPE_MPEG2_TS\n", + "%s() type=V4L2_CODEC_STREAM_TYPE_MPEG2_TS\n", __func__); params->samplesperline = 188; params->numberoflines = 312; @@ -437,13 +437,13 @@ static int saa7164_s_ctrl(struct v4l2_ctrl *ctrl) port->ctl_volume = ctrl->val; saa7164_api_set_audio_volume(port, port->ctl_volume); break; - case V4L2_CID_MPEG_VIDEO_BITRATE: + case V4L2_CID_CODEC_VIDEO_BITRATE: params->bitrate = ctrl->val; break; - case V4L2_CID_MPEG_STREAM_TYPE: + case V4L2_CID_CODEC_STREAM_TYPE: params->stream_type = ctrl->val; break; - case V4L2_CID_MPEG_AUDIO_MUTE: + case V4L2_CID_CODEC_AUDIO_MUTE: params->ctl_mute = ctrl->val; ret = saa7164_api_audio_mute(port, params->ctl_mute); if (ret != SAA_OK) { @@ -452,7 +452,7 @@ static int saa7164_s_ctrl(struct v4l2_ctrl *ctrl) ret = -EIO; } break; - case V4L2_CID_MPEG_VIDEO_ASPECT: + case V4L2_CID_CODEC_VIDEO_ASPECT: params->ctl_aspect = ctrl->val; ret = saa7164_api_set_aspect_ratio(port); if (ret != SAA_OK) { @@ -461,16 +461,16 @@ static int saa7164_s_ctrl(struct v4l2_ctrl *ctrl) ret = -EIO; } break; - case V4L2_CID_MPEG_VIDEO_BITRATE_MODE: + case V4L2_CID_CODEC_VIDEO_BITRATE_MODE: params->bitrate_mode = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_B_FRAMES: + case V4L2_CID_CODEC_VIDEO_B_FRAMES: params->refdist = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_BITRATE_PEAK: + case V4L2_CID_CODEC_VIDEO_BITRATE_PEAK: params->bitrate_peak = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_GOP_SIZE: + case V4L2_CID_CODEC_VIDEO_GOP_SIZE: params->gop_size = ctrl->val; break; default: @@ -1033,31 +1033,31 @@ int saa7164_encoder_register(struct saa7164_port *port) v4l2_ctrl_new_std(hdl, &saa7164_ctrl_ops, V4L2_CID_SHARPNESS, 0x0, 0x0f, 1, 8); v4l2_ctrl_new_std(hdl, &saa7164_ctrl_ops, - V4L2_CID_MPEG_AUDIO_MUTE, 0x0, 0x01, 1, 0); + V4L2_CID_CODEC_AUDIO_MUTE, 0x0, 0x01, 1, 0); v4l2_ctrl_new_std(hdl, &saa7164_ctrl_ops, V4L2_CID_AUDIO_VOLUME, -83, 24, 1, 20); v4l2_ctrl_new_std(hdl, &saa7164_ctrl_ops, - V4L2_CID_MPEG_VIDEO_BITRATE, + V4L2_CID_CODEC_VIDEO_BITRATE, ENCODER_MIN_BITRATE, ENCODER_MAX_BITRATE, 100000, ENCODER_DEF_BITRATE); v4l2_ctrl_new_std_menu(hdl, &saa7164_ctrl_ops, - V4L2_CID_MPEG_STREAM_TYPE, - V4L2_MPEG_STREAM_TYPE_MPEG2_TS, 0, - V4L2_MPEG_STREAM_TYPE_MPEG2_PS); + V4L2_CID_CODEC_STREAM_TYPE, + V4L2_CODEC_STREAM_TYPE_MPEG2_TS, 0, + V4L2_CODEC_STREAM_TYPE_MPEG2_PS); v4l2_ctrl_new_std_menu(hdl, &saa7164_ctrl_ops, - V4L2_CID_MPEG_VIDEO_ASPECT, - V4L2_MPEG_VIDEO_ASPECT_221x100, 0, - V4L2_MPEG_VIDEO_ASPECT_4x3); + V4L2_CID_CODEC_VIDEO_ASPECT, + V4L2_CODEC_VIDEO_ASPECT_221x100, 0, + V4L2_CODEC_VIDEO_ASPECT_4x3); v4l2_ctrl_new_std(hdl, &saa7164_ctrl_ops, - V4L2_CID_MPEG_VIDEO_GOP_SIZE, 1, 255, 1, 15); + V4L2_CID_CODEC_VIDEO_GOP_SIZE, 1, 255, 1, 15); v4l2_ctrl_new_std_menu(hdl, &saa7164_ctrl_ops, - V4L2_CID_MPEG_VIDEO_BITRATE_MODE, - V4L2_MPEG_VIDEO_BITRATE_MODE_CBR, 0, - V4L2_MPEG_VIDEO_BITRATE_MODE_VBR); + V4L2_CID_CODEC_VIDEO_BITRATE_MODE, + V4L2_CODEC_VIDEO_BITRATE_MODE_CBR, 0, + V4L2_CODEC_VIDEO_BITRATE_MODE_VBR); v4l2_ctrl_new_std(hdl, &saa7164_ctrl_ops, - V4L2_CID_MPEG_VIDEO_B_FRAMES, 1, 3, 1, 1); + V4L2_CID_CODEC_VIDEO_B_FRAMES, 1, 3, 1, 1); v4l2_ctrl_new_std(hdl, &saa7164_ctrl_ops, - V4L2_CID_MPEG_VIDEO_BITRATE_PEAK, + V4L2_CID_CODEC_VIDEO_BITRATE_PEAK, ENCODER_MIN_BITRATE, ENCODER_MAX_BITRATE, 100000, ENCODER_DEF_BITRATE); if (hdl->error) { diff --git a/drivers/media/pci/saa7164/saa7164.h b/drivers/media/pci/saa7164/saa7164.h index 4b4eb156e214..87de4b9898a1 100644 --- a/drivers/media/pci/saa7164/saa7164.h +++ b/drivers/media/pci/saa7164/saa7164.h @@ -262,7 +262,7 @@ struct saa7164_encoder_params { u32 bitrate; /* bps */ u32 bitrate_peak; /* bps */ u32 bitrate_mode; - u32 stream_type; /* V4L2_MPEG_STREAM_TYPE_MPEG2_TS */ + u32 stream_type; /* V4L2_CODEC_STREAM_TYPE_MPEG2_TS */ u32 audio_sampling_freq; u32 ctl_mute; @@ -279,7 +279,7 @@ struct saa7164_vbi_params { u32 bitrate; /* bps */ u32 bitrate_peak; /* bps */ u32 bitrate_mode; - u32 stream_type; /* V4L2_MPEG_STREAM_TYPE_MPEG2_TS */ + u32 stream_type; /* V4L2_CODEC_STREAM_TYPE_MPEG2_TS */ u32 audio_sampling_freq; u32 ctl_mute; diff --git a/drivers/media/pci/solo6x10/solo6x10-v4l2-enc.c b/drivers/media/pci/solo6x10/solo6x10-v4l2-enc.c index 0abcad4e84fa..c931d775a71e 100644 --- a/drivers/media/pci/solo6x10/solo6x10-v4l2-enc.c +++ b/drivers/media/pci/solo6x10/solo6x10-v4l2-enc.c @@ -1069,12 +1069,12 @@ static int solo_s_ctrl(struct v4l2_ctrl *ctrl) case V4L2_CID_SHARPNESS: return tw28_set_ctrl_val(solo_dev, ctrl->id, solo_enc->ch, ctrl->val); - case V4L2_CID_MPEG_VIDEO_GOP_SIZE: + case V4L2_CID_CODEC_VIDEO_GOP_SIZE: solo_enc->gop = ctrl->val; solo_reg_write(solo_dev, SOLO_VE_CH_GOP(solo_enc->ch), solo_enc->gop); solo_reg_write(solo_dev, SOLO_VE_CH_GOP_E(solo_enc->ch), solo_enc->gop); return 0; - case V4L2_CID_MPEG_VIDEO_H264_MIN_QP: + case V4L2_CID_CODEC_VIDEO_H264_MIN_QP: solo_enc->qp = ctrl->val; solo_reg_write(solo_dev, SOLO_VE_CH_QP(solo_enc->ch), solo_enc->qp); solo_reg_write(solo_dev, SOLO_VE_CH_QP_E(solo_enc->ch), solo_enc->qp); @@ -1231,9 +1231,9 @@ static struct solo_enc_dev *solo_enc_alloc(struct solo_dev *solo_dev, v4l2_ctrl_new_std(hdl, &solo_ctrl_ops, V4L2_CID_SHARPNESS, 0, 15, 1, 0); v4l2_ctrl_new_std(hdl, &solo_ctrl_ops, - V4L2_CID_MPEG_VIDEO_GOP_SIZE, 1, 255, 1, solo_dev->fps); + V4L2_CID_CODEC_VIDEO_GOP_SIZE, 1, 255, 1, solo_dev->fps); v4l2_ctrl_new_std(hdl, &solo_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_MIN_QP, 0, 31, 1, SOLO_DEFAULT_QP); + V4L2_CID_CODEC_VIDEO_H264_MIN_QP, 0, 31, 1, SOLO_DEFAULT_QP); v4l2_ctrl_new_std_menu(hdl, &solo_ctrl_ops, V4L2_CID_DETECT_MD_MODE, V4L2_DETECT_MD_MODE_THRESHOLD_GRID, 0, diff --git a/drivers/media/pci/tw5864/tw5864-video.c b/drivers/media/pci/tw5864/tw5864-video.c index 9131265c2b87..0f0fe4b41a51 100644 --- a/drivers/media/pci/tw5864/tw5864-video.c +++ b/drivers/media/pci/tw5864/tw5864-video.c @@ -500,10 +500,10 @@ static int tw5864_s_ctrl(struct v4l2_ctrl *ctrl) tw_indir_writeb(TW5864_INDIR_VIN_C_SAT_V(input->nr), (u8)ctrl->val); break; - case V4L2_CID_MPEG_VIDEO_GOP_SIZE: + case V4L2_CID_CODEC_VIDEO_GOP_SIZE: input->gop = ctrl->val; return 0; - case V4L2_CID_MPEG_VIDEO_H264_MIN_QP: + case V4L2_CID_CODEC_VIDEO_H264_MIN_QP: spin_lock_irqsave(&input->slock, flags); input->qp = ctrl->val; input->reg_dsp_qp = input->qp; @@ -1136,10 +1136,10 @@ static int tw5864_video_input_init(struct tw5864_input *input, int video_nr) v4l2_ctrl_new_std(hdl, &tw5864_ctrl_ops, V4L2_CID_SATURATION, 0, 255, 1, 128); v4l2_ctrl_new_std(hdl, &tw5864_ctrl_ops, V4L2_CID_HUE, -128, 127, 1, 0); - v4l2_ctrl_new_std(hdl, &tw5864_ctrl_ops, V4L2_CID_MPEG_VIDEO_GOP_SIZE, + v4l2_ctrl_new_std(hdl, &tw5864_ctrl_ops, V4L2_CID_CODEC_VIDEO_GOP_SIZE, 1, MAX_GOP_SIZE, 1, GOP_SIZE); v4l2_ctrl_new_std(hdl, &tw5864_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_MIN_QP, 28, 51, 1, QP_VALUE); + V4L2_CID_CODEC_VIDEO_H264_MIN_QP, 28, 51, 1, QP_VALUE); v4l2_ctrl_new_std_menu(hdl, &tw5864_ctrl_ops, V4L2_CID_DETECT_MD_MODE, V4L2_DETECT_MD_MODE_THRESHOLD_GRID, 0, From patchwork Sat Mar 13 14:43:16 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans Verkuil X-Patchwork-Id: 400254 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-18.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER, INCLUDES_PATCH, MAILING_LIST_MULTI, SPF_HELO_NONE, SPF_PASS, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7E7FCC4332E for ; Sat, 13 Mar 2021 14:44:26 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 6C6A164F2E for ; Sat, 13 Mar 2021 14:44:26 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234067AbhCMOnw (ORCPT ); Sat, 13 Mar 2021 09:43:52 -0500 Received: from lb3-smtp-cloud9.xs4all.net ([194.109.24.30]:36105 "EHLO lb3-smtp-cloud9.xs4all.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234033AbhCMOna (ORCPT ); Sat, 13 Mar 2021 09:43:30 -0500 Received: from cust-b5b5937f ([IPv6:fc0c:c16d:66b8:757f:c639:739b:9d66:799d]) by smtp-cloud9.xs4all.net with ESMTPA id L5UBljyoWC40pL5UHlV5eF; Sat, 13 Mar 2021 15:43:29 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=xs4all.nl; s=s2; t=1615646609; bh=aATMYyeNTX6JQmtF9LMH0YzWn52oU5nafLmfwDYuxJw=; h=From:To:Subject:Date:Message-Id:MIME-Version:From:Subject; b=riA5wVi8g+IK+b6K03MqAp3JxNH5O1w5NL+KEqoPPFHaiBJo33Sfk0YefluaIa2GR cizMebE1clmTyEM5SXq+IiUAF1/N8Y5WbPcvCu5obxTwC11F0Kdw/sEy4GNp/E7FoL DGO7IzplwkdM9pbsJeLbByeqwzFsdTYEA/cqUrrYHF6/8d7uIeJ1PcFuhpZVCO8iUY 9+kC/s7gxAzfDyEOn1EW0JIzlucbUgsdvZVbDpXFJKenuqMTYI0Xd7y3mKjHn4QnZU srUe/gMaqCtwFeGIBLeFcwHHP5J3tEuQ9CE10pdIgBTJv8Y3z8qxALFDIhmZVkRAG0 xnEG6qu3r2RbA== From: Hans Verkuil To: linux-media@vger.kernel.org Cc: Ezequiel Garcia , Nicolas Dufresne , Tomasz Figa , Alexandre Courbot , Hans Verkuil Subject: [PATCH 08/15] media/usb: rename MPEG to CODEC Date: Sat, 13 Mar 2021 15:43:16 +0100 Message-Id: <20210313144323.143600-9-hverkuil-cisco@xs4all.nl> X-Mailer: git-send-email 2.30.1 In-Reply-To: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> References: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> MIME-Version: 1.0 X-CMAE-Envelope: MS4xfHB20MmtF5ZcYetgXeMEMm916KOLGm4CPZp4loUBMb4p735IcJ67kybPCw6oLhk36CkLiIbYkSy/XTsGdBZMReFwjEZwC922p9K7bU4wslAFdYlR5M7M dSkvAl5oCD5Eps37hYkSc/INvgFdyL4ayp75pW0RWxRN/Z/GeWD0y44I5Z6D3gjTM1DNgK8JVcV1YCXHdjsBOf8B04vYoJ0zC1OJxDZyC37ES+VumK3BGuT/ ltuj5UhuoVVT+uDCgWcfNEMHd0uyQkpT4M6455DHwYFyIuqnsgELwMnEsa2IXyDbrGlTq7uUo+FzIbApU+9/N4hUTW8pPXf5/TpnS5hxCbmTwr1qpBizIMEK jFUhB5vxbxvJ6+r+NOgJr8jCvLWy1g== Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Historically all codec-related data structures and defines used the MPEG prefix. This is confusing. Rename MPEG to CODEC to make it clear that the MPEG prefix isn't MPEG specific. Signed-off-by: Hans Verkuil --- drivers/media/usb/cx231xx/cx231xx-417.c | 2 +- drivers/media/usb/go7007/go7007-v4l2.c | 22 ++++---- drivers/media/usb/hdpvr/hdpvr-control.c | 6 +-- drivers/media/usb/hdpvr/hdpvr-core.c | 4 +- drivers/media/usb/hdpvr/hdpvr-video.c | 46 ++++++++-------- drivers/media/usb/hdpvr/hdpvr.h | 4 +- drivers/media/usb/pvrusb2/pvrusb2-hdw.c | 72 ++++++++++++------------- 7 files changed, 78 insertions(+), 78 deletions(-) diff --git a/drivers/media/usb/cx231xx/cx231xx-417.c b/drivers/media/usb/cx231xx/cx231xx-417.c index c5e21785fafe..ea9ed9a1fe4d 100644 --- a/drivers/media/usb/cx231xx/cx231xx-417.c +++ b/drivers/media/usb/cx231xx/cx231xx-417.c @@ -1674,7 +1674,7 @@ void cx231xx_417_unregister(struct cx231xx *dev) static int cx231xx_s_video_encoding(struct cx2341x_handler *cxhdl, u32 val) { struct cx231xx *dev = container_of(cxhdl, struct cx231xx, mpeg_ctrl_handler); - int is_mpeg1 = val == V4L2_MPEG_VIDEO_ENCODING_MPEG_1; + int is_mpeg1 = val == V4L2_CODEC_VIDEO_ENCODING_MPEG_1; struct v4l2_subdev_format format = { .which = V4L2_SUBDEV_FORMAT_ACTIVE, }; diff --git a/drivers/media/usb/go7007/go7007-v4l2.c b/drivers/media/usb/go7007/go7007-v4l2.c index b2edc4deaca3..fd1c1520ea31 100644 --- a/drivers/media/usb/go7007/go7007-v4l2.c +++ b/drivers/media/usb/go7007/go7007-v4l2.c @@ -161,13 +161,13 @@ static void set_formatting(struct go7007 *go) switch (v4l2_ctrl_g_ctrl(go->mpeg_video_aspect_ratio)) { default: - case V4L2_MPEG_VIDEO_ASPECT_1x1: + case V4L2_CODEC_VIDEO_ASPECT_1x1: go->aspect_ratio = GO7007_RATIO_1_1; break; - case V4L2_MPEG_VIDEO_ASPECT_4x3: + case V4L2_CODEC_VIDEO_ASPECT_4x3: go->aspect_ratio = GO7007_RATIO_4_3; break; - case V4L2_MPEG_VIDEO_ASPECT_16x9: + case V4L2_CODEC_VIDEO_ASPECT_16x9: go->aspect_ratio = GO7007_RATIO_16_9; break; } @@ -1020,21 +1020,21 @@ int go7007_v4l2_ctrl_init(struct go7007 *go) v4l2_ctrl_handler_init(hdl, 22); go->mpeg_video_gop_size = v4l2_ctrl_new_std(hdl, NULL, - V4L2_CID_MPEG_VIDEO_GOP_SIZE, 0, 34, 1, 15); + V4L2_CID_CODEC_VIDEO_GOP_SIZE, 0, 34, 1, 15); go->mpeg_video_gop_closure = v4l2_ctrl_new_std(hdl, NULL, - V4L2_CID_MPEG_VIDEO_GOP_CLOSURE, 0, 1, 1, 1); + V4L2_CID_CODEC_VIDEO_GOP_CLOSURE, 0, 1, 1, 1); go->mpeg_video_bitrate = v4l2_ctrl_new_std(hdl, NULL, - V4L2_CID_MPEG_VIDEO_BITRATE, + V4L2_CID_CODEC_VIDEO_BITRATE, 64000, 10000000, 1, 9800000); go->mpeg_video_b_frames = v4l2_ctrl_new_std(hdl, NULL, - V4L2_CID_MPEG_VIDEO_B_FRAMES, 0, 2, 2, 0); + V4L2_CID_CODEC_VIDEO_B_FRAMES, 0, 2, 2, 0); go->mpeg_video_rep_seqheader = v4l2_ctrl_new_std(hdl, NULL, - V4L2_CID_MPEG_VIDEO_REPEAT_SEQ_HEADER, 0, 1, 1, 1); + V4L2_CID_CODEC_VIDEO_REPEAT_SEQ_HEADER, 0, 1, 1, 1); go->mpeg_video_aspect_ratio = v4l2_ctrl_new_std_menu(hdl, NULL, - V4L2_CID_MPEG_VIDEO_ASPECT, - V4L2_MPEG_VIDEO_ASPECT_16x9, 0, - V4L2_MPEG_VIDEO_ASPECT_1x1); + V4L2_CID_CODEC_VIDEO_ASPECT, + V4L2_CODEC_VIDEO_ASPECT_16x9, 0, + V4L2_CODEC_VIDEO_ASPECT_1x1); ctrl = v4l2_ctrl_new_std(hdl, NULL, V4L2_CID_JPEG_ACTIVE_MARKER, 0, V4L2_JPEG_ACTIVE_MARKER_DQT | diff --git a/drivers/media/usb/hdpvr/hdpvr-control.c b/drivers/media/usb/hdpvr/hdpvr-control.c index 37c53ab85b30..0951f4d6bddf 100644 --- a/drivers/media/usb/hdpvr/hdpvr-control.c +++ b/drivers/media/usb/hdpvr/hdpvr-control.c @@ -118,7 +118,7 @@ int hdpvr_set_bitrate(struct hdpvr_device *dev) } int hdpvr_set_audio(struct hdpvr_device *dev, u8 input, - enum v4l2_mpeg_audio_encoding codec) + enum v4l2_codec_audio_encoding codec) { int ret = 0; @@ -126,9 +126,9 @@ int hdpvr_set_audio(struct hdpvr_device *dev, u8 input, mutex_lock(&dev->usbc_mutex); memset(dev->usbc_buf, 0, 2); dev->usbc_buf[0] = input; - if (codec == V4L2_MPEG_AUDIO_ENCODING_AAC) + if (codec == V4L2_CODEC_AUDIO_ENCODING_AAC) dev->usbc_buf[1] = 0; - else if (codec == V4L2_MPEG_AUDIO_ENCODING_AC3) + else if (codec == V4L2_CODEC_AUDIO_ENCODING_AC3) dev->usbc_buf[1] = 1; else { mutex_unlock(&dev->usbc_mutex); diff --git a/drivers/media/usb/hdpvr/hdpvr-core.c b/drivers/media/usb/hdpvr/hdpvr-core.c index 52e05a69c46e..e35a27b1b8a4 100644 --- a/drivers/media/usb/hdpvr/hdpvr-core.c +++ b/drivers/media/usb/hdpvr/hdpvr-core.c @@ -251,7 +251,7 @@ static const struct hdpvr_options hdpvr_default_options = { .peak_bitrate = 90, /* 9 mbps */ .bitrate_mode = HDPVR_CONSTANT, .gop_mode = HDPVR_SIMPLE_IDR_GOP, - .audio_codec = V4L2_MPEG_AUDIO_ENCODING_AAC, + .audio_codec = V4L2_CODEC_AUDIO_ENCODING_AAC, /* original picture controls for firmware version <= 0x15 */ /* updated in device_authorization() for newer firmware */ .brightness = 0x86, @@ -314,7 +314,7 @@ static int hdpvr_probe(struct usb_interface *interface, dev->options.audio_input = default_audio_input; if (default_audio_input == HDPVR_SPDIF) dev->options.audio_codec = - V4L2_MPEG_AUDIO_ENCODING_AC3; + V4L2_CODEC_AUDIO_ENCODING_AC3; } dev->udev = usb_get_dev(interface_to_usbdev(interface)); diff --git a/drivers/media/usb/hdpvr/hdpvr-video.c b/drivers/media/usb/hdpvr/hdpvr-video.c index 563128d11731..8eb0bdc977e7 100644 --- a/drivers/media/usb/hdpvr/hdpvr-video.c +++ b/drivers/media/usb/hdpvr/hdpvr-video.c @@ -881,8 +881,8 @@ static int hdpvr_try_ctrl(struct v4l2_ctrl *ctrl) container_of(ctrl->handler, struct hdpvr_device, hdl); switch (ctrl->id) { - case V4L2_CID_MPEG_VIDEO_BITRATE_MODE: - if (ctrl->val == V4L2_MPEG_VIDEO_BITRATE_MODE_VBR && + case V4L2_CID_CODEC_VIDEO_BITRATE_MODE: + if (ctrl->val == V4L2_CODEC_VIDEO_BITRATE_MODE_VBR && dev->video_bitrate->val >= dev->video_bitrate_peak->val) dev->video_bitrate_peak->val = dev->video_bitrate->val + 100000; @@ -929,16 +929,16 @@ static int hdpvr_s_ctrl(struct v4l2_ctrl *ctrl) break; dev->options.sharpness = ctrl->val; return 0; - case V4L2_CID_MPEG_AUDIO_ENCODING: + case V4L2_CID_CODEC_AUDIO_ENCODING: if (dev->flags & HDPVR_FLAG_AC3_CAP) { opt->audio_codec = ctrl->val; return hdpvr_set_audio(dev, opt->audio_input + 1, opt->audio_codec); } return 0; - case V4L2_CID_MPEG_VIDEO_ENCODING: + case V4L2_CID_CODEC_VIDEO_ENCODING: return 0; -/* case V4L2_CID_MPEG_VIDEO_B_FRAMES: */ +/* case V4L2_CID_CODEC_VIDEO_B_FRAMES: */ /* if (ctrl->value == 0 && !(opt->gop_mode & 0x2)) { */ /* opt->gop_mode |= 0x2; */ /* hdpvr_config_call(dev, CTRL_GOP_MODE_VALUE, */ @@ -950,19 +950,19 @@ static int hdpvr_s_ctrl(struct v4l2_ctrl *ctrl) /* opt->gop_mode); */ /* } */ /* break; */ - case V4L2_CID_MPEG_VIDEO_BITRATE_MODE: { + case V4L2_CID_CODEC_VIDEO_BITRATE_MODE: { uint peak_bitrate = dev->video_bitrate_peak->val / 100000; uint bitrate = dev->video_bitrate->val / 100000; if (ctrl->is_new) { - if (ctrl->val == V4L2_MPEG_VIDEO_BITRATE_MODE_CBR) + if (ctrl->val == V4L2_CODEC_VIDEO_BITRATE_MODE_CBR) opt->bitrate_mode = HDPVR_CONSTANT; else opt->bitrate_mode = HDPVR_VARIABLE_AVERAGE; hdpvr_config_call(dev, CTRL_BITRATE_MODE_VALUE, opt->bitrate_mode); v4l2_ctrl_activate(dev->video_bitrate_peak, - ctrl->val != V4L2_MPEG_VIDEO_BITRATE_MODE_CBR); + ctrl->val != V4L2_CODEC_VIDEO_BITRATE_MODE_CBR); } if (dev->video_bitrate_peak->is_new || @@ -973,7 +973,7 @@ static int hdpvr_s_ctrl(struct v4l2_ctrl *ctrl) } return 0; } - case V4L2_CID_MPEG_STREAM_TYPE: + case V4L2_CID_CODEC_STREAM_TYPE: return 0; default: break; @@ -1195,28 +1195,28 @@ int hdpvr_register_videodev(struct hdpvr_device *dev, struct device *parent, } v4l2_ctrl_new_std_menu(hdl, &hdpvr_ctrl_ops, - V4L2_CID_MPEG_STREAM_TYPE, - V4L2_MPEG_STREAM_TYPE_MPEG2_TS, - 0x1, V4L2_MPEG_STREAM_TYPE_MPEG2_TS); + V4L2_CID_CODEC_STREAM_TYPE, + V4L2_CODEC_STREAM_TYPE_MPEG2_TS, + 0x1, V4L2_CODEC_STREAM_TYPE_MPEG2_TS); v4l2_ctrl_new_std_menu(hdl, &hdpvr_ctrl_ops, - V4L2_CID_MPEG_AUDIO_ENCODING, - ac3 ? V4L2_MPEG_AUDIO_ENCODING_AC3 : V4L2_MPEG_AUDIO_ENCODING_AAC, - 0x7, ac3 ? dev->options.audio_codec : V4L2_MPEG_AUDIO_ENCODING_AAC); + V4L2_CID_CODEC_AUDIO_ENCODING, + ac3 ? V4L2_CODEC_AUDIO_ENCODING_AC3 : V4L2_CODEC_AUDIO_ENCODING_AAC, + 0x7, ac3 ? dev->options.audio_codec : V4L2_CODEC_AUDIO_ENCODING_AAC); v4l2_ctrl_new_std_menu(hdl, &hdpvr_ctrl_ops, - V4L2_CID_MPEG_VIDEO_ENCODING, - V4L2_MPEG_VIDEO_ENCODING_MPEG_4_AVC, 0x3, - V4L2_MPEG_VIDEO_ENCODING_MPEG_4_AVC); + V4L2_CID_CODEC_VIDEO_ENCODING, + V4L2_CODEC_VIDEO_ENCODING_MPEG_4_AVC, 0x3, + V4L2_CODEC_VIDEO_ENCODING_MPEG_4_AVC); dev->video_mode = v4l2_ctrl_new_std_menu(hdl, &hdpvr_ctrl_ops, - V4L2_CID_MPEG_VIDEO_BITRATE_MODE, - V4L2_MPEG_VIDEO_BITRATE_MODE_CBR, 0, - V4L2_MPEG_VIDEO_BITRATE_MODE_CBR); + V4L2_CID_CODEC_VIDEO_BITRATE_MODE, + V4L2_CODEC_VIDEO_BITRATE_MODE_CBR, 0, + V4L2_CODEC_VIDEO_BITRATE_MODE_CBR); dev->video_bitrate = v4l2_ctrl_new_std(hdl, &hdpvr_ctrl_ops, - V4L2_CID_MPEG_VIDEO_BITRATE, + V4L2_CID_CODEC_VIDEO_BITRATE, 1000000, 13500000, 100000, 6500000); dev->video_bitrate_peak = v4l2_ctrl_new_std(hdl, &hdpvr_ctrl_ops, - V4L2_CID_MPEG_VIDEO_BITRATE_PEAK, + V4L2_CID_CODEC_VIDEO_BITRATE_PEAK, 1100000, 20200000, 100000, 9000000); dev->v4l2_dev.ctrl_handler = hdl; if (hdl->error) { diff --git a/drivers/media/usb/hdpvr/hdpvr.h b/drivers/media/usb/hdpvr/hdpvr.h index 84519c962cb4..bc1296cafb5e 100644 --- a/drivers/media/usb/hdpvr/hdpvr.h +++ b/drivers/media/usb/hdpvr/hdpvr.h @@ -51,7 +51,7 @@ struct hdpvr_options { u8 peak_bitrate; /* in 100kbps */ u8 bitrate_mode; u8 gop_mode; - enum v4l2_mpeg_audio_encoding audio_codec; + enum v4l2_codec_audio_encoding audio_codec; u8 brightness; u8 contrast; u8 hue; @@ -293,7 +293,7 @@ int hdpvr_set_options(struct hdpvr_device *dev); int hdpvr_set_bitrate(struct hdpvr_device *dev); int hdpvr_set_audio(struct hdpvr_device *dev, u8 input, - enum v4l2_mpeg_audio_encoding codec); + enum v4l2_codec_audio_encoding codec); int hdpvr_config_call(struct hdpvr_device *dev, uint value, unsigned char valbuf); diff --git a/drivers/media/usb/pvrusb2/pvrusb2-hdw.c b/drivers/media/usb/pvrusb2/pvrusb2-hdw.c index f4a727918e35..ab5f50c737f4 100644 --- a/drivers/media/usb/pvrusb2/pvrusb2-hdw.c +++ b/drivers/media/usb/pvrusb2/pvrusb2-hdw.c @@ -149,92 +149,92 @@ struct pvr2_mpeg_ids { static const struct pvr2_mpeg_ids mpeg_ids[] = { { .strid = "audio_layer", - .id = V4L2_CID_MPEG_AUDIO_ENCODING, + .id = V4L2_CID_CODEC_AUDIO_ENCODING, },{ .strid = "audio_bitrate", - .id = V4L2_CID_MPEG_AUDIO_L2_BITRATE, + .id = V4L2_CID_CODEC_AUDIO_L2_BITRATE, },{ /* Already using audio_mode elsewhere :-( */ .strid = "mpeg_audio_mode", - .id = V4L2_CID_MPEG_AUDIO_MODE, + .id = V4L2_CID_CODEC_AUDIO_MODE, },{ .strid = "mpeg_audio_mode_extension", - .id = V4L2_CID_MPEG_AUDIO_MODE_EXTENSION, + .id = V4L2_CID_CODEC_AUDIO_MODE_EXTENSION, },{ .strid = "audio_emphasis", - .id = V4L2_CID_MPEG_AUDIO_EMPHASIS, + .id = V4L2_CID_CODEC_AUDIO_EMPHASIS, },{ .strid = "audio_crc", - .id = V4L2_CID_MPEG_AUDIO_CRC, + .id = V4L2_CID_CODEC_AUDIO_CRC, },{ .strid = "video_aspect", - .id = V4L2_CID_MPEG_VIDEO_ASPECT, + .id = V4L2_CID_CODEC_VIDEO_ASPECT, },{ .strid = "video_b_frames", - .id = V4L2_CID_MPEG_VIDEO_B_FRAMES, + .id = V4L2_CID_CODEC_VIDEO_B_FRAMES, },{ .strid = "video_gop_size", - .id = V4L2_CID_MPEG_VIDEO_GOP_SIZE, + .id = V4L2_CID_CODEC_VIDEO_GOP_SIZE, },{ .strid = "video_gop_closure", - .id = V4L2_CID_MPEG_VIDEO_GOP_CLOSURE, + .id = V4L2_CID_CODEC_VIDEO_GOP_CLOSURE, },{ .strid = "video_bitrate_mode", - .id = V4L2_CID_MPEG_VIDEO_BITRATE_MODE, + .id = V4L2_CID_CODEC_VIDEO_BITRATE_MODE, },{ .strid = "video_bitrate", - .id = V4L2_CID_MPEG_VIDEO_BITRATE, + .id = V4L2_CID_CODEC_VIDEO_BITRATE, },{ .strid = "video_bitrate_peak", - .id = V4L2_CID_MPEG_VIDEO_BITRATE_PEAK, + .id = V4L2_CID_CODEC_VIDEO_BITRATE_PEAK, },{ .strid = "video_temporal_decimation", - .id = V4L2_CID_MPEG_VIDEO_TEMPORAL_DECIMATION, + .id = V4L2_CID_CODEC_VIDEO_TEMPORAL_DECIMATION, },{ .strid = "stream_type", - .id = V4L2_CID_MPEG_STREAM_TYPE, + .id = V4L2_CID_CODEC_STREAM_TYPE, },{ .strid = "video_spatial_filter_mode", - .id = V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE, + .id = V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER_MODE, },{ .strid = "video_spatial_filter", - .id = V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER, + .id = V4L2_CID_CODEC_CX2341X_VIDEO_SPATIAL_FILTER, },{ .strid = "video_luma_spatial_filter_type", - .id = V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE, + .id = V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE, },{ .strid = "video_chroma_spatial_filter_type", - .id = V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE, + .id = V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE, },{ .strid = "video_temporal_filter_mode", - .id = V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE, + .id = V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER_MODE, },{ .strid = "video_temporal_filter", - .id = V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER, + .id = V4L2_CID_CODEC_CX2341X_VIDEO_TEMPORAL_FILTER, },{ .strid = "video_median_filter_type", - .id = V4L2_CID_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE, + .id = V4L2_CID_CODEC_CX2341X_VIDEO_MEDIAN_FILTER_TYPE, },{ .strid = "video_luma_median_filter_top", - .id = V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP, + .id = V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP, },{ .strid = "video_luma_median_filter_bottom", - .id = V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM, + .id = V4L2_CID_CODEC_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM, },{ .strid = "video_chroma_median_filter_top", - .id = V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP, + .id = V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP, },{ .strid = "video_chroma_median_filter_bottom", - .id = V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM, + .id = V4L2_CID_CODEC_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM, } }; #define MPEGDEF_COUNT ARRAY_SIZE(mpeg_ids) static const char *control_values_srate[] = { - [V4L2_MPEG_AUDIO_SAMPLING_FREQ_44100] = "44.1 kHz", - [V4L2_MPEG_AUDIO_SAMPLING_FREQ_48000] = "48 kHz", - [V4L2_MPEG_AUDIO_SAMPLING_FREQ_32000] = "32 kHz", + [V4L2_CODEC_AUDIO_SAMPLING_FREQ_44100] = "44.1 kHz", + [V4L2_CODEC_AUDIO_SAMPLING_FREQ_48000] = "48 kHz", + [V4L2_CODEC_AUDIO_SAMPLING_FREQ_32000] = "32 kHz", }; @@ -1152,8 +1152,8 @@ static const struct pvr2_ctl_info control_defs[] = { .get_max_value = ctrl_vres_max_get, .get_min_value = ctrl_vres_min_get, },{ - .v4l_id = V4L2_CID_MPEG_AUDIO_SAMPLING_FREQ, - .default_value = V4L2_MPEG_AUDIO_SAMPLING_FREQ_48000, + .v4l_id = V4L2_CID_CODEC_AUDIO_SAMPLING_FREQ, + .default_value = V4L2_CODEC_AUDIO_SAMPLING_FREQ_48000, .desc = "Audio Sampling Frequency", .name = "srate", DEFREF(srate), @@ -2932,13 +2932,13 @@ static void pvr2_subdev_update(struct pvr2_hdw *hdw) hdw->srate_val); switch (hdw->srate_val) { default: - case V4L2_MPEG_AUDIO_SAMPLING_FREQ_48000: + case V4L2_CODEC_AUDIO_SAMPLING_FREQ_48000: val = 48000; break; - case V4L2_MPEG_AUDIO_SAMPLING_FREQ_44100: + case V4L2_CODEC_AUDIO_SAMPLING_FREQ_44100: val = 44100; break; - case V4L2_MPEG_AUDIO_SAMPLING_FREQ_32000: + case V4L2_CODEC_AUDIO_SAMPLING_FREQ_32000: val = 32000; break; } @@ -3061,7 +3061,7 @@ static int pvr2_hdw_commit_execute(struct pvr2_hdw *hdw) memset(&c1, 0, sizeof(c1)); cs.controls = &c1; cs.count = 1; - c1.id = V4L2_CID_MPEG_VIDEO_GOP_SIZE; + c1.id = V4L2_CID_CODEC_VIDEO_GOP_SIZE; c1.value = gop_size; cx2341x_ext_ctrls(&hdw->enc_ctl_state, 0, &cs, VIDIOC_S_EXT_CTRLS); @@ -3123,7 +3123,7 @@ static int pvr2_hdw_commit_execute(struct pvr2_hdw *hdw) memset(&c1,0,sizeof(c1)); cs.controls = &c1; cs.count = 1; - c1.id = V4L2_CID_MPEG_AUDIO_SAMPLING_FREQ; + c1.id = V4L2_CID_CODEC_AUDIO_SAMPLING_FREQ; c1.value = hdw->srate_val; cx2341x_ext_ctrls(&hdw->enc_ctl_state, 0, &cs,VIDIOC_S_EXT_CTRLS); } From patchwork Sat Mar 13 14:43:17 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans Verkuil X-Patchwork-Id: 399845 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-18.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER, INCLUDES_PATCH, MAILING_LIST_MULTI, SPF_HELO_NONE, SPF_PASS, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 999A0C43332 for ; Sat, 13 Mar 2021 14:44:26 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 7CFA564F19 for ; Sat, 13 Mar 2021 14:44:26 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234065AbhCMOnw (ORCPT ); Sat, 13 Mar 2021 09:43:52 -0500 Received: from lb1-smtp-cloud9.xs4all.net ([194.109.24.22]:39887 "EHLO lb1-smtp-cloud9.xs4all.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234034AbhCMOnb (ORCPT ); Sat, 13 Mar 2021 09:43:31 -0500 Received: from cust-b5b5937f ([IPv6:fc0c:c16d:66b8:757f:c639:739b:9d66:799d]) by smtp-cloud9.xs4all.net with ESMTPA id L5UBljyoWC40pL5UIlV5eX; Sat, 13 Mar 2021 15:43:30 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=xs4all.nl; s=s2; t=1615646610; bh=Q7QiQVmH8VVhnSJZxvkP8BuPJlLvE+U9lNHKjTbZ3/U=; h=From:To:Subject:Date:Message-Id:MIME-Version:From:Subject; b=OLmm0SXOHINpoCcculWtqKYpDRaEH+fvm4bXOyl3ki/M+hta9Bq/1Ku0A0fLim4d8 ldLns/Gqs0J8VKDpvxt3A4XKwZfFIuD6tAUF54lrtAnojU4Z5UxoHEE1TdOdoZnxD2 UcPGkxPziY8KORjK/ZkZtONOMRxfjYQEwGF60ttvA9ibA4n5pz8AN/4Ta8J+qTI287 gwRp+HYSXCdekRlGho4c7eYScsLnwdfY3n66jAKD/LQygln8yjJMlDT5XpR587fpvf avNH/iHx1mh4x6bhXnmYnIWt4Xc80U9H38UxorodmAW6LN2G8VyX5w1uU0NQ0inhcv ZoGFccvfOGkNw== From: Hans Verkuil To: linux-media@vger.kernel.org Cc: Ezequiel Garcia , Nicolas Dufresne , Tomasz Figa , Alexandre Courbot , Hans Verkuil Subject: [PATCH 09/15] media/platform: rename MPEG to CODEC Date: Sat, 13 Mar 2021 15:43:17 +0100 Message-Id: <20210313144323.143600-10-hverkuil-cisco@xs4all.nl> X-Mailer: git-send-email 2.30.1 In-Reply-To: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> References: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> MIME-Version: 1.0 X-CMAE-Envelope: MS4xfIh2kl1GkjNDZ839RU89rU7JIlz/Dpg9Ug6+sf1vZ9aM0wB9FTrQXLWmvRXqms0kreacuBi5YkmdKj8bnJ7Us4Gy4qoOzqpcs4oOLhG6c8fl+fqFphUO 1TZh4fS6XwQ55u2ThsAxwVG6eSvUBoa++FhjYoPSEXsZ9IW4dbt/w40or9IiDT8zCwxsthOKeQpMVFDUd5ev739T3PfS5/CVs4/drG+I1k3ijeMjLpPblhXY xUOk0qRK6etC493qrR/4UOfwre0isvld9zigxomdadiZfqxJU+X6o54Kyhh5zz+avLBwf84TfGR8iOwbDAlosIPHZfK/A+gTaafjHx68aEr8EiLULp9tnanO aPnx8e2oupAaJjV3ZgzBcUbkVZvpqQ== Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Historically all codec-related data structures and defines used the MPEG prefix. This is confusing. Rename MPEG to CODEC to make it clear that the MPEG prefix isn't MPEG specific. Signed-off-by: Hans Verkuil --- .../media/platform/allegro-dvt/allegro-core.c | 348 ++++---- drivers/media/platform/allegro-dvt/nal-h264.c | 52 +- drivers/media/platform/allegro-dvt/nal-h264.h | 4 +- drivers/media/platform/allegro-dvt/nal-hevc.c | 42 +- drivers/media/platform/allegro-dvt/nal-hevc.h | 6 +- drivers/media/platform/coda/coda-bit.c | 8 +- drivers/media/platform/coda/coda-common.c | 218 ++--- drivers/media/platform/coda/coda-h264.c | 40 +- drivers/media/platform/coda/coda-mpeg2.c | 18 +- drivers/media/platform/coda/coda-mpeg4.c | 22 +- drivers/media/platform/coda/coda.h | 2 +- .../platform/mtk-vcodec/mtk_vcodec_dec.c | 6 +- .../platform/mtk-vcodec/mtk_vcodec_enc.c | 80 +- .../platform/mtk-vcodec/venc/venc_h264_if.c | 38 +- drivers/media/platform/qcom/venus/helpers.c | 154 ++-- .../media/platform/qcom/venus/vdec_ctrls.c | 92 +-- drivers/media/platform/qcom/venus/venc.c | 26 +- .../media/platform/qcom/venus/venc_ctrls.c | 294 +++---- .../media/platform/s5p-mfc/s5p_mfc_common.h | 28 +- drivers/media/platform/s5p-mfc/s5p_mfc_dec.c | 16 +- drivers/media/platform/s5p-mfc/s5p_mfc_enc.c | 764 +++++++++--------- .../media/platform/s5p-mfc/s5p_mfc_opr_v5.c | 12 +- .../media/platform/s5p-mfc/s5p_mfc_opr_v6.c | 38 +- drivers/media/platform/sti/hva/hva-debugfs.c | 10 +- drivers/media/platform/sti/hva/hva-h264.c | 48 +- drivers/media/platform/sti/hva/hva-v4l2.c | 100 +-- drivers/media/platform/sti/hva/hva.h | 14 +- 27 files changed, 1240 insertions(+), 1240 deletions(-) diff --git a/drivers/media/platform/allegro-dvt/allegro-core.c b/drivers/media/platform/allegro-dvt/allegro-core.c index 887b492e4ad1..1601ae01dfda 100644 --- a/drivers/media/platform/allegro-dvt/allegro-core.c +++ b/drivers/media/platform/allegro-dvt/allegro-core.c @@ -496,13 +496,13 @@ static unsigned int estimate_stream_size(unsigned int width, return round_up(offset + num_blocks * pcm_size + partition_table, 32); } -static enum v4l2_mpeg_video_h264_level +static enum v4l2_codec_video_h264_level select_minimum_h264_level(unsigned int width, unsigned int height) { unsigned int pic_width_in_mb = DIV_ROUND_UP(width, SIZE_MACROBLOCK); unsigned int frame_height_in_mb = DIV_ROUND_UP(height, SIZE_MACROBLOCK); unsigned int frame_size_in_mb = pic_width_in_mb * frame_height_in_mb; - enum v4l2_mpeg_video_h264_level level = V4L2_MPEG_VIDEO_H264_LEVEL_4_0; + enum v4l2_codec_video_h264_level level = V4L2_CODEC_VIDEO_H264_LEVEL_4_0; /* * The level limits are specified in Rec. ITU-T H.264 Annex A.3.1 and @@ -512,183 +512,183 @@ select_minimum_h264_level(unsigned int width, unsigned int height) * Level 5.1 allows up to 4k video resolution. */ if (frame_size_in_mb <= 99) - level = V4L2_MPEG_VIDEO_H264_LEVEL_1_0; + level = V4L2_CODEC_VIDEO_H264_LEVEL_1_0; else if (frame_size_in_mb <= 396) - level = V4L2_MPEG_VIDEO_H264_LEVEL_1_1; + level = V4L2_CODEC_VIDEO_H264_LEVEL_1_1; else if (frame_size_in_mb <= 792) - level = V4L2_MPEG_VIDEO_H264_LEVEL_2_1; + level = V4L2_CODEC_VIDEO_H264_LEVEL_2_1; else if (frame_size_in_mb <= 1620) - level = V4L2_MPEG_VIDEO_H264_LEVEL_2_2; + level = V4L2_CODEC_VIDEO_H264_LEVEL_2_2; else if (frame_size_in_mb <= 3600) - level = V4L2_MPEG_VIDEO_H264_LEVEL_3_1; + level = V4L2_CODEC_VIDEO_H264_LEVEL_3_1; else if (frame_size_in_mb <= 5120) - level = V4L2_MPEG_VIDEO_H264_LEVEL_3_2; + level = V4L2_CODEC_VIDEO_H264_LEVEL_3_2; else if (frame_size_in_mb <= 8192) - level = V4L2_MPEG_VIDEO_H264_LEVEL_4_0; + level = V4L2_CODEC_VIDEO_H264_LEVEL_4_0; else if (frame_size_in_mb <= 8704) - level = V4L2_MPEG_VIDEO_H264_LEVEL_4_2; + level = V4L2_CODEC_VIDEO_H264_LEVEL_4_2; else if (frame_size_in_mb <= 22080) - level = V4L2_MPEG_VIDEO_H264_LEVEL_5_0; + level = V4L2_CODEC_VIDEO_H264_LEVEL_5_0; else - level = V4L2_MPEG_VIDEO_H264_LEVEL_5_1; + level = V4L2_CODEC_VIDEO_H264_LEVEL_5_1; return level; } -static unsigned int h264_maximum_bitrate(enum v4l2_mpeg_video_h264_level level) +static unsigned int h264_maximum_bitrate(enum v4l2_codec_video_h264_level level) { switch (level) { - case V4L2_MPEG_VIDEO_H264_LEVEL_1_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_0: return 64000; - case V4L2_MPEG_VIDEO_H264_LEVEL_1B: + case V4L2_CODEC_VIDEO_H264_LEVEL_1B: return 128000; - case V4L2_MPEG_VIDEO_H264_LEVEL_1_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_1: return 192000; - case V4L2_MPEG_VIDEO_H264_LEVEL_1_2: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_2: return 384000; - case V4L2_MPEG_VIDEO_H264_LEVEL_1_3: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_3: return 768000; - case V4L2_MPEG_VIDEO_H264_LEVEL_2_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_2_0: return 2000000; - case V4L2_MPEG_VIDEO_H264_LEVEL_2_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_2_1: return 4000000; - case V4L2_MPEG_VIDEO_H264_LEVEL_2_2: + case V4L2_CODEC_VIDEO_H264_LEVEL_2_2: return 4000000; - case V4L2_MPEG_VIDEO_H264_LEVEL_3_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_3_0: return 10000000; - case V4L2_MPEG_VIDEO_H264_LEVEL_3_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_3_1: return 14000000; - case V4L2_MPEG_VIDEO_H264_LEVEL_3_2: + case V4L2_CODEC_VIDEO_H264_LEVEL_3_2: return 20000000; - case V4L2_MPEG_VIDEO_H264_LEVEL_4_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_4_0: return 20000000; - case V4L2_MPEG_VIDEO_H264_LEVEL_4_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_4_1: return 50000000; - case V4L2_MPEG_VIDEO_H264_LEVEL_4_2: + case V4L2_CODEC_VIDEO_H264_LEVEL_4_2: return 50000000; - case V4L2_MPEG_VIDEO_H264_LEVEL_5_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_5_0: return 135000000; - case V4L2_MPEG_VIDEO_H264_LEVEL_5_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_5_1: default: return 240000000; } } -static unsigned int h264_maximum_cpb_size(enum v4l2_mpeg_video_h264_level level) +static unsigned int h264_maximum_cpb_size(enum v4l2_codec_video_h264_level level) { switch (level) { - case V4L2_MPEG_VIDEO_H264_LEVEL_1_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_0: return 175; - case V4L2_MPEG_VIDEO_H264_LEVEL_1B: + case V4L2_CODEC_VIDEO_H264_LEVEL_1B: return 350; - case V4L2_MPEG_VIDEO_H264_LEVEL_1_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_1: return 500; - case V4L2_MPEG_VIDEO_H264_LEVEL_1_2: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_2: return 1000; - case V4L2_MPEG_VIDEO_H264_LEVEL_1_3: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_3: return 2000; - case V4L2_MPEG_VIDEO_H264_LEVEL_2_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_2_0: return 2000; - case V4L2_MPEG_VIDEO_H264_LEVEL_2_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_2_1: return 4000; - case V4L2_MPEG_VIDEO_H264_LEVEL_2_2: + case V4L2_CODEC_VIDEO_H264_LEVEL_2_2: return 4000; - case V4L2_MPEG_VIDEO_H264_LEVEL_3_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_3_0: return 10000; - case V4L2_MPEG_VIDEO_H264_LEVEL_3_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_3_1: return 14000; - case V4L2_MPEG_VIDEO_H264_LEVEL_3_2: + case V4L2_CODEC_VIDEO_H264_LEVEL_3_2: return 20000; - case V4L2_MPEG_VIDEO_H264_LEVEL_4_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_4_0: return 25000; - case V4L2_MPEG_VIDEO_H264_LEVEL_4_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_4_1: return 62500; - case V4L2_MPEG_VIDEO_H264_LEVEL_4_2: + case V4L2_CODEC_VIDEO_H264_LEVEL_4_2: return 62500; - case V4L2_MPEG_VIDEO_H264_LEVEL_5_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_5_0: return 135000; - case V4L2_MPEG_VIDEO_H264_LEVEL_5_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_5_1: default: return 240000; } } -static enum v4l2_mpeg_video_hevc_level +static enum v4l2_codec_video_hevc_level select_minimum_hevc_level(unsigned int width, unsigned int height) { unsigned int luma_picture_size = width * height; - enum v4l2_mpeg_video_hevc_level level; + enum v4l2_codec_video_hevc_level level; if (luma_picture_size <= 36864) - level = V4L2_MPEG_VIDEO_HEVC_LEVEL_1; + level = V4L2_CODEC_VIDEO_HEVC_LEVEL_1; else if (luma_picture_size <= 122880) - level = V4L2_MPEG_VIDEO_HEVC_LEVEL_2; + level = V4L2_CODEC_VIDEO_HEVC_LEVEL_2; else if (luma_picture_size <= 245760) - level = V4L2_MPEG_VIDEO_HEVC_LEVEL_2_1; + level = V4L2_CODEC_VIDEO_HEVC_LEVEL_2_1; else if (luma_picture_size <= 552960) - level = V4L2_MPEG_VIDEO_HEVC_LEVEL_3; + level = V4L2_CODEC_VIDEO_HEVC_LEVEL_3; else if (luma_picture_size <= 983040) - level = V4L2_MPEG_VIDEO_HEVC_LEVEL_3_1; + level = V4L2_CODEC_VIDEO_HEVC_LEVEL_3_1; else if (luma_picture_size <= 2228224) - level = V4L2_MPEG_VIDEO_HEVC_LEVEL_4; + level = V4L2_CODEC_VIDEO_HEVC_LEVEL_4; else if (luma_picture_size <= 8912896) - level = V4L2_MPEG_VIDEO_HEVC_LEVEL_5; + level = V4L2_CODEC_VIDEO_HEVC_LEVEL_5; else - level = V4L2_MPEG_VIDEO_HEVC_LEVEL_6; + level = V4L2_CODEC_VIDEO_HEVC_LEVEL_6; return level; } -static unsigned int hevc_maximum_bitrate(enum v4l2_mpeg_video_hevc_level level) +static unsigned int hevc_maximum_bitrate(enum v4l2_codec_video_hevc_level level) { /* * See Rec. ITU-T H.265 v5 (02/2018), A.4.2 Profile-specific level * limits for the video profiles. */ switch (level) { - case V4L2_MPEG_VIDEO_HEVC_LEVEL_1: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_1: return 128; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_2: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_2: return 1500; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_2_1: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_2_1: return 3000; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_3: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_3: return 6000; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_3_1: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_3_1: return 10000; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_4: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_4: return 12000; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_4_1: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_4_1: return 20000; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_5: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_5: return 25000; default: - case V4L2_MPEG_VIDEO_HEVC_LEVEL_5_1: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_5_1: return 40000; } } -static unsigned int hevc_maximum_cpb_size(enum v4l2_mpeg_video_hevc_level level) +static unsigned int hevc_maximum_cpb_size(enum v4l2_codec_video_hevc_level level) { switch (level) { - case V4L2_MPEG_VIDEO_HEVC_LEVEL_1: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_1: return 350; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_2: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_2: return 1500; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_2_1: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_2_1: return 3000; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_3: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_3: return 6000; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_3_1: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_3_1: return 10000; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_4: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_4: return 12000; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_4_1: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_4_1: return 20000; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_5: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_5: return 25000; default: - case V4L2_MPEG_VIDEO_HEVC_LEVEL_5_1: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_5_1: return 40000; } } @@ -970,108 +970,108 @@ static u32 v4l2_colorspace_to_mcu_colorspace(enum v4l2_colorspace colorspace) } } -static u8 v4l2_profile_to_mcu_profile(enum v4l2_mpeg_video_h264_profile profile) +static u8 v4l2_profile_to_mcu_profile(enum v4l2_codec_video_h264_profile profile) { switch (profile) { - case V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE: + case V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE: default: return 66; } } -static u16 v4l2_level_to_mcu_level(enum v4l2_mpeg_video_h264_level level) +static u16 v4l2_level_to_mcu_level(enum v4l2_codec_video_h264_level level) { switch (level) { - case V4L2_MPEG_VIDEO_H264_LEVEL_1_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_0: return 10; - case V4L2_MPEG_VIDEO_H264_LEVEL_1_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_1: return 11; - case V4L2_MPEG_VIDEO_H264_LEVEL_1_2: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_2: return 12; - case V4L2_MPEG_VIDEO_H264_LEVEL_1_3: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_3: return 13; - case V4L2_MPEG_VIDEO_H264_LEVEL_2_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_2_0: return 20; - case V4L2_MPEG_VIDEO_H264_LEVEL_2_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_2_1: return 21; - case V4L2_MPEG_VIDEO_H264_LEVEL_2_2: + case V4L2_CODEC_VIDEO_H264_LEVEL_2_2: return 22; - case V4L2_MPEG_VIDEO_H264_LEVEL_3_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_3_0: return 30; - case V4L2_MPEG_VIDEO_H264_LEVEL_3_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_3_1: return 31; - case V4L2_MPEG_VIDEO_H264_LEVEL_3_2: + case V4L2_CODEC_VIDEO_H264_LEVEL_3_2: return 32; - case V4L2_MPEG_VIDEO_H264_LEVEL_4_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_4_0: return 40; - case V4L2_MPEG_VIDEO_H264_LEVEL_4_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_4_1: return 41; - case V4L2_MPEG_VIDEO_H264_LEVEL_4_2: + case V4L2_CODEC_VIDEO_H264_LEVEL_4_2: return 42; - case V4L2_MPEG_VIDEO_H264_LEVEL_5_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_5_0: return 50; - case V4L2_MPEG_VIDEO_H264_LEVEL_5_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_5_1: default: return 51; } } -static u8 hevc_profile_to_mcu_profile(enum v4l2_mpeg_video_hevc_profile profile) +static u8 hevc_profile_to_mcu_profile(enum v4l2_codec_video_hevc_profile profile) { switch (profile) { default: - case V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN: + case V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN: return 1; - case V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN_10: + case V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN_10: return 2; - case V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN_STILL_PICTURE: + case V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN_STILL_PICTURE: return 3; } } -static u16 hevc_level_to_mcu_level(enum v4l2_mpeg_video_hevc_level level) +static u16 hevc_level_to_mcu_level(enum v4l2_codec_video_hevc_level level) { switch (level) { - case V4L2_MPEG_VIDEO_HEVC_LEVEL_1: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_1: return 10; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_2: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_2: return 20; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_2_1: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_2_1: return 21; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_3: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_3: return 30; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_3_1: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_3_1: return 31; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_4: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_4: return 40; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_4_1: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_4_1: return 41; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_5: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_5: return 50; default: - case V4L2_MPEG_VIDEO_HEVC_LEVEL_5_1: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_5_1: return 51; } } -static u8 hevc_tier_to_mcu_tier(enum v4l2_mpeg_video_hevc_tier tier) +static u8 hevc_tier_to_mcu_tier(enum v4l2_codec_video_hevc_tier tier) { switch (tier) { default: - case V4L2_MPEG_VIDEO_HEVC_TIER_MAIN: + case V4L2_CODEC_VIDEO_HEVC_TIER_MAIN: return 0; - case V4L2_MPEG_VIDEO_HEVC_TIER_HIGH: + case V4L2_CODEC_VIDEO_HEVC_TIER_HIGH: return 1; } } static u32 -v4l2_bitrate_mode_to_mcu_mode(enum v4l2_mpeg_video_bitrate_mode mode) +v4l2_bitrate_mode_to_mcu_mode(enum v4l2_codec_video_bitrate_mode mode) { switch (mode) { - case V4L2_MPEG_VIDEO_BITRATE_MODE_VBR: + case V4L2_CODEC_VIDEO_BITRATE_MODE_VBR: return 2; - case V4L2_MPEG_VIDEO_BITRATE_MODE_CBR: + case V4L2_CODEC_VIDEO_BITRATE_MODE_CBR: default: return 1; } @@ -1084,7 +1084,7 @@ static u32 v4l2_cpb_size_to_mcu(unsigned int cpb_size, unsigned int bitrate) /* * The mcu expects the CPB size in units of a 90 kHz clock, but the - * channel follows the V4L2_CID_MPEG_VIDEO_H264_CPB_SIZE and stores + * channel follows the V4L2_CID_CODEC_VIDEO_H264_CPB_SIZE and stores * the CPB size in kilobytes. */ cpb_size_kbit = cpb_size * BITS_PER_BYTE; @@ -1131,8 +1131,8 @@ static int fill_create_channel_param(struct allegro_channel *channel, param->codec = channel->codec; if (channel->codec == V4L2_PIX_FMT_H264) { - enum v4l2_mpeg_video_h264_profile profile; - enum v4l2_mpeg_video_h264_level level; + enum v4l2_codec_video_h264_profile profile; + enum v4l2_codec_video_h264_level level; profile = v4l2_ctrl_g_ctrl(channel->mpeg_video_h264_profile); level = v4l2_ctrl_g_ctrl(channel->mpeg_video_h264_level); @@ -1141,9 +1141,9 @@ static int fill_create_channel_param(struct allegro_channel *channel, param->constraint_set_flags = BIT(1); param->level = v4l2_level_to_mcu_level(level); } else { - enum v4l2_mpeg_video_hevc_profile profile; - enum v4l2_mpeg_video_hevc_level level; - enum v4l2_mpeg_video_hevc_tier tier; + enum v4l2_codec_video_hevc_profile profile; + enum v4l2_codec_video_hevc_level level; + enum v4l2_codec_video_hevc_tier tier; profile = v4l2_ctrl_g_ctrl(channel->mpeg_video_hevc_profile); level = v4l2_ctrl_g_ctrl(channel->mpeg_video_hevc_level); @@ -1497,8 +1497,8 @@ static ssize_t allegro_h264_write_sps(struct allegro_channel *channel, /* Calculation of crop units in Rec. ITU-T H.264 (04/2017) p. 76 */ unsigned int crop_unit_x = 2; unsigned int crop_unit_y = 2; - enum v4l2_mpeg_video_h264_profile profile; - enum v4l2_mpeg_video_h264_level level; + enum v4l2_codec_video_h264_profile profile; + enum v4l2_codec_video_h264_level level; unsigned int cpb_size; unsigned int cpb_size_scale; @@ -2797,9 +2797,9 @@ static int allegro_clamp_qp(struct allegro_channel *channel, { struct v4l2_ctrl *next_ctrl; - if (ctrl->id == V4L2_CID_MPEG_VIDEO_H264_I_FRAME_QP) + if (ctrl->id == V4L2_CID_CODEC_VIDEO_H264_I_FRAME_QP) next_ctrl = channel->mpeg_video_h264_p_frame_qp; - else if (ctrl->id == V4L2_CID_MPEG_VIDEO_H264_P_FRAME_QP) + else if (ctrl->id == V4L2_CID_CODEC_VIDEO_H264_P_FRAME_QP) next_ctrl = channel->mpeg_video_h264_b_frame_qp; else return 0; @@ -2816,7 +2816,7 @@ static int allegro_clamp_bitrate(struct allegro_channel *channel, struct v4l2_ctrl *ctrl_bitrate = channel->mpeg_video_bitrate; struct v4l2_ctrl *ctrl_bitrate_peak = channel->mpeg_video_bitrate_peak; - if (ctrl->val == V4L2_MPEG_VIDEO_BITRATE_MODE_VBR && + if (ctrl->val == V4L2_CODEC_VIDEO_BITRATE_MODE_VBR && ctrl_bitrate_peak->val < ctrl_bitrate->val) ctrl_bitrate_peak->val = ctrl_bitrate->val; @@ -2830,7 +2830,7 @@ static int allegro_try_ctrl(struct v4l2_ctrl *ctrl) ctrl_handler); switch (ctrl->id) { - case V4L2_CID_MPEG_VIDEO_BITRATE_MODE: + case V4L2_CID_CODEC_VIDEO_BITRATE_MODE: allegro_clamp_bitrate(channel, ctrl); break; } @@ -2849,18 +2849,18 @@ static int allegro_s_ctrl(struct v4l2_ctrl *ctrl) "s_ctrl: %s = %d\n", v4l2_ctrl_get_name(ctrl->id), ctrl->val); switch (ctrl->id) { - case V4L2_CID_MPEG_VIDEO_FRAME_RC_ENABLE: + case V4L2_CID_CODEC_VIDEO_FRAME_RC_ENABLE: channel->frame_rc_enable = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_BITRATE_MODE: + case V4L2_CID_CODEC_VIDEO_BITRATE_MODE: channel->bitrate = channel->mpeg_video_bitrate->val; channel->bitrate_peak = channel->mpeg_video_bitrate_peak->val; v4l2_ctrl_activate(channel->mpeg_video_bitrate_peak, - ctrl->val == V4L2_MPEG_VIDEO_BITRATE_MODE_VBR); + ctrl->val == V4L2_CODEC_VIDEO_BITRATE_MODE_VBR); break; - case V4L2_CID_MPEG_VIDEO_H264_I_FRAME_QP: - case V4L2_CID_MPEG_VIDEO_H264_P_FRAME_QP: - case V4L2_CID_MPEG_VIDEO_H264_B_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_H264_I_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_H264_P_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_H264_B_FRAME_QP: allegro_clamp_qp(channel, ctrl); break; } @@ -2905,123 +2905,123 @@ static int allegro_open(struct file *file) v4l2_ctrl_handler_init(handler, 0); channel->mpeg_video_h264_profile = v4l2_ctrl_new_std_menu(handler, &allegro_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_PROFILE, - V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE, 0x0, - V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE); - mask = 1 << V4L2_MPEG_VIDEO_H264_LEVEL_1B; + V4L2_CID_CODEC_VIDEO_H264_PROFILE, + V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE, 0x0, + V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE); + mask = 1 << V4L2_CODEC_VIDEO_H264_LEVEL_1B; channel->mpeg_video_h264_level = v4l2_ctrl_new_std_menu(handler, &allegro_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_LEVEL, - V4L2_MPEG_VIDEO_H264_LEVEL_5_1, mask, - V4L2_MPEG_VIDEO_H264_LEVEL_5_1); + V4L2_CID_CODEC_VIDEO_H264_LEVEL, + V4L2_CODEC_VIDEO_H264_LEVEL_5_1, mask, + V4L2_CODEC_VIDEO_H264_LEVEL_5_1); channel->mpeg_video_h264_i_frame_qp = v4l2_ctrl_new_std(handler, &allegro_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_I_FRAME_QP, + V4L2_CID_CODEC_VIDEO_H264_I_FRAME_QP, 0, 51, 1, 30); channel->mpeg_video_h264_max_qp = v4l2_ctrl_new_std(handler, &allegro_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_MAX_QP, + V4L2_CID_CODEC_VIDEO_H264_MAX_QP, 0, 51, 1, 51); channel->mpeg_video_h264_min_qp = v4l2_ctrl_new_std(handler, &allegro_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_MIN_QP, + V4L2_CID_CODEC_VIDEO_H264_MIN_QP, 0, 51, 1, 0); channel->mpeg_video_h264_p_frame_qp = v4l2_ctrl_new_std(handler, &allegro_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_P_FRAME_QP, + V4L2_CID_CODEC_VIDEO_H264_P_FRAME_QP, 0, 51, 1, 30); channel->mpeg_video_h264_b_frame_qp = v4l2_ctrl_new_std(handler, &allegro_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_B_FRAME_QP, + V4L2_CID_CODEC_VIDEO_H264_B_FRAME_QP, 0, 51, 1, 30); channel->mpeg_video_hevc_profile = v4l2_ctrl_new_std_menu(handler, &allegro_ctrl_ops, - V4L2_CID_MPEG_VIDEO_HEVC_PROFILE, - V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN, 0x0, - V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN); + V4L2_CID_CODEC_VIDEO_HEVC_PROFILE, + V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN, 0x0, + V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN); channel->mpeg_video_hevc_level = v4l2_ctrl_new_std_menu(handler, &allegro_ctrl_ops, - V4L2_CID_MPEG_VIDEO_HEVC_LEVEL, - V4L2_MPEG_VIDEO_HEVC_LEVEL_5_1, 0x0, - V4L2_MPEG_VIDEO_HEVC_LEVEL_5_1); + V4L2_CID_CODEC_VIDEO_HEVC_LEVEL, + V4L2_CODEC_VIDEO_HEVC_LEVEL_5_1, 0x0, + V4L2_CODEC_VIDEO_HEVC_LEVEL_5_1); channel->mpeg_video_hevc_tier = v4l2_ctrl_new_std_menu(handler, &allegro_ctrl_ops, - V4L2_CID_MPEG_VIDEO_HEVC_TIER, - V4L2_MPEG_VIDEO_HEVC_TIER_HIGH, 0x0, - V4L2_MPEG_VIDEO_HEVC_TIER_MAIN); + V4L2_CID_CODEC_VIDEO_HEVC_TIER, + V4L2_CODEC_VIDEO_HEVC_TIER_HIGH, 0x0, + V4L2_CODEC_VIDEO_HEVC_TIER_MAIN); channel->mpeg_video_hevc_i_frame_qp = v4l2_ctrl_new_std(handler, &allegro_ctrl_ops, - V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_QP, + V4L2_CID_CODEC_VIDEO_HEVC_I_FRAME_QP, 0, 51, 1, 30); channel->mpeg_video_hevc_max_qp = v4l2_ctrl_new_std(handler, &allegro_ctrl_ops, - V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP, + V4L2_CID_CODEC_VIDEO_HEVC_MAX_QP, 0, 51, 1, 51); channel->mpeg_video_hevc_min_qp = v4l2_ctrl_new_std(handler, &allegro_ctrl_ops, - V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP, + V4L2_CID_CODEC_VIDEO_HEVC_MIN_QP, 0, 51, 1, 0); channel->mpeg_video_hevc_p_frame_qp = v4l2_ctrl_new_std(handler, &allegro_ctrl_ops, - V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_QP, + V4L2_CID_CODEC_VIDEO_HEVC_P_FRAME_QP, 0, 51, 1, 30); channel->mpeg_video_hevc_b_frame_qp = v4l2_ctrl_new_std(handler, &allegro_ctrl_ops, - V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_QP, + V4L2_CID_CODEC_VIDEO_HEVC_B_FRAME_QP, 0, 51, 1, 30); channel->mpeg_video_frame_rc_enable = v4l2_ctrl_new_std(handler, &allegro_ctrl_ops, - V4L2_CID_MPEG_VIDEO_FRAME_RC_ENABLE, + V4L2_CID_CODEC_VIDEO_FRAME_RC_ENABLE, false, 0x1, true, false); channel->mpeg_video_bitrate_mode = v4l2_ctrl_new_std_menu(handler, &allegro_ctrl_ops, - V4L2_CID_MPEG_VIDEO_BITRATE_MODE, - V4L2_MPEG_VIDEO_BITRATE_MODE_CBR, 0, - V4L2_MPEG_VIDEO_BITRATE_MODE_CBR); + V4L2_CID_CODEC_VIDEO_BITRATE_MODE, + V4L2_CODEC_VIDEO_BITRATE_MODE_CBR, 0, + V4L2_CODEC_VIDEO_BITRATE_MODE_CBR); if (channel->codec == V4L2_PIX_FMT_H264) { - bitrate_max = h264_maximum_bitrate(V4L2_MPEG_VIDEO_H264_LEVEL_5_1); - bitrate_def = h264_maximum_bitrate(V4L2_MPEG_VIDEO_H264_LEVEL_5_1); - cpb_size_max = h264_maximum_cpb_size(V4L2_MPEG_VIDEO_H264_LEVEL_5_1); - cpb_size_def = h264_maximum_cpb_size(V4L2_MPEG_VIDEO_H264_LEVEL_5_1); + bitrate_max = h264_maximum_bitrate(V4L2_CODEC_VIDEO_H264_LEVEL_5_1); + bitrate_def = h264_maximum_bitrate(V4L2_CODEC_VIDEO_H264_LEVEL_5_1); + cpb_size_max = h264_maximum_cpb_size(V4L2_CODEC_VIDEO_H264_LEVEL_5_1); + cpb_size_def = h264_maximum_cpb_size(V4L2_CODEC_VIDEO_H264_LEVEL_5_1); } else { - bitrate_max = hevc_maximum_bitrate(V4L2_MPEG_VIDEO_HEVC_LEVEL_5_1); - bitrate_def = hevc_maximum_bitrate(V4L2_MPEG_VIDEO_HEVC_LEVEL_5_1); - cpb_size_max = hevc_maximum_cpb_size(V4L2_MPEG_VIDEO_HEVC_LEVEL_5_1); - cpb_size_def = hevc_maximum_cpb_size(V4L2_MPEG_VIDEO_HEVC_LEVEL_5_1); + bitrate_max = hevc_maximum_bitrate(V4L2_CODEC_VIDEO_HEVC_LEVEL_5_1); + bitrate_def = hevc_maximum_bitrate(V4L2_CODEC_VIDEO_HEVC_LEVEL_5_1); + cpb_size_max = hevc_maximum_cpb_size(V4L2_CODEC_VIDEO_HEVC_LEVEL_5_1); + cpb_size_def = hevc_maximum_cpb_size(V4L2_CODEC_VIDEO_HEVC_LEVEL_5_1); } channel->mpeg_video_bitrate = v4l2_ctrl_new_std(handler, &allegro_ctrl_ops, - V4L2_CID_MPEG_VIDEO_BITRATE, + V4L2_CID_CODEC_VIDEO_BITRATE, 0, bitrate_max, 1, bitrate_def); channel->mpeg_video_bitrate_peak = v4l2_ctrl_new_std(handler, &allegro_ctrl_ops, - V4L2_CID_MPEG_VIDEO_BITRATE_PEAK, + V4L2_CID_CODEC_VIDEO_BITRATE_PEAK, 0, bitrate_max, 1, bitrate_def); channel->mpeg_video_cpb_size = v4l2_ctrl_new_std(handler, &allegro_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_CPB_SIZE, + V4L2_CID_CODEC_VIDEO_H264_CPB_SIZE, 0, cpb_size_max, 1, cpb_size_def); channel->mpeg_video_gop_size = v4l2_ctrl_new_std(handler, &allegro_ctrl_ops, - V4L2_CID_MPEG_VIDEO_GOP_SIZE, + V4L2_CID_CODEC_VIDEO_GOP_SIZE, 0, ALLEGRO_GOP_SIZE_MAX, 1, ALLEGRO_GOP_SIZE_DEFAULT); v4l2_ctrl_new_std(handler, diff --git a/drivers/media/platform/allegro-dvt/nal-h264.c b/drivers/media/platform/allegro-dvt/nal-h264.c index 94dd9266d850..b6494994ae7f 100644 --- a/drivers/media/platform/allegro-dvt/nal-h264.c +++ b/drivers/media/platform/allegro-dvt/nal-h264.c @@ -36,23 +36,23 @@ enum nal_unit_type { /** * nal_h264_profile_from_v4l2() - Get profile_idc for v4l2 h264 profile - * @profile: the profile as &enum v4l2_mpeg_video_h264_profile + * @profile: the profile as &enum v4l2_codec_video_h264_profile * - * Convert the &enum v4l2_mpeg_video_h264_profile to profile_idc as specified + * Convert the &enum v4l2_codec_video_h264_profile to profile_idc as specified * in Rec. ITU-T H.264 (04/2017) A.2. * * Return: the profile_idc for the passed level */ -int nal_h264_profile_from_v4l2(enum v4l2_mpeg_video_h264_profile profile) +int nal_h264_profile_from_v4l2(enum v4l2_codec_video_h264_profile profile) { switch (profile) { - case V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE: + case V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE: return 66; - case V4L2_MPEG_VIDEO_H264_PROFILE_MAIN: + case V4L2_CODEC_VIDEO_H264_PROFILE_MAIN: return 77; - case V4L2_MPEG_VIDEO_H264_PROFILE_EXTENDED: + case V4L2_CODEC_VIDEO_H264_PROFILE_EXTENDED: return 88; - case V4L2_MPEG_VIDEO_H264_PROFILE_HIGH: + case V4L2_CODEC_VIDEO_H264_PROFILE_HIGH: return 100; default: return -EINVAL; @@ -61,47 +61,47 @@ int nal_h264_profile_from_v4l2(enum v4l2_mpeg_video_h264_profile profile) /** * nal_h264_level_from_v4l2() - Get level_idc for v4l2 h264 level - * @level: the level as &enum v4l2_mpeg_video_h264_level + * @level: the level as &enum v4l2_codec_video_h264_level * - * Convert the &enum v4l2_mpeg_video_h264_level to level_idc as specified in + * Convert the &enum v4l2_codec_video_h264_level to level_idc as specified in * Rec. ITU-T H.264 (04/2017) A.3.2. * * Return: the level_idc for the passed level */ -int nal_h264_level_from_v4l2(enum v4l2_mpeg_video_h264_level level) +int nal_h264_level_from_v4l2(enum v4l2_codec_video_h264_level level) { switch (level) { - case V4L2_MPEG_VIDEO_H264_LEVEL_1_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_0: return 10; - case V4L2_MPEG_VIDEO_H264_LEVEL_1B: + case V4L2_CODEC_VIDEO_H264_LEVEL_1B: return 9; - case V4L2_MPEG_VIDEO_H264_LEVEL_1_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_1: return 11; - case V4L2_MPEG_VIDEO_H264_LEVEL_1_2: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_2: return 12; - case V4L2_MPEG_VIDEO_H264_LEVEL_1_3: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_3: return 13; - case V4L2_MPEG_VIDEO_H264_LEVEL_2_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_2_0: return 20; - case V4L2_MPEG_VIDEO_H264_LEVEL_2_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_2_1: return 21; - case V4L2_MPEG_VIDEO_H264_LEVEL_2_2: + case V4L2_CODEC_VIDEO_H264_LEVEL_2_2: return 22; - case V4L2_MPEG_VIDEO_H264_LEVEL_3_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_3_0: return 30; - case V4L2_MPEG_VIDEO_H264_LEVEL_3_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_3_1: return 31; - case V4L2_MPEG_VIDEO_H264_LEVEL_3_2: + case V4L2_CODEC_VIDEO_H264_LEVEL_3_2: return 32; - case V4L2_MPEG_VIDEO_H264_LEVEL_4_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_4_0: return 40; - case V4L2_MPEG_VIDEO_H264_LEVEL_4_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_4_1: return 41; - case V4L2_MPEG_VIDEO_H264_LEVEL_4_2: + case V4L2_CODEC_VIDEO_H264_LEVEL_4_2: return 42; - case V4L2_MPEG_VIDEO_H264_LEVEL_5_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_5_0: return 50; - case V4L2_MPEG_VIDEO_H264_LEVEL_5_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_5_1: return 51; default: return -EINVAL; diff --git a/drivers/media/platform/allegro-dvt/nal-h264.h b/drivers/media/platform/allegro-dvt/nal-h264.h index 2ba7cbced7a5..bebee9bc6328 100644 --- a/drivers/media/platform/allegro-dvt/nal-h264.h +++ b/drivers/media/platform/allegro-dvt/nal-h264.h @@ -187,8 +187,8 @@ struct nal_h264_pps { }; }; -int nal_h264_profile_from_v4l2(enum v4l2_mpeg_video_h264_profile profile); -int nal_h264_level_from_v4l2(enum v4l2_mpeg_video_h264_level level); +int nal_h264_profile_from_v4l2(enum v4l2_codec_video_h264_profile profile); +int nal_h264_level_from_v4l2(enum v4l2_codec_video_h264_level level); ssize_t nal_h264_write_sps(const struct device *dev, void *dest, size_t n, struct nal_h264_sps *sps); diff --git a/drivers/media/platform/allegro-dvt/nal-hevc.c b/drivers/media/platform/allegro-dvt/nal-hevc.c index 5db540c69bfe..73fc3db1c3b1 100644 --- a/drivers/media/platform/allegro-dvt/nal-hevc.c +++ b/drivers/media/platform/allegro-dvt/nal-hevc.c @@ -35,14 +35,14 @@ enum nal_unit_type { FD_NUT = 38, }; -int nal_hevc_profile_from_v4l2(enum v4l2_mpeg_video_hevc_profile profile) +int nal_hevc_profile_from_v4l2(enum v4l2_codec_video_hevc_profile profile) { switch (profile) { - case V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN: + case V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN: return 1; - case V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN_10: + case V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN_10: return 2; - case V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN_STILL_PICTURE: + case V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN_STILL_PICTURE: return 3; default: return -EINVAL; @@ -50,12 +50,12 @@ int nal_hevc_profile_from_v4l2(enum v4l2_mpeg_video_hevc_profile profile) } EXPORT_SYMBOL_GPL(nal_hevc_profile_from_v4l2); -int nal_hevc_tier_from_v4l2(enum v4l2_mpeg_video_hevc_tier tier) +int nal_hevc_tier_from_v4l2(enum v4l2_codec_video_hevc_tier tier) { switch (tier) { - case V4L2_MPEG_VIDEO_HEVC_TIER_MAIN: + case V4L2_CODEC_VIDEO_HEVC_TIER_MAIN: return 0; - case V4L2_MPEG_VIDEO_HEVC_TIER_HIGH: + case V4L2_CODEC_VIDEO_HEVC_TIER_HIGH: return 1; default: return -EINVAL; @@ -63,7 +63,7 @@ int nal_hevc_tier_from_v4l2(enum v4l2_mpeg_video_hevc_tier tier) } EXPORT_SYMBOL_GPL(nal_hevc_tier_from_v4l2); -int nal_hevc_level_from_v4l2(enum v4l2_mpeg_video_hevc_level level) +int nal_hevc_level_from_v4l2(enum v4l2_codec_video_hevc_level level) { /* * T-Rec-H.265 p. 280: general_level_idc and sub_layer_level_idc[ i ] @@ -73,31 +73,31 @@ int nal_hevc_level_from_v4l2(enum v4l2_mpeg_video_hevc_level level) int factor = 30 / 10; switch (level) { - case V4L2_MPEG_VIDEO_HEVC_LEVEL_1: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_1: return factor * 10; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_2: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_2: return factor * 20; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_2_1: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_2_1: return factor * 21; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_3: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_3: return factor * 30; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_3_1: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_3_1: return factor * 31; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_4: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_4: return factor * 40; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_4_1: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_4_1: return factor * 41; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_5: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_5: return factor * 50; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_5_1: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_5_1: return factor * 51; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_5_2: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_5_2: return factor * 52; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_6: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_6: return factor * 60; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_6_1: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_6_1: return factor * 61; - case V4L2_MPEG_VIDEO_HEVC_LEVEL_6_2: + case V4L2_CODEC_VIDEO_HEVC_LEVEL_6_2: return factor * 62; default: return -EINVAL; diff --git a/drivers/media/platform/allegro-dvt/nal-hevc.h b/drivers/media/platform/allegro-dvt/nal-hevc.h index fc994d4242d8..16d9e7931de1 100644 --- a/drivers/media/platform/allegro-dvt/nal-hevc.h +++ b/drivers/media/platform/allegro-dvt/nal-hevc.h @@ -318,9 +318,9 @@ struct nal_hevc_pps { }; }; -int nal_hevc_profile_from_v4l2(enum v4l2_mpeg_video_hevc_profile profile); -int nal_hevc_tier_from_v4l2(enum v4l2_mpeg_video_hevc_tier tier); -int nal_hevc_level_from_v4l2(enum v4l2_mpeg_video_hevc_level level); +int nal_hevc_profile_from_v4l2(enum v4l2_codec_video_hevc_profile profile); +int nal_hevc_tier_from_v4l2(enum v4l2_codec_video_hevc_tier tier); +int nal_hevc_level_from_v4l2(enum v4l2_codec_video_hevc_level level); int nal_range_from_v4l2(enum v4l2_quantization quantization); int nal_color_primaries_from_v4l2(enum v4l2_colorspace colorspace); diff --git a/drivers/media/platform/coda/coda-bit.c b/drivers/media/platform/coda/coda-bit.c index 2f42808c43a4..30bd468f7f95 100644 --- a/drivers/media/platform/coda/coda-bit.c +++ b/drivers/media/platform/coda/coda-bit.c @@ -680,14 +680,14 @@ static u32 coda_slice_mode(struct coda_ctx *ctx) int size, unit; switch (ctx->params.slice_mode) { - case V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_SINGLE: + case V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_SINGLE: default: return 0; - case V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_MB: + case V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_MAX_MB: size = ctx->params.slice_max_mb; unit = 1; break; - case V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_BYTES: + case V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_MAX_BYTES: size = ctx->params.slice_max_bits; unit = 0; break; @@ -1834,7 +1834,7 @@ static bool coda_reorder_enable(struct coda_ctx *ctx) ctx->params.h264_profile_idc); /* Baseline profile does not support reordering */ - return profile > V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE; + return profile > V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE; } static void coda_decoder_drop_used_metas(struct coda_ctx *ctx) diff --git a/drivers/media/platform/coda/coda-common.c b/drivers/media/platform/coda/coda-common.c index 995e95272e51..a6e41ebdf168 100644 --- a/drivers/media/platform/coda/coda-common.c +++ b/drivers/media/platform/coda/coda-common.c @@ -1791,8 +1791,8 @@ void coda_update_profile_level_ctrls(struct coda_ctx *ctx, u8 profile_idc, switch (ctx->codec->src_fourcc) { case V4L2_PIX_FMT_H264: codec_name = "H264"; - profile_cid = V4L2_CID_MPEG_VIDEO_H264_PROFILE; - level_cid = V4L2_CID_MPEG_VIDEO_H264_LEVEL; + profile_cid = V4L2_CID_CODEC_VIDEO_H264_PROFILE; + level_cid = V4L2_CID_CODEC_VIDEO_H264_LEVEL; profile_ctrl = ctx->h264_profile_ctrl; level_ctrl = ctx->h264_level_ctrl; profile = coda_h264_profile(profile_idc); @@ -1800,8 +1800,8 @@ void coda_update_profile_level_ctrls(struct coda_ctx *ctx, u8 profile_idc, break; case V4L2_PIX_FMT_MPEG2: codec_name = "MPEG-2"; - profile_cid = V4L2_CID_MPEG_VIDEO_MPEG2_PROFILE; - level_cid = V4L2_CID_MPEG_VIDEO_MPEG2_LEVEL; + profile_cid = V4L2_CID_CODEC_VIDEO_MPEG2_PROFILE; + level_cid = V4L2_CID_CODEC_VIDEO_MPEG2_LEVEL; profile_ctrl = ctx->mpeg2_profile_ctrl; level_ctrl = ctx->mpeg2_level_ctrl; profile = coda_mpeg2_profile(profile_idc); @@ -1809,8 +1809,8 @@ void coda_update_profile_level_ctrls(struct coda_ctx *ctx, u8 profile_idc, break; case V4L2_PIX_FMT_MPEG4: codec_name = "MPEG-4"; - profile_cid = V4L2_CID_MPEG_VIDEO_MPEG4_PROFILE; - level_cid = V4L2_CID_MPEG_VIDEO_MPEG4_LEVEL; + profile_cid = V4L2_CID_CODEC_VIDEO_MPEG4_PROFILE; + level_cid = V4L2_CID_CODEC_VIDEO_MPEG4_LEVEL; profile_ctrl = ctx->mpeg4_profile_ctrl; level_ctrl = ctx->mpeg4_level_ctrl; profile = coda_mpeg4_profile(profile_idc); @@ -2189,86 +2189,86 @@ static int coda_s_ctrl(struct v4l2_ctrl *ctrl) else ctx->params.rot_mode &= ~CODA_MIR_VER; break; - case V4L2_CID_MPEG_VIDEO_BITRATE: + case V4L2_CID_CODEC_VIDEO_BITRATE: ctx->params.bitrate = ctrl->val / 1000; ctx->params.bitrate_changed = true; break; - case V4L2_CID_MPEG_VIDEO_GOP_SIZE: + case V4L2_CID_CODEC_VIDEO_GOP_SIZE: ctx->params.gop_size = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_I_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_H264_I_FRAME_QP: ctx->params.h264_intra_qp = ctrl->val; ctx->params.h264_intra_qp_changed = true; break; - case V4L2_CID_MPEG_VIDEO_H264_P_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_H264_P_FRAME_QP: ctx->params.h264_inter_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_MIN_QP: + case V4L2_CID_CODEC_VIDEO_H264_MIN_QP: ctx->params.h264_min_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_MAX_QP: + case V4L2_CID_CODEC_VIDEO_H264_MAX_QP: ctx->params.h264_max_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_ALPHA: + case V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_ALPHA: ctx->params.h264_slice_alpha_c0_offset_div2 = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_BETA: + case V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_BETA: ctx->params.h264_slice_beta_offset_div2 = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_MODE: + case V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_MODE: ctx->params.h264_disable_deblocking_filter_idc = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_CONSTRAINED_INTRA_PREDICTION: + case V4L2_CID_CODEC_VIDEO_H264_CONSTRAINED_INTRA_PREDICTION: ctx->params.h264_constrained_intra_pred_flag = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_FRAME_RC_ENABLE: + case V4L2_CID_CODEC_VIDEO_FRAME_RC_ENABLE: ctx->params.frame_rc_enable = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE: + case V4L2_CID_CODEC_VIDEO_MB_RC_ENABLE: ctx->params.mb_rc_enable = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_CHROMA_QP_INDEX_OFFSET: + case V4L2_CID_CODEC_VIDEO_H264_CHROMA_QP_INDEX_OFFSET: ctx->params.h264_chroma_qp_index_offset = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_PROFILE: + case V4L2_CID_CODEC_VIDEO_H264_PROFILE: /* TODO: switch between baseline and constrained baseline */ if (ctx->inst_type == CODA_INST_ENCODER) ctx->params.h264_profile_idc = 66; break; - case V4L2_CID_MPEG_VIDEO_H264_LEVEL: + case V4L2_CID_CODEC_VIDEO_H264_LEVEL: /* nothing to do, this is set by the encoder */ break; - case V4L2_CID_MPEG_VIDEO_MPEG4_I_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_MPEG4_I_FRAME_QP: ctx->params.mpeg4_intra_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_MPEG4_P_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_MPEG4_P_FRAME_QP: ctx->params.mpeg4_inter_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_MPEG2_PROFILE: - case V4L2_CID_MPEG_VIDEO_MPEG2_LEVEL: - case V4L2_CID_MPEG_VIDEO_MPEG4_PROFILE: - case V4L2_CID_MPEG_VIDEO_MPEG4_LEVEL: + case V4L2_CID_CODEC_VIDEO_MPEG2_PROFILE: + case V4L2_CID_CODEC_VIDEO_MPEG2_LEVEL: + case V4L2_CID_CODEC_VIDEO_MPEG4_PROFILE: + case V4L2_CID_CODEC_VIDEO_MPEG4_LEVEL: /* nothing to do, these are fixed */ break; - case V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MODE: + case V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MODE: ctx->params.slice_mode = ctrl->val; ctx->params.slice_mode_changed = true; break; - case V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MAX_MB: + case V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MAX_MB: ctx->params.slice_max_mb = ctrl->val; ctx->params.slice_mode_changed = true; break; - case V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MAX_BYTES: + case V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MAX_BYTES: ctx->params.slice_max_bits = ctrl->val * 8; ctx->params.slice_mode_changed = true; break; - case V4L2_CID_MPEG_VIDEO_HEADER_MODE: + case V4L2_CID_CODEC_VIDEO_HEADER_MODE: break; - case V4L2_CID_MPEG_VIDEO_CYCLIC_INTRA_REFRESH_MB: + case V4L2_CID_CODEC_VIDEO_CYCLIC_INTRA_REFRESH_MB: ctx->params.intra_refresh = ctrl->val; ctx->params.intra_refresh_changed = true; break; - case V4L2_CID_MPEG_VIDEO_FORCE_KEY_FRAME: + case V4L2_CID_CODEC_VIDEO_FORCE_KEY_FRAME: ctx->params.force_ipicture = true; break; case V4L2_CID_JPEG_COMPRESSION_QUALITY: @@ -2277,10 +2277,10 @@ static int coda_s_ctrl(struct v4l2_ctrl *ctrl) case V4L2_CID_JPEG_RESTART_INTERVAL: ctx->params.jpeg_restart_interval = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_VBV_DELAY: + case V4L2_CID_CODEC_VIDEO_VBV_DELAY: ctx->params.vbv_delay = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_VBV_SIZE: + case V4L2_CID_CODEC_VIDEO_VBV_SIZE: ctx->params.vbv_size = min(ctrl->val * 8192, 0x7fffffff); break; default: @@ -2301,103 +2301,103 @@ static void coda_encode_ctrls(struct coda_ctx *ctx) int max_gop_size = (ctx->dev->devtype->product == CODA_DX6) ? 60 : 99; v4l2_ctrl_new_std(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_BITRATE, 0, 32767000, 1000, 0); + V4L2_CID_CODEC_VIDEO_BITRATE, 0, 32767000, 1000, 0); v4l2_ctrl_new_std(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_GOP_SIZE, 0, max_gop_size, 1, 16); + V4L2_CID_CODEC_VIDEO_GOP_SIZE, 0, max_gop_size, 1, 16); v4l2_ctrl_new_std(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_I_FRAME_QP, 0, 51, 1, 25); + V4L2_CID_CODEC_VIDEO_H264_I_FRAME_QP, 0, 51, 1, 25); v4l2_ctrl_new_std(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_P_FRAME_QP, 0, 51, 1, 25); + V4L2_CID_CODEC_VIDEO_H264_P_FRAME_QP, 0, 51, 1, 25); if (ctx->dev->devtype->product != CODA_960) { v4l2_ctrl_new_std(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_MIN_QP, 0, 51, 1, 12); + V4L2_CID_CODEC_VIDEO_H264_MIN_QP, 0, 51, 1, 12); } v4l2_ctrl_new_std(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_MAX_QP, 0, 51, 1, 51); + V4L2_CID_CODEC_VIDEO_H264_MAX_QP, 0, 51, 1, 51); v4l2_ctrl_new_std(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_ALPHA, -6, 6, 1, 0); + V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_ALPHA, -6, 6, 1, 0); v4l2_ctrl_new_std(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_BETA, -6, 6, 1, 0); + V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_BETA, -6, 6, 1, 0); v4l2_ctrl_new_std_menu(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_MODE, - V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY, - 0x0, V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_ENABLED); + V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_MODE, + V4L2_CODEC_VIDEO_H264_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY, + 0x0, V4L2_CODEC_VIDEO_H264_LOOP_FILTER_MODE_ENABLED); v4l2_ctrl_new_std(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_CONSTRAINED_INTRA_PREDICTION, 0, 1, 1, + V4L2_CID_CODEC_VIDEO_H264_CONSTRAINED_INTRA_PREDICTION, 0, 1, 1, 0); v4l2_ctrl_new_std(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_FRAME_RC_ENABLE, 0, 1, 1, 1); + V4L2_CID_CODEC_VIDEO_FRAME_RC_ENABLE, 0, 1, 1, 1); v4l2_ctrl_new_std(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE, 0, 1, 1, 1); + V4L2_CID_CODEC_VIDEO_MB_RC_ENABLE, 0, 1, 1, 1); v4l2_ctrl_new_std(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_CHROMA_QP_INDEX_OFFSET, -12, 12, 1, 0); + V4L2_CID_CODEC_VIDEO_H264_CHROMA_QP_INDEX_OFFSET, -12, 12, 1, 0); v4l2_ctrl_new_std_menu(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_PROFILE, - V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE, 0x0, - V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE); + V4L2_CID_CODEC_VIDEO_H264_PROFILE, + V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE, 0x0, + V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE); if (ctx->dev->devtype->product == CODA_HX4 || ctx->dev->devtype->product == CODA_7541) { v4l2_ctrl_new_std_menu(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_LEVEL, - V4L2_MPEG_VIDEO_H264_LEVEL_3_1, - ~((1 << V4L2_MPEG_VIDEO_H264_LEVEL_2_0) | - (1 << V4L2_MPEG_VIDEO_H264_LEVEL_3_0) | - (1 << V4L2_MPEG_VIDEO_H264_LEVEL_3_1)), - V4L2_MPEG_VIDEO_H264_LEVEL_3_1); + V4L2_CID_CODEC_VIDEO_H264_LEVEL, + V4L2_CODEC_VIDEO_H264_LEVEL_3_1, + ~((1 << V4L2_CODEC_VIDEO_H264_LEVEL_2_0) | + (1 << V4L2_CODEC_VIDEO_H264_LEVEL_3_0) | + (1 << V4L2_CODEC_VIDEO_H264_LEVEL_3_1)), + V4L2_CODEC_VIDEO_H264_LEVEL_3_1); } if (ctx->dev->devtype->product == CODA_960) { v4l2_ctrl_new_std_menu(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_LEVEL, - V4L2_MPEG_VIDEO_H264_LEVEL_4_0, - ~((1 << V4L2_MPEG_VIDEO_H264_LEVEL_2_0) | - (1 << V4L2_MPEG_VIDEO_H264_LEVEL_3_0) | - (1 << V4L2_MPEG_VIDEO_H264_LEVEL_3_1) | - (1 << V4L2_MPEG_VIDEO_H264_LEVEL_3_2) | - (1 << V4L2_MPEG_VIDEO_H264_LEVEL_4_0)), - V4L2_MPEG_VIDEO_H264_LEVEL_4_0); + V4L2_CID_CODEC_VIDEO_H264_LEVEL, + V4L2_CODEC_VIDEO_H264_LEVEL_4_0, + ~((1 << V4L2_CODEC_VIDEO_H264_LEVEL_2_0) | + (1 << V4L2_CODEC_VIDEO_H264_LEVEL_3_0) | + (1 << V4L2_CODEC_VIDEO_H264_LEVEL_3_1) | + (1 << V4L2_CODEC_VIDEO_H264_LEVEL_3_2) | + (1 << V4L2_CODEC_VIDEO_H264_LEVEL_4_0)), + V4L2_CODEC_VIDEO_H264_LEVEL_4_0); } v4l2_ctrl_new_std(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_MPEG4_I_FRAME_QP, 1, 31, 1, 2); + V4L2_CID_CODEC_VIDEO_MPEG4_I_FRAME_QP, 1, 31, 1, 2); v4l2_ctrl_new_std(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_MPEG4_P_FRAME_QP, 1, 31, 1, 2); + V4L2_CID_CODEC_VIDEO_MPEG4_P_FRAME_QP, 1, 31, 1, 2); v4l2_ctrl_new_std_menu(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_MPEG4_PROFILE, - V4L2_MPEG_VIDEO_MPEG4_PROFILE_SIMPLE, 0x0, - V4L2_MPEG_VIDEO_MPEG4_PROFILE_SIMPLE); + V4L2_CID_CODEC_VIDEO_MPEG4_PROFILE, + V4L2_CODEC_VIDEO_MPEG4_PROFILE_SIMPLE, 0x0, + V4L2_CODEC_VIDEO_MPEG4_PROFILE_SIMPLE); if (ctx->dev->devtype->product == CODA_HX4 || ctx->dev->devtype->product == CODA_7541 || ctx->dev->devtype->product == CODA_960) { v4l2_ctrl_new_std_menu(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_MPEG4_LEVEL, - V4L2_MPEG_VIDEO_MPEG4_LEVEL_5, - ~(1 << V4L2_MPEG_VIDEO_MPEG4_LEVEL_5), - V4L2_MPEG_VIDEO_MPEG4_LEVEL_5); + V4L2_CID_CODEC_VIDEO_MPEG4_LEVEL, + V4L2_CODEC_VIDEO_MPEG4_LEVEL_5, + ~(1 << V4L2_CODEC_VIDEO_MPEG4_LEVEL_5), + V4L2_CODEC_VIDEO_MPEG4_LEVEL_5); } v4l2_ctrl_new_std_menu(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MODE, - V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_BYTES, 0x0, - V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_SINGLE); + V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MODE, + V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_MAX_BYTES, 0x0, + V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_SINGLE); v4l2_ctrl_new_std(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MAX_MB, 1, 0x3fffffff, 1, 1); + V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MAX_MB, 1, 0x3fffffff, 1, 1); v4l2_ctrl_new_std(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MAX_BYTES, 1, 0x3fffffff, 1, + V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MAX_BYTES, 1, 0x3fffffff, 1, 500); v4l2_ctrl_new_std_menu(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_HEADER_MODE, - V4L2_MPEG_VIDEO_HEADER_MODE_JOINED_WITH_1ST_FRAME, - (1 << V4L2_MPEG_VIDEO_HEADER_MODE_SEPARATE), - V4L2_MPEG_VIDEO_HEADER_MODE_JOINED_WITH_1ST_FRAME); + V4L2_CID_CODEC_VIDEO_HEADER_MODE, + V4L2_CODEC_VIDEO_HEADER_MODE_JOINED_WITH_1ST_FRAME, + (1 << V4L2_CODEC_VIDEO_HEADER_MODE_SEPARATE), + V4L2_CODEC_VIDEO_HEADER_MODE_JOINED_WITH_1ST_FRAME); v4l2_ctrl_new_std(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_CYCLIC_INTRA_REFRESH_MB, 0, + V4L2_CID_CODEC_VIDEO_CYCLIC_INTRA_REFRESH_MB, 0, 1920 * 1088 / 256, 1, 0); v4l2_ctrl_new_std(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_VBV_DELAY, 0, 0x7fff, 1, 0); + V4L2_CID_CODEC_VIDEO_VBV_DELAY, 0, 0x7fff, 1, 0); /* * The maximum VBV size value is 0x7fffffff bits, * one bit less than 262144 KiB */ v4l2_ctrl_new_std(&ctx->ctrls, &coda_ctrl_ops, - V4L2_CID_MPEG_VIDEO_VBV_SIZE, 0, 262144, 1, 0); + V4L2_CID_CODEC_VIDEO_VBV_SIZE, 0, 262144, 1, 0); } static void coda_jpeg_encode_ctrls(struct coda_ctx *ctx) @@ -2413,52 +2413,52 @@ static void coda_decode_ctrls(struct coda_ctx *ctx) u8 max; ctx->h264_profile_ctrl = v4l2_ctrl_new_std_menu(&ctx->ctrls, - &coda_ctrl_ops, V4L2_CID_MPEG_VIDEO_H264_PROFILE, - V4L2_MPEG_VIDEO_H264_PROFILE_HIGH, - ~((1 << V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE) | - (1 << V4L2_MPEG_VIDEO_H264_PROFILE_MAIN) | - (1 << V4L2_MPEG_VIDEO_H264_PROFILE_HIGH)), - V4L2_MPEG_VIDEO_H264_PROFILE_HIGH); + &coda_ctrl_ops, V4L2_CID_CODEC_VIDEO_H264_PROFILE, + V4L2_CODEC_VIDEO_H264_PROFILE_HIGH, + ~((1 << V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE) | + (1 << V4L2_CODEC_VIDEO_H264_PROFILE_MAIN) | + (1 << V4L2_CODEC_VIDEO_H264_PROFILE_HIGH)), + V4L2_CODEC_VIDEO_H264_PROFILE_HIGH); if (ctx->h264_profile_ctrl) ctx->h264_profile_ctrl->flags |= V4L2_CTRL_FLAG_READ_ONLY; if (ctx->dev->devtype->product == CODA_HX4 || ctx->dev->devtype->product == CODA_7541) - max = V4L2_MPEG_VIDEO_H264_LEVEL_4_0; + max = V4L2_CODEC_VIDEO_H264_LEVEL_4_0; else if (ctx->dev->devtype->product == CODA_960) - max = V4L2_MPEG_VIDEO_H264_LEVEL_4_1; + max = V4L2_CODEC_VIDEO_H264_LEVEL_4_1; else return; ctx->h264_level_ctrl = v4l2_ctrl_new_std_menu(&ctx->ctrls, - &coda_ctrl_ops, V4L2_CID_MPEG_VIDEO_H264_LEVEL, max, 0, max); + &coda_ctrl_ops, V4L2_CID_CODEC_VIDEO_H264_LEVEL, max, 0, max); if (ctx->h264_level_ctrl) ctx->h264_level_ctrl->flags |= V4L2_CTRL_FLAG_READ_ONLY; ctx->mpeg2_profile_ctrl = v4l2_ctrl_new_std_menu(&ctx->ctrls, - &coda_ctrl_ops, V4L2_CID_MPEG_VIDEO_MPEG2_PROFILE, - V4L2_MPEG_VIDEO_MPEG2_PROFILE_HIGH, 0, - V4L2_MPEG_VIDEO_MPEG2_PROFILE_HIGH); + &coda_ctrl_ops, V4L2_CID_CODEC_VIDEO_MPEG2_PROFILE, + V4L2_CODEC_VIDEO_MPEG2_PROFILE_HIGH, 0, + V4L2_CODEC_VIDEO_MPEG2_PROFILE_HIGH); if (ctx->mpeg2_profile_ctrl) ctx->mpeg2_profile_ctrl->flags |= V4L2_CTRL_FLAG_READ_ONLY; ctx->mpeg2_level_ctrl = v4l2_ctrl_new_std_menu(&ctx->ctrls, - &coda_ctrl_ops, V4L2_CID_MPEG_VIDEO_MPEG2_LEVEL, - V4L2_MPEG_VIDEO_MPEG2_LEVEL_HIGH, 0, - V4L2_MPEG_VIDEO_MPEG2_LEVEL_HIGH); + &coda_ctrl_ops, V4L2_CID_CODEC_VIDEO_MPEG2_LEVEL, + V4L2_CODEC_VIDEO_MPEG2_LEVEL_HIGH, 0, + V4L2_CODEC_VIDEO_MPEG2_LEVEL_HIGH); if (ctx->mpeg2_level_ctrl) ctx->mpeg2_level_ctrl->flags |= V4L2_CTRL_FLAG_READ_ONLY; ctx->mpeg4_profile_ctrl = v4l2_ctrl_new_std_menu(&ctx->ctrls, - &coda_ctrl_ops, V4L2_CID_MPEG_VIDEO_MPEG4_PROFILE, - V4L2_MPEG_VIDEO_MPEG4_PROFILE_ADVANCED_CODING_EFFICIENCY, 0, - V4L2_MPEG_VIDEO_MPEG4_PROFILE_ADVANCED_CODING_EFFICIENCY); + &coda_ctrl_ops, V4L2_CID_CODEC_VIDEO_MPEG4_PROFILE, + V4L2_CODEC_VIDEO_MPEG4_PROFILE_ADVANCED_CODING_EFFICIENCY, 0, + V4L2_CODEC_VIDEO_MPEG4_PROFILE_ADVANCED_CODING_EFFICIENCY); if (ctx->mpeg4_profile_ctrl) ctx->mpeg4_profile_ctrl->flags |= V4L2_CTRL_FLAG_READ_ONLY; ctx->mpeg4_level_ctrl = v4l2_ctrl_new_std_menu(&ctx->ctrls, - &coda_ctrl_ops, V4L2_CID_MPEG_VIDEO_MPEG4_LEVEL, - V4L2_MPEG_VIDEO_MPEG4_LEVEL_5, 0, - V4L2_MPEG_VIDEO_MPEG4_LEVEL_5); + &coda_ctrl_ops, V4L2_CID_CODEC_VIDEO_MPEG4_LEVEL, + V4L2_CODEC_VIDEO_MPEG4_LEVEL_5, 0, + V4L2_CODEC_VIDEO_MPEG4_LEVEL_5); if (ctx->mpeg4_level_ctrl) ctx->mpeg4_level_ctrl->flags |= V4L2_CTRL_FLAG_READ_ONLY; } diff --git a/drivers/media/platform/coda/coda-h264.c b/drivers/media/platform/coda/coda-h264.c index 8bd0aa8af114..852307f30c80 100644 --- a/drivers/media/platform/coda/coda-h264.c +++ b/drivers/media/platform/coda/coda-h264.c @@ -81,10 +81,10 @@ int coda_h264_padding(int size, char *p) int coda_h264_profile(int profile_idc) { switch (profile_idc) { - case 66: return V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE; - case 77: return V4L2_MPEG_VIDEO_H264_PROFILE_MAIN; - case 88: return V4L2_MPEG_VIDEO_H264_PROFILE_EXTENDED; - case 100: return V4L2_MPEG_VIDEO_H264_PROFILE_HIGH; + case 66: return V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE; + case 77: return V4L2_CODEC_VIDEO_H264_PROFILE_MAIN; + case 88: return V4L2_CODEC_VIDEO_H264_PROFILE_EXTENDED; + case 100: return V4L2_CODEC_VIDEO_H264_PROFILE_HIGH; default: return -EINVAL; } } @@ -92,22 +92,22 @@ int coda_h264_profile(int profile_idc) int coda_h264_level(int level_idc) { switch (level_idc) { - case 10: return V4L2_MPEG_VIDEO_H264_LEVEL_1_0; - case 9: return V4L2_MPEG_VIDEO_H264_LEVEL_1B; - case 11: return V4L2_MPEG_VIDEO_H264_LEVEL_1_1; - case 12: return V4L2_MPEG_VIDEO_H264_LEVEL_1_2; - case 13: return V4L2_MPEG_VIDEO_H264_LEVEL_1_3; - case 20: return V4L2_MPEG_VIDEO_H264_LEVEL_2_0; - case 21: return V4L2_MPEG_VIDEO_H264_LEVEL_2_1; - case 22: return V4L2_MPEG_VIDEO_H264_LEVEL_2_2; - case 30: return V4L2_MPEG_VIDEO_H264_LEVEL_3_0; - case 31: return V4L2_MPEG_VIDEO_H264_LEVEL_3_1; - case 32: return V4L2_MPEG_VIDEO_H264_LEVEL_3_2; - case 40: return V4L2_MPEG_VIDEO_H264_LEVEL_4_0; - case 41: return V4L2_MPEG_VIDEO_H264_LEVEL_4_1; - case 42: return V4L2_MPEG_VIDEO_H264_LEVEL_4_2; - case 50: return V4L2_MPEG_VIDEO_H264_LEVEL_5_0; - case 51: return V4L2_MPEG_VIDEO_H264_LEVEL_5_1; + case 10: return V4L2_CODEC_VIDEO_H264_LEVEL_1_0; + case 9: return V4L2_CODEC_VIDEO_H264_LEVEL_1B; + case 11: return V4L2_CODEC_VIDEO_H264_LEVEL_1_1; + case 12: return V4L2_CODEC_VIDEO_H264_LEVEL_1_2; + case 13: return V4L2_CODEC_VIDEO_H264_LEVEL_1_3; + case 20: return V4L2_CODEC_VIDEO_H264_LEVEL_2_0; + case 21: return V4L2_CODEC_VIDEO_H264_LEVEL_2_1; + case 22: return V4L2_CODEC_VIDEO_H264_LEVEL_2_2; + case 30: return V4L2_CODEC_VIDEO_H264_LEVEL_3_0; + case 31: return V4L2_CODEC_VIDEO_H264_LEVEL_3_1; + case 32: return V4L2_CODEC_VIDEO_H264_LEVEL_3_2; + case 40: return V4L2_CODEC_VIDEO_H264_LEVEL_4_0; + case 41: return V4L2_CODEC_VIDEO_H264_LEVEL_4_1; + case 42: return V4L2_CODEC_VIDEO_H264_LEVEL_4_2; + case 50: return V4L2_CODEC_VIDEO_H264_LEVEL_5_0; + case 51: return V4L2_CODEC_VIDEO_H264_LEVEL_5_1; default: return -EINVAL; } } diff --git a/drivers/media/platform/coda/coda-mpeg2.c b/drivers/media/platform/coda/coda-mpeg2.c index 6f3f6721d286..277614f68f4b 100644 --- a/drivers/media/platform/coda/coda-mpeg2.c +++ b/drivers/media/platform/coda/coda-mpeg2.c @@ -13,15 +13,15 @@ int coda_mpeg2_profile(int profile_idc) { switch (profile_idc) { case 5: - return V4L2_MPEG_VIDEO_MPEG2_PROFILE_SIMPLE; + return V4L2_CODEC_VIDEO_MPEG2_PROFILE_SIMPLE; case 4: - return V4L2_MPEG_VIDEO_MPEG2_PROFILE_MAIN; + return V4L2_CODEC_VIDEO_MPEG2_PROFILE_MAIN; case 3: - return V4L2_MPEG_VIDEO_MPEG2_PROFILE_SNR_SCALABLE; + return V4L2_CODEC_VIDEO_MPEG2_PROFILE_SNR_SCALABLE; case 2: - return V4L2_MPEG_VIDEO_MPEG2_PROFILE_SPATIALLY_SCALABLE; + return V4L2_CODEC_VIDEO_MPEG2_PROFILE_SPATIALLY_SCALABLE; case 1: - return V4L2_MPEG_VIDEO_MPEG2_PROFILE_HIGH; + return V4L2_CODEC_VIDEO_MPEG2_PROFILE_HIGH; default: return -EINVAL; } @@ -31,13 +31,13 @@ int coda_mpeg2_level(int level_idc) { switch (level_idc) { case 10: - return V4L2_MPEG_VIDEO_MPEG2_LEVEL_LOW; + return V4L2_CODEC_VIDEO_MPEG2_LEVEL_LOW; case 8: - return V4L2_MPEG_VIDEO_MPEG2_LEVEL_MAIN; + return V4L2_CODEC_VIDEO_MPEG2_LEVEL_MAIN; case 6: - return V4L2_MPEG_VIDEO_MPEG2_LEVEL_HIGH_1440; + return V4L2_CODEC_VIDEO_MPEG2_LEVEL_HIGH_1440; case 4: - return V4L2_MPEG_VIDEO_MPEG2_LEVEL_HIGH; + return V4L2_CODEC_VIDEO_MPEG2_LEVEL_HIGH; default: return -EINVAL; } diff --git a/drivers/media/platform/coda/coda-mpeg4.c b/drivers/media/platform/coda/coda-mpeg4.c index 483a4fba1b4f..159eff42026e 100644 --- a/drivers/media/platform/coda/coda-mpeg4.c +++ b/drivers/media/platform/coda/coda-mpeg4.c @@ -14,15 +14,15 @@ int coda_mpeg4_profile(int profile_idc) { switch (profile_idc) { case 0: - return V4L2_MPEG_VIDEO_MPEG4_PROFILE_SIMPLE; + return V4L2_CODEC_VIDEO_MPEG4_PROFILE_SIMPLE; case 15: - return V4L2_MPEG_VIDEO_MPEG4_PROFILE_ADVANCED_SIMPLE; + return V4L2_CODEC_VIDEO_MPEG4_PROFILE_ADVANCED_SIMPLE; case 2: - return V4L2_MPEG_VIDEO_MPEG4_PROFILE_CORE; + return V4L2_CODEC_VIDEO_MPEG4_PROFILE_CORE; case 1: - return V4L2_MPEG_VIDEO_MPEG4_PROFILE_SIMPLE_SCALABLE; + return V4L2_CODEC_VIDEO_MPEG4_PROFILE_SIMPLE_SCALABLE; case 11: - return V4L2_MPEG_VIDEO_MPEG4_PROFILE_ADVANCED_CODING_EFFICIENCY; + return V4L2_CODEC_VIDEO_MPEG4_PROFILE_ADVANCED_CODING_EFFICIENCY; default: return -EINVAL; } @@ -32,17 +32,17 @@ int coda_mpeg4_level(int level_idc) { switch (level_idc) { case 0: - return V4L2_MPEG_VIDEO_MPEG4_LEVEL_0; + return V4L2_CODEC_VIDEO_MPEG4_LEVEL_0; case 1: - return V4L2_MPEG_VIDEO_MPEG4_LEVEL_1; + return V4L2_CODEC_VIDEO_MPEG4_LEVEL_1; case 2: - return V4L2_MPEG_VIDEO_MPEG4_LEVEL_2; + return V4L2_CODEC_VIDEO_MPEG4_LEVEL_2; case 3: - return V4L2_MPEG_VIDEO_MPEG4_LEVEL_3; + return V4L2_CODEC_VIDEO_MPEG4_LEVEL_3; case 4: - return V4L2_MPEG_VIDEO_MPEG4_LEVEL_4; + return V4L2_CODEC_VIDEO_MPEG4_LEVEL_4; case 5: - return V4L2_MPEG_VIDEO_MPEG4_LEVEL_5; + return V4L2_CODEC_VIDEO_MPEG4_LEVEL_5; default: return -EINVAL; } diff --git a/drivers/media/platform/coda/coda.h b/drivers/media/platform/coda/coda.h index dcf35641c603..125b5f126e6c 100644 --- a/drivers/media/platform/coda/coda.h +++ b/drivers/media/platform/coda/coda.h @@ -143,7 +143,7 @@ struct coda_params { struct coda_huff_tab *jpeg_huff_tab; int codec_mode; int codec_mode_aux; - enum v4l2_mpeg_video_multi_slice_mode slice_mode; + enum v4l2_codec_video_multi_slice_mode slice_mode; u32 framerate; u16 bitrate; u16 vbv_delay; diff --git a/drivers/media/platform/mtk-vcodec/mtk_vcodec_dec.c b/drivers/media/platform/mtk-vcodec/mtk_vcodec_dec.c index 56d86e59421e..967dfba10af4 100644 --- a/drivers/media/platform/mtk-vcodec/mtk_vcodec_dec.c +++ b/drivers/media/platform/mtk-vcodec/mtk_vcodec_dec.c @@ -1418,9 +1418,9 @@ int mtk_vcodec_dec_ctrls_setup(struct mtk_vcodec_ctx *ctx) ctrl->flags |= V4L2_CTRL_FLAG_VOLATILE; v4l2_ctrl_new_std_menu(&ctx->ctrl_hdl, &mtk_vcodec_dec_ctrl_ops, - V4L2_CID_MPEG_VIDEO_VP9_PROFILE, - V4L2_MPEG_VIDEO_VP9_PROFILE_0, - 0, V4L2_MPEG_VIDEO_VP9_PROFILE_0); + V4L2_CID_CODEC_VIDEO_VP9_PROFILE, + V4L2_CODEC_VIDEO_VP9_PROFILE_0, + 0, V4L2_CODEC_VIDEO_VP9_PROFILE_0); if (ctx->ctrl_hdl.error) { mtk_v4l2_err("Adding control failed %d", diff --git a/drivers/media/platform/mtk-vcodec/mtk_vcodec_enc.c b/drivers/media/platform/mtk-vcodec/mtk_vcodec_enc.c index 8c917969c2f1..eb2d3ff6aa07 100644 --- a/drivers/media/platform/mtk-vcodec/mtk_vcodec_enc.c +++ b/drivers/media/platform/mtk-vcodec/mtk_vcodec_enc.c @@ -43,61 +43,61 @@ static int vidioc_venc_s_ctrl(struct v4l2_ctrl *ctrl) int ret = 0; switch (ctrl->id) { - case V4L2_CID_MPEG_VIDEO_BITRATE: - mtk_v4l2_debug(2, "V4L2_CID_MPEG_VIDEO_BITRATE val = %d", + case V4L2_CID_CODEC_VIDEO_BITRATE: + mtk_v4l2_debug(2, "V4L2_CID_CODEC_VIDEO_BITRATE val = %d", ctrl->val); p->bitrate = ctrl->val; ctx->param_change |= MTK_ENCODE_PARAM_BITRATE; break; - case V4L2_CID_MPEG_VIDEO_B_FRAMES: - mtk_v4l2_debug(2, "V4L2_CID_MPEG_VIDEO_B_FRAMES val = %d", + case V4L2_CID_CODEC_VIDEO_B_FRAMES: + mtk_v4l2_debug(2, "V4L2_CID_CODEC_VIDEO_B_FRAMES val = %d", ctrl->val); p->num_b_frame = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_FRAME_RC_ENABLE: - mtk_v4l2_debug(2, "V4L2_CID_MPEG_VIDEO_FRAME_RC_ENABLE val = %d", + case V4L2_CID_CODEC_VIDEO_FRAME_RC_ENABLE: + mtk_v4l2_debug(2, "V4L2_CID_CODEC_VIDEO_FRAME_RC_ENABLE val = %d", ctrl->val); p->rc_frame = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_MAX_QP: - mtk_v4l2_debug(2, "V4L2_CID_MPEG_VIDEO_H264_MAX_QP val = %d", + case V4L2_CID_CODEC_VIDEO_H264_MAX_QP: + mtk_v4l2_debug(2, "V4L2_CID_CODEC_VIDEO_H264_MAX_QP val = %d", ctrl->val); p->h264_max_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEADER_MODE: - mtk_v4l2_debug(2, "V4L2_CID_MPEG_VIDEO_HEADER_MODE val = %d", + case V4L2_CID_CODEC_VIDEO_HEADER_MODE: + mtk_v4l2_debug(2, "V4L2_CID_CODEC_VIDEO_HEADER_MODE val = %d", ctrl->val); p->seq_hdr_mode = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE: - mtk_v4l2_debug(2, "V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE val = %d", + case V4L2_CID_CODEC_VIDEO_MB_RC_ENABLE: + mtk_v4l2_debug(2, "V4L2_CID_CODEC_VIDEO_MB_RC_ENABLE val = %d", ctrl->val); p->rc_mb = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_PROFILE: - mtk_v4l2_debug(2, "V4L2_CID_MPEG_VIDEO_H264_PROFILE val = %d", + case V4L2_CID_CODEC_VIDEO_H264_PROFILE: + mtk_v4l2_debug(2, "V4L2_CID_CODEC_VIDEO_H264_PROFILE val = %d", ctrl->val); p->h264_profile = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_LEVEL: - mtk_v4l2_debug(2, "V4L2_CID_MPEG_VIDEO_H264_LEVEL val = %d", + case V4L2_CID_CODEC_VIDEO_H264_LEVEL: + mtk_v4l2_debug(2, "V4L2_CID_CODEC_VIDEO_H264_LEVEL val = %d", ctrl->val); p->h264_level = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_I_PERIOD: - mtk_v4l2_debug(2, "V4L2_CID_MPEG_VIDEO_H264_I_PERIOD val = %d", + case V4L2_CID_CODEC_VIDEO_H264_I_PERIOD: + mtk_v4l2_debug(2, "V4L2_CID_CODEC_VIDEO_H264_I_PERIOD val = %d", ctrl->val); p->intra_period = ctrl->val; ctx->param_change |= MTK_ENCODE_PARAM_INTRA_PERIOD; break; - case V4L2_CID_MPEG_VIDEO_GOP_SIZE: - mtk_v4l2_debug(2, "V4L2_CID_MPEG_VIDEO_GOP_SIZE val = %d", + case V4L2_CID_CODEC_VIDEO_GOP_SIZE: + mtk_v4l2_debug(2, "V4L2_CID_CODEC_VIDEO_GOP_SIZE val = %d", ctrl->val); p->gop_size = ctrl->val; ctx->param_change |= MTK_ENCODE_PARAM_GOP_SIZE; break; - case V4L2_CID_MPEG_VIDEO_FORCE_KEY_FRAME: - mtk_v4l2_debug(2, "V4L2_CID_MPEG_VIDEO_FORCE_KEY_FRAME"); + case V4L2_CID_CODEC_VIDEO_FORCE_KEY_FRAME: + mtk_v4l2_debug(2, "V4L2_CID_CODEC_VIDEO_FORCE_KEY_FRAME"); p->force_intra = 1; ctx->param_change |= MTK_ENCODE_PARAM_FORCE_INTRA; break; @@ -810,7 +810,7 @@ static int vb2ops_venc_start_streaming(struct vb2_queue *q, unsigned int count) if ((ctx->q_data[MTK_Q_DATA_DST].fmt->fourcc == V4L2_PIX_FMT_H264) && (ctx->enc_params.seq_hdr_mode != - V4L2_MPEG_VIDEO_HEADER_MODE_SEPARATE)) { + V4L2_CODEC_VIDEO_HEADER_MODE_SEPARATE)) { ret = venc_if_set_param(ctx, VENC_SET_PARAM_PREPEND_HEADER, NULL); @@ -1207,33 +1207,33 @@ int mtk_vcodec_enc_ctrls_setup(struct mtk_vcodec_ctx *ctx) v4l2_ctrl_new_std(handler, ops, V4L2_CID_MIN_BUFFERS_FOR_OUTPUT, 1, 1, 1, 1); - v4l2_ctrl_new_std(handler, ops, V4L2_CID_MPEG_VIDEO_BITRATE, + v4l2_ctrl_new_std(handler, ops, V4L2_CID_CODEC_VIDEO_BITRATE, ctx->dev->venc_pdata->min_bitrate, ctx->dev->venc_pdata->max_bitrate, 1, 4000000); - v4l2_ctrl_new_std(handler, ops, V4L2_CID_MPEG_VIDEO_B_FRAMES, + v4l2_ctrl_new_std(handler, ops, V4L2_CID_CODEC_VIDEO_B_FRAMES, 0, 2, 1, 0); - v4l2_ctrl_new_std(handler, ops, V4L2_CID_MPEG_VIDEO_FRAME_RC_ENABLE, + v4l2_ctrl_new_std(handler, ops, V4L2_CID_CODEC_VIDEO_FRAME_RC_ENABLE, 0, 1, 1, 1); - v4l2_ctrl_new_std(handler, ops, V4L2_CID_MPEG_VIDEO_H264_MAX_QP, + v4l2_ctrl_new_std(handler, ops, V4L2_CID_CODEC_VIDEO_H264_MAX_QP, 0, 51, 1, 51); - v4l2_ctrl_new_std(handler, ops, V4L2_CID_MPEG_VIDEO_H264_I_PERIOD, + v4l2_ctrl_new_std(handler, ops, V4L2_CID_CODEC_VIDEO_H264_I_PERIOD, 0, 65535, 1, 0); - v4l2_ctrl_new_std(handler, ops, V4L2_CID_MPEG_VIDEO_GOP_SIZE, + v4l2_ctrl_new_std(handler, ops, V4L2_CID_CODEC_VIDEO_GOP_SIZE, 0, 65535, 1, 0); - v4l2_ctrl_new_std(handler, ops, V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE, + v4l2_ctrl_new_std(handler, ops, V4L2_CID_CODEC_VIDEO_MB_RC_ENABLE, 0, 1, 1, 0); - v4l2_ctrl_new_std(handler, ops, V4L2_CID_MPEG_VIDEO_FORCE_KEY_FRAME, + v4l2_ctrl_new_std(handler, ops, V4L2_CID_CODEC_VIDEO_FORCE_KEY_FRAME, 0, 0, 0, 0); v4l2_ctrl_new_std_menu(handler, ops, - V4L2_CID_MPEG_VIDEO_HEADER_MODE, - V4L2_MPEG_VIDEO_HEADER_MODE_JOINED_WITH_1ST_FRAME, - 0, V4L2_MPEG_VIDEO_HEADER_MODE_SEPARATE); - v4l2_ctrl_new_std_menu(handler, ops, V4L2_CID_MPEG_VIDEO_H264_PROFILE, - V4L2_MPEG_VIDEO_H264_PROFILE_HIGH, - 0, V4L2_MPEG_VIDEO_H264_PROFILE_HIGH); - v4l2_ctrl_new_std_menu(handler, ops, V4L2_CID_MPEG_VIDEO_H264_LEVEL, - V4L2_MPEG_VIDEO_H264_LEVEL_4_2, - 0, V4L2_MPEG_VIDEO_H264_LEVEL_4_0); + V4L2_CID_CODEC_VIDEO_HEADER_MODE, + V4L2_CODEC_VIDEO_HEADER_MODE_JOINED_WITH_1ST_FRAME, + 0, V4L2_CODEC_VIDEO_HEADER_MODE_SEPARATE); + v4l2_ctrl_new_std_menu(handler, ops, V4L2_CID_CODEC_VIDEO_H264_PROFILE, + V4L2_CODEC_VIDEO_H264_PROFILE_HIGH, + 0, V4L2_CODEC_VIDEO_H264_PROFILE_HIGH); + v4l2_ctrl_new_std_menu(handler, ops, V4L2_CID_CODEC_VIDEO_H264_LEVEL, + V4L2_CODEC_VIDEO_H264_LEVEL_4_2, + 0, V4L2_CODEC_VIDEO_H264_LEVEL_4_0); if (handler->error) { mtk_v4l2_err("Init control handler fail %d", handler->error); diff --git a/drivers/media/platform/mtk-vcodec/venc/venc_h264_if.c b/drivers/media/platform/mtk-vcodec/venc/venc_h264_if.c index d0123dfc5f93..1633791bb780 100644 --- a/drivers/media/platform/mtk-vcodec/venc/venc_h264_if.c +++ b/drivers/media/platform/mtk-vcodec/venc/venc_h264_if.c @@ -164,16 +164,16 @@ static unsigned int h264_get_profile(struct venc_h264_inst *inst, unsigned int profile) { switch (profile) { - case V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE: + case V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE: return 66; - case V4L2_MPEG_VIDEO_H264_PROFILE_MAIN: + case V4L2_CODEC_VIDEO_H264_PROFILE_MAIN: return 77; - case V4L2_MPEG_VIDEO_H264_PROFILE_HIGH: + case V4L2_CODEC_VIDEO_H264_PROFILE_HIGH: return 100; - case V4L2_MPEG_VIDEO_H264_PROFILE_CONSTRAINED_BASELINE: + case V4L2_CODEC_VIDEO_H264_PROFILE_CONSTRAINED_BASELINE: mtk_vcodec_err(inst, "unsupported CONSTRAINED_BASELINE"); return 0; - case V4L2_MPEG_VIDEO_H264_PROFILE_EXTENDED: + case V4L2_CODEC_VIDEO_H264_PROFILE_EXTENDED: mtk_vcodec_err(inst, "unsupported EXTENDED"); return 0; default: @@ -186,34 +186,34 @@ static unsigned int h264_get_level(struct venc_h264_inst *inst, unsigned int level) { switch (level) { - case V4L2_MPEG_VIDEO_H264_LEVEL_1B: + case V4L2_CODEC_VIDEO_H264_LEVEL_1B: mtk_vcodec_err(inst, "unsupported 1B"); return 0; - case V4L2_MPEG_VIDEO_H264_LEVEL_1_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_0: return 10; - case V4L2_MPEG_VIDEO_H264_LEVEL_1_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_1: return 11; - case V4L2_MPEG_VIDEO_H264_LEVEL_1_2: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_2: return 12; - case V4L2_MPEG_VIDEO_H264_LEVEL_1_3: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_3: return 13; - case V4L2_MPEG_VIDEO_H264_LEVEL_2_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_2_0: return 20; - case V4L2_MPEG_VIDEO_H264_LEVEL_2_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_2_1: return 21; - case V4L2_MPEG_VIDEO_H264_LEVEL_2_2: + case V4L2_CODEC_VIDEO_H264_LEVEL_2_2: return 22; - case V4L2_MPEG_VIDEO_H264_LEVEL_3_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_3_0: return 30; - case V4L2_MPEG_VIDEO_H264_LEVEL_3_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_3_1: return 31; - case V4L2_MPEG_VIDEO_H264_LEVEL_3_2: + case V4L2_CODEC_VIDEO_H264_LEVEL_3_2: return 32; - case V4L2_MPEG_VIDEO_H264_LEVEL_4_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_4_0: return 40; - case V4L2_MPEG_VIDEO_H264_LEVEL_4_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_4_1: return 41; - case V4L2_MPEG_VIDEO_H264_LEVEL_4_2: + case V4L2_CODEC_VIDEO_H264_LEVEL_4_2: return 42; default: mtk_vcodec_debug(inst, "unsupported level %d", level); diff --git a/drivers/media/platform/qcom/venus/helpers.c b/drivers/media/platform/qcom/venus/helpers.c index 76ece2ff8d39..441aa4c8e498 100644 --- a/drivers/media/platform/qcom/venus/helpers.c +++ b/drivers/media/platform/qcom/venus/helpers.c @@ -590,7 +590,7 @@ static int platform_get_bufreq(struct venus_inst *inst, u32 buftype, params.hfi_color_fmt = to_hfi_raw_fmt(inst->fmt_out->pixfmt); params.enc.work_mode = VIDC_WORK_MODE_2; params.enc.rc_type = HFI_RATE_CONTROL_OFF; - if (enc_ctr->bitrate_mode == V4L2_MPEG_VIDEO_BITRATE_MODE_CQ) + if (enc_ctr->bitrate_mode == V4L2_CODEC_VIDEO_BITRATE_MODE_CQ) params.enc.rc_type = HFI_RATE_CONTROL_CQ; params.enc.num_b_frames = enc_ctr->num_b_frames; params.enc.is_tenbit = inst->bit_depth == VIDC_BITDEPTH_10; @@ -640,112 +640,112 @@ struct id_mapping { }; static const struct id_mapping mpeg4_profiles[] = { - { HFI_MPEG4_PROFILE_SIMPLE, V4L2_MPEG_VIDEO_MPEG4_PROFILE_SIMPLE }, - { HFI_MPEG4_PROFILE_ADVANCEDSIMPLE, V4L2_MPEG_VIDEO_MPEG4_PROFILE_ADVANCED_SIMPLE }, + { HFI_MPEG4_PROFILE_SIMPLE, V4L2_CODEC_VIDEO_MPEG4_PROFILE_SIMPLE }, + { HFI_MPEG4_PROFILE_ADVANCEDSIMPLE, V4L2_CODEC_VIDEO_MPEG4_PROFILE_ADVANCED_SIMPLE }, }; static const struct id_mapping mpeg4_levels[] = { - { HFI_MPEG4_LEVEL_0, V4L2_MPEG_VIDEO_MPEG4_LEVEL_0 }, - { HFI_MPEG4_LEVEL_0b, V4L2_MPEG_VIDEO_MPEG4_LEVEL_0B }, - { HFI_MPEG4_LEVEL_1, V4L2_MPEG_VIDEO_MPEG4_LEVEL_1 }, - { HFI_MPEG4_LEVEL_2, V4L2_MPEG_VIDEO_MPEG4_LEVEL_2 }, - { HFI_MPEG4_LEVEL_3, V4L2_MPEG_VIDEO_MPEG4_LEVEL_3 }, - { HFI_MPEG4_LEVEL_4, V4L2_MPEG_VIDEO_MPEG4_LEVEL_4 }, - { HFI_MPEG4_LEVEL_5, V4L2_MPEG_VIDEO_MPEG4_LEVEL_5 }, + { HFI_MPEG4_LEVEL_0, V4L2_CODEC_VIDEO_MPEG4_LEVEL_0 }, + { HFI_MPEG4_LEVEL_0b, V4L2_CODEC_VIDEO_MPEG4_LEVEL_0B }, + { HFI_MPEG4_LEVEL_1, V4L2_CODEC_VIDEO_MPEG4_LEVEL_1 }, + { HFI_MPEG4_LEVEL_2, V4L2_CODEC_VIDEO_MPEG4_LEVEL_2 }, + { HFI_MPEG4_LEVEL_3, V4L2_CODEC_VIDEO_MPEG4_LEVEL_3 }, + { HFI_MPEG4_LEVEL_4, V4L2_CODEC_VIDEO_MPEG4_LEVEL_4 }, + { HFI_MPEG4_LEVEL_5, V4L2_CODEC_VIDEO_MPEG4_LEVEL_5 }, }; static const struct id_mapping mpeg2_profiles[] = { - { HFI_MPEG2_PROFILE_SIMPLE, V4L2_MPEG_VIDEO_MPEG2_PROFILE_SIMPLE }, - { HFI_MPEG2_PROFILE_MAIN, V4L2_MPEG_VIDEO_MPEG2_PROFILE_MAIN }, - { HFI_MPEG2_PROFILE_SNR, V4L2_MPEG_VIDEO_MPEG2_PROFILE_SNR_SCALABLE }, - { HFI_MPEG2_PROFILE_SPATIAL, V4L2_MPEG_VIDEO_MPEG2_PROFILE_SPATIALLY_SCALABLE }, - { HFI_MPEG2_PROFILE_HIGH, V4L2_MPEG_VIDEO_MPEG2_PROFILE_HIGH }, + { HFI_MPEG2_PROFILE_SIMPLE, V4L2_CODEC_VIDEO_MPEG2_PROFILE_SIMPLE }, + { HFI_MPEG2_PROFILE_MAIN, V4L2_CODEC_VIDEO_MPEG2_PROFILE_MAIN }, + { HFI_MPEG2_PROFILE_SNR, V4L2_CODEC_VIDEO_MPEG2_PROFILE_SNR_SCALABLE }, + { HFI_MPEG2_PROFILE_SPATIAL, V4L2_CODEC_VIDEO_MPEG2_PROFILE_SPATIALLY_SCALABLE }, + { HFI_MPEG2_PROFILE_HIGH, V4L2_CODEC_VIDEO_MPEG2_PROFILE_HIGH }, }; static const struct id_mapping mpeg2_levels[] = { - { HFI_MPEG2_LEVEL_LL, V4L2_MPEG_VIDEO_MPEG2_LEVEL_LOW }, - { HFI_MPEG2_LEVEL_ML, V4L2_MPEG_VIDEO_MPEG2_LEVEL_MAIN }, - { HFI_MPEG2_LEVEL_H14, V4L2_MPEG_VIDEO_MPEG2_LEVEL_HIGH_1440 }, - { HFI_MPEG2_LEVEL_HL, V4L2_MPEG_VIDEO_MPEG2_LEVEL_HIGH }, + { HFI_MPEG2_LEVEL_LL, V4L2_CODEC_VIDEO_MPEG2_LEVEL_LOW }, + { HFI_MPEG2_LEVEL_ML, V4L2_CODEC_VIDEO_MPEG2_LEVEL_MAIN }, + { HFI_MPEG2_LEVEL_H14, V4L2_CODEC_VIDEO_MPEG2_LEVEL_HIGH_1440 }, + { HFI_MPEG2_LEVEL_HL, V4L2_CODEC_VIDEO_MPEG2_LEVEL_HIGH }, }; static const struct id_mapping h264_profiles[] = { - { HFI_H264_PROFILE_BASELINE, V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE }, - { HFI_H264_PROFILE_MAIN, V4L2_MPEG_VIDEO_H264_PROFILE_MAIN }, - { HFI_H264_PROFILE_HIGH, V4L2_MPEG_VIDEO_H264_PROFILE_HIGH }, - { HFI_H264_PROFILE_STEREO_HIGH, V4L2_MPEG_VIDEO_H264_PROFILE_STEREO_HIGH }, - { HFI_H264_PROFILE_MULTIVIEW_HIGH, V4L2_MPEG_VIDEO_H264_PROFILE_MULTIVIEW_HIGH }, - { HFI_H264_PROFILE_CONSTRAINED_BASE, V4L2_MPEG_VIDEO_H264_PROFILE_CONSTRAINED_BASELINE }, - { HFI_H264_PROFILE_CONSTRAINED_HIGH, V4L2_MPEG_VIDEO_H264_PROFILE_CONSTRAINED_HIGH }, + { HFI_H264_PROFILE_BASELINE, V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE }, + { HFI_H264_PROFILE_MAIN, V4L2_CODEC_VIDEO_H264_PROFILE_MAIN }, + { HFI_H264_PROFILE_HIGH, V4L2_CODEC_VIDEO_H264_PROFILE_HIGH }, + { HFI_H264_PROFILE_STEREO_HIGH, V4L2_CODEC_VIDEO_H264_PROFILE_STEREO_HIGH }, + { HFI_H264_PROFILE_MULTIVIEW_HIGH, V4L2_CODEC_VIDEO_H264_PROFILE_MULTIVIEW_HIGH }, + { HFI_H264_PROFILE_CONSTRAINED_BASE, V4L2_CODEC_VIDEO_H264_PROFILE_CONSTRAINED_BASELINE }, + { HFI_H264_PROFILE_CONSTRAINED_HIGH, V4L2_CODEC_VIDEO_H264_PROFILE_CONSTRAINED_HIGH }, }; static const struct id_mapping h264_levels[] = { - { HFI_H264_LEVEL_1, V4L2_MPEG_VIDEO_H264_LEVEL_1_0 }, - { HFI_H264_LEVEL_1b, V4L2_MPEG_VIDEO_H264_LEVEL_1B }, - { HFI_H264_LEVEL_11, V4L2_MPEG_VIDEO_H264_LEVEL_1_1 }, - { HFI_H264_LEVEL_12, V4L2_MPEG_VIDEO_H264_LEVEL_1_2 }, - { HFI_H264_LEVEL_13, V4L2_MPEG_VIDEO_H264_LEVEL_1_3 }, - { HFI_H264_LEVEL_2, V4L2_MPEG_VIDEO_H264_LEVEL_2_0 }, - { HFI_H264_LEVEL_21, V4L2_MPEG_VIDEO_H264_LEVEL_2_1 }, - { HFI_H264_LEVEL_22, V4L2_MPEG_VIDEO_H264_LEVEL_2_2 }, - { HFI_H264_LEVEL_3, V4L2_MPEG_VIDEO_H264_LEVEL_3_0 }, - { HFI_H264_LEVEL_31, V4L2_MPEG_VIDEO_H264_LEVEL_3_1 }, - { HFI_H264_LEVEL_32, V4L2_MPEG_VIDEO_H264_LEVEL_3_2 }, - { HFI_H264_LEVEL_4, V4L2_MPEG_VIDEO_H264_LEVEL_4_0 }, - { HFI_H264_LEVEL_41, V4L2_MPEG_VIDEO_H264_LEVEL_4_1 }, - { HFI_H264_LEVEL_42, V4L2_MPEG_VIDEO_H264_LEVEL_4_2 }, - { HFI_H264_LEVEL_5, V4L2_MPEG_VIDEO_H264_LEVEL_5_0 }, - { HFI_H264_LEVEL_51, V4L2_MPEG_VIDEO_H264_LEVEL_5_1 }, - { HFI_H264_LEVEL_52, V4L2_MPEG_VIDEO_H264_LEVEL_5_1 }, + { HFI_H264_LEVEL_1, V4L2_CODEC_VIDEO_H264_LEVEL_1_0 }, + { HFI_H264_LEVEL_1b, V4L2_CODEC_VIDEO_H264_LEVEL_1B }, + { HFI_H264_LEVEL_11, V4L2_CODEC_VIDEO_H264_LEVEL_1_1 }, + { HFI_H264_LEVEL_12, V4L2_CODEC_VIDEO_H264_LEVEL_1_2 }, + { HFI_H264_LEVEL_13, V4L2_CODEC_VIDEO_H264_LEVEL_1_3 }, + { HFI_H264_LEVEL_2, V4L2_CODEC_VIDEO_H264_LEVEL_2_0 }, + { HFI_H264_LEVEL_21, V4L2_CODEC_VIDEO_H264_LEVEL_2_1 }, + { HFI_H264_LEVEL_22, V4L2_CODEC_VIDEO_H264_LEVEL_2_2 }, + { HFI_H264_LEVEL_3, V4L2_CODEC_VIDEO_H264_LEVEL_3_0 }, + { HFI_H264_LEVEL_31, V4L2_CODEC_VIDEO_H264_LEVEL_3_1 }, + { HFI_H264_LEVEL_32, V4L2_CODEC_VIDEO_H264_LEVEL_3_2 }, + { HFI_H264_LEVEL_4, V4L2_CODEC_VIDEO_H264_LEVEL_4_0 }, + { HFI_H264_LEVEL_41, V4L2_CODEC_VIDEO_H264_LEVEL_4_1 }, + { HFI_H264_LEVEL_42, V4L2_CODEC_VIDEO_H264_LEVEL_4_2 }, + { HFI_H264_LEVEL_5, V4L2_CODEC_VIDEO_H264_LEVEL_5_0 }, + { HFI_H264_LEVEL_51, V4L2_CODEC_VIDEO_H264_LEVEL_5_1 }, + { HFI_H264_LEVEL_52, V4L2_CODEC_VIDEO_H264_LEVEL_5_1 }, }; static const struct id_mapping hevc_profiles[] = { - { HFI_HEVC_PROFILE_MAIN, V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN }, - { HFI_HEVC_PROFILE_MAIN_STILL_PIC, V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN_STILL_PICTURE }, - { HFI_HEVC_PROFILE_MAIN10, V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN_10 }, + { HFI_HEVC_PROFILE_MAIN, V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN }, + { HFI_HEVC_PROFILE_MAIN_STILL_PIC, V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN_STILL_PICTURE }, + { HFI_HEVC_PROFILE_MAIN10, V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN_10 }, }; static const struct id_mapping hevc_levels[] = { - { HFI_HEVC_LEVEL_1, V4L2_MPEG_VIDEO_HEVC_LEVEL_1 }, - { HFI_HEVC_LEVEL_2, V4L2_MPEG_VIDEO_HEVC_LEVEL_2 }, - { HFI_HEVC_LEVEL_21, V4L2_MPEG_VIDEO_HEVC_LEVEL_2_1 }, - { HFI_HEVC_LEVEL_3, V4L2_MPEG_VIDEO_HEVC_LEVEL_3 }, - { HFI_HEVC_LEVEL_31, V4L2_MPEG_VIDEO_HEVC_LEVEL_3_1 }, - { HFI_HEVC_LEVEL_4, V4L2_MPEG_VIDEO_HEVC_LEVEL_4 }, - { HFI_HEVC_LEVEL_41, V4L2_MPEG_VIDEO_HEVC_LEVEL_4_1 }, - { HFI_HEVC_LEVEL_5, V4L2_MPEG_VIDEO_HEVC_LEVEL_5 }, - { HFI_HEVC_LEVEL_51, V4L2_MPEG_VIDEO_HEVC_LEVEL_5_1 }, - { HFI_HEVC_LEVEL_52, V4L2_MPEG_VIDEO_HEVC_LEVEL_5_2 }, - { HFI_HEVC_LEVEL_6, V4L2_MPEG_VIDEO_HEVC_LEVEL_6 }, - { HFI_HEVC_LEVEL_61, V4L2_MPEG_VIDEO_HEVC_LEVEL_6_1 }, - { HFI_HEVC_LEVEL_62, V4L2_MPEG_VIDEO_HEVC_LEVEL_6_2 }, + { HFI_HEVC_LEVEL_1, V4L2_CODEC_VIDEO_HEVC_LEVEL_1 }, + { HFI_HEVC_LEVEL_2, V4L2_CODEC_VIDEO_HEVC_LEVEL_2 }, + { HFI_HEVC_LEVEL_21, V4L2_CODEC_VIDEO_HEVC_LEVEL_2_1 }, + { HFI_HEVC_LEVEL_3, V4L2_CODEC_VIDEO_HEVC_LEVEL_3 }, + { HFI_HEVC_LEVEL_31, V4L2_CODEC_VIDEO_HEVC_LEVEL_3_1 }, + { HFI_HEVC_LEVEL_4, V4L2_CODEC_VIDEO_HEVC_LEVEL_4 }, + { HFI_HEVC_LEVEL_41, V4L2_CODEC_VIDEO_HEVC_LEVEL_4_1 }, + { HFI_HEVC_LEVEL_5, V4L2_CODEC_VIDEO_HEVC_LEVEL_5 }, + { HFI_HEVC_LEVEL_51, V4L2_CODEC_VIDEO_HEVC_LEVEL_5_1 }, + { HFI_HEVC_LEVEL_52, V4L2_CODEC_VIDEO_HEVC_LEVEL_5_2 }, + { HFI_HEVC_LEVEL_6, V4L2_CODEC_VIDEO_HEVC_LEVEL_6 }, + { HFI_HEVC_LEVEL_61, V4L2_CODEC_VIDEO_HEVC_LEVEL_6_1 }, + { HFI_HEVC_LEVEL_62, V4L2_CODEC_VIDEO_HEVC_LEVEL_6_2 }, }; static const struct id_mapping vp8_profiles[] = { - { HFI_VPX_PROFILE_VERSION_0, V4L2_MPEG_VIDEO_VP8_PROFILE_0 }, - { HFI_VPX_PROFILE_VERSION_1, V4L2_MPEG_VIDEO_VP8_PROFILE_1 }, - { HFI_VPX_PROFILE_VERSION_2, V4L2_MPEG_VIDEO_VP8_PROFILE_2 }, - { HFI_VPX_PROFILE_VERSION_3, V4L2_MPEG_VIDEO_VP8_PROFILE_3 }, + { HFI_VPX_PROFILE_VERSION_0, V4L2_CODEC_VIDEO_VP8_PROFILE_0 }, + { HFI_VPX_PROFILE_VERSION_1, V4L2_CODEC_VIDEO_VP8_PROFILE_1 }, + { HFI_VPX_PROFILE_VERSION_2, V4L2_CODEC_VIDEO_VP8_PROFILE_2 }, + { HFI_VPX_PROFILE_VERSION_3, V4L2_CODEC_VIDEO_VP8_PROFILE_3 }, }; static const struct id_mapping vp9_profiles[] = { - { HFI_VP9_PROFILE_P0, V4L2_MPEG_VIDEO_VP9_PROFILE_0 }, - { HFI_VP9_PROFILE_P2_10B, V4L2_MPEG_VIDEO_VP9_PROFILE_2 }, + { HFI_VP9_PROFILE_P0, V4L2_CODEC_VIDEO_VP9_PROFILE_0 }, + { HFI_VP9_PROFILE_P2_10B, V4L2_CODEC_VIDEO_VP9_PROFILE_2 }, }; static const struct id_mapping vp9_levels[] = { - { HFI_VP9_LEVEL_1, V4L2_MPEG_VIDEO_VP9_LEVEL_1_0 }, - { HFI_VP9_LEVEL_11, V4L2_MPEG_VIDEO_VP9_LEVEL_1_1 }, - { HFI_VP9_LEVEL_2, V4L2_MPEG_VIDEO_VP9_LEVEL_2_0}, - { HFI_VP9_LEVEL_21, V4L2_MPEG_VIDEO_VP9_LEVEL_2_1 }, - { HFI_VP9_LEVEL_3, V4L2_MPEG_VIDEO_VP9_LEVEL_3_0}, - { HFI_VP9_LEVEL_31, V4L2_MPEG_VIDEO_VP9_LEVEL_3_1 }, - { HFI_VP9_LEVEL_4, V4L2_MPEG_VIDEO_VP9_LEVEL_4_0 }, - { HFI_VP9_LEVEL_41, V4L2_MPEG_VIDEO_VP9_LEVEL_4_1 }, - { HFI_VP9_LEVEL_5, V4L2_MPEG_VIDEO_VP9_LEVEL_5_0 }, - { HFI_VP9_LEVEL_51, V4L2_MPEG_VIDEO_VP9_LEVEL_5_1 }, - { HFI_VP9_LEVEL_6, V4L2_MPEG_VIDEO_VP9_LEVEL_6_0 }, - { HFI_VP9_LEVEL_61, V4L2_MPEG_VIDEO_VP9_LEVEL_6_1 }, + { HFI_VP9_LEVEL_1, V4L2_CODEC_VIDEO_VP9_LEVEL_1_0 }, + { HFI_VP9_LEVEL_11, V4L2_CODEC_VIDEO_VP9_LEVEL_1_1 }, + { HFI_VP9_LEVEL_2, V4L2_CODEC_VIDEO_VP9_LEVEL_2_0}, + { HFI_VP9_LEVEL_21, V4L2_CODEC_VIDEO_VP9_LEVEL_2_1 }, + { HFI_VP9_LEVEL_3, V4L2_CODEC_VIDEO_VP9_LEVEL_3_0}, + { HFI_VP9_LEVEL_31, V4L2_CODEC_VIDEO_VP9_LEVEL_3_1 }, + { HFI_VP9_LEVEL_4, V4L2_CODEC_VIDEO_VP9_LEVEL_4_0 }, + { HFI_VP9_LEVEL_41, V4L2_CODEC_VIDEO_VP9_LEVEL_4_1 }, + { HFI_VP9_LEVEL_5, V4L2_CODEC_VIDEO_VP9_LEVEL_5_0 }, + { HFI_VP9_LEVEL_51, V4L2_CODEC_VIDEO_VP9_LEVEL_5_1 }, + { HFI_VP9_LEVEL_6, V4L2_CODEC_VIDEO_VP9_LEVEL_6_0 }, + { HFI_VP9_LEVEL_61, V4L2_CODEC_VIDEO_VP9_LEVEL_6_1 }, }; static u32 find_v4l2_id(u32 hfi_id, const struct id_mapping *array, unsigned int array_sz) diff --git a/drivers/media/platform/qcom/venus/vdec_ctrls.c b/drivers/media/platform/qcom/venus/vdec_ctrls.c index 974110b75b93..e6dd79af10af 100644 --- a/drivers/media/platform/qcom/venus/vdec_ctrls.c +++ b/drivers/media/platform/qcom/venus/vdec_ctrls.c @@ -16,18 +16,18 @@ static int vdec_op_s_ctrl(struct v4l2_ctrl *ctrl) struct vdec_controls *ctr = &inst->controls.dec; switch (ctrl->id) { - case V4L2_CID_MPEG_VIDEO_DECODER_MPEG4_DEBLOCK_FILTER: + case V4L2_CID_CODEC_VIDEO_DECODER_MPEG4_DEBLOCK_FILTER: ctr->post_loop_deb_mode = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_PROFILE: - case V4L2_CID_MPEG_VIDEO_MPEG4_PROFILE: - case V4L2_CID_MPEG_VIDEO_VP8_PROFILE: - case V4L2_CID_MPEG_VIDEO_VP9_PROFILE: + case V4L2_CID_CODEC_VIDEO_H264_PROFILE: + case V4L2_CID_CODEC_VIDEO_MPEG4_PROFILE: + case V4L2_CID_CODEC_VIDEO_VP8_PROFILE: + case V4L2_CID_CODEC_VIDEO_VP9_PROFILE: ctr->profile = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_LEVEL: - case V4L2_CID_MPEG_VIDEO_MPEG4_LEVEL: - case V4L2_CID_MPEG_VIDEO_VP9_LEVEL: + case V4L2_CID_CODEC_VIDEO_H264_LEVEL: + case V4L2_CID_CODEC_VIDEO_MPEG4_LEVEL: + case V4L2_CID_CODEC_VIDEO_VP9_LEVEL: ctr->level = ctrl->val; break; default: @@ -47,24 +47,24 @@ static int vdec_op_g_volatile_ctrl(struct v4l2_ctrl *ctrl) int ret; switch (ctrl->id) { - case V4L2_CID_MPEG_VIDEO_H264_PROFILE: - case V4L2_CID_MPEG_VIDEO_MPEG4_PROFILE: - case V4L2_CID_MPEG_VIDEO_VP8_PROFILE: - case V4L2_CID_MPEG_VIDEO_VP9_PROFILE: + case V4L2_CID_CODEC_VIDEO_H264_PROFILE: + case V4L2_CID_CODEC_VIDEO_MPEG4_PROFILE: + case V4L2_CID_CODEC_VIDEO_VP8_PROFILE: + case V4L2_CID_CODEC_VIDEO_VP9_PROFILE: ret = venus_helper_get_profile_level(inst, &profile, &level); if (!ret) ctr->profile = profile; ctrl->val = ctr->profile; break; - case V4L2_CID_MPEG_VIDEO_H264_LEVEL: - case V4L2_CID_MPEG_VIDEO_MPEG4_LEVEL: - case V4L2_CID_MPEG_VIDEO_VP9_LEVEL: + case V4L2_CID_CODEC_VIDEO_H264_LEVEL: + case V4L2_CID_CODEC_VIDEO_MPEG4_LEVEL: + case V4L2_CID_CODEC_VIDEO_VP9_LEVEL: ret = venus_helper_get_profile_level(inst, &profile, &level); if (!ret) ctr->level = level; ctrl->val = ctr->level; break; - case V4L2_CID_MPEG_VIDEO_DECODER_MPEG4_DEBLOCK_FILTER: + case V4L2_CID_CODEC_VIDEO_DECODER_MPEG4_DEBLOCK_FILTER: ctrl->val = ctr->post_loop_deb_mode; break; case V4L2_CID_MIN_BUFFERS_FOR_CAPTURE: @@ -94,64 +94,64 @@ int vdec_ctrl_init(struct venus_inst *inst) return ret; ctrl = v4l2_ctrl_new_std_menu(&inst->ctrl_handler, &vdec_ctrl_ops, - V4L2_CID_MPEG_VIDEO_MPEG4_PROFILE, - V4L2_MPEG_VIDEO_MPEG4_PROFILE_ADVANCED_CODING_EFFICIENCY, - ~((1 << V4L2_MPEG_VIDEO_MPEG4_PROFILE_SIMPLE) | - (1 << V4L2_MPEG_VIDEO_MPEG4_PROFILE_ADVANCED_SIMPLE)), - V4L2_MPEG_VIDEO_MPEG4_PROFILE_SIMPLE); + V4L2_CID_CODEC_VIDEO_MPEG4_PROFILE, + V4L2_CODEC_VIDEO_MPEG4_PROFILE_ADVANCED_CODING_EFFICIENCY, + ~((1 << V4L2_CODEC_VIDEO_MPEG4_PROFILE_SIMPLE) | + (1 << V4L2_CODEC_VIDEO_MPEG4_PROFILE_ADVANCED_SIMPLE)), + V4L2_CODEC_VIDEO_MPEG4_PROFILE_SIMPLE); if (ctrl) ctrl->flags |= V4L2_CTRL_FLAG_VOLATILE; ctrl = v4l2_ctrl_new_std_menu(&inst->ctrl_handler, &vdec_ctrl_ops, - V4L2_CID_MPEG_VIDEO_MPEG4_LEVEL, - V4L2_MPEG_VIDEO_MPEG4_LEVEL_5, - 0, V4L2_MPEG_VIDEO_MPEG4_LEVEL_0); + V4L2_CID_CODEC_VIDEO_MPEG4_LEVEL, + V4L2_CODEC_VIDEO_MPEG4_LEVEL_5, + 0, V4L2_CODEC_VIDEO_MPEG4_LEVEL_0); if (ctrl) ctrl->flags |= V4L2_CTRL_FLAG_VOLATILE; ctrl = v4l2_ctrl_new_std_menu(&inst->ctrl_handler, &vdec_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_PROFILE, - V4L2_MPEG_VIDEO_H264_PROFILE_MULTIVIEW_HIGH, - ~((1 << V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE) | - (1 << V4L2_MPEG_VIDEO_H264_PROFILE_CONSTRAINED_BASELINE) | - (1 << V4L2_MPEG_VIDEO_H264_PROFILE_MAIN) | - (1 << V4L2_MPEG_VIDEO_H264_PROFILE_HIGH) | - (1 << V4L2_MPEG_VIDEO_H264_PROFILE_STEREO_HIGH) | - (1 << V4L2_MPEG_VIDEO_H264_PROFILE_MULTIVIEW_HIGH)), - V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE); + V4L2_CID_CODEC_VIDEO_H264_PROFILE, + V4L2_CODEC_VIDEO_H264_PROFILE_MULTIVIEW_HIGH, + ~((1 << V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE) | + (1 << V4L2_CODEC_VIDEO_H264_PROFILE_CONSTRAINED_BASELINE) | + (1 << V4L2_CODEC_VIDEO_H264_PROFILE_MAIN) | + (1 << V4L2_CODEC_VIDEO_H264_PROFILE_HIGH) | + (1 << V4L2_CODEC_VIDEO_H264_PROFILE_STEREO_HIGH) | + (1 << V4L2_CODEC_VIDEO_H264_PROFILE_MULTIVIEW_HIGH)), + V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE); if (ctrl) ctrl->flags |= V4L2_CTRL_FLAG_VOLATILE; ctrl = v4l2_ctrl_new_std_menu(&inst->ctrl_handler, &vdec_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_LEVEL, - V4L2_MPEG_VIDEO_H264_LEVEL_5_1, - 0, V4L2_MPEG_VIDEO_H264_LEVEL_1_0); + V4L2_CID_CODEC_VIDEO_H264_LEVEL, + V4L2_CODEC_VIDEO_H264_LEVEL_5_1, + 0, V4L2_CODEC_VIDEO_H264_LEVEL_1_0); if (ctrl) ctrl->flags |= V4L2_CTRL_FLAG_VOLATILE; ctrl = v4l2_ctrl_new_std_menu(&inst->ctrl_handler, &vdec_ctrl_ops, - V4L2_CID_MPEG_VIDEO_VP8_PROFILE, - V4L2_MPEG_VIDEO_VP8_PROFILE_3, - 0, V4L2_MPEG_VIDEO_VP8_PROFILE_0); + V4L2_CID_CODEC_VIDEO_VP8_PROFILE, + V4L2_CODEC_VIDEO_VP8_PROFILE_3, + 0, V4L2_CODEC_VIDEO_VP8_PROFILE_0); if (ctrl) ctrl->flags |= V4L2_CTRL_FLAG_VOLATILE; ctrl = v4l2_ctrl_new_std_menu(&inst->ctrl_handler, &vdec_ctrl_ops, - V4L2_CID_MPEG_VIDEO_VP9_PROFILE, - V4L2_MPEG_VIDEO_VP9_PROFILE_3, - 0, V4L2_MPEG_VIDEO_VP9_PROFILE_0); + V4L2_CID_CODEC_VIDEO_VP9_PROFILE, + V4L2_CODEC_VIDEO_VP9_PROFILE_3, + 0, V4L2_CODEC_VIDEO_VP9_PROFILE_0); if (ctrl) ctrl->flags |= V4L2_CTRL_FLAG_VOLATILE; ctrl = v4l2_ctrl_new_std_menu(&inst->ctrl_handler, &vdec_ctrl_ops, - V4L2_CID_MPEG_VIDEO_VP9_LEVEL, - V4L2_MPEG_VIDEO_VP9_LEVEL_6_2, - 0, V4L2_MPEG_VIDEO_VP9_LEVEL_1_0); + V4L2_CID_CODEC_VIDEO_VP9_LEVEL, + V4L2_CODEC_VIDEO_VP9_LEVEL_6_2, + 0, V4L2_CODEC_VIDEO_VP9_LEVEL_1_0); if (ctrl) ctrl->flags |= V4L2_CTRL_FLAG_VOLATILE; v4l2_ctrl_new_std(&inst->ctrl_handler, &vdec_ctrl_ops, - V4L2_CID_MPEG_VIDEO_DECODER_MPEG4_DEBLOCK_FILTER, 0, 1, 1, 0); + V4L2_CID_CODEC_VIDEO_DECODER_MPEG4_DEBLOCK_FILTER, 0, 1, 1, 0); ctrl = v4l2_ctrl_new_std(&inst->ctrl_handler, &vdec_ctrl_ops, V4L2_CID_MIN_BUFFERS_FOR_CAPTURE, 1, 32, 1, 1); diff --git a/drivers/media/platform/qcom/venus/venc.c b/drivers/media/platform/qcom/venus/venc.c index 6976ed553647..16251e662b64 100644 --- a/drivers/media/platform/qcom/venus/venc.c +++ b/drivers/media/platform/qcom/venus/venc.c @@ -113,22 +113,22 @@ find_format_by_index(struct venus_inst *inst, unsigned int index, u32 type) static int venc_v4l2_to_hfi(int id, int value) { switch (id) { - case V4L2_CID_MPEG_VIDEO_H264_ENTROPY_MODE: + case V4L2_CID_CODEC_VIDEO_H264_ENTROPY_MODE: switch (value) { - case V4L2_MPEG_VIDEO_H264_ENTROPY_MODE_CAVLC: + case V4L2_CODEC_VIDEO_H264_ENTROPY_MODE_CAVLC: default: return HFI_H264_ENTROPY_CAVLC; - case V4L2_MPEG_VIDEO_H264_ENTROPY_MODE_CABAC: + case V4L2_CODEC_VIDEO_H264_ENTROPY_MODE_CABAC: return HFI_H264_ENTROPY_CABAC; } - case V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_MODE: + case V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_MODE: switch (value) { - case V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_ENABLED: + case V4L2_CODEC_VIDEO_H264_LOOP_FILTER_MODE_ENABLED: default: return HFI_H264_DB_MODE_ALL_BOUNDARY; - case V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_DISABLED: + case V4L2_CODEC_VIDEO_H264_LOOP_FILTER_MODE_DISABLED: return HFI_H264_DB_MODE_DISABLE; - case V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY: + case V4L2_CODEC_VIDEO_H264_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY: return HFI_H264_DB_MODE_SKIP_SLICE_BOUNDARY; } } @@ -578,7 +578,7 @@ static int venc_set_properties(struct venus_inst *inst) ptype = HFI_PROPERTY_PARAM_VENC_H264_ENTROPY_CONTROL; entropy.entropy_mode = venc_v4l2_to_hfi( - V4L2_CID_MPEG_VIDEO_H264_ENTROPY_MODE, + V4L2_CID_CODEC_VIDEO_H264_ENTROPY_MODE, ctr->h264_entropy_mode); entropy.cabac_model = HFI_H264_CABAC_MODEL_0; @@ -588,7 +588,7 @@ static int venc_set_properties(struct venus_inst *inst) ptype = HFI_PROPERTY_PARAM_VENC_H264_DEBLOCK_CONTROL; deblock.mode = venc_v4l2_to_hfi( - V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_MODE, + V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_MODE, ctr->h264_loop_filter_mode); deblock.slice_alpha_offset = ctr->h264_loop_filter_alpha; deblock.slice_beta_offset = ctr->h264_loop_filter_beta; @@ -631,13 +631,13 @@ static int venc_set_properties(struct venus_inst *inst) if (!ctr->rc_enable) rate_control = HFI_RATE_CONTROL_OFF; - else if (ctr->bitrate_mode == V4L2_MPEG_VIDEO_BITRATE_MODE_VBR) + else if (ctr->bitrate_mode == V4L2_CODEC_VIDEO_BITRATE_MODE_VBR) rate_control = ctr->frame_skip_mode ? HFI_RATE_CONTROL_VBR_VFR : HFI_RATE_CONTROL_VBR_CFR; - else if (ctr->bitrate_mode == V4L2_MPEG_VIDEO_BITRATE_MODE_CBR) + else if (ctr->bitrate_mode == V4L2_CODEC_VIDEO_BITRATE_MODE_CBR) rate_control = ctr->frame_skip_mode ? HFI_RATE_CONTROL_CBR_VFR : HFI_RATE_CONTROL_CBR_CFR; - else if (ctr->bitrate_mode == V4L2_MPEG_VIDEO_BITRATE_MODE_CQ) + else if (ctr->bitrate_mode == V4L2_CODEC_VIDEO_BITRATE_MODE_CQ) rate_control = HFI_RATE_CONTROL_CQ; ptype = HFI_PROPERTY_PARAM_VENC_RATE_CONTROL; @@ -671,7 +671,7 @@ static int venc_set_properties(struct venus_inst *inst) if (inst->fmt_cap->pixfmt == V4L2_PIX_FMT_H264 || inst->fmt_cap->pixfmt == V4L2_PIX_FMT_HEVC) { ptype = HFI_PROPERTY_CONFIG_VENC_SYNC_FRAME_SEQUENCE_HEADER; - if (ctr->header_mode == V4L2_MPEG_VIDEO_HEADER_MODE_SEPARATE) + if (ctr->header_mode == V4L2_CODEC_VIDEO_HEADER_MODE_SEPARATE) en.enable = 0; else en.enable = 1; diff --git a/drivers/media/platform/qcom/venus/venc_ctrls.c b/drivers/media/platform/qcom/venus/venc_ctrls.c index a52b80055173..cf0943ee5be0 100644 --- a/drivers/media/platform/qcom/venus/venc_ctrls.c +++ b/drivers/media/platform/qcom/venus/venc_ctrls.c @@ -19,7 +19,7 @@ #define SLICE_MB_SIZE_MAX 300 #define INTRA_REFRESH_MBS_MAX 300 #define AT_SLICE_BOUNDARY \ - V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY + V4L2_CODEC_VIDEO_H264_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY static int venc_calc_bpframes(u32 gop_size, u32 conseq_b, u32 *bf, u32 *pf) { @@ -77,10 +77,10 @@ static int venc_op_s_ctrl(struct v4l2_ctrl *ctrl) int ret; switch (ctrl->id) { - case V4L2_CID_MPEG_VIDEO_BITRATE_MODE: + case V4L2_CID_CODEC_VIDEO_BITRATE_MODE: ctr->bitrate_mode = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_BITRATE: + case V4L2_CID_CODEC_VIDEO_BITRATE: ctr->bitrate = ctrl->val; mutex_lock(&inst->lock); if (inst->streamon_out && inst->streamon_cap) { @@ -96,122 +96,122 @@ static int venc_op_s_ctrl(struct v4l2_ctrl *ctrl) } mutex_unlock(&inst->lock); break; - case V4L2_CID_MPEG_VIDEO_BITRATE_PEAK: + case V4L2_CID_CODEC_VIDEO_BITRATE_PEAK: ctr->bitrate_peak = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_ENTROPY_MODE: + case V4L2_CID_CODEC_VIDEO_H264_ENTROPY_MODE: ctr->h264_entropy_mode = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_MPEG4_PROFILE: + case V4L2_CID_CODEC_VIDEO_MPEG4_PROFILE: ctr->profile.mpeg4 = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_PROFILE: + case V4L2_CID_CODEC_VIDEO_H264_PROFILE: ctr->profile.h264 = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_PROFILE: + case V4L2_CID_CODEC_VIDEO_HEVC_PROFILE: ctr->profile.hevc = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_VP8_PROFILE: + case V4L2_CID_CODEC_VIDEO_VP8_PROFILE: ctr->profile.vp8 = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_MPEG4_LEVEL: + case V4L2_CID_CODEC_VIDEO_MPEG4_LEVEL: ctr->level.mpeg4 = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_LEVEL: + case V4L2_CID_CODEC_VIDEO_H264_LEVEL: ctr->level.h264 = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_LEVEL: + case V4L2_CID_CODEC_VIDEO_HEVC_LEVEL: ctr->level.hevc = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_I_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_H264_I_FRAME_QP: ctr->h264_i_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_P_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_H264_P_FRAME_QP: ctr->h264_p_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_B_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_H264_B_FRAME_QP: ctr->h264_b_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_MIN_QP: + case V4L2_CID_CODEC_VIDEO_H264_MIN_QP: ctr->h264_min_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_I_FRAME_MIN_QP: + case V4L2_CID_CODEC_VIDEO_H264_I_FRAME_MIN_QP: ctr->h264_i_min_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_P_FRAME_MIN_QP: + case V4L2_CID_CODEC_VIDEO_H264_P_FRAME_MIN_QP: ctr->h264_p_min_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_B_FRAME_MIN_QP: + case V4L2_CID_CODEC_VIDEO_H264_B_FRAME_MIN_QP: ctr->h264_b_min_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_MAX_QP: + case V4L2_CID_CODEC_VIDEO_H264_MAX_QP: ctr->h264_max_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_I_FRAME_MAX_QP: + case V4L2_CID_CODEC_VIDEO_H264_I_FRAME_MAX_QP: ctr->h264_i_max_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_P_FRAME_MAX_QP: + case V4L2_CID_CODEC_VIDEO_H264_P_FRAME_MAX_QP: ctr->h264_p_max_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_B_FRAME_MAX_QP: + case V4L2_CID_CODEC_VIDEO_H264_B_FRAME_MAX_QP: ctr->h264_b_max_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_HEVC_I_FRAME_QP: ctr->hevc_i_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_HEVC_P_FRAME_QP: ctr->hevc_p_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_HEVC_B_FRAME_QP: ctr->hevc_b_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP: + case V4L2_CID_CODEC_VIDEO_HEVC_MIN_QP: ctr->hevc_min_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_MIN_QP: + case V4L2_CID_CODEC_VIDEO_HEVC_I_FRAME_MIN_QP: ctr->hevc_i_min_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_MIN_QP: + case V4L2_CID_CODEC_VIDEO_HEVC_P_FRAME_MIN_QP: ctr->hevc_p_min_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_MIN_QP: + case V4L2_CID_CODEC_VIDEO_HEVC_B_FRAME_MIN_QP: ctr->hevc_b_min_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP: + case V4L2_CID_CODEC_VIDEO_HEVC_MAX_QP: ctr->hevc_max_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_MAX_QP: + case V4L2_CID_CODEC_VIDEO_HEVC_I_FRAME_MAX_QP: ctr->hevc_i_max_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_MAX_QP: + case V4L2_CID_CODEC_VIDEO_HEVC_P_FRAME_MAX_QP: ctr->hevc_p_max_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_MAX_QP: + case V4L2_CID_CODEC_VIDEO_HEVC_B_FRAME_MAX_QP: ctr->hevc_b_max_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MODE: + case V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MODE: ctr->multi_slice_mode = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MAX_BYTES: + case V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MAX_BYTES: ctr->multi_slice_max_bytes = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MAX_MB: + case V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MAX_MB: ctr->multi_slice_max_mb = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_ALPHA: + case V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_ALPHA: ctr->h264_loop_filter_alpha = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_BETA: + case V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_BETA: ctr->h264_loop_filter_beta = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_MODE: + case V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_MODE: ctr->h264_loop_filter_mode = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEADER_MODE: + case V4L2_CID_CODEC_VIDEO_HEADER_MODE: ctr->header_mode = ctrl->val; mutex_lock(&inst->lock); if (inst->streamon_out && inst->streamon_cap) { - if (ctrl->val == V4L2_MPEG_VIDEO_HEADER_MODE_SEPARATE) + if (ctrl->val == V4L2_CODEC_VIDEO_HEADER_MODE_SEPARATE) en.enable = 0; else en.enable = 1; @@ -224,9 +224,9 @@ static int venc_op_s_ctrl(struct v4l2_ctrl *ctrl) } mutex_unlock(&inst->lock); break; - case V4L2_CID_MPEG_VIDEO_CYCLIC_INTRA_REFRESH_MB: + case V4L2_CID_CODEC_VIDEO_CYCLIC_INTRA_REFRESH_MB: break; - case V4L2_CID_MPEG_VIDEO_GOP_SIZE: + case V4L2_CID_CODEC_VIDEO_GOP_SIZE: ret = venc_calc_bpframes(ctrl->val, ctr->num_b_frames, &bframes, &ctr->num_p_frames); if (ret) @@ -234,16 +234,16 @@ static int venc_op_s_ctrl(struct v4l2_ctrl *ctrl) ctr->gop_size = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_I_PERIOD: + case V4L2_CID_CODEC_VIDEO_H264_I_PERIOD: ctr->h264_i_period = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_VPX_MIN_QP: + case V4L2_CID_CODEC_VIDEO_VPX_MIN_QP: ctr->vp8_min_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_VPX_MAX_QP: + case V4L2_CID_CODEC_VIDEO_VPX_MAX_QP: ctr->vp8_max_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_B_FRAMES: + case V4L2_CID_CODEC_VIDEO_B_FRAMES: ret = venc_calc_bpframes(ctr->gop_size, ctrl->val, &bframes, &ctr->num_p_frames); if (ret) @@ -251,7 +251,7 @@ static int venc_op_s_ctrl(struct v4l2_ctrl *ctrl) ctr->num_b_frames = bframes; break; - case V4L2_CID_MPEG_VIDEO_FORCE_KEY_FRAME: + case V4L2_CID_CODEC_VIDEO_FORCE_KEY_FRAME: mutex_lock(&inst->lock); if (inst->streamon_out && inst->streamon_cap) { ptype = HFI_PROPERTY_CONFIG_VENC_REQUEST_SYNC_FRAME; @@ -264,16 +264,16 @@ static int venc_op_s_ctrl(struct v4l2_ctrl *ctrl) } mutex_unlock(&inst->lock); break; - case V4L2_CID_MPEG_VIDEO_FRAME_RC_ENABLE: + case V4L2_CID_CODEC_VIDEO_FRAME_RC_ENABLE: ctr->rc_enable = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_CONSTANT_QUALITY: + case V4L2_CID_CODEC_VIDEO_CONSTANT_QUALITY: ctr->const_quality = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_FRAME_SKIP_MODE: + case V4L2_CID_CODEC_VIDEO_FRAME_SKIP_MODE: ctr->frame_skip_mode = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_BASELAYER_PRIORITY_ID: + case V4L2_CID_CODEC_VIDEO_BASELAYER_PRIORITY_ID: ctr->base_priority_id = ctrl->val; break; default: @@ -296,206 +296,206 @@ int venc_ctrl_init(struct venus_inst *inst) return ret; v4l2_ctrl_new_std_menu(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_BITRATE_MODE, - V4L2_MPEG_VIDEO_BITRATE_MODE_CBR, - ~((1 << V4L2_MPEG_VIDEO_BITRATE_MODE_VBR) | - (1 << V4L2_MPEG_VIDEO_BITRATE_MODE_CBR) | - (1 << V4L2_MPEG_VIDEO_BITRATE_MODE_CQ)), - V4L2_MPEG_VIDEO_BITRATE_MODE_VBR); + V4L2_CID_CODEC_VIDEO_BITRATE_MODE, + V4L2_CODEC_VIDEO_BITRATE_MODE_CBR, + ~((1 << V4L2_CODEC_VIDEO_BITRATE_MODE_VBR) | + (1 << V4L2_CODEC_VIDEO_BITRATE_MODE_CBR) | + (1 << V4L2_CODEC_VIDEO_BITRATE_MODE_CQ)), + V4L2_CODEC_VIDEO_BITRATE_MODE_VBR); v4l2_ctrl_new_std_menu(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_ENTROPY_MODE, - V4L2_MPEG_VIDEO_H264_ENTROPY_MODE_CABAC, - 0, V4L2_MPEG_VIDEO_H264_ENTROPY_MODE_CAVLC); + V4L2_CID_CODEC_VIDEO_H264_ENTROPY_MODE, + V4L2_CODEC_VIDEO_H264_ENTROPY_MODE_CABAC, + 0, V4L2_CODEC_VIDEO_H264_ENTROPY_MODE_CAVLC); v4l2_ctrl_new_std_menu(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_MPEG4_PROFILE, - V4L2_MPEG_VIDEO_MPEG4_PROFILE_ADVANCED_CODING_EFFICIENCY, - ~((1 << V4L2_MPEG_VIDEO_MPEG4_PROFILE_SIMPLE) | - (1 << V4L2_MPEG_VIDEO_MPEG4_PROFILE_ADVANCED_SIMPLE)), - V4L2_MPEG_VIDEO_MPEG4_PROFILE_SIMPLE); + V4L2_CID_CODEC_VIDEO_MPEG4_PROFILE, + V4L2_CODEC_VIDEO_MPEG4_PROFILE_ADVANCED_CODING_EFFICIENCY, + ~((1 << V4L2_CODEC_VIDEO_MPEG4_PROFILE_SIMPLE) | + (1 << V4L2_CODEC_VIDEO_MPEG4_PROFILE_ADVANCED_SIMPLE)), + V4L2_CODEC_VIDEO_MPEG4_PROFILE_SIMPLE); v4l2_ctrl_new_std_menu(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_MPEG4_LEVEL, - V4L2_MPEG_VIDEO_MPEG4_LEVEL_5, - 0, V4L2_MPEG_VIDEO_MPEG4_LEVEL_0); + V4L2_CID_CODEC_VIDEO_MPEG4_LEVEL, + V4L2_CODEC_VIDEO_MPEG4_LEVEL_5, + 0, V4L2_CODEC_VIDEO_MPEG4_LEVEL_0); v4l2_ctrl_new_std_menu(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_HEVC_PROFILE, - V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN_10, - ~((1 << V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN) | - (1 << V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN_STILL_PICTURE) | - (1 << V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN_10)), - V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN); + V4L2_CID_CODEC_VIDEO_HEVC_PROFILE, + V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN_10, + ~((1 << V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN) | + (1 << V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN_STILL_PICTURE) | + (1 << V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN_10)), + V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN); v4l2_ctrl_new_std_menu(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_HEVC_LEVEL, - V4L2_MPEG_VIDEO_HEVC_LEVEL_6_2, - 0, V4L2_MPEG_VIDEO_HEVC_LEVEL_1); + V4L2_CID_CODEC_VIDEO_HEVC_LEVEL, + V4L2_CODEC_VIDEO_HEVC_LEVEL_6_2, + 0, V4L2_CODEC_VIDEO_HEVC_LEVEL_1); v4l2_ctrl_new_std_menu(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_PROFILE, - V4L2_MPEG_VIDEO_H264_PROFILE_MULTIVIEW_HIGH, - ~((1 << V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE) | - (1 << V4L2_MPEG_VIDEO_H264_PROFILE_CONSTRAINED_BASELINE) | - (1 << V4L2_MPEG_VIDEO_H264_PROFILE_MAIN) | - (1 << V4L2_MPEG_VIDEO_H264_PROFILE_HIGH) | - (1 << V4L2_MPEG_VIDEO_H264_PROFILE_STEREO_HIGH) | - (1 << V4L2_MPEG_VIDEO_H264_PROFILE_MULTIVIEW_HIGH)), - V4L2_MPEG_VIDEO_H264_PROFILE_HIGH); + V4L2_CID_CODEC_VIDEO_H264_PROFILE, + V4L2_CODEC_VIDEO_H264_PROFILE_MULTIVIEW_HIGH, + ~((1 << V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE) | + (1 << V4L2_CODEC_VIDEO_H264_PROFILE_CONSTRAINED_BASELINE) | + (1 << V4L2_CODEC_VIDEO_H264_PROFILE_MAIN) | + (1 << V4L2_CODEC_VIDEO_H264_PROFILE_HIGH) | + (1 << V4L2_CODEC_VIDEO_H264_PROFILE_STEREO_HIGH) | + (1 << V4L2_CODEC_VIDEO_H264_PROFILE_MULTIVIEW_HIGH)), + V4L2_CODEC_VIDEO_H264_PROFILE_HIGH); v4l2_ctrl_new_std_menu(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_LEVEL, - V4L2_MPEG_VIDEO_H264_LEVEL_5_1, - 0, V4L2_MPEG_VIDEO_H264_LEVEL_1_0); + V4L2_CID_CODEC_VIDEO_H264_LEVEL, + V4L2_CODEC_VIDEO_H264_LEVEL_5_1, + 0, V4L2_CODEC_VIDEO_H264_LEVEL_1_0); v4l2_ctrl_new_std_menu(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_MODE, + V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_MODE, AT_SLICE_BOUNDARY, - 0, V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_DISABLED); + 0, V4L2_CODEC_VIDEO_H264_LOOP_FILTER_MODE_DISABLED); v4l2_ctrl_new_std_menu(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_HEADER_MODE, - V4L2_MPEG_VIDEO_HEADER_MODE_JOINED_WITH_1ST_FRAME, - ~((1 << V4L2_MPEG_VIDEO_HEADER_MODE_SEPARATE) | - (1 << V4L2_MPEG_VIDEO_HEADER_MODE_JOINED_WITH_1ST_FRAME)), - V4L2_MPEG_VIDEO_HEADER_MODE_SEPARATE); + V4L2_CID_CODEC_VIDEO_HEADER_MODE, + V4L2_CODEC_VIDEO_HEADER_MODE_JOINED_WITH_1ST_FRAME, + ~((1 << V4L2_CODEC_VIDEO_HEADER_MODE_SEPARATE) | + (1 << V4L2_CODEC_VIDEO_HEADER_MODE_JOINED_WITH_1ST_FRAME)), + V4L2_CODEC_VIDEO_HEADER_MODE_SEPARATE); v4l2_ctrl_new_std_menu(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MODE, - V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_BYTES, - 0, V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_SINGLE); + V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MODE, + V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_MAX_BYTES, + 0, V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_SINGLE); v4l2_ctrl_new_std_menu(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_VP8_PROFILE, - V4L2_MPEG_VIDEO_VP8_PROFILE_3, - 0, V4L2_MPEG_VIDEO_VP8_PROFILE_0); + V4L2_CID_CODEC_VIDEO_VP8_PROFILE, + V4L2_CODEC_VIDEO_VP8_PROFILE_3, + 0, V4L2_CODEC_VIDEO_VP8_PROFILE_0); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_BITRATE, BITRATE_MIN, BITRATE_MAX, + V4L2_CID_CODEC_VIDEO_BITRATE, BITRATE_MIN, BITRATE_MAX, BITRATE_STEP, BITRATE_DEFAULT); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_BITRATE_PEAK, BITRATE_MIN, BITRATE_MAX, + V4L2_CID_CODEC_VIDEO_BITRATE_PEAK, BITRATE_MIN, BITRATE_MAX, BITRATE_STEP, BITRATE_DEFAULT_PEAK); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_I_FRAME_QP, 1, 51, 1, 26); + V4L2_CID_CODEC_VIDEO_H264_I_FRAME_QP, 1, 51, 1, 26); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_P_FRAME_QP, 1, 51, 1, 28); + V4L2_CID_CODEC_VIDEO_H264_P_FRAME_QP, 1, 51, 1, 28); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_B_FRAME_QP, 1, 51, 1, 30); + V4L2_CID_CODEC_VIDEO_H264_B_FRAME_QP, 1, 51, 1, 30); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_MIN_QP, 1, 51, 1, 1); + V4L2_CID_CODEC_VIDEO_H264_MIN_QP, 1, 51, 1, 1); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_I_FRAME_MIN_QP, 1, 51, 1, 1); + V4L2_CID_CODEC_VIDEO_H264_I_FRAME_MIN_QP, 1, 51, 1, 1); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_P_FRAME_MIN_QP, 1, 51, 1, 1); + V4L2_CID_CODEC_VIDEO_H264_P_FRAME_MIN_QP, 1, 51, 1, 1); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_B_FRAME_MIN_QP, 1, 51, 1, 1); + V4L2_CID_CODEC_VIDEO_H264_B_FRAME_MIN_QP, 1, 51, 1, 1); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_MAX_QP, 1, 51, 1, 51); + V4L2_CID_CODEC_VIDEO_H264_MAX_QP, 1, 51, 1, 51); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_I_FRAME_MAX_QP, 1, 51, 1, 51); + V4L2_CID_CODEC_VIDEO_H264_I_FRAME_MAX_QP, 1, 51, 1, 51); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_P_FRAME_MAX_QP, 1, 51, 1, 51); + V4L2_CID_CODEC_VIDEO_H264_P_FRAME_MAX_QP, 1, 51, 1, 51); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_B_FRAME_MAX_QP, 1, 51, 1, 51); + V4L2_CID_CODEC_VIDEO_H264_B_FRAME_MAX_QP, 1, 51, 1, 51); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_QP, 1, 63, 1, 26); + V4L2_CID_CODEC_VIDEO_HEVC_I_FRAME_QP, 1, 63, 1, 26); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_QP, 1, 63, 1, 28); + V4L2_CID_CODEC_VIDEO_HEVC_P_FRAME_QP, 1, 63, 1, 28); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_QP, 1, 63, 1, 30); + V4L2_CID_CODEC_VIDEO_HEVC_B_FRAME_QP, 1, 63, 1, 30); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP, 1, 63, 1, 1); + V4L2_CID_CODEC_VIDEO_HEVC_MIN_QP, 1, 63, 1, 1); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_MIN_QP, 1, 63, 1, 1); + V4L2_CID_CODEC_VIDEO_HEVC_I_FRAME_MIN_QP, 1, 63, 1, 1); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_MIN_QP, 1, 63, 1, 1); + V4L2_CID_CODEC_VIDEO_HEVC_P_FRAME_MIN_QP, 1, 63, 1, 1); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_MIN_QP, 1, 63, 1, 1); + V4L2_CID_CODEC_VIDEO_HEVC_B_FRAME_MIN_QP, 1, 63, 1, 1); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP, 1, 63, 1, 63); + V4L2_CID_CODEC_VIDEO_HEVC_MAX_QP, 1, 63, 1, 63); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_MAX_QP, 1, 63, 1, 63); + V4L2_CID_CODEC_VIDEO_HEVC_I_FRAME_MAX_QP, 1, 63, 1, 63); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_MAX_QP, 1, 63, 1, 63); + V4L2_CID_CODEC_VIDEO_HEVC_P_FRAME_MAX_QP, 1, 63, 1, 63); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_MAX_QP, 1, 63, 1, 63); + V4L2_CID_CODEC_VIDEO_HEVC_B_FRAME_MAX_QP, 1, 63, 1, 63); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MAX_BYTES, SLICE_BYTE_SIZE_MIN, + V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MAX_BYTES, SLICE_BYTE_SIZE_MIN, SLICE_BYTE_SIZE_MAX, 1, SLICE_BYTE_SIZE_MIN); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MAX_MB, 1, + V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MAX_MB, 1, SLICE_MB_SIZE_MAX, 1, 1); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_ALPHA, -6, 6, 1, 0); + V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_ALPHA, -6, 6, 1, 0); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_BETA, -6, 6, 1, 0); + V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_BETA, -6, 6, 1, 0); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_CYCLIC_INTRA_REFRESH_MB, + V4L2_CID_CODEC_VIDEO_CYCLIC_INTRA_REFRESH_MB, 0, INTRA_REFRESH_MBS_MAX, 1, 0); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_GOP_SIZE, 0, (1 << 16) - 1, 1, 30); + V4L2_CID_CODEC_VIDEO_GOP_SIZE, 0, (1 << 16) - 1, 1, 30); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_VPX_MIN_QP, 1, 128, 1, 1); + V4L2_CID_CODEC_VIDEO_VPX_MIN_QP, 1, 128, 1, 1); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_VPX_MAX_QP, 1, 128, 1, 128); + V4L2_CID_CODEC_VIDEO_VPX_MAX_QP, 1, 128, 1, 128); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_B_FRAMES, 0, 4, 1, 0); + V4L2_CID_CODEC_VIDEO_B_FRAMES, 0, 4, 1, 0); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_I_PERIOD, 0, (1 << 16) - 1, 1, 0); + V4L2_CID_CODEC_VIDEO_H264_I_PERIOD, 0, (1 << 16) - 1, 1, 0); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_FORCE_KEY_FRAME, 0, 0, 0, 0); + V4L2_CID_CODEC_VIDEO_FORCE_KEY_FRAME, 0, 0, 0, 0); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_FRAME_RC_ENABLE, 0, 1, 1, 1); + V4L2_CID_CODEC_VIDEO_FRAME_RC_ENABLE, 0, 1, 1, 1); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_CONSTANT_QUALITY, 0, 100, 1, 0); + V4L2_CID_CODEC_VIDEO_CONSTANT_QUALITY, 0, 100, 1, 0); v4l2_ctrl_new_std_menu(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_FRAME_SKIP_MODE, - V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT, - ~((1 << V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_DISABLED) | - (1 << V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT)), - V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_DISABLED); + V4L2_CID_CODEC_VIDEO_FRAME_SKIP_MODE, + V4L2_CODEC_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT, + ~((1 << V4L2_CODEC_VIDEO_FRAME_SKIP_MODE_DISABLED) | + (1 << V4L2_CODEC_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT)), + V4L2_CODEC_VIDEO_FRAME_SKIP_MODE_DISABLED); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, - V4L2_CID_MPEG_VIDEO_BASELAYER_PRIORITY_ID, 0, + V4L2_CID_CODEC_VIDEO_BASELAYER_PRIORITY_ID, 0, 6, 1, 0); ret = inst->ctrl_handler.error; diff --git a/drivers/media/platform/s5p-mfc/s5p_mfc_common.h b/drivers/media/platform/s5p-mfc/s5p_mfc_common.h index 96d1ecd1521b..6739fbab4c00 100644 --- a/drivers/media/platform/s5p-mfc/s5p_mfc_common.h +++ b/drivers/media/platform/s5p-mfc/s5p_mfc_common.h @@ -346,11 +346,11 @@ struct s5p_mfc_dev { * struct s5p_mfc_h264_enc_params - encoding parameters for h264 */ struct s5p_mfc_h264_enc_params { - enum v4l2_mpeg_video_h264_profile profile; - enum v4l2_mpeg_video_h264_loop_filter_mode loop_filter_mode; + enum v4l2_codec_video_h264_profile profile; + enum v4l2_codec_video_h264_loop_filter_mode loop_filter_mode; s8 loop_filter_alpha; s8 loop_filter_beta; - enum v4l2_mpeg_video_h264_entropy_mode entropy_mode; + enum v4l2_codec_video_h264_entropy_mode entropy_mode; u8 max_ref_pic; u8 num_ref_pic_4p; int _8x8_transform; @@ -369,7 +369,7 @@ struct s5p_mfc_h264_enc_params { u8 rc_max_qp; u8 rc_p_frame_qp; u8 rc_b_frame_qp; - enum v4l2_mpeg_video_h264_level level_v4l2; + enum v4l2_codec_video_h264_level level_v4l2; int level; u16 cpb_size; int interlace; @@ -396,7 +396,7 @@ struct s5p_mfc_h264_enc_params { */ struct s5p_mfc_mpeg4_enc_params { /* MPEG4 Only */ - enum v4l2_mpeg_video_mpeg4_profile profile; + enum v4l2_codec_video_mpeg4_profile profile; int quarter_pixel; /* Common for MPEG4, H263 */ u16 vop_time_res; @@ -406,7 +406,7 @@ struct s5p_mfc_mpeg4_enc_params { u8 rc_max_qp; u8 rc_p_frame_qp; u8 rc_b_frame_qp; - enum v4l2_mpeg_video_mpeg4_level level_v4l2; + enum v4l2_codec_video_mpeg4_level level_v4l2; int level; }; @@ -431,9 +431,9 @@ struct s5p_mfc_vp8_enc_params { }; struct s5p_mfc_hevc_enc_params { - enum v4l2_mpeg_video_hevc_profile profile; + enum v4l2_codec_video_hevc_profile profile; int level; - enum v4l2_mpeg_video_h264_level level_v4l2; + enum v4l2_codec_video_h264_level level_v4l2; u8 tier; u32 rc_framerate; u8 rc_min_qp; @@ -462,7 +462,7 @@ struct s5p_mfc_hevc_enc_params { u8 wavefront_enable; u8 enable_ltr; u8 hier_qp_enable; - enum v4l2_mpeg_video_hevc_hier_coding_type hier_qp_type; + enum v4l2_codec_video_hevc_hier_coding_type hier_qp_type; u8 num_hier_layer; u8 hier_qp_layer[7]; u32 hier_bit_layer[7]; @@ -489,7 +489,7 @@ struct s5p_mfc_enc_params { u32 mv_v_range; u16 gop_size; - enum v4l2_mpeg_video_multi_slice_mode slice_mode; + enum v4l2_codec_video_multi_slice_mode slice_mode; u16 slice_mb; u32 slice_bit; u16 intra_refresh_mb; @@ -504,8 +504,8 @@ struct s5p_mfc_enc_params { u16 vbv_size; u32 vbv_delay; - enum v4l2_mpeg_video_header_mode seq_hdr_mode; - enum v4l2_mpeg_mfc51_video_frame_skip_mode frame_skip_mode; + enum v4l2_codec_video_header_mode seq_hdr_mode; + enum v4l2_codec_mfc51_video_frame_skip_mode frame_skip_mode; int fixed_target_bit; u8 num_b_frame; @@ -694,12 +694,12 @@ struct s5p_mfc_ctx { size_t me_buffer_size; size_t tmv_buffer_size; - enum v4l2_mpeg_mfc51_video_force_frame_type force_frame_type; + enum v4l2_codec_mfc51_video_force_frame_type force_frame_type; struct list_head ref_queue; unsigned int ref_queue_cnt; - enum v4l2_mpeg_video_multi_slice_mode slice_mode; + enum v4l2_codec_video_multi_slice_mode slice_mode; union { unsigned int mb; unsigned int bits; diff --git a/drivers/media/platform/s5p-mfc/s5p_mfc_dec.c b/drivers/media/platform/s5p-mfc/s5p_mfc_dec.c index a71753d459ba..4aa6735a7202 100644 --- a/drivers/media/platform/s5p-mfc/s5p_mfc_dec.c +++ b/drivers/media/platform/s5p-mfc/s5p_mfc_dec.c @@ -159,7 +159,7 @@ static struct s5p_mfc_fmt *find_format(struct v4l2_format *f, unsigned int t) static struct mfc_control controls[] = { { - .id = V4L2_CID_MPEG_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY, + .id = V4L2_CID_CODEC_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY, .type = V4L2_CTRL_TYPE_INTEGER, .name = "H264 Display Delay", .minimum = 0, @@ -168,7 +168,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY_ENABLE, + .id = V4L2_CID_CODEC_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY_ENABLE, .type = V4L2_CTRL_TYPE_BOOLEAN, .name = "H264 Display Delay Enable", .minimum = 0, @@ -177,7 +177,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_DECODER_MPEG4_DEBLOCK_FILTER, + .id = V4L2_CID_CODEC_VIDEO_DECODER_MPEG4_DEBLOCK_FILTER, .type = V4L2_CTRL_TYPE_BOOLEAN, .name = "Mpeg4 Loop Filter Enable", .minimum = 0, @@ -186,7 +186,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_DECODER_SLICE_INTERFACE, + .id = V4L2_CID_CODEC_VIDEO_DECODER_SLICE_INTERFACE, .type = V4L2_CTRL_TYPE_BOOLEAN, .name = "Slice Interface Enable", .minimum = 0, @@ -689,16 +689,16 @@ static int s5p_mfc_dec_s_ctrl(struct v4l2_ctrl *ctrl) struct s5p_mfc_ctx *ctx = ctrl_to_ctx(ctrl); switch (ctrl->id) { - case V4L2_CID_MPEG_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY: + case V4L2_CID_CODEC_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY: ctx->display_delay = ctrl->val; break; - case V4L2_CID_MPEG_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY_ENABLE: + case V4L2_CID_CODEC_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY_ENABLE: ctx->display_delay_enable = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_DECODER_MPEG4_DEBLOCK_FILTER: + case V4L2_CID_CODEC_VIDEO_DECODER_MPEG4_DEBLOCK_FILTER: ctx->loop_filter_mpeg4 = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_DECODER_SLICE_INTERFACE: + case V4L2_CID_CODEC_VIDEO_DECODER_SLICE_INTERFACE: ctx->slice_interface = ctrl->val; break; default: diff --git a/drivers/media/platform/s5p-mfc/s5p_mfc_enc.c b/drivers/media/platform/s5p-mfc/s5p_mfc_enc.c index 1fad99edb091..d3401828b73c 100644 --- a/drivers/media/platform/s5p-mfc/s5p_mfc_enc.c +++ b/drivers/media/platform/s5p-mfc/s5p_mfc_enc.c @@ -111,7 +111,7 @@ static struct s5p_mfc_fmt *find_format(struct v4l2_format *f, unsigned int t) static struct mfc_control controls[] = { { - .id = V4L2_CID_MPEG_VIDEO_GOP_SIZE, + .id = V4L2_CID_CODEC_VIDEO_GOP_SIZE, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = (1 << 16) - 1, @@ -119,15 +119,15 @@ static struct mfc_control controls[] = { .default_value = 12, }, { - .id = V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MODE, + .id = V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MODE, .type = V4L2_CTRL_TYPE_MENU, - .minimum = V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_SINGLE, - .maximum = V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_BYTES, - .default_value = V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_SINGLE, + .minimum = V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_SINGLE, + .maximum = V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_MAX_BYTES, + .default_value = V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_SINGLE, .menu_skip_mask = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MAX_MB, + .id = V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MAX_MB, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 1, .maximum = (1 << 16) - 1, @@ -135,7 +135,7 @@ static struct mfc_control controls[] = { .default_value = 1, }, { - .id = V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MAX_BYTES, + .id = V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MAX_BYTES, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 1900, .maximum = (1 << 30) - 1, @@ -143,7 +143,7 @@ static struct mfc_control controls[] = { .default_value = 1900, }, { - .id = V4L2_CID_MPEG_VIDEO_CYCLIC_INTRA_REFRESH_MB, + .id = V4L2_CID_CODEC_VIDEO_CYCLIC_INTRA_REFRESH_MB, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = (1 << 16) - 1, @@ -151,7 +151,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_MFC51_VIDEO_PADDING, + .id = V4L2_CID_CODEC_MFC51_VIDEO_PADDING, .type = V4L2_CTRL_TYPE_BOOLEAN, .name = "Padding Control Enable", .minimum = 0, @@ -160,7 +160,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_MFC51_VIDEO_PADDING_YUV, + .id = V4L2_CID_CODEC_MFC51_VIDEO_PADDING_YUV, .type = V4L2_CTRL_TYPE_INTEGER, .name = "Padding Color YUV Value", .minimum = 0, @@ -169,7 +169,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_FRAME_RC_ENABLE, + .id = V4L2_CID_CODEC_VIDEO_FRAME_RC_ENABLE, .type = V4L2_CTRL_TYPE_BOOLEAN, .minimum = 0, .maximum = 1, @@ -177,7 +177,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_BITRATE, + .id = V4L2_CID_CODEC_VIDEO_BITRATE, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 1, .maximum = (1 << 30) - 1, @@ -185,7 +185,7 @@ static struct mfc_control controls[] = { .default_value = 1, }, { - .id = V4L2_CID_MPEG_MFC51_VIDEO_RC_REACTION_COEFF, + .id = V4L2_CID_CODEC_MFC51_VIDEO_RC_REACTION_COEFF, .type = V4L2_CTRL_TYPE_INTEGER, .name = "Rate Control Reaction Coeff.", .minimum = 1, @@ -194,16 +194,16 @@ static struct mfc_control controls[] = { .default_value = 1, }, { - .id = V4L2_CID_MPEG_MFC51_VIDEO_FORCE_FRAME_TYPE, + .id = V4L2_CID_CODEC_MFC51_VIDEO_FORCE_FRAME_TYPE, .type = V4L2_CTRL_TYPE_MENU, .name = "Force frame type", - .minimum = V4L2_MPEG_MFC51_VIDEO_FORCE_FRAME_TYPE_DISABLED, - .maximum = V4L2_MPEG_MFC51_VIDEO_FORCE_FRAME_TYPE_NOT_CODED, - .default_value = V4L2_MPEG_MFC51_VIDEO_FORCE_FRAME_TYPE_DISABLED, + .minimum = V4L2_CODEC_MFC51_VIDEO_FORCE_FRAME_TYPE_DISABLED, + .maximum = V4L2_CODEC_MFC51_VIDEO_FORCE_FRAME_TYPE_NOT_CODED, + .default_value = V4L2_CODEC_MFC51_VIDEO_FORCE_FRAME_TYPE_DISABLED, .menu_skip_mask = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_FORCE_KEY_FRAME, + .id = V4L2_CID_CODEC_VIDEO_FORCE_KEY_FRAME, .type = V4L2_CTRL_TYPE_BUTTON, .minimum = 0, .maximum = 0, @@ -211,7 +211,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_VBV_SIZE, + .id = V4L2_CID_CODEC_VIDEO_VBV_SIZE, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = (1 << 16) - 1, @@ -219,7 +219,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_MV_H_SEARCH_RANGE, + .id = V4L2_CID_CODEC_VIDEO_MV_H_SEARCH_RANGE, .type = V4L2_CTRL_TYPE_INTEGER, .name = "Horizontal MV Search Range", .minimum = 16, @@ -228,7 +228,7 @@ static struct mfc_control controls[] = { .default_value = 32, }, { - .id = V4L2_CID_MPEG_VIDEO_MV_V_SEARCH_RANGE, + .id = V4L2_CID_CODEC_VIDEO_MV_V_SEARCH_RANGE, .type = V4L2_CTRL_TYPE_INTEGER, .name = "Vertical MV Search Range", .minimum = 16, @@ -237,7 +237,7 @@ static struct mfc_control controls[] = { .default_value = 32, }, { - .id = V4L2_CID_MPEG_VIDEO_H264_CPB_SIZE, + .id = V4L2_CID_CODEC_VIDEO_H264_CPB_SIZE, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = (1 << 16) - 1, @@ -245,30 +245,30 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEADER_MODE, + .id = V4L2_CID_CODEC_VIDEO_HEADER_MODE, .type = V4L2_CTRL_TYPE_MENU, - .minimum = V4L2_MPEG_VIDEO_HEADER_MODE_SEPARATE, - .maximum = V4L2_MPEG_VIDEO_HEADER_MODE_JOINED_WITH_1ST_FRAME, - .default_value = V4L2_MPEG_VIDEO_HEADER_MODE_SEPARATE, + .minimum = V4L2_CODEC_VIDEO_HEADER_MODE_SEPARATE, + .maximum = V4L2_CODEC_VIDEO_HEADER_MODE_JOINED_WITH_1ST_FRAME, + .default_value = V4L2_CODEC_VIDEO_HEADER_MODE_SEPARATE, .menu_skip_mask = 0, }, { - .id = V4L2_CID_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE, + .id = V4L2_CID_CODEC_MFC51_VIDEO_FRAME_SKIP_MODE, .type = V4L2_CTRL_TYPE_MENU, .name = "Frame Skip Enable", - .minimum = V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_DISABLED, - .maximum = V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT, + .minimum = V4L2_CODEC_MFC51_VIDEO_FRAME_SKIP_MODE_DISABLED, + .maximum = V4L2_CODEC_MFC51_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT, .menu_skip_mask = 0, - .default_value = V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_DISABLED, + .default_value = V4L2_CODEC_MFC51_VIDEO_FRAME_SKIP_MODE_DISABLED, }, { - .id = V4L2_CID_MPEG_VIDEO_FRAME_SKIP_MODE, + .id = V4L2_CID_CODEC_VIDEO_FRAME_SKIP_MODE, .type = V4L2_CTRL_TYPE_MENU, - .maximum = V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT, - .default_value = V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_DISABLED, + .maximum = V4L2_CODEC_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT, + .default_value = V4L2_CODEC_VIDEO_FRAME_SKIP_MODE_DISABLED, }, { - .id = V4L2_CID_MPEG_MFC51_VIDEO_RC_FIXED_TARGET_BIT, + .id = V4L2_CID_CODEC_MFC51_VIDEO_RC_FIXED_TARGET_BIT, .type = V4L2_CTRL_TYPE_BOOLEAN, .name = "Fixed Target Bit Enable", .minimum = 0, @@ -278,7 +278,7 @@ static struct mfc_control controls[] = { .menu_skip_mask = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_B_FRAMES, + .id = V4L2_CID_CODEC_VIDEO_B_FRAMES, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = 2, @@ -286,42 +286,42 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_H264_PROFILE, + .id = V4L2_CID_CODEC_VIDEO_H264_PROFILE, .type = V4L2_CTRL_TYPE_MENU, - .minimum = V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE, - .maximum = V4L2_MPEG_VIDEO_H264_PROFILE_MULTIVIEW_HIGH, - .default_value = V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE, + .minimum = V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE, + .maximum = V4L2_CODEC_VIDEO_H264_PROFILE_MULTIVIEW_HIGH, + .default_value = V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE, .menu_skip_mask = ~( - (1 << V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE) | - (1 << V4L2_MPEG_VIDEO_H264_PROFILE_MAIN) | - (1 << V4L2_MPEG_VIDEO_H264_PROFILE_HIGH) + (1 << V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE) | + (1 << V4L2_CODEC_VIDEO_H264_PROFILE_MAIN) | + (1 << V4L2_CODEC_VIDEO_H264_PROFILE_HIGH) ), }, { - .id = V4L2_CID_MPEG_VIDEO_H264_LEVEL, + .id = V4L2_CID_CODEC_VIDEO_H264_LEVEL, .type = V4L2_CTRL_TYPE_MENU, - .minimum = V4L2_MPEG_VIDEO_H264_LEVEL_1_0, - .maximum = V4L2_MPEG_VIDEO_H264_LEVEL_4_0, - .default_value = V4L2_MPEG_VIDEO_H264_LEVEL_1_0, + .minimum = V4L2_CODEC_VIDEO_H264_LEVEL_1_0, + .maximum = V4L2_CODEC_VIDEO_H264_LEVEL_4_0, + .default_value = V4L2_CODEC_VIDEO_H264_LEVEL_1_0, }, { - .id = V4L2_CID_MPEG_VIDEO_MPEG4_LEVEL, + .id = V4L2_CID_CODEC_VIDEO_MPEG4_LEVEL, .type = V4L2_CTRL_TYPE_MENU, - .minimum = V4L2_MPEG_VIDEO_MPEG4_LEVEL_0, - .maximum = V4L2_MPEG_VIDEO_MPEG4_LEVEL_5, - .default_value = V4L2_MPEG_VIDEO_MPEG4_LEVEL_0, + .minimum = V4L2_CODEC_VIDEO_MPEG4_LEVEL_0, + .maximum = V4L2_CODEC_VIDEO_MPEG4_LEVEL_5, + .default_value = V4L2_CODEC_VIDEO_MPEG4_LEVEL_0, .menu_skip_mask = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_MODE, + .id = V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_MODE, .type = V4L2_CTRL_TYPE_MENU, - .minimum = V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_ENABLED, - .maximum = V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY, - .default_value = V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_ENABLED, + .minimum = V4L2_CODEC_VIDEO_H264_LOOP_FILTER_MODE_ENABLED, + .maximum = V4L2_CODEC_VIDEO_H264_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY, + .default_value = V4L2_CODEC_VIDEO_H264_LOOP_FILTER_MODE_ENABLED, .menu_skip_mask = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_ALPHA, + .id = V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_ALPHA, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = -6, .maximum = 6, @@ -329,7 +329,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_BETA, + .id = V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_BETA, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = -6, .maximum = 6, @@ -337,15 +337,15 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_H264_ENTROPY_MODE, + .id = V4L2_CID_CODEC_VIDEO_H264_ENTROPY_MODE, .type = V4L2_CTRL_TYPE_MENU, - .minimum = V4L2_MPEG_VIDEO_H264_ENTROPY_MODE_CAVLC, - .maximum = V4L2_MPEG_VIDEO_H264_ENTROPY_MODE_CABAC, - .default_value = V4L2_MPEG_VIDEO_H264_ENTROPY_MODE_CAVLC, + .minimum = V4L2_CODEC_VIDEO_H264_ENTROPY_MODE_CAVLC, + .maximum = V4L2_CODEC_VIDEO_H264_ENTROPY_MODE_CABAC, + .default_value = V4L2_CODEC_VIDEO_H264_ENTROPY_MODE_CAVLC, .menu_skip_mask = 0, }, { - .id = V4L2_CID_MPEG_MFC51_VIDEO_H264_NUM_REF_PIC_FOR_P, + .id = V4L2_CID_CODEC_MFC51_VIDEO_H264_NUM_REF_PIC_FOR_P, .type = V4L2_CTRL_TYPE_INTEGER, .name = "The Number of Ref. Pic for P", .minimum = 1, @@ -354,7 +354,7 @@ static struct mfc_control controls[] = { .default_value = 1, }, { - .id = V4L2_CID_MPEG_VIDEO_H264_8X8_TRANSFORM, + .id = V4L2_CID_CODEC_VIDEO_H264_8X8_TRANSFORM, .type = V4L2_CTRL_TYPE_BOOLEAN, .minimum = 0, .maximum = 1, @@ -362,7 +362,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE, + .id = V4L2_CID_CODEC_VIDEO_MB_RC_ENABLE, .type = V4L2_CTRL_TYPE_BOOLEAN, .minimum = 0, .maximum = 1, @@ -370,7 +370,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_H264_I_FRAME_QP, + .id = V4L2_CID_CODEC_VIDEO_H264_I_FRAME_QP, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = 51, @@ -378,7 +378,7 @@ static struct mfc_control controls[] = { .default_value = 1, }, { - .id = V4L2_CID_MPEG_VIDEO_H264_MIN_QP, + .id = V4L2_CID_CODEC_VIDEO_H264_MIN_QP, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = 51, @@ -386,7 +386,7 @@ static struct mfc_control controls[] = { .default_value = 1, }, { - .id = V4L2_CID_MPEG_VIDEO_H264_MAX_QP, + .id = V4L2_CID_CODEC_VIDEO_H264_MAX_QP, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = 51, @@ -394,7 +394,7 @@ static struct mfc_control controls[] = { .default_value = 51, }, { - .id = V4L2_CID_MPEG_VIDEO_H264_P_FRAME_QP, + .id = V4L2_CID_CODEC_VIDEO_H264_P_FRAME_QP, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = 51, @@ -402,7 +402,7 @@ static struct mfc_control controls[] = { .default_value = 1, }, { - .id = V4L2_CID_MPEG_VIDEO_H264_B_FRAME_QP, + .id = V4L2_CID_CODEC_VIDEO_H264_B_FRAME_QP, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = 51, @@ -410,7 +410,7 @@ static struct mfc_control controls[] = { .default_value = 1, }, { - .id = V4L2_CID_MPEG_VIDEO_H263_I_FRAME_QP, + .id = V4L2_CID_CODEC_VIDEO_H263_I_FRAME_QP, .type = V4L2_CTRL_TYPE_INTEGER, .name = "H263 I-Frame QP value", .minimum = 1, @@ -419,7 +419,7 @@ static struct mfc_control controls[] = { .default_value = 1, }, { - .id = V4L2_CID_MPEG_VIDEO_H263_MIN_QP, + .id = V4L2_CID_CODEC_VIDEO_H263_MIN_QP, .type = V4L2_CTRL_TYPE_INTEGER, .name = "H263 Minimum QP value", .minimum = 1, @@ -428,7 +428,7 @@ static struct mfc_control controls[] = { .default_value = 1, }, { - .id = V4L2_CID_MPEG_VIDEO_H263_MAX_QP, + .id = V4L2_CID_CODEC_VIDEO_H263_MAX_QP, .type = V4L2_CTRL_TYPE_INTEGER, .name = "H263 Maximum QP value", .minimum = 1, @@ -437,7 +437,7 @@ static struct mfc_control controls[] = { .default_value = 31, }, { - .id = V4L2_CID_MPEG_VIDEO_H263_P_FRAME_QP, + .id = V4L2_CID_CODEC_VIDEO_H263_P_FRAME_QP, .type = V4L2_CTRL_TYPE_INTEGER, .name = "H263 P frame QP value", .minimum = 1, @@ -446,7 +446,7 @@ static struct mfc_control controls[] = { .default_value = 1, }, { - .id = V4L2_CID_MPEG_VIDEO_H263_B_FRAME_QP, + .id = V4L2_CID_CODEC_VIDEO_H263_B_FRAME_QP, .type = V4L2_CTRL_TYPE_INTEGER, .name = "H263 B frame QP value", .minimum = 1, @@ -455,7 +455,7 @@ static struct mfc_control controls[] = { .default_value = 1, }, { - .id = V4L2_CID_MPEG_VIDEO_MPEG4_I_FRAME_QP, + .id = V4L2_CID_CODEC_VIDEO_MPEG4_I_FRAME_QP, .type = V4L2_CTRL_TYPE_INTEGER, .name = "MPEG4 I-Frame QP value", .minimum = 1, @@ -464,7 +464,7 @@ static struct mfc_control controls[] = { .default_value = 1, }, { - .id = V4L2_CID_MPEG_VIDEO_MPEG4_MIN_QP, + .id = V4L2_CID_CODEC_VIDEO_MPEG4_MIN_QP, .type = V4L2_CTRL_TYPE_INTEGER, .name = "MPEG4 Minimum QP value", .minimum = 1, @@ -473,7 +473,7 @@ static struct mfc_control controls[] = { .default_value = 1, }, { - .id = V4L2_CID_MPEG_VIDEO_MPEG4_MAX_QP, + .id = V4L2_CID_CODEC_VIDEO_MPEG4_MAX_QP, .type = V4L2_CTRL_TYPE_INTEGER, .name = "MPEG4 Maximum QP value", .minimum = 0, @@ -482,7 +482,7 @@ static struct mfc_control controls[] = { .default_value = 51, }, { - .id = V4L2_CID_MPEG_VIDEO_MPEG4_P_FRAME_QP, + .id = V4L2_CID_CODEC_VIDEO_MPEG4_P_FRAME_QP, .type = V4L2_CTRL_TYPE_INTEGER, .name = "MPEG4 P frame QP value", .minimum = 1, @@ -491,7 +491,7 @@ static struct mfc_control controls[] = { .default_value = 1, }, { - .id = V4L2_CID_MPEG_VIDEO_MPEG4_B_FRAME_QP, + .id = V4L2_CID_CODEC_VIDEO_MPEG4_B_FRAME_QP, .type = V4L2_CTRL_TYPE_INTEGER, .name = "MPEG4 B frame QP value", .minimum = 1, @@ -500,7 +500,7 @@ static struct mfc_control controls[] = { .default_value = 1, }, { - .id = V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_DARK, + .id = V4L2_CID_CODEC_MFC51_VIDEO_H264_ADAPTIVE_RC_DARK, .type = V4L2_CTRL_TYPE_BOOLEAN, .name = "H264 Dark Reg Adaptive RC", .minimum = 0, @@ -509,7 +509,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_SMOOTH, + .id = V4L2_CID_CODEC_MFC51_VIDEO_H264_ADAPTIVE_RC_SMOOTH, .type = V4L2_CTRL_TYPE_BOOLEAN, .name = "H264 Smooth Reg Adaptive RC", .minimum = 0, @@ -518,7 +518,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_STATIC, + .id = V4L2_CID_CODEC_MFC51_VIDEO_H264_ADAPTIVE_RC_STATIC, .type = V4L2_CTRL_TYPE_BOOLEAN, .name = "H264 Static Reg Adaptive RC", .minimum = 0, @@ -527,7 +527,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_ACTIVITY, + .id = V4L2_CID_CODEC_MFC51_VIDEO_H264_ADAPTIVE_RC_ACTIVITY, .type = V4L2_CTRL_TYPE_BOOLEAN, .name = "H264 Activity Reg Adaptive RC", .minimum = 0, @@ -536,7 +536,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_H264_VUI_SAR_ENABLE, + .id = V4L2_CID_CODEC_VIDEO_H264_VUI_SAR_ENABLE, .type = V4L2_CTRL_TYPE_BOOLEAN, .minimum = 0, .maximum = 1, @@ -544,15 +544,15 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_H264_VUI_SAR_IDC, + .id = V4L2_CID_CODEC_VIDEO_H264_VUI_SAR_IDC, .type = V4L2_CTRL_TYPE_MENU, - .minimum = V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_UNSPECIFIED, - .maximum = V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_EXTENDED, - .default_value = V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_UNSPECIFIED, + .minimum = V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_UNSPECIFIED, + .maximum = V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_EXTENDED, + .default_value = V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_UNSPECIFIED, .menu_skip_mask = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_H264_VUI_EXT_SAR_WIDTH, + .id = V4L2_CID_CODEC_VIDEO_H264_VUI_EXT_SAR_WIDTH, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = (1 << 16) - 1, @@ -560,7 +560,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_H264_VUI_EXT_SAR_HEIGHT, + .id = V4L2_CID_CODEC_VIDEO_H264_VUI_EXT_SAR_HEIGHT, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = (1 << 16) - 1, @@ -568,7 +568,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_GOP_CLOSURE, + .id = V4L2_CID_CODEC_VIDEO_GOP_CLOSURE, .type = V4L2_CTRL_TYPE_BOOLEAN, .minimum = 0, .maximum = 1, @@ -576,7 +576,7 @@ static struct mfc_control controls[] = { .default_value = 1, }, { - .id = V4L2_CID_MPEG_VIDEO_H264_I_PERIOD, + .id = V4L2_CID_CODEC_VIDEO_H264_I_PERIOD, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = (1 << 16) - 1, @@ -584,15 +584,15 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_MPEG4_PROFILE, + .id = V4L2_CID_CODEC_VIDEO_MPEG4_PROFILE, .type = V4L2_CTRL_TYPE_MENU, - .minimum = V4L2_MPEG_VIDEO_MPEG4_PROFILE_SIMPLE, - .maximum = V4L2_MPEG_VIDEO_MPEG4_PROFILE_ADVANCED_SIMPLE, - .default_value = V4L2_MPEG_VIDEO_MPEG4_PROFILE_SIMPLE, + .minimum = V4L2_CODEC_VIDEO_MPEG4_PROFILE_SIMPLE, + .maximum = V4L2_CODEC_VIDEO_MPEG4_PROFILE_ADVANCED_SIMPLE, + .default_value = V4L2_CODEC_VIDEO_MPEG4_PROFILE_SIMPLE, .menu_skip_mask = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_MPEG4_QPEL, + .id = V4L2_CID_CODEC_VIDEO_MPEG4_QPEL, .type = V4L2_CTRL_TYPE_BOOLEAN, .minimum = 0, .maximum = 1, @@ -600,14 +600,14 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_VPX_NUM_PARTITIONS, + .id = V4L2_CID_CODEC_VIDEO_VPX_NUM_PARTITIONS, .type = V4L2_CTRL_TYPE_INTEGER_MENU, - .maximum = V4L2_CID_MPEG_VIDEO_VPX_8_PARTITIONS, - .default_value = V4L2_CID_MPEG_VIDEO_VPX_1_PARTITION, + .maximum = V4L2_CID_CODEC_VIDEO_VPX_8_PARTITIONS, + .default_value = V4L2_CID_CODEC_VIDEO_VPX_1_PARTITION, .menu_skip_mask = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_VPX_IMD_DISABLE_4X4, + .id = V4L2_CID_CODEC_VIDEO_VPX_IMD_DISABLE_4X4, .type = V4L2_CTRL_TYPE_BOOLEAN, .minimum = 0, .maximum = 1, @@ -615,14 +615,14 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_VPX_NUM_REF_FRAMES, + .id = V4L2_CID_CODEC_VIDEO_VPX_NUM_REF_FRAMES, .type = V4L2_CTRL_TYPE_INTEGER_MENU, - .maximum = V4L2_CID_MPEG_VIDEO_VPX_2_REF_FRAME, - .default_value = V4L2_CID_MPEG_VIDEO_VPX_1_REF_FRAME, + .maximum = V4L2_CID_CODEC_VIDEO_VPX_2_REF_FRAME, + .default_value = V4L2_CID_CODEC_VIDEO_VPX_1_REF_FRAME, .menu_skip_mask = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_VPX_FILTER_LEVEL, + .id = V4L2_CID_CODEC_VIDEO_VPX_FILTER_LEVEL, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = 63, @@ -630,7 +630,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_VPX_FILTER_SHARPNESS, + .id = V4L2_CID_CODEC_VIDEO_VPX_FILTER_SHARPNESS, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = 7, @@ -638,7 +638,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_REF_PERIOD, + .id = V4L2_CID_CODEC_VIDEO_VPX_GOLDEN_FRAME_REF_PERIOD, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = (1 << 16) - 1, @@ -646,15 +646,15 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_SEL, + .id = V4L2_CID_CODEC_VIDEO_VPX_GOLDEN_FRAME_SEL, .type = V4L2_CTRL_TYPE_MENU, - .minimum = V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_USE_PREV, - .maximum = V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_USE_REF_PERIOD, - .default_value = V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_USE_PREV, + .minimum = V4L2_CID_CODEC_VIDEO_VPX_GOLDEN_FRAME_USE_PREV, + .maximum = V4L2_CID_CODEC_VIDEO_VPX_GOLDEN_FRAME_USE_REF_PERIOD, + .default_value = V4L2_CID_CODEC_VIDEO_VPX_GOLDEN_FRAME_USE_PREV, .menu_skip_mask = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_VPX_MAX_QP, + .id = V4L2_CID_CODEC_VIDEO_VPX_MAX_QP, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = 127, @@ -662,7 +662,7 @@ static struct mfc_control controls[] = { .default_value = 127, }, { - .id = V4L2_CID_MPEG_VIDEO_VPX_MIN_QP, + .id = V4L2_CID_CODEC_VIDEO_VPX_MIN_QP, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = 11, @@ -670,7 +670,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_VPX_I_FRAME_QP, + .id = V4L2_CID_CODEC_VIDEO_VPX_I_FRAME_QP, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = 127, @@ -678,7 +678,7 @@ static struct mfc_control controls[] = { .default_value = 10, }, { - .id = V4L2_CID_MPEG_VIDEO_VPX_P_FRAME_QP, + .id = V4L2_CID_CODEC_VIDEO_VPX_P_FRAME_QP, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = 127, @@ -686,15 +686,15 @@ static struct mfc_control controls[] = { .default_value = 10, }, { - .id = V4L2_CID_MPEG_VIDEO_VP8_PROFILE, + .id = V4L2_CID_CODEC_VIDEO_VP8_PROFILE, .type = V4L2_CTRL_TYPE_MENU, - .minimum = V4L2_MPEG_VIDEO_VP8_PROFILE_0, - .maximum = V4L2_MPEG_VIDEO_VP8_PROFILE_3, - .default_value = V4L2_MPEG_VIDEO_VP8_PROFILE_0, + .minimum = V4L2_CODEC_VIDEO_VP8_PROFILE_0, + .maximum = V4L2_CODEC_VIDEO_VP8_PROFILE_3, + .default_value = V4L2_CODEC_VIDEO_VP8_PROFILE_0, .menu_skip_mask = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_QP, + .id = V4L2_CID_CODEC_VIDEO_HEVC_I_FRAME_QP, .type = V4L2_CTRL_TYPE_INTEGER, .name = "HEVC I Frame QP Value", .minimum = 0, @@ -703,7 +703,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_QP, + .id = V4L2_CID_CODEC_VIDEO_HEVC_P_FRAME_QP, .type = V4L2_CTRL_TYPE_INTEGER, .name = "HEVC P Frame QP Value", .minimum = 0, @@ -712,7 +712,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_QP, + .id = V4L2_CID_CODEC_VIDEO_HEVC_B_FRAME_QP, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = 51, @@ -720,7 +720,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP, + .id = V4L2_CID_CODEC_VIDEO_HEVC_MIN_QP, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = 51, @@ -728,7 +728,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP, + .id = V4L2_CID_CODEC_VIDEO_HEVC_MAX_QP, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = 51, @@ -736,31 +736,31 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_PROFILE, + .id = V4L2_CID_CODEC_VIDEO_HEVC_PROFILE, .type = V4L2_CTRL_TYPE_MENU, - .minimum = V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN, - .maximum = V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN_STILL_PICTURE, + .minimum = V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN, + .maximum = V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN_STILL_PICTURE, .step = 1, - .default_value = V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN, + .default_value = V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_LEVEL, + .id = V4L2_CID_CODEC_VIDEO_HEVC_LEVEL, .type = V4L2_CTRL_TYPE_MENU, - .minimum = V4L2_MPEG_VIDEO_HEVC_LEVEL_1, - .maximum = V4L2_MPEG_VIDEO_HEVC_LEVEL_6_2, + .minimum = V4L2_CODEC_VIDEO_HEVC_LEVEL_1, + .maximum = V4L2_CODEC_VIDEO_HEVC_LEVEL_6_2, .step = 1, - .default_value = V4L2_MPEG_VIDEO_HEVC_LEVEL_1, + .default_value = V4L2_CODEC_VIDEO_HEVC_LEVEL_1, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_TIER, + .id = V4L2_CID_CODEC_VIDEO_HEVC_TIER, .type = V4L2_CTRL_TYPE_MENU, - .minimum = V4L2_MPEG_VIDEO_HEVC_TIER_MAIN, - .maximum = V4L2_MPEG_VIDEO_HEVC_TIER_HIGH, + .minimum = V4L2_CODEC_VIDEO_HEVC_TIER_MAIN, + .maximum = V4L2_CODEC_VIDEO_HEVC_TIER_HIGH, .step = 1, - .default_value = V4L2_MPEG_VIDEO_HEVC_TIER_MAIN, + .default_value = V4L2_CODEC_VIDEO_HEVC_TIER_MAIN, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_FRAME_RATE_RESOLUTION, + .id = V4L2_CID_CODEC_VIDEO_HEVC_FRAME_RATE_RESOLUTION, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 1, .maximum = (1 << 16) - 1, @@ -768,7 +768,7 @@ static struct mfc_control controls[] = { .default_value = 1, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_MAX_PARTITION_DEPTH, + .id = V4L2_CID_CODEC_VIDEO_HEVC_MAX_PARTITION_DEPTH, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = 1, @@ -776,7 +776,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_REF_NUMBER_FOR_PFRAMES, + .id = V4L2_CID_CODEC_VIDEO_REF_NUMBER_FOR_PFRAMES, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 1, .maximum = 2, @@ -784,15 +784,15 @@ static struct mfc_control controls[] = { .default_value = 1, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_REFRESH_TYPE, + .id = V4L2_CID_CODEC_VIDEO_HEVC_REFRESH_TYPE, .type = V4L2_CTRL_TYPE_MENU, - .minimum = V4L2_MPEG_VIDEO_HEVC_REFRESH_NONE, - .maximum = V4L2_MPEG_VIDEO_HEVC_REFRESH_IDR, + .minimum = V4L2_CODEC_VIDEO_HEVC_REFRESH_NONE, + .maximum = V4L2_CODEC_VIDEO_HEVC_REFRESH_IDR, .step = 1, - .default_value = V4L2_MPEG_VIDEO_HEVC_REFRESH_NONE, + .default_value = V4L2_CODEC_VIDEO_HEVC_REFRESH_NONE, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_CONST_INTRA_PRED, + .id = V4L2_CID_CODEC_VIDEO_HEVC_CONST_INTRA_PRED, .type = V4L2_CTRL_TYPE_BOOLEAN, .minimum = 0, .maximum = 1, @@ -800,7 +800,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_LOSSLESS_CU, + .id = V4L2_CID_CODEC_VIDEO_HEVC_LOSSLESS_CU, .type = V4L2_CTRL_TYPE_BOOLEAN, .minimum = 0, .maximum = 1, @@ -808,7 +808,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_WAVEFRONT, + .id = V4L2_CID_CODEC_VIDEO_HEVC_WAVEFRONT, .type = V4L2_CTRL_TYPE_BOOLEAN, .minimum = 0, .maximum = 1, @@ -816,15 +816,15 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE, + .id = V4L2_CID_CODEC_VIDEO_HEVC_LOOP_FILTER_MODE, .type = V4L2_CTRL_TYPE_MENU, - .minimum = V4L2_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE_DISABLED, - .maximum = V4L2_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY, + .minimum = V4L2_CODEC_VIDEO_HEVC_LOOP_FILTER_MODE_DISABLED, + .maximum = V4L2_CODEC_VIDEO_HEVC_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY, .step = 1, - .default_value = V4L2_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE_DISABLED, + .default_value = V4L2_CODEC_VIDEO_HEVC_LOOP_FILTER_MODE_DISABLED, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_HIER_QP, + .id = V4L2_CID_CODEC_VIDEO_HEVC_HIER_QP, .type = V4L2_CTRL_TYPE_BOOLEAN, .minimum = 0, .maximum = 1, @@ -832,15 +832,15 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_TYPE, + .id = V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_TYPE, .type = V4L2_CTRL_TYPE_MENU, - .minimum = V4L2_MPEG_VIDEO_HEVC_HIERARCHICAL_CODING_B, - .maximum = V4L2_MPEG_VIDEO_HEVC_HIERARCHICAL_CODING_P, + .minimum = V4L2_CODEC_VIDEO_HEVC_HIERARCHICAL_CODING_B, + .maximum = V4L2_CODEC_VIDEO_HEVC_HIERARCHICAL_CODING_P, .step = 1, - .default_value = V4L2_MPEG_VIDEO_HEVC_HIERARCHICAL_CODING_B, + .default_value = V4L2_CODEC_VIDEO_HEVC_HIERARCHICAL_CODING_B, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_LAYER, + .id = V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_LAYER, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = 6, @@ -848,7 +848,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L0_QP, + .id = V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L0_QP, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = 51, @@ -856,7 +856,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L1_QP, + .id = V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L1_QP, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = 51, @@ -864,7 +864,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L2_QP, + .id = V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L2_QP, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = 51, @@ -872,7 +872,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L3_QP, + .id = V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L3_QP, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = 51, @@ -880,7 +880,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L4_QP, + .id = V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L4_QP, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = 51, @@ -888,7 +888,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L5_QP, + .id = V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L5_QP, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = 51, @@ -896,7 +896,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L6_QP, + .id = V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L6_QP, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = 51, @@ -904,7 +904,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L0_BR, + .id = V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L0_BR, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = INT_MIN, .maximum = INT_MAX, @@ -912,7 +912,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L1_BR, + .id = V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L1_BR, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = INT_MIN, .maximum = INT_MAX, @@ -920,7 +920,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L2_BR, + .id = V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L2_BR, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = INT_MIN, .maximum = INT_MAX, @@ -928,7 +928,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L3_BR, + .id = V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L3_BR, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = INT_MIN, .maximum = INT_MAX, @@ -936,7 +936,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L4_BR, + .id = V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L4_BR, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = INT_MIN, .maximum = INT_MAX, @@ -944,7 +944,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L5_BR, + .id = V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L5_BR, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = INT_MIN, .maximum = INT_MAX, @@ -952,7 +952,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L6_BR, + .id = V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L6_BR, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = INT_MIN, .maximum = INT_MAX, @@ -960,7 +960,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_GENERAL_PB, + .id = V4L2_CID_CODEC_VIDEO_HEVC_GENERAL_PB, .type = V4L2_CTRL_TYPE_BOOLEAN, .minimum = 0, .maximum = 1, @@ -968,7 +968,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_TEMPORAL_ID, + .id = V4L2_CID_CODEC_VIDEO_HEVC_TEMPORAL_ID, .type = V4L2_CTRL_TYPE_BOOLEAN, .minimum = 0, .maximum = 1, @@ -976,7 +976,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_STRONG_SMOOTHING, + .id = V4L2_CID_CODEC_VIDEO_HEVC_STRONG_SMOOTHING, .type = V4L2_CTRL_TYPE_BOOLEAN, .minimum = 0, .maximum = 1, @@ -984,7 +984,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_INTRA_PU_SPLIT, + .id = V4L2_CID_CODEC_VIDEO_HEVC_INTRA_PU_SPLIT, .type = V4L2_CTRL_TYPE_BOOLEAN, .minimum = 0, .maximum = 1, @@ -992,7 +992,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_TMV_PREDICTION, + .id = V4L2_CID_CODEC_VIDEO_HEVC_TMV_PREDICTION, .type = V4L2_CTRL_TYPE_BOOLEAN, .minimum = 0, .maximum = 1, @@ -1000,7 +1000,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_MAX_NUM_MERGE_MV_MINUS1, + .id = V4L2_CID_CODEC_VIDEO_HEVC_MAX_NUM_MERGE_MV_MINUS1, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = 4, @@ -1008,7 +1008,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_WITHOUT_STARTCODE, + .id = V4L2_CID_CODEC_VIDEO_HEVC_WITHOUT_STARTCODE, .type = V4L2_CTRL_TYPE_BOOLEAN, .minimum = 0, .maximum = 1, @@ -1016,7 +1016,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_REFRESH_PERIOD, + .id = V4L2_CID_CODEC_VIDEO_HEVC_REFRESH_PERIOD, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = (1 << 16) - 1, @@ -1024,7 +1024,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_LF_BETA_OFFSET_DIV2, + .id = V4L2_CID_CODEC_VIDEO_HEVC_LF_BETA_OFFSET_DIV2, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = -6, .maximum = 6, @@ -1032,7 +1032,7 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_LF_TC_OFFSET_DIV2, + .id = V4L2_CID_CODEC_VIDEO_HEVC_LF_TC_OFFSET_DIV2, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = -6, .maximum = 6, @@ -1040,15 +1040,15 @@ static struct mfc_control controls[] = { .default_value = 0, }, { - .id = V4L2_CID_MPEG_VIDEO_HEVC_SIZE_OF_LENGTH_FIELD, + .id = V4L2_CID_CODEC_VIDEO_HEVC_SIZE_OF_LENGTH_FIELD, .type = V4L2_CTRL_TYPE_MENU, - .minimum = V4L2_MPEG_VIDEO_HEVC_SIZE_0, - .maximum = V4L2_MPEG_VIDEO_HEVC_SIZE_4, + .minimum = V4L2_CODEC_VIDEO_HEVC_SIZE_0, + .maximum = V4L2_CODEC_VIDEO_HEVC_SIZE_4, .step = 1, - .default_value = V4L2_MPEG_VIDEO_HEVC_SIZE_0, + .default_value = V4L2_CODEC_VIDEO_HEVC_SIZE_0, }, { - .id = V4L2_CID_MPEG_VIDEO_PREPEND_SPSPPS_TO_IDR, + .id = V4L2_CID_CODEC_VIDEO_PREPEND_SPSPPS_TO_IDR, .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 0, .maximum = 1, @@ -1083,9 +1083,9 @@ static const char * const *mfc51_get_menu(u32 id) NULL, }; switch (id) { - case V4L2_CID_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE: + case V4L2_CID_CODEC_MFC51_VIDEO_FRAME_SKIP_MODE: return mfc51_video_frame_skip; - case V4L2_CID_MPEG_MFC51_VIDEO_FORCE_FRAME_TYPE: + case V4L2_CID_CODEC_MFC51_VIDEO_FORCE_FRAME_TYPE: return mfc51_video_force_frame; } return NULL; @@ -1152,7 +1152,7 @@ static int enc_post_seq_start(struct s5p_mfc_ctx *ctx) struct s5p_mfc_buf *dst_mb; unsigned int enc_pb_count; - if (p->seq_hdr_mode == V4L2_MPEG_VIDEO_HEADER_MODE_SEPARATE) { + if (p->seq_hdr_mode == V4L2_CODEC_VIDEO_HEADER_MODE_SEPARATE) { if (!list_empty(&ctx->dst_queue)) { dst_mb = list_entry(ctx->dst_queue.next, struct s5p_mfc_buf, list); @@ -1677,103 +1677,103 @@ static int vidioc_streamoff(struct file *file, void *priv, return -EINVAL; } -static inline int h264_level(enum v4l2_mpeg_video_h264_level lvl) +static inline int h264_level(enum v4l2_codec_video_h264_level lvl) { - static unsigned int t[V4L2_MPEG_VIDEO_H264_LEVEL_4_0 + 1] = { - /* V4L2_MPEG_VIDEO_H264_LEVEL_1_0 */ 10, - /* V4L2_MPEG_VIDEO_H264_LEVEL_1B */ 9, - /* V4L2_MPEG_VIDEO_H264_LEVEL_1_1 */ 11, - /* V4L2_MPEG_VIDEO_H264_LEVEL_1_2 */ 12, - /* V4L2_MPEG_VIDEO_H264_LEVEL_1_3 */ 13, - /* V4L2_MPEG_VIDEO_H264_LEVEL_2_0 */ 20, - /* V4L2_MPEG_VIDEO_H264_LEVEL_2_1 */ 21, - /* V4L2_MPEG_VIDEO_H264_LEVEL_2_2 */ 22, - /* V4L2_MPEG_VIDEO_H264_LEVEL_3_0 */ 30, - /* V4L2_MPEG_VIDEO_H264_LEVEL_3_1 */ 31, - /* V4L2_MPEG_VIDEO_H264_LEVEL_3_2 */ 32, - /* V4L2_MPEG_VIDEO_H264_LEVEL_4_0 */ 40, + static unsigned int t[V4L2_CODEC_VIDEO_H264_LEVEL_4_0 + 1] = { + /* V4L2_CODEC_VIDEO_H264_LEVEL_1_0 */ 10, + /* V4L2_CODEC_VIDEO_H264_LEVEL_1B */ 9, + /* V4L2_CODEC_VIDEO_H264_LEVEL_1_1 */ 11, + /* V4L2_CODEC_VIDEO_H264_LEVEL_1_2 */ 12, + /* V4L2_CODEC_VIDEO_H264_LEVEL_1_3 */ 13, + /* V4L2_CODEC_VIDEO_H264_LEVEL_2_0 */ 20, + /* V4L2_CODEC_VIDEO_H264_LEVEL_2_1 */ 21, + /* V4L2_CODEC_VIDEO_H264_LEVEL_2_2 */ 22, + /* V4L2_CODEC_VIDEO_H264_LEVEL_3_0 */ 30, + /* V4L2_CODEC_VIDEO_H264_LEVEL_3_1 */ 31, + /* V4L2_CODEC_VIDEO_H264_LEVEL_3_2 */ 32, + /* V4L2_CODEC_VIDEO_H264_LEVEL_4_0 */ 40, }; return t[lvl]; } -static inline int mpeg4_level(enum v4l2_mpeg_video_mpeg4_level lvl) +static inline int mpeg4_level(enum v4l2_codec_video_mpeg4_level lvl) { - static unsigned int t[V4L2_MPEG_VIDEO_MPEG4_LEVEL_5 + 1] = { - /* V4L2_MPEG_VIDEO_MPEG4_LEVEL_0 */ 0, - /* V4L2_MPEG_VIDEO_MPEG4_LEVEL_0B */ 9, - /* V4L2_MPEG_VIDEO_MPEG4_LEVEL_1 */ 1, - /* V4L2_MPEG_VIDEO_MPEG4_LEVEL_2 */ 2, - /* V4L2_MPEG_VIDEO_MPEG4_LEVEL_3 */ 3, - /* V4L2_MPEG_VIDEO_MPEG4_LEVEL_3B */ 7, - /* V4L2_MPEG_VIDEO_MPEG4_LEVEL_4 */ 4, - /* V4L2_MPEG_VIDEO_MPEG4_LEVEL_5 */ 5, + static unsigned int t[V4L2_CODEC_VIDEO_MPEG4_LEVEL_5 + 1] = { + /* V4L2_CODEC_VIDEO_MPEG4_LEVEL_0 */ 0, + /* V4L2_CODEC_VIDEO_MPEG4_LEVEL_0B */ 9, + /* V4L2_CODEC_VIDEO_MPEG4_LEVEL_1 */ 1, + /* V4L2_CODEC_VIDEO_MPEG4_LEVEL_2 */ 2, + /* V4L2_CODEC_VIDEO_MPEG4_LEVEL_3 */ 3, + /* V4L2_CODEC_VIDEO_MPEG4_LEVEL_3B */ 7, + /* V4L2_CODEC_VIDEO_MPEG4_LEVEL_4 */ 4, + /* V4L2_CODEC_VIDEO_MPEG4_LEVEL_5 */ 5, }; return t[lvl]; } -static inline int hevc_level(enum v4l2_mpeg_video_hevc_level lvl) +static inline int hevc_level(enum v4l2_codec_video_hevc_level lvl) { static unsigned int t[] = { - /* V4L2_MPEG_VIDEO_HEVC_LEVEL_1 */ 10, - /* V4L2_MPEG_VIDEO_HEVC_LEVEL_2 */ 20, - /* V4L2_MPEG_VIDEO_HEVC_LEVEL_2_1 */ 21, - /* V4L2_MPEG_VIDEO_HEVC_LEVEL_3 */ 30, - /* V4L2_MPEG_VIDEO_HEVC_LEVEL_3_1 */ 31, - /* V4L2_MPEG_VIDEO_HEVC_LEVEL_4 */ 40, - /* V4L2_MPEG_VIDEO_HEVC_LEVEL_4_1 */ 41, - /* V4L2_MPEG_VIDEO_HEVC_LEVEL_5 */ 50, - /* V4L2_MPEG_VIDEO_HEVC_LEVEL_5_1 */ 51, - /* V4L2_MPEG_VIDEO_HEVC_LEVEL_5_2 */ 52, - /* V4L2_MPEG_VIDEO_HEVC_LEVEL_6 */ 60, - /* V4L2_MPEG_VIDEO_HEVC_LEVEL_6_1 */ 61, - /* V4L2_MPEG_VIDEO_HEVC_LEVEL_6_2 */ 62, + /* V4L2_CODEC_VIDEO_HEVC_LEVEL_1 */ 10, + /* V4L2_CODEC_VIDEO_HEVC_LEVEL_2 */ 20, + /* V4L2_CODEC_VIDEO_HEVC_LEVEL_2_1 */ 21, + /* V4L2_CODEC_VIDEO_HEVC_LEVEL_3 */ 30, + /* V4L2_CODEC_VIDEO_HEVC_LEVEL_3_1 */ 31, + /* V4L2_CODEC_VIDEO_HEVC_LEVEL_4 */ 40, + /* V4L2_CODEC_VIDEO_HEVC_LEVEL_4_1 */ 41, + /* V4L2_CODEC_VIDEO_HEVC_LEVEL_5 */ 50, + /* V4L2_CODEC_VIDEO_HEVC_LEVEL_5_1 */ 51, + /* V4L2_CODEC_VIDEO_HEVC_LEVEL_5_2 */ 52, + /* V4L2_CODEC_VIDEO_HEVC_LEVEL_6 */ 60, + /* V4L2_CODEC_VIDEO_HEVC_LEVEL_6_1 */ 61, + /* V4L2_CODEC_VIDEO_HEVC_LEVEL_6_2 */ 62, }; return t[lvl]; } -static inline int vui_sar_idc(enum v4l2_mpeg_video_h264_vui_sar_idc sar) +static inline int vui_sar_idc(enum v4l2_codec_video_h264_vui_sar_idc sar) { - static unsigned int t[V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_EXTENDED + 1] = { - /* V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_UNSPECIFIED */ 0, - /* V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_1x1 */ 1, - /* V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_12x11 */ 2, - /* V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_10x11 */ 3, - /* V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_16x11 */ 4, - /* V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_40x33 */ 5, - /* V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_24x11 */ 6, - /* V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_20x11 */ 7, - /* V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_32x11 */ 8, - /* V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_80x33 */ 9, - /* V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_18x11 */ 10, - /* V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_15x11 */ 11, - /* V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_64x33 */ 12, - /* V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_160x99 */ 13, - /* V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_4x3 */ 14, - /* V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_3x2 */ 15, - /* V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_2x1 */ 16, - /* V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_EXTENDED */ 255, + static unsigned int t[V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_EXTENDED + 1] = { + /* V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_UNSPECIFIED */ 0, + /* V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_1x1 */ 1, + /* V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_12x11 */ 2, + /* V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_10x11 */ 3, + /* V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_16x11 */ 4, + /* V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_40x33 */ 5, + /* V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_24x11 */ 6, + /* V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_20x11 */ 7, + /* V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_32x11 */ 8, + /* V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_80x33 */ 9, + /* V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_18x11 */ 10, + /* V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_15x11 */ 11, + /* V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_64x33 */ 12, + /* V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_160x99 */ 13, + /* V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_4x3 */ 14, + /* V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_3x2 */ 15, + /* V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_2x1 */ 16, + /* V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_EXTENDED */ 255, }; return t[sar]; } /* * Update range of all HEVC quantization parameter controls that depend on the - * V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP, V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP controls. + * V4L2_CID_CODEC_VIDEO_HEVC_MIN_QP, V4L2_CID_CODEC_VIDEO_HEVC_MAX_QP controls. */ static void __enc_update_hevc_qp_ctrls_range(struct s5p_mfc_ctx *ctx, int min, int max) { static const int __hevc_qp_ctrls[] = { - V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_QP, - V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_QP, - V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_QP, - V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L0_QP, - V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L1_QP, - V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L2_QP, - V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L3_QP, - V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L4_QP, - V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L5_QP, - V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L6_QP, + V4L2_CID_CODEC_VIDEO_HEVC_I_FRAME_QP, + V4L2_CID_CODEC_VIDEO_HEVC_P_FRAME_QP, + V4L2_CID_CODEC_VIDEO_HEVC_B_FRAME_QP, + V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L0_QP, + V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L1_QP, + V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L2_QP, + V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L3_QP, + V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L4_QP, + V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L5_QP, + V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L6_QP, }; struct v4l2_ctrl *ctrl = NULL; int i, j; @@ -1800,85 +1800,85 @@ static int s5p_mfc_enc_s_ctrl(struct v4l2_ctrl *ctrl) int ret = 0; switch (ctrl->id) { - case V4L2_CID_MPEG_VIDEO_GOP_SIZE: + case V4L2_CID_CODEC_VIDEO_GOP_SIZE: p->gop_size = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MODE: + case V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MODE: p->slice_mode = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MAX_MB: + case V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MAX_MB: p->slice_mb = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MAX_BYTES: + case V4L2_CID_CODEC_VIDEO_MULTI_SLICE_MAX_BYTES: p->slice_bit = ctrl->val * 8; break; - case V4L2_CID_MPEG_VIDEO_CYCLIC_INTRA_REFRESH_MB: + case V4L2_CID_CODEC_VIDEO_CYCLIC_INTRA_REFRESH_MB: p->intra_refresh_mb = ctrl->val; break; - case V4L2_CID_MPEG_MFC51_VIDEO_PADDING: + case V4L2_CID_CODEC_MFC51_VIDEO_PADDING: p->pad = ctrl->val; break; - case V4L2_CID_MPEG_MFC51_VIDEO_PADDING_YUV: + case V4L2_CID_CODEC_MFC51_VIDEO_PADDING_YUV: p->pad_luma = (ctrl->val >> 16) & 0xff; p->pad_cb = (ctrl->val >> 8) & 0xff; p->pad_cr = (ctrl->val >> 0) & 0xff; break; - case V4L2_CID_MPEG_VIDEO_FRAME_RC_ENABLE: + case V4L2_CID_CODEC_VIDEO_FRAME_RC_ENABLE: p->rc_frame = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_BITRATE: + case V4L2_CID_CODEC_VIDEO_BITRATE: p->rc_bitrate = ctrl->val; break; - case V4L2_CID_MPEG_MFC51_VIDEO_RC_REACTION_COEFF: + case V4L2_CID_CODEC_MFC51_VIDEO_RC_REACTION_COEFF: p->rc_reaction_coeff = ctrl->val; break; - case V4L2_CID_MPEG_MFC51_VIDEO_FORCE_FRAME_TYPE: + case V4L2_CID_CODEC_MFC51_VIDEO_FORCE_FRAME_TYPE: ctx->force_frame_type = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_FORCE_KEY_FRAME: + case V4L2_CID_CODEC_VIDEO_FORCE_KEY_FRAME: ctx->force_frame_type = - V4L2_MPEG_MFC51_VIDEO_FORCE_FRAME_TYPE_I_FRAME; + V4L2_CODEC_MFC51_VIDEO_FORCE_FRAME_TYPE_I_FRAME; break; - case V4L2_CID_MPEG_VIDEO_VBV_SIZE: + case V4L2_CID_CODEC_VIDEO_VBV_SIZE: p->vbv_size = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_MV_H_SEARCH_RANGE: + case V4L2_CID_CODEC_VIDEO_MV_H_SEARCH_RANGE: p->mv_h_range = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_MV_V_SEARCH_RANGE: + case V4L2_CID_CODEC_VIDEO_MV_V_SEARCH_RANGE: p->mv_v_range = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_CPB_SIZE: + case V4L2_CID_CODEC_VIDEO_H264_CPB_SIZE: p->codec.h264.cpb_size = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEADER_MODE: + case V4L2_CID_CODEC_VIDEO_HEADER_MODE: p->seq_hdr_mode = ctrl->val; break; - case V4L2_CID_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE: - case V4L2_CID_MPEG_VIDEO_FRAME_SKIP_MODE: + case V4L2_CID_CODEC_MFC51_VIDEO_FRAME_SKIP_MODE: + case V4L2_CID_CODEC_VIDEO_FRAME_SKIP_MODE: p->frame_skip_mode = ctrl->val; break; - case V4L2_CID_MPEG_MFC51_VIDEO_RC_FIXED_TARGET_BIT: + case V4L2_CID_CODEC_MFC51_VIDEO_RC_FIXED_TARGET_BIT: p->fixed_target_bit = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_B_FRAMES: + case V4L2_CID_CODEC_VIDEO_B_FRAMES: p->num_b_frame = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_PROFILE: + case V4L2_CID_CODEC_VIDEO_H264_PROFILE: switch (ctrl->val) { - case V4L2_MPEG_VIDEO_H264_PROFILE_MAIN: + case V4L2_CODEC_VIDEO_H264_PROFILE_MAIN: p->codec.h264.profile = S5P_FIMV_ENC_PROFILE_H264_MAIN; break; - case V4L2_MPEG_VIDEO_H264_PROFILE_HIGH: + case V4L2_CODEC_VIDEO_H264_PROFILE_HIGH: p->codec.h264.profile = S5P_FIMV_ENC_PROFILE_H264_HIGH; break; - case V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE: + case V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE: p->codec.h264.profile = S5P_FIMV_ENC_PROFILE_H264_BASELINE; break; - case V4L2_MPEG_VIDEO_H264_PROFILE_CONSTRAINED_BASELINE: + case V4L2_CODEC_VIDEO_H264_PROFILE_CONSTRAINED_BASELINE: if (IS_MFCV6_PLUS(dev)) p->codec.h264.profile = S5P_FIMV_ENC_PROFILE_H264_CONSTRAINED_BASELINE; @@ -1889,7 +1889,7 @@ static int s5p_mfc_enc_s_ctrl(struct v4l2_ctrl *ctrl) ret = -EINVAL; } break; - case V4L2_CID_MPEG_VIDEO_H264_LEVEL: + case V4L2_CID_CODEC_VIDEO_H264_LEVEL: p->codec.h264.level_v4l2 = ctrl->val; p->codec.h264.level = h264_level(ctrl->val); if (p->codec.h264.level < 0) { @@ -1897,7 +1897,7 @@ static int s5p_mfc_enc_s_ctrl(struct v4l2_ctrl *ctrl) ret = p->codec.h264.level; } break; - case V4L2_CID_MPEG_VIDEO_MPEG4_LEVEL: + case V4L2_CID_CODEC_VIDEO_MPEG4_LEVEL: p->codec.mpeg4.level_v4l2 = ctrl->val; p->codec.mpeg4.level = mpeg4_level(ctrl->val); if (p->codec.mpeg4.level < 0) { @@ -1905,99 +1905,99 @@ static int s5p_mfc_enc_s_ctrl(struct v4l2_ctrl *ctrl) ret = p->codec.mpeg4.level; } break; - case V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_MODE: + case V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_MODE: p->codec.h264.loop_filter_mode = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_ALPHA: + case V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_ALPHA: p->codec.h264.loop_filter_alpha = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_BETA: + case V4L2_CID_CODEC_VIDEO_H264_LOOP_FILTER_BETA: p->codec.h264.loop_filter_beta = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_ENTROPY_MODE: + case V4L2_CID_CODEC_VIDEO_H264_ENTROPY_MODE: p->codec.h264.entropy_mode = ctrl->val; break; - case V4L2_CID_MPEG_MFC51_VIDEO_H264_NUM_REF_PIC_FOR_P: + case V4L2_CID_CODEC_MFC51_VIDEO_H264_NUM_REF_PIC_FOR_P: p->codec.h264.num_ref_pic_4p = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_8X8_TRANSFORM: + case V4L2_CID_CODEC_VIDEO_H264_8X8_TRANSFORM: p->codec.h264._8x8_transform = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE: + case V4L2_CID_CODEC_VIDEO_MB_RC_ENABLE: p->rc_mb = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_I_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_H264_I_FRAME_QP: p->codec.h264.rc_frame_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_MIN_QP: + case V4L2_CID_CODEC_VIDEO_H264_MIN_QP: p->codec.h264.rc_min_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_MAX_QP: + case V4L2_CID_CODEC_VIDEO_H264_MAX_QP: p->codec.h264.rc_max_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_P_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_H264_P_FRAME_QP: p->codec.h264.rc_p_frame_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_B_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_H264_B_FRAME_QP: p->codec.h264.rc_b_frame_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_MPEG4_I_FRAME_QP: - case V4L2_CID_MPEG_VIDEO_H263_I_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_MPEG4_I_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_H263_I_FRAME_QP: p->codec.mpeg4.rc_frame_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_MPEG4_MIN_QP: - case V4L2_CID_MPEG_VIDEO_H263_MIN_QP: + case V4L2_CID_CODEC_VIDEO_MPEG4_MIN_QP: + case V4L2_CID_CODEC_VIDEO_H263_MIN_QP: p->codec.mpeg4.rc_min_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_MPEG4_MAX_QP: - case V4L2_CID_MPEG_VIDEO_H263_MAX_QP: + case V4L2_CID_CODEC_VIDEO_MPEG4_MAX_QP: + case V4L2_CID_CODEC_VIDEO_H263_MAX_QP: p->codec.mpeg4.rc_max_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_MPEG4_P_FRAME_QP: - case V4L2_CID_MPEG_VIDEO_H263_P_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_MPEG4_P_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_H263_P_FRAME_QP: p->codec.mpeg4.rc_p_frame_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_MPEG4_B_FRAME_QP: - case V4L2_CID_MPEG_VIDEO_H263_B_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_MPEG4_B_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_H263_B_FRAME_QP: p->codec.mpeg4.rc_b_frame_qp = ctrl->val; break; - case V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_DARK: + case V4L2_CID_CODEC_MFC51_VIDEO_H264_ADAPTIVE_RC_DARK: p->codec.h264.rc_mb_dark = ctrl->val; break; - case V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_SMOOTH: + case V4L2_CID_CODEC_MFC51_VIDEO_H264_ADAPTIVE_RC_SMOOTH: p->codec.h264.rc_mb_smooth = ctrl->val; break; - case V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_STATIC: + case V4L2_CID_CODEC_MFC51_VIDEO_H264_ADAPTIVE_RC_STATIC: p->codec.h264.rc_mb_static = ctrl->val; break; - case V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_ACTIVITY: + case V4L2_CID_CODEC_MFC51_VIDEO_H264_ADAPTIVE_RC_ACTIVITY: p->codec.h264.rc_mb_activity = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_VUI_SAR_ENABLE: + case V4L2_CID_CODEC_VIDEO_H264_VUI_SAR_ENABLE: p->codec.h264.vui_sar = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_VUI_SAR_IDC: + case V4L2_CID_CODEC_VIDEO_H264_VUI_SAR_IDC: p->codec.h264.vui_sar_idc = vui_sar_idc(ctrl->val); break; - case V4L2_CID_MPEG_VIDEO_H264_VUI_EXT_SAR_WIDTH: + case V4L2_CID_CODEC_VIDEO_H264_VUI_EXT_SAR_WIDTH: p->codec.h264.vui_ext_sar_width = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_VUI_EXT_SAR_HEIGHT: + case V4L2_CID_CODEC_VIDEO_H264_VUI_EXT_SAR_HEIGHT: p->codec.h264.vui_ext_sar_height = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_GOP_CLOSURE: + case V4L2_CID_CODEC_VIDEO_GOP_CLOSURE: p->codec.h264.open_gop = !ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_I_PERIOD: + case V4L2_CID_CODEC_VIDEO_H264_I_PERIOD: p->codec.h264.open_gop_size = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_MPEG4_PROFILE: + case V4L2_CID_CODEC_VIDEO_MPEG4_PROFILE: switch (ctrl->val) { - case V4L2_MPEG_VIDEO_MPEG4_PROFILE_SIMPLE: + case V4L2_CODEC_VIDEO_MPEG4_PROFILE_SIMPLE: p->codec.mpeg4.profile = S5P_FIMV_ENC_PROFILE_MPEG4_SIMPLE; break; - case V4L2_MPEG_VIDEO_MPEG4_PROFILE_ADVANCED_SIMPLE: + case V4L2_CODEC_VIDEO_MPEG4_PROFILE_ADVANCED_SIMPLE: p->codec.mpeg4.profile = S5P_FIMV_ENC_PROFILE_MPEG4_ADVANCED_SIMPLE; break; @@ -2005,194 +2005,194 @@ static int s5p_mfc_enc_s_ctrl(struct v4l2_ctrl *ctrl) ret = -EINVAL; } break; - case V4L2_CID_MPEG_VIDEO_MPEG4_QPEL: + case V4L2_CID_CODEC_VIDEO_MPEG4_QPEL: p->codec.mpeg4.quarter_pixel = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_VPX_NUM_PARTITIONS: + case V4L2_CID_CODEC_VIDEO_VPX_NUM_PARTITIONS: p->codec.vp8.num_partitions = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_VPX_IMD_DISABLE_4X4: + case V4L2_CID_CODEC_VIDEO_VPX_IMD_DISABLE_4X4: p->codec.vp8.imd_4x4 = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_VPX_NUM_REF_FRAMES: + case V4L2_CID_CODEC_VIDEO_VPX_NUM_REF_FRAMES: p->codec.vp8.num_ref = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_VPX_FILTER_LEVEL: + case V4L2_CID_CODEC_VIDEO_VPX_FILTER_LEVEL: p->codec.vp8.filter_level = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_VPX_FILTER_SHARPNESS: + case V4L2_CID_CODEC_VIDEO_VPX_FILTER_SHARPNESS: p->codec.vp8.filter_sharpness = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_REF_PERIOD: + case V4L2_CID_CODEC_VIDEO_VPX_GOLDEN_FRAME_REF_PERIOD: p->codec.vp8.golden_frame_ref_period = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_SEL: + case V4L2_CID_CODEC_VIDEO_VPX_GOLDEN_FRAME_SEL: p->codec.vp8.golden_frame_sel = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_VPX_MIN_QP: + case V4L2_CID_CODEC_VIDEO_VPX_MIN_QP: p->codec.vp8.rc_min_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_VPX_MAX_QP: + case V4L2_CID_CODEC_VIDEO_VPX_MAX_QP: p->codec.vp8.rc_max_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_VPX_I_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_VPX_I_FRAME_QP: p->codec.vp8.rc_frame_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_VPX_P_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_VPX_P_FRAME_QP: p->codec.vp8.rc_p_frame_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_VP8_PROFILE: + case V4L2_CID_CODEC_VIDEO_VP8_PROFILE: p->codec.vp8.profile = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_HEVC_I_FRAME_QP: p->codec.hevc.rc_frame_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_HEVC_P_FRAME_QP: p->codec.hevc.rc_p_frame_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_QP: + case V4L2_CID_CODEC_VIDEO_HEVC_B_FRAME_QP: p->codec.hevc.rc_b_frame_qp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_FRAME_RATE_RESOLUTION: + case V4L2_CID_CODEC_VIDEO_HEVC_FRAME_RATE_RESOLUTION: p->codec.hevc.rc_framerate = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP: + case V4L2_CID_CODEC_VIDEO_HEVC_MIN_QP: p->codec.hevc.rc_min_qp = ctrl->val; __enc_update_hevc_qp_ctrls_range(ctx, ctrl->val, p->codec.hevc.rc_max_qp); break; - case V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP: + case V4L2_CID_CODEC_VIDEO_HEVC_MAX_QP: p->codec.hevc.rc_max_qp = ctrl->val; __enc_update_hevc_qp_ctrls_range(ctx, p->codec.hevc.rc_min_qp, ctrl->val); break; - case V4L2_CID_MPEG_VIDEO_HEVC_LEVEL: + case V4L2_CID_CODEC_VIDEO_HEVC_LEVEL: p->codec.hevc.level_v4l2 = ctrl->val; p->codec.hevc.level = hevc_level(ctrl->val); break; - case V4L2_CID_MPEG_VIDEO_HEVC_PROFILE: + case V4L2_CID_CODEC_VIDEO_HEVC_PROFILE: switch (ctrl->val) { - case V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN: + case V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN: p->codec.hevc.profile = - V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN; + V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN; break; - case V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN_STILL_PICTURE: + case V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN_STILL_PICTURE: p->codec.hevc.profile = - V4L2_MPEG_VIDEO_HEVC_PROFILE_MAIN_STILL_PICTURE; + V4L2_CODEC_VIDEO_HEVC_PROFILE_MAIN_STILL_PICTURE; break; default: ret = -EINVAL; } break; - case V4L2_CID_MPEG_VIDEO_HEVC_TIER: + case V4L2_CID_CODEC_VIDEO_HEVC_TIER: p->codec.hevc.tier = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_MAX_PARTITION_DEPTH: + case V4L2_CID_CODEC_VIDEO_HEVC_MAX_PARTITION_DEPTH: p->codec.hevc.max_partition_depth = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_REF_NUMBER_FOR_PFRAMES: + case V4L2_CID_CODEC_VIDEO_REF_NUMBER_FOR_PFRAMES: p->codec.hevc.num_refs_for_p = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_REFRESH_TYPE: + case V4L2_CID_CODEC_VIDEO_HEVC_REFRESH_TYPE: p->codec.hevc.refreshtype = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_CONST_INTRA_PRED: + case V4L2_CID_CODEC_VIDEO_HEVC_CONST_INTRA_PRED: p->codec.hevc.const_intra_period_enable = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_LOSSLESS_CU: + case V4L2_CID_CODEC_VIDEO_HEVC_LOSSLESS_CU: p->codec.hevc.lossless_cu_enable = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_WAVEFRONT: + case V4L2_CID_CODEC_VIDEO_HEVC_WAVEFRONT: p->codec.hevc.wavefront_enable = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE: + case V4L2_CID_CODEC_VIDEO_HEVC_LOOP_FILTER_MODE: p->codec.hevc.loopfilter = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_QP: + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_QP: p->codec.hevc.hier_qp_enable = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_TYPE: + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_TYPE: p->codec.hevc.hier_qp_type = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_LAYER: + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_LAYER: p->codec.hevc.num_hier_layer = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L0_QP: + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L0_QP: p->codec.hevc.hier_qp_layer[0] = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L1_QP: + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L1_QP: p->codec.hevc.hier_qp_layer[1] = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L2_QP: + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L2_QP: p->codec.hevc.hier_qp_layer[2] = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L3_QP: + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L3_QP: p->codec.hevc.hier_qp_layer[3] = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L4_QP: + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L4_QP: p->codec.hevc.hier_qp_layer[4] = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L5_QP: + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L5_QP: p->codec.hevc.hier_qp_layer[5] = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L6_QP: + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L6_QP: p->codec.hevc.hier_qp_layer[6] = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L0_BR: + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L0_BR: p->codec.hevc.hier_bit_layer[0] = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L1_BR: + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L1_BR: p->codec.hevc.hier_bit_layer[1] = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L2_BR: + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L2_BR: p->codec.hevc.hier_bit_layer[2] = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L3_BR: + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L3_BR: p->codec.hevc.hier_bit_layer[3] = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L4_BR: + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L4_BR: p->codec.hevc.hier_bit_layer[4] = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L5_BR: + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L5_BR: p->codec.hevc.hier_bit_layer[5] = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L6_BR: + case V4L2_CID_CODEC_VIDEO_HEVC_HIER_CODING_L6_BR: p->codec.hevc.hier_bit_layer[6] = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_GENERAL_PB: + case V4L2_CID_CODEC_VIDEO_HEVC_GENERAL_PB: p->codec.hevc.general_pb_enable = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_TEMPORAL_ID: + case V4L2_CID_CODEC_VIDEO_HEVC_TEMPORAL_ID: p->codec.hevc.temporal_id_enable = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_STRONG_SMOOTHING: + case V4L2_CID_CODEC_VIDEO_HEVC_STRONG_SMOOTHING: p->codec.hevc.strong_intra_smooth = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_INTRA_PU_SPLIT: + case V4L2_CID_CODEC_VIDEO_HEVC_INTRA_PU_SPLIT: p->codec.hevc.intra_pu_split_disable = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_TMV_PREDICTION: + case V4L2_CID_CODEC_VIDEO_HEVC_TMV_PREDICTION: p->codec.hevc.tmv_prediction_disable = !ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_MAX_NUM_MERGE_MV_MINUS1: + case V4L2_CID_CODEC_VIDEO_HEVC_MAX_NUM_MERGE_MV_MINUS1: p->codec.hevc.max_num_merge_mv = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_WITHOUT_STARTCODE: + case V4L2_CID_CODEC_VIDEO_HEVC_WITHOUT_STARTCODE: p->codec.hevc.encoding_nostartcode_enable = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_REFRESH_PERIOD: + case V4L2_CID_CODEC_VIDEO_HEVC_REFRESH_PERIOD: p->codec.hevc.refreshperiod = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_LF_BETA_OFFSET_DIV2: + case V4L2_CID_CODEC_VIDEO_HEVC_LF_BETA_OFFSET_DIV2: p->codec.hevc.lf_beta_offset_div2 = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_LF_TC_OFFSET_DIV2: + case V4L2_CID_CODEC_VIDEO_HEVC_LF_TC_OFFSET_DIV2: p->codec.hevc.lf_tc_offset_div2 = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_HEVC_SIZE_OF_LENGTH_FIELD: + case V4L2_CID_CODEC_VIDEO_HEVC_SIZE_OF_LENGTH_FIELD: p->codec.hevc.size_of_length_field = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_PREPEND_SPSPPS_TO_IDR: + case V4L2_CID_CODEC_VIDEO_PREPEND_SPSPPS_TO_IDR: p->codec.hevc.prepend_sps_pps_to_idr = ctrl->val; break; default: diff --git a/drivers/media/platform/s5p-mfc/s5p_mfc_opr_v5.c b/drivers/media/platform/s5p-mfc/s5p_mfc_opr_v5.c index 49503c20d320..cecb8b669c76 100644 --- a/drivers/media/platform/s5p-mfc/s5p_mfc_opr_v5.c +++ b/drivers/media/platform/s5p-mfc/s5p_mfc_opr_v5.c @@ -692,9 +692,9 @@ static int s5p_mfc_set_enc_params(struct s5p_mfc_ctx *ctx) /* multi-slice control */ /* multi-slice MB number or bit size */ mfc_write(dev, p->slice_mode, S5P_FIMV_ENC_MSLICE_CTRL); - if (p->slice_mode == V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_MB) { + if (p->slice_mode == V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_MAX_MB) { mfc_write(dev, p->slice_mb, S5P_FIMV_ENC_MSLICE_MB); - } else if (p->slice_mode == V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_BYTES) { + } else if (p->slice_mode == V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_MAX_BYTES) { mfc_write(dev, p->slice_bit, S5P_FIMV_ENC_MSLICE_BIT); } else { mfc_write(dev, 0, S5P_FIMV_ENC_MSLICE_MB); @@ -804,7 +804,7 @@ static int s5p_mfc_set_enc_params_h264(struct s5p_mfc_ctx *ctx) } mfc_write(dev, reg, S5P_FIMV_ENC_BETA_OFF); /* entropy coding mode */ - if (p_264->entropy_mode == V4L2_MPEG_VIDEO_H264_ENTROPY_MODE_CABAC) + if (p_264->entropy_mode == V4L2_CODEC_VIDEO_H264_ENTROPY_MODE_CABAC) mfc_write(dev, 1, S5P_FIMV_ENC_H264_ENTROPY_MODE); else mfc_write(dev, 0, S5P_FIMV_ENC_H264_ENTROPY_MODE); @@ -903,7 +903,7 @@ static int s5p_mfc_set_enc_params_h264(struct s5p_mfc_ctx *ctx) shm = s5p_mfc_read_info_v5(ctx, EXT_ENC_CONTROL); /* vbv buffer size */ if (p->frame_skip_mode == - V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT) { + V4L2_CODEC_MFC51_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT) { shm &= ~(0xFFFF << 16); shm |= (p_264->cpb_size << 16); } @@ -982,7 +982,7 @@ static int s5p_mfc_set_enc_params_mpeg4(struct s5p_mfc_ctx *ctx) shm = s5p_mfc_read_info_v5(ctx, EXT_ENC_CONTROL); /* vbv buffer size */ if (p->frame_skip_mode == - V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT) { + V4L2_CODEC_MFC51_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT) { shm &= ~(0xFFFF << 16); shm |= (p->vbv_size << 16); } @@ -1031,7 +1031,7 @@ static int s5p_mfc_set_enc_params_h263(struct s5p_mfc_ctx *ctx) shm = s5p_mfc_read_info_v5(ctx, EXT_ENC_CONTROL); /* vbv buffer size */ if (p->frame_skip_mode == - V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT) { + V4L2_CODEC_MFC51_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT) { shm &= ~(0xFFFF << 16); shm |= (p->vbv_size << 16); } diff --git a/drivers/media/platform/s5p-mfc/s5p_mfc_opr_v6.c b/drivers/media/platform/s5p-mfc/s5p_mfc_opr_v6.c index a1453053e31a..1422a0b84d7d 100644 --- a/drivers/media/platform/s5p-mfc/s5p_mfc_opr_v6.c +++ b/drivers/media/platform/s5p-mfc/s5p_mfc_opr_v6.c @@ -733,10 +733,10 @@ static int s5p_mfc_set_slice_mode(struct s5p_mfc_ctx *ctx) /* multi-slice control */ /* multi-slice MB number or bit size */ writel(ctx->slice_mode, mfc_regs->e_mslice_mode); - if (ctx->slice_mode == V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_MB) { + if (ctx->slice_mode == V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_MAX_MB) { writel(ctx->slice_size.mb, mfc_regs->e_mslice_size_mb); } else if (ctx->slice_mode == - V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_BYTES) { + V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_MAX_BYTES) { writel(ctx->slice_size.bits, mfc_regs->e_mslice_size_bits); } else { writel(0x0, mfc_regs->e_mslice_size_mb); @@ -776,11 +776,11 @@ static int s5p_mfc_set_enc_params(struct s5p_mfc_ctx *ctx) /* multi-slice MB number or bit size */ ctx->slice_mode = p->slice_mode; reg = 0; - if (p->slice_mode == V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_MB) { + if (p->slice_mode == V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_MAX_MB) { reg |= (0x1 << 3); writel(reg, mfc_regs->e_enc_options); ctx->slice_size.mb = p->slice_mb; - } else if (p->slice_mode == V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_BYTES) { + } else if (p->slice_mode == V4L2_CODEC_VIDEO_MULTI_SLICE_MODE_MAX_BYTES) { reg |= (0x1 << 3); writel(reg, mfc_regs->e_enc_options); ctx->slice_size.bits = p->slice_bit; @@ -978,7 +978,7 @@ static int s5p_mfc_set_enc_params_h264(struct s5p_mfc_ctx *ctx) /* vbv buffer size */ if (p->frame_skip_mode == - V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT) { + V4L2_CODEC_MFC51_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT) { writel(p_h264->cpb_size & 0xFFFF, mfc_regs->e_vbv_buffer_size); @@ -1149,7 +1149,7 @@ static int s5p_mfc_set_enc_params_h264(struct s5p_mfc_ctx *ctx) if (p_h264->fmo) { switch (p_h264->fmo_map_type) { - case V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_INTERLEAVED_SLICES: + case V4L2_CODEC_VIDEO_H264_FMO_MAP_TYPE_INTERLEAVED_SLICES: if (p_h264->fmo_slice_grp > 4) p_h264->fmo_slice_grp = 4; for (i = 0; i < (p_h264->fmo_slice_grp & 0xF); i++) @@ -1157,12 +1157,12 @@ static int s5p_mfc_set_enc_params_h264(struct s5p_mfc_ctx *ctx) mfc_regs->e_h264_fmo_run_length_minus1_0 + i * 4); break; - case V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_SCATTERED_SLICES: + case V4L2_CODEC_VIDEO_H264_FMO_MAP_TYPE_SCATTERED_SLICES: if (p_h264->fmo_slice_grp > 4) p_h264->fmo_slice_grp = 4; break; - case V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_RASTER_SCAN: - case V4L2_MPEG_VIDEO_H264_FMO_MAP_TYPE_WIPE_SCAN: + case V4L2_CODEC_VIDEO_H264_FMO_MAP_TYPE_RASTER_SCAN: + case V4L2_CODEC_VIDEO_H264_FMO_MAP_TYPE_WIPE_SCAN: if (p_h264->fmo_slice_grp > 2) p_h264->fmo_slice_grp = 2; writel(p_h264->fmo_chg_dir & 0x1, @@ -1258,7 +1258,7 @@ static int s5p_mfc_set_enc_params_mpeg4(struct s5p_mfc_ctx *ctx) /* vbv buffer size */ if (p->frame_skip_mode == - V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT) { + V4L2_CODEC_MFC51_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT) { writel(p->vbv_size & 0xFFFF, mfc_regs->e_vbv_buffer_size); if (p->rc_frame) @@ -1332,7 +1332,7 @@ static int s5p_mfc_set_enc_params_h263(struct s5p_mfc_ctx *ctx) /* vbv buffer size */ if (p->frame_skip_mode == - V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT) { + V4L2_CODEC_MFC51_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT) { writel(p->vbv_size & 0xFFFF, mfc_regs->e_vbv_buffer_size); if (p->rc_frame) @@ -1404,7 +1404,7 @@ static int s5p_mfc_set_enc_params_vp8(struct s5p_mfc_ctx *ctx) /* vbv buffer size */ if (p->frame_skip_mode == - V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT) { + V4L2_CODEC_MFC51_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT) { writel(p->vbv_size & 0xFFFF, mfc_regs->e_vbv_buffer_size); if (p->rc_frame) @@ -1415,16 +1415,16 @@ static int s5p_mfc_set_enc_params_vp8(struct s5p_mfc_ctx *ctx) reg = 0; reg |= (p_vp8->imd_4x4 & 0x1) << 10; switch (p_vp8->num_partitions) { - case V4L2_CID_MPEG_VIDEO_VPX_1_PARTITION: + case V4L2_CID_CODEC_VIDEO_VPX_1_PARTITION: val = 0; break; - case V4L2_CID_MPEG_VIDEO_VPX_2_PARTITIONS: + case V4L2_CID_CODEC_VIDEO_VPX_2_PARTITIONS: val = 2; break; - case V4L2_CID_MPEG_VIDEO_VPX_4_PARTITIONS: + case V4L2_CID_CODEC_VIDEO_VPX_4_PARTITIONS: val = 4; break; - case V4L2_CID_MPEG_VIDEO_VPX_8_PARTITIONS: + case V4L2_CID_CODEC_VIDEO_VPX_8_PARTITIONS: val = 8; break; } @@ -1476,14 +1476,14 @@ static int s5p_mfc_set_enc_params_hevc(struct s5p_mfc_ctx *ctx) writel(reg, mfc_regs->e_picture_profile); switch (p_hevc->loopfilter) { - case V4L2_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE_DISABLED: + case V4L2_CODEC_VIDEO_HEVC_LOOP_FILTER_MODE_DISABLED: p_hevc->loopfilter_disable = 1; break; - case V4L2_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE_ENABLED: + case V4L2_CODEC_VIDEO_HEVC_LOOP_FILTER_MODE_ENABLED: p_hevc->loopfilter_disable = 0; p_hevc->loopfilter_across = 1; break; - case V4L2_MPEG_VIDEO_HEVC_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY: + case V4L2_CODEC_VIDEO_HEVC_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY: p_hevc->loopfilter_disable = 0; p_hevc->loopfilter_across = 0; break; diff --git a/drivers/media/platform/sti/hva/hva-debugfs.c b/drivers/media/platform/sti/hva/hva-debugfs.c index a86a07b6fbc7..9841eaaf22c0 100644 --- a/drivers/media/platform/sti/hva/hva-debugfs.c +++ b/drivers/media/platform/sti/hva/hva-debugfs.c @@ -41,8 +41,8 @@ static void format_ctx(struct seq_file *s, struct hva_ctx *ctx) stream->width, stream->height, stream->profile, stream->level); - bitrate_mode = V4L2_CID_MPEG_VIDEO_BITRATE_MODE; - aspect = V4L2_CID_MPEG_VIDEO_ASPECT; + bitrate_mode = V4L2_CID_CODEC_VIDEO_BITRATE_MODE; + aspect = V4L2_CID_CODEC_VIDEO_ASPECT; seq_puts(s, " |-[parameters]\n"); seq_printf(s, " | |- %s\n" " | |- bitrate=%d bps\n" @@ -56,9 +56,9 @@ static void format_ctx(struct seq_file *s, struct hva_ctx *ctx) ctrls->time_per_frame.denominator, ctrls->time_per_frame.numerator); - entropy = V4L2_CID_MPEG_VIDEO_H264_ENTROPY_MODE; - vui_sar = V4L2_CID_MPEG_VIDEO_H264_VUI_SAR_IDC; - sei_fp = V4L2_CID_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE; + entropy = V4L2_CID_CODEC_VIDEO_H264_ENTROPY_MODE; + vui_sar = V4L2_CID_CODEC_VIDEO_H264_VUI_SAR_IDC; + sei_fp = V4L2_CID_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE; if (stream->streamformat == V4L2_PIX_FMT_H264) { seq_printf(s, " | |- %s entropy mode\n" " | |- CPB size=%d kB\n" diff --git a/drivers/media/platform/sti/hva/hva-h264.c b/drivers/media/platform/sti/hva/hva-h264.c index 98cb00d2d868..8b910e660ffd 100644 --- a/drivers/media/platform/sti/hva/hva-h264.c +++ b/drivers/media/platform/sti/hva/hva-h264.c @@ -48,7 +48,7 @@ #define H264_FILLER_DATA_SIZE 6 struct h264_profile { - enum v4l2_mpeg_video_h264_level level; + enum v4l2_codec_video_h264_level level; u32 max_mb_per_seconds; u32 max_frame_size; u32 max_bitrate; @@ -57,22 +57,22 @@ struct h264_profile { }; static const struct h264_profile h264_infos_list[] = { - {V4L2_MPEG_VIDEO_H264_LEVEL_1_0, 1485, 99, 64, 175, 2}, - {V4L2_MPEG_VIDEO_H264_LEVEL_1B, 1485, 99, 128, 350, 2}, - {V4L2_MPEG_VIDEO_H264_LEVEL_1_1, 3000, 396, 192, 500, 2}, - {V4L2_MPEG_VIDEO_H264_LEVEL_1_2, 6000, 396, 384, 1000, 2}, - {V4L2_MPEG_VIDEO_H264_LEVEL_1_3, 11880, 396, 768, 2000, 2}, - {V4L2_MPEG_VIDEO_H264_LEVEL_2_0, 11880, 396, 2000, 2000, 2}, - {V4L2_MPEG_VIDEO_H264_LEVEL_2_1, 19800, 792, 4000, 4000, 2}, - {V4L2_MPEG_VIDEO_H264_LEVEL_2_2, 20250, 1620, 4000, 4000, 2}, - {V4L2_MPEG_VIDEO_H264_LEVEL_3_0, 40500, 1620, 10000, 10000, 2}, - {V4L2_MPEG_VIDEO_H264_LEVEL_3_1, 108000, 3600, 14000, 14000, 4}, - {V4L2_MPEG_VIDEO_H264_LEVEL_3_2, 216000, 5120, 20000, 20000, 4}, - {V4L2_MPEG_VIDEO_H264_LEVEL_4_0, 245760, 8192, 20000, 25000, 4}, - {V4L2_MPEG_VIDEO_H264_LEVEL_4_1, 245760, 8192, 50000, 62500, 2}, - {V4L2_MPEG_VIDEO_H264_LEVEL_4_2, 522240, 8704, 50000, 62500, 2}, - {V4L2_MPEG_VIDEO_H264_LEVEL_5_0, 589824, 22080, 135000, 135000, 2}, - {V4L2_MPEG_VIDEO_H264_LEVEL_5_1, 983040, 36864, 240000, 240000, 2} + {V4L2_CODEC_VIDEO_H264_LEVEL_1_0, 1485, 99, 64, 175, 2}, + {V4L2_CODEC_VIDEO_H264_LEVEL_1B, 1485, 99, 128, 350, 2}, + {V4L2_CODEC_VIDEO_H264_LEVEL_1_1, 3000, 396, 192, 500, 2}, + {V4L2_CODEC_VIDEO_H264_LEVEL_1_2, 6000, 396, 384, 1000, 2}, + {V4L2_CODEC_VIDEO_H264_LEVEL_1_3, 11880, 396, 768, 2000, 2}, + {V4L2_CODEC_VIDEO_H264_LEVEL_2_0, 11880, 396, 2000, 2000, 2}, + {V4L2_CODEC_VIDEO_H264_LEVEL_2_1, 19800, 792, 4000, 4000, 2}, + {V4L2_CODEC_VIDEO_H264_LEVEL_2_2, 20250, 1620, 4000, 4000, 2}, + {V4L2_CODEC_VIDEO_H264_LEVEL_3_0, 40500, 1620, 10000, 10000, 2}, + {V4L2_CODEC_VIDEO_H264_LEVEL_3_1, 108000, 3600, 14000, 14000, 4}, + {V4L2_CODEC_VIDEO_H264_LEVEL_3_2, 216000, 5120, 20000, 20000, 4}, + {V4L2_CODEC_VIDEO_H264_LEVEL_4_0, 245760, 8192, 20000, 25000, 4}, + {V4L2_CODEC_VIDEO_H264_LEVEL_4_1, 245760, 8192, 50000, 62500, 2}, + {V4L2_CODEC_VIDEO_H264_LEVEL_4_2, 522240, 8704, 50000, 62500, 2}, + {V4L2_CODEC_VIDEO_H264_LEVEL_5_0, 589824, 22080, 135000, 135000, 2}, + {V4L2_CODEC_VIDEO_H264_LEVEL_5_1, 983040, 36864, 240000, 240000, 2} }; enum hva_brc_type { @@ -427,7 +427,7 @@ static int hva_h264_fill_slice_header(struct hva_ctx *pctx, * The part of host is precomputed and available through this array. */ struct device *dev = ctx_to_dev(pctx); - int cabac = V4L2_MPEG_VIDEO_H264_ENTROPY_MODE_CABAC; + int cabac = V4L2_CODEC_VIDEO_H264_ENTROPY_MODE_CABAC; static const unsigned char slice_header[] = { 0x00, 0x00, 0x00, 0x01, 0x41, 0x34, 0x07, 0x00 @@ -598,10 +598,10 @@ static int hva_h264_prepare_task(struct hva_ctx *pctx, struct hva_h264_td *td = &task->td; struct hva_controls *ctrls = &pctx->ctrls; struct v4l2_fract *time_per_frame = &pctx->ctrls.time_per_frame; - int cavlc = V4L2_MPEG_VIDEO_H264_ENTROPY_MODE_CAVLC; + int cavlc = V4L2_CODEC_VIDEO_H264_ENTROPY_MODE_CAVLC; u32 frame_num = pctx->stream_num; u32 addr_esram = hva->esram_addr; - enum v4l2_mpeg_video_h264_level level; + enum v4l2_codec_video_h264_level level; dma_addr_t paddr = 0; u8 *slice_header_vaddr; u32 frame_width = frame->info.aligned_width; @@ -641,7 +641,7 @@ static int hva_h264_prepare_task(struct hva_ctx *pctx, /* useConstrainedIntraFlag set to false for better coding efficiency */ td->use_constrained_intra_flag = false; - td->brc_type = (ctrls->bitrate_mode == V4L2_MPEG_VIDEO_BITRATE_MODE_CBR) + td->brc_type = (ctrls->bitrate_mode == V4L2_CODEC_VIDEO_BITRATE_MODE_CBR) ? BRC_TYPE_CBR : BRC_TYPE_VBR; td->entropy_coding_mode = (ctrls->entropy_mode == cavlc) ? CAVLC : @@ -674,7 +674,7 @@ static int hva_h264_prepare_task(struct hva_ctx *pctx, } /* compute maximum bitrate depending on profile */ - if (ctrls->profile >= V4L2_MPEG_VIDEO_H264_PROFILE_HIGH) + if (ctrls->profile >= V4L2_CODEC_VIDEO_H264_PROFILE_HIGH) max_bitrate = h264_infos_list[level].max_bitrate * H264_FACTOR_HIGH; else @@ -693,7 +693,7 @@ static int hva_h264_prepare_task(struct hva_ctx *pctx, td->cpb_buffer_size = ctrls->cpb_size * 8000; /* compute maximum cpb buffer size depending on profile */ - if (ctrls->profile >= V4L2_MPEG_VIDEO_H264_PROFILE_HIGH) + if (ctrls->profile >= V4L2_CODEC_VIDEO_H264_PROFILE_HIGH) max_cpb_buffer_size = h264_infos_list[level].max_cpb_size * H264_FACTOR_HIGH; else @@ -712,7 +712,7 @@ static int hva_h264_prepare_task(struct hva_ctx *pctx, td->brc_no_skip = 0; /* initial delay */ - if ((ctrls->bitrate_mode == V4L2_MPEG_VIDEO_BITRATE_MODE_CBR) && + if ((ctrls->bitrate_mode == V4L2_CODEC_VIDEO_BITRATE_MODE_CBR) && td->bit_rate) td->delay = 1000 * (td->cpb_buffer_size / td->bit_rate); else diff --git a/drivers/media/platform/sti/hva/hva-v4l2.c b/drivers/media/platform/sti/hva/hva-v4l2.c index bb34d6997d99..2e24c8a8702a 100644 --- a/drivers/media/platform/sti/hva/hva-v4l2.c +++ b/drivers/media/platform/sti/hva/hva-v4l2.c @@ -623,57 +623,57 @@ static int hva_s_ctrl(struct v4l2_ctrl *ctrl) ctrl->id, ctrl->val); switch (ctrl->id) { - case V4L2_CID_MPEG_VIDEO_BITRATE_MODE: + case V4L2_CID_CODEC_VIDEO_BITRATE_MODE: ctx->ctrls.bitrate_mode = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_GOP_SIZE: + case V4L2_CID_CODEC_VIDEO_GOP_SIZE: ctx->ctrls.gop_size = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_BITRATE: + case V4L2_CID_CODEC_VIDEO_BITRATE: ctx->ctrls.bitrate = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_ASPECT: + case V4L2_CID_CODEC_VIDEO_ASPECT: ctx->ctrls.aspect = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_PROFILE: + case V4L2_CID_CODEC_VIDEO_H264_PROFILE: ctx->ctrls.profile = ctrl->val; snprintf(ctx->streaminfo.profile, sizeof(ctx->streaminfo.profile), "%s profile", v4l2_ctrl_get_menu(ctrl->id)[ctrl->val]); break; - case V4L2_CID_MPEG_VIDEO_H264_LEVEL: + case V4L2_CID_CODEC_VIDEO_H264_LEVEL: ctx->ctrls.level = ctrl->val; snprintf(ctx->streaminfo.level, sizeof(ctx->streaminfo.level), "level %s", v4l2_ctrl_get_menu(ctrl->id)[ctrl->val]); break; - case V4L2_CID_MPEG_VIDEO_H264_ENTROPY_MODE: + case V4L2_CID_CODEC_VIDEO_H264_ENTROPY_MODE: ctx->ctrls.entropy_mode = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_CPB_SIZE: + case V4L2_CID_CODEC_VIDEO_H264_CPB_SIZE: ctx->ctrls.cpb_size = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_8X8_TRANSFORM: + case V4L2_CID_CODEC_VIDEO_H264_8X8_TRANSFORM: ctx->ctrls.dct8x8 = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_MIN_QP: + case V4L2_CID_CODEC_VIDEO_H264_MIN_QP: ctx->ctrls.qpmin = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_MAX_QP: + case V4L2_CID_CODEC_VIDEO_H264_MAX_QP: ctx->ctrls.qpmax = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_VUI_SAR_ENABLE: + case V4L2_CID_CODEC_VIDEO_H264_VUI_SAR_ENABLE: ctx->ctrls.vui_sar = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_VUI_SAR_IDC: + case V4L2_CID_CODEC_VIDEO_H264_VUI_SAR_IDC: ctx->ctrls.vui_sar_idc = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_SEI_FRAME_PACKING: + case V4L2_CID_CODEC_VIDEO_H264_SEI_FRAME_PACKING: ctx->ctrls.sei_fp = ctrl->val; break; - case V4L2_CID_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE: + case V4L2_CID_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE: ctx->ctrls.sei_fp_type = ctrl->val; break; default: @@ -694,88 +694,88 @@ static int hva_ctrls_setup(struct hva_ctx *ctx) { struct device *dev = ctx_to_dev(ctx); u64 mask; - enum v4l2_mpeg_video_h264_sei_fp_arrangement_type sei_fp_type = - V4L2_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_TOP_BOTTOM; + enum v4l2_codec_video_h264_sei_fp_arrangement_type sei_fp_type = + V4L2_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE_TOP_BOTTOM; v4l2_ctrl_handler_init(&ctx->ctrl_handler, 15); v4l2_ctrl_new_std_menu(&ctx->ctrl_handler, &hva_ctrl_ops, - V4L2_CID_MPEG_VIDEO_BITRATE_MODE, - V4L2_MPEG_VIDEO_BITRATE_MODE_CBR, + V4L2_CID_CODEC_VIDEO_BITRATE_MODE, + V4L2_CODEC_VIDEO_BITRATE_MODE_CBR, 0, - V4L2_MPEG_VIDEO_BITRATE_MODE_CBR); + V4L2_CODEC_VIDEO_BITRATE_MODE_CBR); v4l2_ctrl_new_std(&ctx->ctrl_handler, &hva_ctrl_ops, - V4L2_CID_MPEG_VIDEO_GOP_SIZE, + V4L2_CID_CODEC_VIDEO_GOP_SIZE, 1, 60, 1, 16); v4l2_ctrl_new_std(&ctx->ctrl_handler, &hva_ctrl_ops, - V4L2_CID_MPEG_VIDEO_BITRATE, + V4L2_CID_CODEC_VIDEO_BITRATE, 1000, 60000000, 1000, 20000000); - mask = ~(1 << V4L2_MPEG_VIDEO_ASPECT_1x1); + mask = ~(1 << V4L2_CODEC_VIDEO_ASPECT_1x1); v4l2_ctrl_new_std_menu(&ctx->ctrl_handler, &hva_ctrl_ops, - V4L2_CID_MPEG_VIDEO_ASPECT, - V4L2_MPEG_VIDEO_ASPECT_1x1, + V4L2_CID_CODEC_VIDEO_ASPECT, + V4L2_CODEC_VIDEO_ASPECT_1x1, mask, - V4L2_MPEG_VIDEO_ASPECT_1x1); + V4L2_CODEC_VIDEO_ASPECT_1x1); - mask = ~((1 << V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE) | - (1 << V4L2_MPEG_VIDEO_H264_PROFILE_MAIN) | - (1 << V4L2_MPEG_VIDEO_H264_PROFILE_HIGH) | - (1 << V4L2_MPEG_VIDEO_H264_PROFILE_STEREO_HIGH)); + mask = ~((1 << V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE) | + (1 << V4L2_CODEC_VIDEO_H264_PROFILE_MAIN) | + (1 << V4L2_CODEC_VIDEO_H264_PROFILE_HIGH) | + (1 << V4L2_CODEC_VIDEO_H264_PROFILE_STEREO_HIGH)); v4l2_ctrl_new_std_menu(&ctx->ctrl_handler, &hva_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_PROFILE, - V4L2_MPEG_VIDEO_H264_PROFILE_STEREO_HIGH, + V4L2_CID_CODEC_VIDEO_H264_PROFILE, + V4L2_CODEC_VIDEO_H264_PROFILE_STEREO_HIGH, mask, - V4L2_MPEG_VIDEO_H264_PROFILE_HIGH); + V4L2_CODEC_VIDEO_H264_PROFILE_HIGH); v4l2_ctrl_new_std_menu(&ctx->ctrl_handler, &hva_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_LEVEL, - V4L2_MPEG_VIDEO_H264_LEVEL_4_2, + V4L2_CID_CODEC_VIDEO_H264_LEVEL, + V4L2_CODEC_VIDEO_H264_LEVEL_4_2, 0, - V4L2_MPEG_VIDEO_H264_LEVEL_4_0); + V4L2_CODEC_VIDEO_H264_LEVEL_4_0); v4l2_ctrl_new_std_menu(&ctx->ctrl_handler, &hva_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_ENTROPY_MODE, - V4L2_MPEG_VIDEO_H264_ENTROPY_MODE_CABAC, + V4L2_CID_CODEC_VIDEO_H264_ENTROPY_MODE, + V4L2_CODEC_VIDEO_H264_ENTROPY_MODE_CABAC, 0, - V4L2_MPEG_VIDEO_H264_ENTROPY_MODE_CAVLC); + V4L2_CODEC_VIDEO_H264_ENTROPY_MODE_CAVLC); v4l2_ctrl_new_std(&ctx->ctrl_handler, &hva_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_CPB_SIZE, + V4L2_CID_CODEC_VIDEO_H264_CPB_SIZE, 1, 10000, 1, 3000); v4l2_ctrl_new_std(&ctx->ctrl_handler, &hva_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_8X8_TRANSFORM, + V4L2_CID_CODEC_VIDEO_H264_8X8_TRANSFORM, 0, 1, 1, 0); v4l2_ctrl_new_std(&ctx->ctrl_handler, &hva_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_MIN_QP, + V4L2_CID_CODEC_VIDEO_H264_MIN_QP, 0, 51, 1, 5); v4l2_ctrl_new_std(&ctx->ctrl_handler, &hva_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_MAX_QP, + V4L2_CID_CODEC_VIDEO_H264_MAX_QP, 0, 51, 1, 51); v4l2_ctrl_new_std(&ctx->ctrl_handler, &hva_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_VUI_SAR_ENABLE, + V4L2_CID_CODEC_VIDEO_H264_VUI_SAR_ENABLE, 0, 1, 1, 1); - mask = ~(1 << V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_1x1); + mask = ~(1 << V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_1x1); v4l2_ctrl_new_std_menu(&ctx->ctrl_handler, &hva_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_VUI_SAR_IDC, - V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_1x1, + V4L2_CID_CODEC_VIDEO_H264_VUI_SAR_IDC, + V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_1x1, mask, - V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_1x1); + V4L2_CODEC_VIDEO_H264_VUI_SAR_IDC_1x1); v4l2_ctrl_new_std(&ctx->ctrl_handler, &hva_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_SEI_FRAME_PACKING, + V4L2_CID_CODEC_VIDEO_H264_SEI_FRAME_PACKING, 0, 1, 1, 0); mask = ~(1 << sei_fp_type); v4l2_ctrl_new_std_menu(&ctx->ctrl_handler, &hva_ctrl_ops, - V4L2_CID_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE, + V4L2_CID_CODEC_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE, sei_fp_type, mask, sei_fp_type); diff --git a/drivers/media/platform/sti/hva/hva.h b/drivers/media/platform/sti/hva/hva.h index 1226d60cc367..4ba1fb9b3660 100644 --- a/drivers/media/platform/sti/hva/hva.h +++ b/drivers/media/platform/sti/hva/hva.h @@ -85,21 +85,21 @@ struct hva_streaminfo { */ struct hva_controls { struct v4l2_fract time_per_frame; - enum v4l2_mpeg_video_bitrate_mode bitrate_mode; + enum v4l2_codec_video_bitrate_mode bitrate_mode; u32 gop_size; u32 bitrate; - enum v4l2_mpeg_video_aspect aspect; - enum v4l2_mpeg_video_h264_profile profile; - enum v4l2_mpeg_video_h264_level level; - enum v4l2_mpeg_video_h264_entropy_mode entropy_mode; + enum v4l2_codec_video_aspect aspect; + enum v4l2_codec_video_h264_profile profile; + enum v4l2_codec_video_h264_level level; + enum v4l2_codec_video_h264_entropy_mode entropy_mode; u32 cpb_size; bool dct8x8; u32 qpmin; u32 qpmax; bool vui_sar; - enum v4l2_mpeg_video_h264_vui_sar_idc vui_sar_idc; + enum v4l2_codec_video_h264_vui_sar_idc vui_sar_idc; bool sei_fp; - enum v4l2_mpeg_video_h264_sei_fp_arrangement_type sei_fp_type; + enum v4l2_codec_video_h264_sei_fp_arrangement_type sei_fp_type; }; /** From patchwork Sat Mar 13 14:43:18 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans Verkuil X-Patchwork-Id: 399850 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-18.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER, INCLUDES_PATCH, MAILING_LIST_MULTI, SPF_HELO_NONE, SPF_PASS, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id D7E7FC43333 for ; Sat, 13 Mar 2021 14:44:26 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id A6DA264F21 for ; Sat, 13 Mar 2021 14:44:26 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234062AbhCMOnv (ORCPT ); Sat, 13 Mar 2021 09:43:51 -0500 Received: from lb1-smtp-cloud9.xs4all.net ([194.109.24.22]:43475 "EHLO lb1-smtp-cloud9.xs4all.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234042AbhCMOnb (ORCPT ); Sat, 13 Mar 2021 09:43:31 -0500 Received: from cust-b5b5937f ([IPv6:fc0c:c16d:66b8:757f:c639:739b:9d66:799d]) by smtp-cloud9.xs4all.net with ESMTPA id L5UBljyoWC40pL5UIlV5er; Sat, 13 Mar 2021 15:43:30 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=xs4all.nl; s=s2; t=1615646610; bh=xny3+yi1N0Br60VZ0WZXRQBJhH0eTTdKwkvrYNNReEs=; h=From:To:Subject:Date:Message-Id:MIME-Version:From:Subject; b=jBa9y+Ic/0bn6IkbLbtEXVGxz3Ktw2LQPZH6bh1JdzitNq9qlWY5qpRBkiOyg0Iv2 7oHYRvUdlinvotHpWr/VeAqRFPRviYrir6uMXGr/1iaFScn/U1XyR1ItlG5CdShrlC Qhr+l7KyhtMmvOCK4YcjYE0koc0wOqnejCyZMnnjq8yNQy5kRe/m1sGOlVRdTxCJFL WM9vv0NYuCLwE8nZ41UvIv25DdA0EzBP2kukbmcVnwpsxH8/UgNFHo1go9StyVmlGC wXDSCHGpGW/og0DfkBfvJKjqcKluGvEAY8xE0+pprTCSoN8vWY6bn2KY5eXMNaPdWH 3q4HWNBHSzMQg== From: Hans Verkuil To: linux-media@vger.kernel.org Cc: Ezequiel Garcia , Nicolas Dufresne , Tomasz Figa , Alexandre Courbot , Hans Verkuil Subject: [PATCH 10/15] media/test-drivers: rename MPEG to CODEC Date: Sat, 13 Mar 2021 15:43:18 +0100 Message-Id: <20210313144323.143600-11-hverkuil-cisco@xs4all.nl> X-Mailer: git-send-email 2.30.1 In-Reply-To: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> References: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> MIME-Version: 1.0 X-CMAE-Envelope: MS4xfIh2kl1GkjNDZ839RU89rU7JIlz/Dpg9Ug6+sf1vZ9aM0wB9FTrQXLWmvRXqms0kreacuBi5YkmdKj8bnJ7Us4Gy4qoOzqpcs4oOLhG6c8fl+fqFphUO 1TZh4fS6XwQ55u2ThsAxwVG6eSvUBoa++FhjYoPSEXsZ9IW4dbt/w40or9IiDT8zCwxsthOKeQpMVFDUd5ev739T3PfS5/CVs4/drG+I1k3ijeMjLpPblhXY xUOk0qRK6etC493qrR/4UOfwre0isvld9zigxomdadiZfqxJU+X6o54Kyhh5zz+avLBwf84TfGR8iOwbDAlosIPHZfK/A+gTaafjHx68aEr8EiLULp9tnanO aPnx8e2oupAaJjV3ZgzBcUbkVZvpqQ== Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Historically all codec-related data structures and defines used the MPEG prefix. This is confusing. Rename MPEG to CODEC to make it clear that the MPEG prefix isn't MPEG specific. Signed-off-by: Hans Verkuil --- drivers/media/test-drivers/vicodec/vicodec-core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/media/test-drivers/vicodec/vicodec-core.c b/drivers/media/test-drivers/vicodec/vicodec-core.c index 33f1c893c1b6..b198e2d6f3d1 100644 --- a/drivers/media/test-drivers/vicodec/vicodec-core.c +++ b/drivers/media/test-drivers/vicodec/vicodec-core.c @@ -1785,7 +1785,7 @@ static int vicodec_s_ctrl(struct v4l2_ctrl *ctrl) const struct v4l2_ctrl_fwht_params *params; switch (ctrl->id) { - case V4L2_CID_MPEG_VIDEO_GOP_SIZE: + case V4L2_CID_CODEC_VIDEO_GOP_SIZE: ctx->state.gop_size = ctrl->val; return 0; case V4L2_CID_FWHT_I_FRAME_QP: @@ -1846,7 +1846,7 @@ static int vicodec_open(struct file *file) ctx->dev = dev; hdl = &ctx->hdl; v4l2_ctrl_handler_init(hdl, 5); - v4l2_ctrl_new_std(hdl, &vicodec_ctrl_ops, V4L2_CID_MPEG_VIDEO_GOP_SIZE, + v4l2_ctrl_new_std(hdl, &vicodec_ctrl_ops, V4L2_CID_CODEC_VIDEO_GOP_SIZE, 1, 16, 1, 10); v4l2_ctrl_new_std(hdl, &vicodec_ctrl_ops, V4L2_CID_FWHT_I_FRAME_QP, 1, 31, 1, 20); From patchwork Sat Mar 13 14:43:19 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans Verkuil X-Patchwork-Id: 399849 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-18.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER, INCLUDES_PATCH, MAILING_LIST_MULTI, SPF_HELO_NONE, SPF_PASS, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id AF83FC43331 for ; Sat, 13 Mar 2021 14:44:26 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 9609F64F1F for ; Sat, 13 Mar 2021 14:44:26 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234064AbhCMOnv (ORCPT ); Sat, 13 Mar 2021 09:43:51 -0500 Received: from lb3-smtp-cloud9.xs4all.net ([194.109.24.30]:58243 "EHLO lb3-smtp-cloud9.xs4all.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234039AbhCMOnb (ORCPT ); Sat, 13 Mar 2021 09:43:31 -0500 Received: from cust-b5b5937f ([IPv6:fc0c:c16d:66b8:757f:c639:739b:9d66:799d]) by smtp-cloud9.xs4all.net with ESMTPA id L5UBljyoWC40pL5UIlV5f5; Sat, 13 Mar 2021 15:43:31 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=xs4all.nl; s=s2; t=1615646611; bh=aOE4vYXLIcxLMsfBLOcJF9b/i7NyWXm53oDkhNM/Fa0=; h=From:To:Subject:Date:Message-Id:MIME-Version:From:Subject; b=P+BOudshLA6Eam5JqoFZuRnaG6ng/o8w9jLA11XIRckRevbWimKEEVejM060J9xKg PKeQDMO4weAXeuDKEIp1JMQdmey8+iQrXsaLsWBwHNgeOwgQS7QYYkm41kzpCfBECW I2VWzd8fteTuEHD7yq+lyumaEpN0joh30awGmHLgahsrCZMkXNS3HcmEFHKv995z+w k6A2u7Lb80RG4a38KJckzFDWvALo0T+9hKMqa//a8AI7Ugfjb8Mo8izQSl3oUnNz8M v9U4dGLG63p8ZZh2LGJ7bHxuy1CaGSoog77y/u76m5vZN1mTLBULHF0Y/IQSIYVP4l AQzTKr1a1vCNQ== From: Hans Verkuil To: linux-media@vger.kernel.org Cc: Ezequiel Garcia , Nicolas Dufresne , Tomasz Figa , Alexandre Courbot , Hans Verkuil Subject: [PATCH 11/15] staging/media: rename MPEG to CODEC Date: Sat, 13 Mar 2021 15:43:19 +0100 Message-Id: <20210313144323.143600-12-hverkuil-cisco@xs4all.nl> X-Mailer: git-send-email 2.30.1 In-Reply-To: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> References: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> MIME-Version: 1.0 X-CMAE-Envelope: MS4xfGjXQlB6dPm00Q5+tRzwB3aFZ8OPWH98sQ8KnCSmkllNXyOGRQ451yEBhBRoSYMx/70Ei/1lTHb4u1Yw6H0ALeY4fngk6nnf7VxwMjVJZ/QCpkLpMsRG 0cbnbgZrMioPgn2hCI1grQsUPJS4MPV7NF0UM8f3Qt46iZkw1yyvlU5ZteXZXVD7CVPHuWYjWWnA7sAzN4+F8MCOgsnyOHL8eOqVNGSWDDRgqL0ulujm5oSG weKk9dhW0UbALkS0GbKq4Ua7DNlgTvhiDCO8eUKkv+J+RlHCMgI1ZUYQVYYllrLhoOtQ7bGTxoQ5ns0gcRVG3SUfLe21/fiJSZ6KWQ+tbog6fM3CObuQ2YzZ CclsM0VNtE3ny/g1X0fBANEUoLwNfQ== Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Historically all codec-related data structures and defines used the MPEG prefix. This is confusing. Rename MPEG to CODEC to make it clear that the MPEG prefix isn't MPEG specific. Signed-off-by: Hans Verkuil --- drivers/staging/media/hantro/hantro_drv.c | 16 ++++----- .../media/hantro/hantro_g1_mpeg2_dec.c | 4 +-- .../staging/media/hantro/hantro_g1_vp8_dec.c | 2 +- .../media/hantro/rk3399_vpu_hw_mpeg2_dec.c | 4 +-- .../media/hantro/rk3399_vpu_hw_vp8_dec.c | 2 +- drivers/staging/media/rkvdec/rkvdec.c | 16 ++++----- drivers/staging/media/sunxi/cedrus/cedrus.c | 34 +++++++++---------- .../staging/media/sunxi/cedrus/cedrus_dec.c | 12 +++---- 8 files changed, 45 insertions(+), 45 deletions(-) diff --git a/drivers/staging/media/hantro/hantro_drv.c b/drivers/staging/media/hantro/hantro_drv.c index e5f200e64993..3ff83550a193 100644 --- a/drivers/staging/media/hantro/hantro_drv.c +++ b/drivers/staging/media/hantro/hantro_drv.c @@ -289,17 +289,17 @@ static const struct hantro_ctrl controls[] = { }, { .codec = HANTRO_MPEG2_DECODER, .cfg = { - .id = V4L2_CID_MPEG_VIDEO_MPEG2_SLICE_PARAMS, + .id = V4L2_CID_CODEC_VIDEO_MPEG2_SLICE_PARAMS, }, }, { .codec = HANTRO_MPEG2_DECODER, .cfg = { - .id = V4L2_CID_MPEG_VIDEO_MPEG2_QUANTIZATION, + .id = V4L2_CID_CODEC_VIDEO_MPEG2_QUANTIZATION, }, }, { .codec = HANTRO_VP8_DECODER, .cfg = { - .id = V4L2_CID_MPEG_VIDEO_VP8_FRAME_HEADER, + .id = V4L2_CID_CODEC_VIDEO_VP8_FRAME_HEADER, }, }, { .codec = HANTRO_H264_DECODER, @@ -341,12 +341,12 @@ static const struct hantro_ctrl controls[] = { }, { .codec = HANTRO_H264_DECODER, .cfg = { - .id = V4L2_CID_MPEG_VIDEO_H264_PROFILE, - .min = V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE, - .max = V4L2_MPEG_VIDEO_H264_PROFILE_HIGH, + .id = V4L2_CID_CODEC_VIDEO_H264_PROFILE, + .min = V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE, + .max = V4L2_CODEC_VIDEO_H264_PROFILE_HIGH, .menu_skip_mask = - BIT(V4L2_MPEG_VIDEO_H264_PROFILE_EXTENDED), - .def = V4L2_MPEG_VIDEO_H264_PROFILE_MAIN, + BIT(V4L2_CODEC_VIDEO_H264_PROFILE_EXTENDED), + .def = V4L2_CODEC_VIDEO_H264_PROFILE_MAIN, } }, { }, diff --git a/drivers/staging/media/hantro/hantro_g1_mpeg2_dec.c b/drivers/staging/media/hantro/hantro_g1_mpeg2_dec.c index 6386a3989bfe..3feaef6115de 100644 --- a/drivers/staging/media/hantro/hantro_g1_mpeg2_dec.c +++ b/drivers/staging/media/hantro/hantro_g1_mpeg2_dec.c @@ -88,7 +88,7 @@ hantro_g1_mpeg2_dec_set_quantization(struct hantro_dev *vpu, struct v4l2_ctrl_mpeg2_quantization *quantization; quantization = hantro_get_ctrl(ctx, - V4L2_CID_MPEG_VIDEO_MPEG2_QUANTIZATION); + V4L2_CID_CODEC_VIDEO_MPEG2_QUANTIZATION); hantro_mpeg2_dec_copy_qtable(ctx->mpeg2_dec.qtable.cpu, quantization); vdpu_write_relaxed(vpu, ctx->mpeg2_dec.qtable.dma, @@ -171,7 +171,7 @@ void hantro_g1_mpeg2_dec_run(struct hantro_ctx *ctx) hantro_start_prepare_run(ctx); slice_params = hantro_get_ctrl(ctx, - V4L2_CID_MPEG_VIDEO_MPEG2_SLICE_PARAMS); + V4L2_CID_CODEC_VIDEO_MPEG2_SLICE_PARAMS); sequence = &slice_params->sequence; picture = &slice_params->picture; diff --git a/drivers/staging/media/hantro/hantro_g1_vp8_dec.c b/drivers/staging/media/hantro/hantro_g1_vp8_dec.c index a5cdf150cd16..a29bb9ea07d5 100644 --- a/drivers/staging/media/hantro/hantro_g1_vp8_dec.c +++ b/drivers/staging/media/hantro/hantro_g1_vp8_dec.c @@ -437,7 +437,7 @@ void hantro_g1_vp8_dec_run(struct hantro_ctx *ctx) hantro_start_prepare_run(ctx); - hdr = hantro_get_ctrl(ctx, V4L2_CID_MPEG_VIDEO_VP8_FRAME_HEADER); + hdr = hantro_get_ctrl(ctx, V4L2_CID_CODEC_VIDEO_VP8_FRAME_HEADER); if (WARN_ON(!hdr)) return; diff --git a/drivers/staging/media/hantro/rk3399_vpu_hw_mpeg2_dec.c b/drivers/staging/media/hantro/rk3399_vpu_hw_mpeg2_dec.c index f610fa5b4335..bc9272c58379 100644 --- a/drivers/staging/media/hantro/rk3399_vpu_hw_mpeg2_dec.c +++ b/drivers/staging/media/hantro/rk3399_vpu_hw_mpeg2_dec.c @@ -90,7 +90,7 @@ rk3399_vpu_mpeg2_dec_set_quantization(struct hantro_dev *vpu, struct v4l2_ctrl_mpeg2_quantization *quantization; quantization = hantro_get_ctrl(ctx, - V4L2_CID_MPEG_VIDEO_MPEG2_QUANTIZATION); + V4L2_CID_CODEC_VIDEO_MPEG2_QUANTIZATION); hantro_mpeg2_dec_copy_qtable(ctx->mpeg2_dec.qtable.cpu, quantization); vdpu_write_relaxed(vpu, ctx->mpeg2_dec.qtable.dma, VDPU_REG_QTABLE_BASE); @@ -172,7 +172,7 @@ void rk3399_vpu_mpeg2_dec_run(struct hantro_ctx *ctx) hantro_start_prepare_run(ctx); slice_params = hantro_get_ctrl(ctx, - V4L2_CID_MPEG_VIDEO_MPEG2_SLICE_PARAMS); + V4L2_CID_CODEC_VIDEO_MPEG2_SLICE_PARAMS); sequence = &slice_params->sequence; picture = &slice_params->picture; diff --git a/drivers/staging/media/hantro/rk3399_vpu_hw_vp8_dec.c b/drivers/staging/media/hantro/rk3399_vpu_hw_vp8_dec.c index a4a792f00b11..3f66139a3d6a 100644 --- a/drivers/staging/media/hantro/rk3399_vpu_hw_vp8_dec.c +++ b/drivers/staging/media/hantro/rk3399_vpu_hw_vp8_dec.c @@ -515,7 +515,7 @@ void rk3399_vpu_vp8_dec_run(struct hantro_ctx *ctx) hantro_start_prepare_run(ctx); - hdr = hantro_get_ctrl(ctx, V4L2_CID_MPEG_VIDEO_VP8_FRAME_HEADER); + hdr = hantro_get_ctrl(ctx, V4L2_CID_CODEC_VIDEO_VP8_FRAME_HEADER); if (WARN_ON(!hdr)) return; diff --git a/drivers/staging/media/rkvdec/rkvdec.c b/drivers/staging/media/rkvdec/rkvdec.c index d3eb81ee8dc2..254f6b6f4428 100644 --- a/drivers/staging/media/rkvdec/rkvdec.c +++ b/drivers/staging/media/rkvdec/rkvdec.c @@ -83,17 +83,17 @@ static const struct rkvdec_ctrl_desc rkvdec_h264_ctrl_descs[] = { .cfg.max = V4L2_STATELESS_H264_START_CODE_ANNEX_B, }, { - .cfg.id = V4L2_CID_MPEG_VIDEO_H264_PROFILE, - .cfg.min = V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE, - .cfg.max = V4L2_MPEG_VIDEO_H264_PROFILE_HIGH, + .cfg.id = V4L2_CID_CODEC_VIDEO_H264_PROFILE, + .cfg.min = V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE, + .cfg.max = V4L2_CODEC_VIDEO_H264_PROFILE_HIGH, .cfg.menu_skip_mask = - BIT(V4L2_MPEG_VIDEO_H264_PROFILE_EXTENDED), - .cfg.def = V4L2_MPEG_VIDEO_H264_PROFILE_MAIN, + BIT(V4L2_CODEC_VIDEO_H264_PROFILE_EXTENDED), + .cfg.def = V4L2_CODEC_VIDEO_H264_PROFILE_MAIN, }, { - .cfg.id = V4L2_CID_MPEG_VIDEO_H264_LEVEL, - .cfg.min = V4L2_MPEG_VIDEO_H264_LEVEL_1_0, - .cfg.max = V4L2_MPEG_VIDEO_H264_LEVEL_5_1, + .cfg.id = V4L2_CID_CODEC_VIDEO_H264_LEVEL, + .cfg.min = V4L2_CODEC_VIDEO_H264_LEVEL_1_0, + .cfg.max = V4L2_CODEC_VIDEO_H264_LEVEL_5_1, }, }; diff --git a/drivers/staging/media/sunxi/cedrus/cedrus.c b/drivers/staging/media/sunxi/cedrus/cedrus.c index 7bd9291c8d5f..7e9ee46ec2b6 100644 --- a/drivers/staging/media/sunxi/cedrus/cedrus.c +++ b/drivers/staging/media/sunxi/cedrus/cedrus.c @@ -31,13 +31,13 @@ static const struct cedrus_control cedrus_controls[] = { { .cfg = { - .id = V4L2_CID_MPEG_VIDEO_MPEG2_SLICE_PARAMS, + .id = V4L2_CID_CODEC_VIDEO_MPEG2_SLICE_PARAMS, }, .codec = CEDRUS_CODEC_MPEG2, }, { .cfg = { - .id = V4L2_CID_MPEG_VIDEO_MPEG2_QUANTIZATION, + .id = V4L2_CID_CODEC_VIDEO_MPEG2_QUANTIZATION, }, .codec = CEDRUS_CODEC_MPEG2, }, @@ -102,52 +102,52 @@ static const struct cedrus_control cedrus_controls[] = { */ { .cfg = { - .id = V4L2_CID_MPEG_VIDEO_H264_PROFILE, - .min = V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE, - .def = V4L2_MPEG_VIDEO_H264_PROFILE_MAIN, - .max = V4L2_MPEG_VIDEO_H264_PROFILE_HIGH, + .id = V4L2_CID_CODEC_VIDEO_H264_PROFILE, + .min = V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE, + .def = V4L2_CODEC_VIDEO_H264_PROFILE_MAIN, + .max = V4L2_CODEC_VIDEO_H264_PROFILE_HIGH, .menu_skip_mask = - BIT(V4L2_MPEG_VIDEO_H264_PROFILE_EXTENDED), + BIT(V4L2_CODEC_VIDEO_H264_PROFILE_EXTENDED), }, .codec = CEDRUS_CODEC_H264, }, { .cfg = { - .id = V4L2_CID_MPEG_VIDEO_HEVC_SPS, + .id = V4L2_CID_CODEC_VIDEO_HEVC_SPS, }, .codec = CEDRUS_CODEC_H265, }, { .cfg = { - .id = V4L2_CID_MPEG_VIDEO_HEVC_PPS, + .id = V4L2_CID_CODEC_VIDEO_HEVC_PPS, }, .codec = CEDRUS_CODEC_H265, }, { .cfg = { - .id = V4L2_CID_MPEG_VIDEO_HEVC_SLICE_PARAMS, + .id = V4L2_CID_CODEC_VIDEO_HEVC_SLICE_PARAMS, }, .codec = CEDRUS_CODEC_H265, }, { .cfg = { - .id = V4L2_CID_MPEG_VIDEO_HEVC_DECODE_MODE, - .max = V4L2_MPEG_VIDEO_HEVC_DECODE_MODE_SLICE_BASED, - .def = V4L2_MPEG_VIDEO_HEVC_DECODE_MODE_SLICE_BASED, + .id = V4L2_CID_CODEC_VIDEO_HEVC_DECODE_MODE, + .max = V4L2_CODEC_VIDEO_HEVC_DECODE_MODE_SLICE_BASED, + .def = V4L2_CODEC_VIDEO_HEVC_DECODE_MODE_SLICE_BASED, }, .codec = CEDRUS_CODEC_H265, }, { .cfg = { - .id = V4L2_CID_MPEG_VIDEO_HEVC_START_CODE, - .max = V4L2_MPEG_VIDEO_HEVC_START_CODE_NONE, - .def = V4L2_MPEG_VIDEO_HEVC_START_CODE_NONE, + .id = V4L2_CID_CODEC_VIDEO_HEVC_START_CODE, + .max = V4L2_CODEC_VIDEO_HEVC_START_CODE_NONE, + .def = V4L2_CODEC_VIDEO_HEVC_START_CODE_NONE, }, .codec = CEDRUS_CODEC_H265, }, { .cfg = { - .id = V4L2_CID_MPEG_VIDEO_VP8_FRAME_HEADER, + .id = V4L2_CID_CODEC_VIDEO_VP8_FRAME_HEADER, }, .codec = CEDRUS_CODEC_VP8, }, diff --git a/drivers/staging/media/sunxi/cedrus/cedrus_dec.c b/drivers/staging/media/sunxi/cedrus/cedrus_dec.c index a9090daf626a..a951819b85d4 100644 --- a/drivers/staging/media/sunxi/cedrus/cedrus_dec.c +++ b/drivers/staging/media/sunxi/cedrus/cedrus_dec.c @@ -41,9 +41,9 @@ void cedrus_device_run(void *priv) switch (ctx->src_fmt.pixelformat) { case V4L2_PIX_FMT_MPEG2_SLICE: run.mpeg2.slice_params = cedrus_find_control_data(ctx, - V4L2_CID_MPEG_VIDEO_MPEG2_SLICE_PARAMS); + V4L2_CID_CODEC_VIDEO_MPEG2_SLICE_PARAMS); run.mpeg2.quantization = cedrus_find_control_data(ctx, - V4L2_CID_MPEG_VIDEO_MPEG2_QUANTIZATION); + V4L2_CID_CODEC_VIDEO_MPEG2_QUANTIZATION); break; case V4L2_PIX_FMT_H264_SLICE: @@ -63,16 +63,16 @@ void cedrus_device_run(void *priv) case V4L2_PIX_FMT_HEVC_SLICE: run.h265.sps = cedrus_find_control_data(ctx, - V4L2_CID_MPEG_VIDEO_HEVC_SPS); + V4L2_CID_CODEC_VIDEO_HEVC_SPS); run.h265.pps = cedrus_find_control_data(ctx, - V4L2_CID_MPEG_VIDEO_HEVC_PPS); + V4L2_CID_CODEC_VIDEO_HEVC_PPS); run.h265.slice_params = cedrus_find_control_data(ctx, - V4L2_CID_MPEG_VIDEO_HEVC_SLICE_PARAMS); + V4L2_CID_CODEC_VIDEO_HEVC_SLICE_PARAMS); break; case V4L2_PIX_FMT_VP8_FRAME: run.vp8.frame_params = cedrus_find_control_data(ctx, - V4L2_CID_MPEG_VIDEO_VP8_FRAME_HEADER); + V4L2_CID_CODEC_VIDEO_VP8_FRAME_HEADER); break; default: From patchwork Sat Mar 13 14:43:20 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans Verkuil X-Patchwork-Id: 399846 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-18.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER, INCLUDES_PATCH, MAILING_LIST_MULTI, SPF_HELO_NONE, SPF_PASS, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 28FA8C4360C for ; Sat, 13 Mar 2021 14:44:27 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 1563564F2A for ; Sat, 13 Mar 2021 14:44:27 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234075AbhCMOnx (ORCPT ); Sat, 13 Mar 2021 09:43:53 -0500 Received: from lb2-smtp-cloud9.xs4all.net ([194.109.24.26]:43711 "EHLO lb2-smtp-cloud9.xs4all.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234043AbhCMOnc (ORCPT ); Sat, 13 Mar 2021 09:43:32 -0500 Received: from cust-b5b5937f ([IPv6:fc0c:c16d:66b8:757f:c639:739b:9d66:799d]) by smtp-cloud9.xs4all.net with ESMTPA id L5UBljyoWC40pL5UJlV5fM; Sat, 13 Mar 2021 15:43:31 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=xs4all.nl; s=s2; t=1615646611; bh=3d7D++bS5q9Gy64oww8ABQ29Cez/HNEYkabgbmhdByQ=; h=From:To:Subject:Date:Message-Id:MIME-Version:From:Subject; b=qEpekST1L1dC/vmU+kPIqc3GmOmgBB2K2jVQ0YhTetD5RnOIIuTEJMdsHrGoxwXKJ SctLCUd/ic8cbrE5dzU6NYzWk4j+bkoT01SuOv3K5H2TuKpPrRko4wQ9yAdl8WxLQR QbpQ4jkZbQabIieHSPJu5TkKD4aFH5Nrr3V7+oxb5z4fxbSYxw0oe4j/vTn6vRujdR acfvC9ACUWj1Nc+WI8+eoRIs/kpI1rG+IdJNA9JeBj9tHAFLXcS9BD7gtpVzZUnp0t h0DHCvGgt+c0aSSZkkp3dOwTaVe2r2d/y3PmFRafDTX6GNgcsD0QgD2LRjZ420juea GdbXud0f6rPLQ== From: Hans Verkuil To: linux-media@vger.kernel.org Cc: Ezequiel Garcia , Nicolas Dufresne , Tomasz Figa , Alexandre Courbot , Hans Verkuil Subject: [PATCH 12/15] include/media: rename MPEG to CODEC Date: Sat, 13 Mar 2021 15:43:20 +0100 Message-Id: <20210313144323.143600-13-hverkuil-cisco@xs4all.nl> X-Mailer: git-send-email 2.30.1 In-Reply-To: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> References: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> MIME-Version: 1.0 X-CMAE-Envelope: MS4xfGjXQlB6dPm00Q5+tRzwB3aFZ8OPWH98sQ8KnCSmkllNXyOGRQ451yEBhBRoSYMx/70Ei/1lTHb4u1Yw6H0ALeY4fngk6nnf7VxwMjVJZ/QCpkLpMsRG 0cbnbgZrMioPgn2hCI1grQsUPJS4MPV7NF0UM8f3Qt46iZkw1yyvlU5ZteXZXVD7CVPHuWYjWWnA7sAzN4+F8MCOgsnyOHL8eOqVNGSWDDRgqL0ulujm5oSG weKk9dhW0UbALkS0GbKq4Ua7DNlgTvhiDCO8eUKkv+J+RlHCMgI1ZUYQVYYllrLhoOtQ7bGTxoQ5ns0gcRVG3SUfLe21/fiJSZ6KWQ+tbog6fM3CObuQ2YzZ CclsM0VNtE3ny/g1X0fBANEUoLwNfQ== Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Historically all codec-related data structures and defines used the MPEG prefix. This is confusing. Rename MPEG to CODEC to make it clear that the MPEG prefix isn't MPEG specific. Signed-off-by: Hans Verkuil --- include/media/drv-intf/cx2341x.h | 36 ++++++++++++++++---------------- include/media/hevc-ctrls.h | 22 +++++++++---------- include/media/mpeg2-ctrls.h | 4 ++-- include/media/vp8-ctrls.h | 2 +- 4 files changed, 32 insertions(+), 32 deletions(-) diff --git a/include/media/drv-intf/cx2341x.h b/include/media/drv-intf/cx2341x.h index 722f5905fc30..9312409fa8f9 100644 --- a/include/media/drv-intf/cx2341x.h +++ b/include/media/drv-intf/cx2341x.h @@ -30,29 +30,29 @@ struct cx2341x_mpeg_params { u16 is_50hz; /* stream */ - enum v4l2_mpeg_stream_type stream_type; - enum v4l2_mpeg_stream_vbi_fmt stream_vbi_fmt; + enum v4l2_codec_stream_type stream_type; + enum v4l2_codec_stream_vbi_fmt stream_vbi_fmt; u16 stream_insert_nav_packets; /* audio */ - enum v4l2_mpeg_audio_sampling_freq audio_sampling_freq; - enum v4l2_mpeg_audio_encoding audio_encoding; - enum v4l2_mpeg_audio_l2_bitrate audio_l2_bitrate; - enum v4l2_mpeg_audio_ac3_bitrate audio_ac3_bitrate; - enum v4l2_mpeg_audio_mode audio_mode; - enum v4l2_mpeg_audio_mode_extension audio_mode_extension; - enum v4l2_mpeg_audio_emphasis audio_emphasis; - enum v4l2_mpeg_audio_crc audio_crc; + enum v4l2_codec_audio_sampling_freq audio_sampling_freq; + enum v4l2_codec_audio_encoding audio_encoding; + enum v4l2_codec_audio_l2_bitrate audio_l2_bitrate; + enum v4l2_codec_audio_ac3_bitrate audio_ac3_bitrate; + enum v4l2_codec_audio_mode audio_mode; + enum v4l2_codec_audio_mode_extension audio_mode_extension; + enum v4l2_codec_audio_emphasis audio_emphasis; + enum v4l2_codec_audio_crc audio_crc; u32 audio_properties; u16 audio_mute; /* video */ - enum v4l2_mpeg_video_encoding video_encoding; - enum v4l2_mpeg_video_aspect video_aspect; + enum v4l2_codec_video_encoding video_encoding; + enum v4l2_codec_video_aspect video_aspect; u16 video_b_frames; u16 video_gop_size; u16 video_gop_closure; - enum v4l2_mpeg_video_bitrate_mode video_bitrate_mode; + enum v4l2_codec_video_bitrate_mode video_bitrate_mode; u32 video_bitrate; u32 video_bitrate_peak; u16 video_temporal_decimation; @@ -60,13 +60,13 @@ struct cx2341x_mpeg_params { u32 video_mute_yuv; /* encoding filters */ - enum v4l2_mpeg_cx2341x_video_spatial_filter_mode video_spatial_filter_mode; + enum v4l2_codec_cx2341x_video_spatial_filter_mode video_spatial_filter_mode; u16 video_spatial_filter; - enum v4l2_mpeg_cx2341x_video_luma_spatial_filter_type video_luma_spatial_filter_type; - enum v4l2_mpeg_cx2341x_video_chroma_spatial_filter_type video_chroma_spatial_filter_type; - enum v4l2_mpeg_cx2341x_video_temporal_filter_mode video_temporal_filter_mode; + enum v4l2_codec_cx2341x_video_luma_spatial_filter_type video_luma_spatial_filter_type; + enum v4l2_codec_cx2341x_video_chroma_spatial_filter_type video_chroma_spatial_filter_type; + enum v4l2_codec_cx2341x_video_temporal_filter_mode video_temporal_filter_mode; u16 video_temporal_filter; - enum v4l2_mpeg_cx2341x_video_median_filter_type video_median_filter_type; + enum v4l2_codec_cx2341x_video_median_filter_type video_median_filter_type; u16 video_luma_median_filter_top; u16 video_luma_median_filter_bottom; u16 video_chroma_median_filter_top; diff --git a/include/media/hevc-ctrls.h b/include/media/hevc-ctrls.h index b4cb2ef02f17..ff2a89f38948 100644 --- a/include/media/hevc-ctrls.h +++ b/include/media/hevc-ctrls.h @@ -16,25 +16,25 @@ /* The pixel format isn't stable at the moment and will likely be renamed. */ #define V4L2_PIX_FMT_HEVC_SLICE v4l2_fourcc('S', '2', '6', '5') /* HEVC parsed slices */ -#define V4L2_CID_MPEG_VIDEO_HEVC_SPS (V4L2_CID_CODEC_BASE + 1008) -#define V4L2_CID_MPEG_VIDEO_HEVC_PPS (V4L2_CID_CODEC_BASE + 1009) -#define V4L2_CID_MPEG_VIDEO_HEVC_SLICE_PARAMS (V4L2_CID_CODEC_BASE + 1010) -#define V4L2_CID_MPEG_VIDEO_HEVC_DECODE_MODE (V4L2_CID_CODEC_BASE + 1015) -#define V4L2_CID_MPEG_VIDEO_HEVC_START_CODE (V4L2_CID_CODEC_BASE + 1016) +#define V4L2_CID_CODEC_VIDEO_HEVC_SPS (V4L2_CID_CODEC_BASE + 1008) +#define V4L2_CID_CODEC_VIDEO_HEVC_PPS (V4L2_CID_CODEC_BASE + 1009) +#define V4L2_CID_CODEC_VIDEO_HEVC_SLICE_PARAMS (V4L2_CID_CODEC_BASE + 1010) +#define V4L2_CID_CODEC_VIDEO_HEVC_DECODE_MODE (V4L2_CID_CODEC_BASE + 1015) +#define V4L2_CID_CODEC_VIDEO_HEVC_START_CODE (V4L2_CID_CODEC_BASE + 1016) /* enum v4l2_ctrl_type type values */ #define V4L2_CTRL_TYPE_HEVC_SPS 0x0120 #define V4L2_CTRL_TYPE_HEVC_PPS 0x0121 #define V4L2_CTRL_TYPE_HEVC_SLICE_PARAMS 0x0122 -enum v4l2_mpeg_video_hevc_decode_mode { - V4L2_MPEG_VIDEO_HEVC_DECODE_MODE_SLICE_BASED, - V4L2_MPEG_VIDEO_HEVC_DECODE_MODE_FRAME_BASED, +enum v4l2_codec_video_hevc_decode_mode { + V4L2_CODEC_VIDEO_HEVC_DECODE_MODE_SLICE_BASED, + V4L2_CODEC_VIDEO_HEVC_DECODE_MODE_FRAME_BASED, }; -enum v4l2_mpeg_video_hevc_start_code { - V4L2_MPEG_VIDEO_HEVC_START_CODE_NONE, - V4L2_MPEG_VIDEO_HEVC_START_CODE_ANNEX_B, +enum v4l2_codec_video_hevc_start_code { + V4L2_CODEC_VIDEO_HEVC_START_CODE_NONE, + V4L2_CODEC_VIDEO_HEVC_START_CODE_ANNEX_B, }; #define V4L2_HEVC_SLICE_TYPE_B 0 diff --git a/include/media/mpeg2-ctrls.h b/include/media/mpeg2-ctrls.h index 2a4ae6701166..bb38e42eaf19 100644 --- a/include/media/mpeg2-ctrls.h +++ b/include/media/mpeg2-ctrls.h @@ -11,8 +11,8 @@ #ifndef _MPEG2_CTRLS_H_ #define _MPEG2_CTRLS_H_ -#define V4L2_CID_MPEG_VIDEO_MPEG2_SLICE_PARAMS (V4L2_CID_CODEC_BASE+250) -#define V4L2_CID_MPEG_VIDEO_MPEG2_QUANTIZATION (V4L2_CID_CODEC_BASE+251) +#define V4L2_CID_CODEC_VIDEO_MPEG2_SLICE_PARAMS (V4L2_CID_CODEC_BASE+250) +#define V4L2_CID_CODEC_VIDEO_MPEG2_QUANTIZATION (V4L2_CID_CODEC_BASE+251) /* enum v4l2_ctrl_type type values */ #define V4L2_CTRL_TYPE_MPEG2_SLICE_PARAMS 0x0103 diff --git a/include/media/vp8-ctrls.h b/include/media/vp8-ctrls.h index 3969550df148..81b97ed0b03b 100644 --- a/include/media/vp8-ctrls.h +++ b/include/media/vp8-ctrls.h @@ -15,7 +15,7 @@ #define V4L2_PIX_FMT_VP8_FRAME v4l2_fourcc('V', 'P', '8', 'F') -#define V4L2_CID_MPEG_VIDEO_VP8_FRAME_HEADER (V4L2_CID_CODEC_BASE + 2000) +#define V4L2_CID_CODEC_VIDEO_VP8_FRAME_HEADER (V4L2_CID_CODEC_BASE + 2000) #define V4L2_CTRL_TYPE_VP8_FRAME_HEADER 0x301 #define V4L2_VP8_SEGMENT_HEADER_FLAG_ENABLED 0x01 From patchwork Sat Mar 13 14:43:21 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans Verkuil X-Patchwork-Id: 400253 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-18.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER, INCLUDES_PATCH, MAILING_LIST_MULTI, SPF_HELO_NONE, SPF_PASS, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id EEBECC43603 for ; Sat, 13 Mar 2021 14:44:26 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id C5C2064F27 for ; Sat, 13 Mar 2021 14:44:26 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234074AbhCMOnx (ORCPT ); Sat, 13 Mar 2021 09:43:53 -0500 Received: from lb3-smtp-cloud9.xs4all.net ([194.109.24.30]:36105 "EHLO lb3-smtp-cloud9.xs4all.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234045AbhCMOnc (ORCPT ); Sat, 13 Mar 2021 09:43:32 -0500 Received: from cust-b5b5937f ([IPv6:fc0c:c16d:66b8:757f:c639:739b:9d66:799d]) by smtp-cloud9.xs4all.net with ESMTPA id L5UBljyoWC40pL5UJlV5fc; Sat, 13 Mar 2021 15:43:31 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=xs4all.nl; s=s2; t=1615646611; bh=cjCEu9Q7NxzS05k7yOFa4La2O8Ohl8VPtngk6zduQUk=; h=From:To:Subject:Date:Message-Id:MIME-Version:From:Subject; b=twA4LPU5YXKaGlx3e6g07XcOuPSRJ5Me+GVJGanWURkMmtkbJ4i2McLlL6Qzs1qOC 8oyGBeLxcjqD3eHmTWZneAkKag276Cba+6G57kUVQMRN6T4lfbd9Ffaei+F//ivDDG vICFu599YZRJ7F/n3bd1i20v5rohSKShKR7+elgQ7b5weg8xKuT1nxaWjCo0D1fr0+ 6DmlQFG6p0O3KTwhxNOHmqltu4Ko7LO14izFAP5BA/Tk/PRW2ClUcknT8w+9vPYmwl /CUjC0yMLU8sc9Enagge8JzQbbTZiicMHeHSVGWEV9OY4ZgdNX2sbVmdMYj0BA9YqR O8Oyf2qBn3HCA== From: Hans Verkuil To: linux-media@vger.kernel.org Cc: Ezequiel Garcia , Nicolas Dufresne , Tomasz Figa , Alexandre Courbot , Hans Verkuil Subject: [PATCH 13/15] videodev2.h: rename MPEG to CODEC Date: Sat, 13 Mar 2021 15:43:21 +0100 Message-Id: <20210313144323.143600-14-hverkuil-cisco@xs4all.nl> X-Mailer: git-send-email 2.30.1 In-Reply-To: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> References: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> MIME-Version: 1.0 X-CMAE-Envelope: MS4xfGjXQlB6dPm00Q5+tRzwB3aFZ8OPWH98sQ8KnCSmkllNXyOGRQ451yEBhBRoSYMx/70Ei/1lTHb4u1Yw6H0ALeY4fngk6nnf7VxwMjVJZ/QCpkLpMsRG 0cbnbgZrMioPgn2hCI1grQsUPJS4MPV7NF0UM8f3Qt46iZkw1yyvlU5ZteXZXVD7CVPHuWYjWWnA7sAzN4+F8MCOgsnyOHL8eOqVNGSWDDRgqL0ulujm5oSG weKk9dhW0UbALkS0GbKq4Ua7DNlgTvhiDCO8eUKkv+J+RlHCMgI1ZUYQVYYllrLhoOtQ7bGTxoQ5ns0gcRVG3SUfLe21/fiJSZ6KWQ+tbog6fM3CObuQ2YzZ CclsM0VNtE3ny/g1X0fBANEUoLwNfQ== Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Historically all codec-related data structures and defines used the MPEG prefix. This is confusing. Rename MPEG to CODEC to make it clear that the MPEG prefix isn't MPEG specific. Signed-off-by: Hans Verkuil --- include/uapi/linux/videodev2.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/uapi/linux/videodev2.h b/include/uapi/linux/videodev2.h index 79dbde3bcf8d..db838c3a548f 100644 --- a/include/uapi/linux/videodev2.h +++ b/include/uapi/linux/videodev2.h @@ -2177,10 +2177,10 @@ struct v4l2_sliced_vbi_data { */ /* - * V4L2_MPEG_STREAM_VBI_FMT_IVTV: + * V4L2_CODEC_STREAM_VBI_FMT_IVTV: * * Structure of payload contained in an MPEG 2 Private Stream 1 PES Packet in an - * MPEG-2 Program Pack that contains V4L2_MPEG_STREAM_VBI_FMT_IVTV Sliced VBI + * MPEG-2 Program Pack that contains V4L2_CODEC_STREAM_VBI_FMT_IVTV Sliced VBI * data * * Note, the MPEG-2 Program Pack and Private Stream 1 PES packet header From patchwork Sat Mar 13 14:43:22 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans Verkuil X-Patchwork-Id: 400251 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-18.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER, INCLUDES_PATCH, MAILING_LIST_MULTI, SPF_HELO_NONE, SPF_PASS, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id EDF79C432C3 for ; Sat, 13 Mar 2021 14:44:26 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id D61A764F35 for ; Sat, 13 Mar 2021 14:44:26 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234071AbhCMOnx (ORCPT ); Sat, 13 Mar 2021 09:43:53 -0500 Received: from lb3-smtp-cloud9.xs4all.net ([194.109.24.30]:58243 "EHLO lb3-smtp-cloud9.xs4all.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234046AbhCMOnc (ORCPT ); Sat, 13 Mar 2021 09:43:32 -0500 Received: from cust-b5b5937f ([IPv6:fc0c:c16d:66b8:757f:c639:739b:9d66:799d]) by smtp-cloud9.xs4all.net with ESMTPA id L5UBljyoWC40pL5UJlV5fx; Sat, 13 Mar 2021 15:43:32 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=xs4all.nl; s=s2; t=1615646612; bh=KW/25ZoMVGqPWkM326YBsSXGAuR0NnKDUfdFjrmqckM=; h=From:To:Subject:Date:Message-Id:MIME-Version:From:Subject; b=BW24+GEgdi45UtvPAYRbjr+vChlNuM8XAf2X/Fec2AygC+TF+OdNEGZ6Z284W3QZy oIrly3XMtj0CMyZ/M3QqO2vyW0FMjumjl6qgaYiMmLtwsBZ95L58ooBh9ZNe3IYq+e mBvxCk+Z5tTG70o3/+EyZ2EGe3+cfh5EmvU0Q86ZVTUhLJSveTmTm4IcqfaKnlIM0H RFuZychpAr321FhYljJnbxqwjFCUCbPMwXkWEaAg2tdr98shN1/Ej3qUHv6uqN+xPP pJ7jFkUQOdBTNrR6AUEE8EeO4+AbPjXu35bNKunJ9hNPegVWwn9IdgjJWWszMuy+UU gOHk2p05Pzp2Q== From: Hans Verkuil To: linux-media@vger.kernel.org Cc: Ezequiel Garcia , Nicolas Dufresne , Tomasz Figa , Alexandre Courbot , Hans Verkuil Subject: [PATCH 14/15] staging/vc04_services: rename MPEG to CODEC Date: Sat, 13 Mar 2021 15:43:22 +0100 Message-Id: <20210313144323.143600-15-hverkuil-cisco@xs4all.nl> X-Mailer: git-send-email 2.30.1 In-Reply-To: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> References: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> MIME-Version: 1.0 X-CMAE-Envelope: MS4xfMsn8vxVIxOwfk1HBWm1Tn7DGMcFBFbrL2w9e7B7pn4zh+SRP2Jqi17Q8et5l39XyCF1q6dYvMVynpi6jD8GJZbtOnePYAy+v8vxRtTsu+FlLMzjey/I 6Yf2reWeEQBe+OBiEXPcSX3xOiLByNfrsU33zfghVRd3mwxeQLH9Gq4GWugIjL4dJLGCBXrWgwo58BS8Sxu/56+i36P9vJr0RkaTCnESq9F/NQlsCuDMX4h3 10pkzvNLw0uYhvnm1xXbFfx1pKTTozHVj9bmvjRoFUvRhpkEKQbLP/gkdVKcDKlCZifRrbV1VJpdbsMQnKHRrjJDCr7QxehVtEcM0E51Kv/9SHktNQQ5z8K1 67fFE2fVamSR0HzbTdI6X+c/qRm4Xw== Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Historically all codec-related data structures and defines used the MPEG prefix. This is confusing. Rename MPEG to CODEC to make it clear that the MPEG prefix isn't MPEG specific. Signed-off-by: Hans Verkuil --- .../bcm2835-camera/bcm2835-camera.c | 4 +- .../bcm2835-camera/bcm2835-camera.h | 4 +- .../vc04_services/bcm2835-camera/controls.c | 126 +++++++++--------- 3 files changed, 67 insertions(+), 67 deletions(-) diff --git a/drivers/staging/vc04_services/bcm2835-camera/bcm2835-camera.c b/drivers/staging/vc04_services/bcm2835-camera/bcm2835-camera.c index df90c1f9d148..528c57811e96 100644 --- a/drivers/staging/vc04_services/bcm2835-camera/bcm2835-camera.c +++ b/drivers/staging/vc04_services/bcm2835-camera/bcm2835-camera.c @@ -1668,8 +1668,8 @@ static int mmal_init(struct bm2835_mmal_dev *dev) dev->capture.fmt = &formats[0]; dev->capture.encode_component = NULL; dev->capture.timeperframe = tpf_default; - dev->capture.enc_profile = V4L2_MPEG_VIDEO_H264_PROFILE_HIGH; - dev->capture.enc_level = V4L2_MPEG_VIDEO_H264_LEVEL_4_0; + dev->capture.enc_profile = V4L2_CODEC_VIDEO_H264_PROFILE_HIGH; + dev->capture.enc_level = V4L2_CODEC_VIDEO_H264_LEVEL_4_0; /* get the preview component ready */ ret = vchiq_mmal_component_init(dev->instance, "ril.video_render", diff --git a/drivers/staging/vc04_services/bcm2835-camera/bcm2835-camera.h b/drivers/staging/vc04_services/bcm2835-camera/bcm2835-camera.h index 75524adff0f5..c7538daa6ebc 100644 --- a/drivers/staging/vc04_services/bcm2835-camera/bcm2835-camera.h +++ b/drivers/staging/vc04_services/bcm2835-camera/bcm2835-camera.h @@ -77,9 +77,9 @@ struct bm2835_mmal_dev { /* H264 bitrate mode. CBR/VBR */ int encode_bitrate_mode; /* H264 profile */ - enum v4l2_mpeg_video_h264_profile enc_profile; + enum v4l2_codec_video_h264_profile enc_profile; /* H264 level */ - enum v4l2_mpeg_video_h264_level enc_level; + enum v4l2_codec_video_h264_level enc_level; /* JPEG Q-factor */ int q_factor; diff --git a/drivers/staging/vc04_services/bcm2835-camera/controls.c b/drivers/staging/vc04_services/bcm2835-camera/controls.c index b096a12387f7..1ac825653c54 100644 --- a/drivers/staging/vc04_services/bcm2835-camera/controls.c +++ b/drivers/staging/vc04_services/bcm2835-camera/controls.c @@ -625,10 +625,10 @@ static int ctrl_set_bitrate_mode(struct bm2835_mmal_dev *dev, dev->capture.encode_bitrate_mode = ctrl->val; switch (ctrl->val) { default: - case V4L2_MPEG_VIDEO_BITRATE_MODE_VBR: + case V4L2_CODEC_VIDEO_BITRATE_MODE_VBR: bitrate_mode = MMAL_VIDEO_RATECONTROL_VARIABLE; break; - case V4L2_MPEG_VIDEO_BITRATE_MODE_CBR: + case V4L2_CODEC_VIDEO_BITRATE_MODE_CBR: bitrate_mode = MMAL_VIDEO_RATECONTROL_CONSTANT; break; } @@ -679,32 +679,32 @@ static int ctrl_set_video_encode_profile_level(struct bm2835_mmal_dev *dev, struct mmal_parameter_video_profile param; int ret = 0; - if (ctrl->id == V4L2_CID_MPEG_VIDEO_H264_PROFILE) { + if (ctrl->id == V4L2_CID_CODEC_VIDEO_H264_PROFILE) { switch (ctrl->val) { - case V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE: - case V4L2_MPEG_VIDEO_H264_PROFILE_CONSTRAINED_BASELINE: - case V4L2_MPEG_VIDEO_H264_PROFILE_MAIN: - case V4L2_MPEG_VIDEO_H264_PROFILE_HIGH: + case V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE: + case V4L2_CODEC_VIDEO_H264_PROFILE_CONSTRAINED_BASELINE: + case V4L2_CODEC_VIDEO_H264_PROFILE_MAIN: + case V4L2_CODEC_VIDEO_H264_PROFILE_HIGH: dev->capture.enc_profile = ctrl->val; break; default: ret = -EINVAL; break; } - } else if (ctrl->id == V4L2_CID_MPEG_VIDEO_H264_LEVEL) { + } else if (ctrl->id == V4L2_CID_CODEC_VIDEO_H264_LEVEL) { switch (ctrl->val) { - case V4L2_MPEG_VIDEO_H264_LEVEL_1_0: - case V4L2_MPEG_VIDEO_H264_LEVEL_1B: - case V4L2_MPEG_VIDEO_H264_LEVEL_1_1: - case V4L2_MPEG_VIDEO_H264_LEVEL_1_2: - case V4L2_MPEG_VIDEO_H264_LEVEL_1_3: - case V4L2_MPEG_VIDEO_H264_LEVEL_2_0: - case V4L2_MPEG_VIDEO_H264_LEVEL_2_1: - case V4L2_MPEG_VIDEO_H264_LEVEL_2_2: - case V4L2_MPEG_VIDEO_H264_LEVEL_3_0: - case V4L2_MPEG_VIDEO_H264_LEVEL_3_1: - case V4L2_MPEG_VIDEO_H264_LEVEL_3_2: - case V4L2_MPEG_VIDEO_H264_LEVEL_4_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_1B: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_2: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_3: + case V4L2_CODEC_VIDEO_H264_LEVEL_2_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_2_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_2_2: + case V4L2_CODEC_VIDEO_H264_LEVEL_3_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_3_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_3_2: + case V4L2_CODEC_VIDEO_H264_LEVEL_4_0: dev->capture.enc_level = ctrl->val; break; default: @@ -715,17 +715,17 @@ static int ctrl_set_video_encode_profile_level(struct bm2835_mmal_dev *dev, if (!ret) { switch (dev->capture.enc_profile) { - case V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE: + case V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE: param.profile = MMAL_VIDEO_PROFILE_H264_BASELINE; break; - case V4L2_MPEG_VIDEO_H264_PROFILE_CONSTRAINED_BASELINE: + case V4L2_CODEC_VIDEO_H264_PROFILE_CONSTRAINED_BASELINE: param.profile = MMAL_VIDEO_PROFILE_H264_CONSTRAINED_BASELINE; break; - case V4L2_MPEG_VIDEO_H264_PROFILE_MAIN: + case V4L2_CODEC_VIDEO_H264_PROFILE_MAIN: param.profile = MMAL_VIDEO_PROFILE_H264_MAIN; break; - case V4L2_MPEG_VIDEO_H264_PROFILE_HIGH: + case V4L2_CODEC_VIDEO_H264_PROFILE_HIGH: param.profile = MMAL_VIDEO_PROFILE_H264_HIGH; break; default: @@ -734,40 +734,40 @@ static int ctrl_set_video_encode_profile_level(struct bm2835_mmal_dev *dev, } switch (dev->capture.enc_level) { - case V4L2_MPEG_VIDEO_H264_LEVEL_1_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_0: param.level = MMAL_VIDEO_LEVEL_H264_1; break; - case V4L2_MPEG_VIDEO_H264_LEVEL_1B: + case V4L2_CODEC_VIDEO_H264_LEVEL_1B: param.level = MMAL_VIDEO_LEVEL_H264_1b; break; - case V4L2_MPEG_VIDEO_H264_LEVEL_1_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_1: param.level = MMAL_VIDEO_LEVEL_H264_11; break; - case V4L2_MPEG_VIDEO_H264_LEVEL_1_2: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_2: param.level = MMAL_VIDEO_LEVEL_H264_12; break; - case V4L2_MPEG_VIDEO_H264_LEVEL_1_3: + case V4L2_CODEC_VIDEO_H264_LEVEL_1_3: param.level = MMAL_VIDEO_LEVEL_H264_13; break; - case V4L2_MPEG_VIDEO_H264_LEVEL_2_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_2_0: param.level = MMAL_VIDEO_LEVEL_H264_2; break; - case V4L2_MPEG_VIDEO_H264_LEVEL_2_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_2_1: param.level = MMAL_VIDEO_LEVEL_H264_21; break; - case V4L2_MPEG_VIDEO_H264_LEVEL_2_2: + case V4L2_CODEC_VIDEO_H264_LEVEL_2_2: param.level = MMAL_VIDEO_LEVEL_H264_22; break; - case V4L2_MPEG_VIDEO_H264_LEVEL_3_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_3_0: param.level = MMAL_VIDEO_LEVEL_H264_3; break; - case V4L2_MPEG_VIDEO_H264_LEVEL_3_1: + case V4L2_CODEC_VIDEO_H264_LEVEL_3_1: param.level = MMAL_VIDEO_LEVEL_H264_31; break; - case V4L2_MPEG_VIDEO_H264_LEVEL_3_2: + case V4L2_CODEC_VIDEO_H264_LEVEL_3_2: param.level = MMAL_VIDEO_LEVEL_H264_32; break; - case V4L2_MPEG_VIDEO_H264_LEVEL_4_0: + case V4L2_CODEC_VIDEO_H264_LEVEL_4_0: param.level = MMAL_VIDEO_LEVEL_H264_4; break; default: @@ -1138,10 +1138,10 @@ static const struct bm2835_mmal_v4l2_ctrl v4l2_ctrls[V4L2_CTRL_COUNT] = { .setter = ctrl_set_flip, }, { - .id = V4L2_CID_MPEG_VIDEO_BITRATE_MODE, + .id = V4L2_CID_CODEC_VIDEO_BITRATE_MODE, .type = MMAL_CONTROL_TYPE_STD_MENU, .min = 0, - .max = V4L2_MPEG_VIDEO_BITRATE_MODE_CBR, + .max = V4L2_CODEC_VIDEO_BITRATE_MODE_CBR, .def = 0, .step = 0, .imenu = NULL, @@ -1149,7 +1149,7 @@ static const struct bm2835_mmal_v4l2_ctrl v4l2_ctrls[V4L2_CTRL_COUNT] = { .setter = ctrl_set_bitrate_mode, }, { - .id = V4L2_CID_MPEG_VIDEO_BITRATE, + .id = V4L2_CID_CODEC_VIDEO_BITRATE, .type = MMAL_CONTROL_TYPE_STD, .min = 25 * 1000, .max = 25 * 1000 * 1000, @@ -1182,7 +1182,7 @@ static const struct bm2835_mmal_v4l2_ctrl v4l2_ctrls[V4L2_CTRL_COUNT] = { .setter = ctrl_set_flicker_avoidance, }, { - .id = V4L2_CID_MPEG_VIDEO_REPEAT_SEQ_HEADER, + .id = V4L2_CID_CODEC_VIDEO_REPEAT_SEQ_HEADER, .type = MMAL_CONTROL_TYPE_STD, .min = 0, .max = 1, @@ -1193,36 +1193,36 @@ static const struct bm2835_mmal_v4l2_ctrl v4l2_ctrls[V4L2_CTRL_COUNT] = { .setter = ctrl_set_video_encode_param_output, }, { - .id = V4L2_CID_MPEG_VIDEO_H264_PROFILE, + .id = V4L2_CID_CODEC_VIDEO_H264_PROFILE, .type = MMAL_CONTROL_TYPE_STD_MENU, - .min = ~(BIT(V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE) | - BIT(V4L2_MPEG_VIDEO_H264_PROFILE_CONSTRAINED_BASELINE) | - BIT(V4L2_MPEG_VIDEO_H264_PROFILE_MAIN) | - BIT(V4L2_MPEG_VIDEO_H264_PROFILE_HIGH)), - .max = V4L2_MPEG_VIDEO_H264_PROFILE_HIGH, - .def = V4L2_MPEG_VIDEO_H264_PROFILE_HIGH, + .min = ~(BIT(V4L2_CODEC_VIDEO_H264_PROFILE_BASELINE) | + BIT(V4L2_CODEC_VIDEO_H264_PROFILE_CONSTRAINED_BASELINE) | + BIT(V4L2_CODEC_VIDEO_H264_PROFILE_MAIN) | + BIT(V4L2_CODEC_VIDEO_H264_PROFILE_HIGH)), + .max = V4L2_CODEC_VIDEO_H264_PROFILE_HIGH, + .def = V4L2_CODEC_VIDEO_H264_PROFILE_HIGH, .step = 1, .imenu = NULL, .mmal_id = MMAL_PARAMETER_PROFILE, .setter = ctrl_set_video_encode_profile_level, }, { - .id = V4L2_CID_MPEG_VIDEO_H264_LEVEL, + .id = V4L2_CID_CODEC_VIDEO_H264_LEVEL, .type = MMAL_CONTROL_TYPE_STD_MENU, - .min = ~(BIT(V4L2_MPEG_VIDEO_H264_LEVEL_1_0) | - BIT(V4L2_MPEG_VIDEO_H264_LEVEL_1B) | - BIT(V4L2_MPEG_VIDEO_H264_LEVEL_1_1) | - BIT(V4L2_MPEG_VIDEO_H264_LEVEL_1_2) | - BIT(V4L2_MPEG_VIDEO_H264_LEVEL_1_3) | - BIT(V4L2_MPEG_VIDEO_H264_LEVEL_2_0) | - BIT(V4L2_MPEG_VIDEO_H264_LEVEL_2_1) | - BIT(V4L2_MPEG_VIDEO_H264_LEVEL_2_2) | - BIT(V4L2_MPEG_VIDEO_H264_LEVEL_3_0) | - BIT(V4L2_MPEG_VIDEO_H264_LEVEL_3_1) | - BIT(V4L2_MPEG_VIDEO_H264_LEVEL_3_2) | - BIT(V4L2_MPEG_VIDEO_H264_LEVEL_4_0)), - .max = V4L2_MPEG_VIDEO_H264_LEVEL_4_0, - .def = V4L2_MPEG_VIDEO_H264_LEVEL_4_0, + .min = ~(BIT(V4L2_CODEC_VIDEO_H264_LEVEL_1_0) | + BIT(V4L2_CODEC_VIDEO_H264_LEVEL_1B) | + BIT(V4L2_CODEC_VIDEO_H264_LEVEL_1_1) | + BIT(V4L2_CODEC_VIDEO_H264_LEVEL_1_2) | + BIT(V4L2_CODEC_VIDEO_H264_LEVEL_1_3) | + BIT(V4L2_CODEC_VIDEO_H264_LEVEL_2_0) | + BIT(V4L2_CODEC_VIDEO_H264_LEVEL_2_1) | + BIT(V4L2_CODEC_VIDEO_H264_LEVEL_2_2) | + BIT(V4L2_CODEC_VIDEO_H264_LEVEL_3_0) | + BIT(V4L2_CODEC_VIDEO_H264_LEVEL_3_1) | + BIT(V4L2_CODEC_VIDEO_H264_LEVEL_3_2) | + BIT(V4L2_CODEC_VIDEO_H264_LEVEL_4_0)), + .max = V4L2_CODEC_VIDEO_H264_LEVEL_4_0, + .def = V4L2_CODEC_VIDEO_H264_LEVEL_4_0, .step = 1, .imenu = NULL, .mmal_id = MMAL_PARAMETER_PROFILE, @@ -1241,7 +1241,7 @@ static const struct bm2835_mmal_v4l2_ctrl v4l2_ctrls[V4L2_CTRL_COUNT] = { .setter = ctrl_set_scene_mode, }, { - .id = V4L2_CID_MPEG_VIDEO_H264_I_PERIOD, + .id = V4L2_CID_CODEC_VIDEO_H264_I_PERIOD, .type = MMAL_CONTROL_TYPE_STD, .min = 0, .max = 0x7FFFFFFF, From patchwork Sat Mar 13 14:43:23 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans Verkuil X-Patchwork-Id: 400252 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-18.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER, INCLUDES_PATCH, MAILING_LIST_MULTI, SPF_HELO_NONE, SPF_PASS, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1BBE2C43619 for ; Sat, 13 Mar 2021 14:44:27 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 0599864F27 for ; Sat, 13 Mar 2021 14:44:27 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234076AbhCMOnx (ORCPT ); Sat, 13 Mar 2021 09:43:53 -0500 Received: from lb1-smtp-cloud9.xs4all.net ([194.109.24.22]:38955 "EHLO lb1-smtp-cloud9.xs4all.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234049AbhCMOnd (ORCPT ); Sat, 13 Mar 2021 09:43:33 -0500 Received: from cust-b5b5937f ([IPv6:fc0c:c16d:66b8:757f:c639:739b:9d66:799d]) by smtp-cloud9.xs4all.net with ESMTPA id L5UBljyoWC40pL5UKlV5gG; Sat, 13 Mar 2021 15:43:32 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=xs4all.nl; s=s2; t=1615646612; bh=rsrtkcUOWdqi6o1JV6lvGU5iGNo+VdAi4yqyPxRzHf4=; h=From:To:Subject:Date:Message-Id:MIME-Version:From:Subject; b=ESf6f/+bCQg80rSHr90XOqi+BDG7RyG1YbdcJQ0q8bWVzpi1d7/YXNtH/Vndt2mh1 PjN4BEOJy/NseclIJmeSUDHGO1Vj22dVGc1Cj47SfLZhb/8o/nIs7AGBrOlRgU4W+b lIGaWBNBo8xC3xXbUmTqvctjAzoseoMwHVChLl7RW62V09fXP27EQGbnAHeAHcS7/L 4oDbsic5Dgxde7sjesplxrW8FXtkmROCVsGG7z+iWs/HFSoO1gN166aItoZyjbdzQF 6cLkUNDDKwPxd4j4oC5MglO9qP/fbYbSkfhDmzfGz+/b+Prq4Ih8C/UWYWb8hJN0f5 b6JZQRkDb+90w== From: Hans Verkuil To: linux-media@vger.kernel.org Cc: Ezequiel Garcia , Nicolas Dufresne , Tomasz Figa , Alexandre Courbot , Hans Verkuil Subject: [PATCH 15/15] v4l2-controls.h: place all MPEG aliases under #ifndef __KERNEL__ Date: Sat, 13 Mar 2021 15:43:23 +0100 Message-Id: <20210313144323.143600-16-hverkuil-cisco@xs4all.nl> X-Mailer: git-send-email 2.30.1 In-Reply-To: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> References: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> MIME-Version: 1.0 X-CMAE-Envelope: MS4xfMsn8vxVIxOwfk1HBWm1Tn7DGMcFBFbrL2w9e7B7pn4zh+SRP2Jqi17Q8et5l39XyCF1q6dYvMVynpi6jD8GJZbtOnePYAy+v8vxRtTsu+FlLMzjey/I 6Yf2reWeEQBe+OBiEXPcSX3xOiLByNfrsU33zfghVRd3mwxeQLH9Gq4GWugIjL4dJLGCBXrWgwo58BS8Sxu/56+i36P9vJr0RkaTCnESq9F/NQlsCuDMX4h3 10pkzvNLw0uYhvnm1xXbFfx1pKTTozHVj9bmvjRoFUvRhpkEKQbLP/gkdVKcDKlCZifRrbV1VJpdbsMQnKHRrjJDCr7QxehVtEcM0E51Kv/9SHktNQQ5z8K1 67fFE2fVamSR0HzbTdI6X+c/qRm4Xw== Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Prevent kernel code from accidentally using the old MPEG aliases by placing them all under #ifndef __KERNEL__. Signed-off-by: Hans Verkuil --- include/uapi/linux/v4l2-controls.h | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/include/uapi/linux/v4l2-controls.h b/include/uapi/linux/v4l2-controls.h index 2e8d450495fa..a70c39f191f4 100644 --- a/include/uapi/linux/v4l2-controls.h +++ b/include/uapi/linux/v4l2-controls.h @@ -1652,16 +1652,10 @@ struct v4l2_ctrl_fwht_params { __u32 quantization; }; -/* MPEG-compression definitions kept for backwards compatibility */ #ifndef __KERNEL__ -#define V4L2_CTRL_CLASS_MPEG V4L2_CTRL_CLASS_CODEC -#define V4L2_CID_MPEG_CLASS V4L2_CID_CODEC_CLASS -#define V4L2_CID_MPEG_BASE V4L2_CID_CODEC_BASE -#define V4L2_CID_MPEG_CX2341X_BASE V4L2_CID_CODEC_CX2341X_BASE -#define V4L2_CID_MPEG_MFC51_BASE V4L2_CID_CODEC_MFC51_BASE -#endif - /* + * MPEG-compression definitions kept for backwards compatibility. + * * Originally all these controls and data structures where all called * MPEG, regardless for which codec they actually applied to. This was * due to historical reasons: the MPEG codec was the first added to V4L2, @@ -1671,6 +1665,13 @@ struct v4l2_ctrl_fwht_params { * Now that MPEG has been replaced with CODEC, we still need to keep * the old names around to avoid breaking the ABI, hence these defines. */ + +#define V4L2_CTRL_CLASS_MPEG V4L2_CTRL_CLASS_CODEC +#define V4L2_CID_MPEG_CLASS V4L2_CID_CODEC_CLASS +#define V4L2_CID_MPEG_BASE V4L2_CID_CODEC_BASE +#define V4L2_CID_MPEG_CX2341X_BASE V4L2_CID_CODEC_CX2341X_BASE +#define V4L2_CID_MPEG_MFC51_BASE V4L2_CID_CODEC_MFC51_BASE + #define v4l2_mpeg_stream_type v4l2_codec_stream_type #define V4L2_MPEG_STREAM_TYPE_MPEG2_PS V4L2_CODEC_STREAM_TYPE_MPEG2_PS #define V4L2_MPEG_STREAM_TYPE_MPEG2_TS V4L2_CODEC_STREAM_TYPE_MPEG2_TS @@ -2230,3 +2231,5 @@ struct v4l2_ctrl_fwht_params { #define v4l2_cid_mpeg_video_hevc_size_of_length_field v4l2_codec_video_hevc_size_of_length_field #endif + +#endif From patchwork Sun Mar 14 08:23:38 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans Verkuil X-Patchwork-Id: 400247 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-17.2 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER, INCLUDES_PATCH, MAILING_LIST_MULTI, SPF_HELO_NONE, SPF_PASS, URIBL_BLOCKED, USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id CEC76C433DB for ; Sun, 14 Mar 2021 08:24:35 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 9013164E13 for ; Sun, 14 Mar 2021 08:24:35 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234831AbhCNIYE (ORCPT ); Sun, 14 Mar 2021 04:24:04 -0400 Received: from lb1-smtp-cloud9.xs4all.net ([194.109.24.22]:53199 "EHLO lb1-smtp-cloud9.xs4all.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234973AbhCNIXn (ORCPT ); Sun, 14 Mar 2021 04:23:43 -0400 Received: from cust-b5b5937f ([IPv6:fc0c:c16d:66b8:757f:c639:739b:9d66:799d]) by smtp-cloud9.xs4all.net with ESMTPA id LM2ElprFUC40pLM2HlXDyg; Sun, 14 Mar 2021 09:23:42 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=xs4all.nl; s=s2; t=1615710222; bh=2WtOOkxT5qZOLcj3QL327sY5LvygJjrDkGAiZv80J1M=; h=Subject:To:From:Message-ID:Date:MIME-Version:Content-Type:From: Subject; b=QffshD4IJILs24d0RgpN3S1lxYiI6ZyxwlJkli3pKuaE0+b+vNEOBsP3O8CKQJ2F3 vYSJWcDdeLhw9xPrivrokX7Ahw4bLHlo/foM7nQRfuTU9kVc9wcYQlniUkZ7RVpzB8 +8C0XJ7WCXDlHoj1mLT/7CSivKxWkzZZFgUJxt61dx6JiPw3QGYKrQ63yuJgIfuyPQ SKcVpoziN9G4VBs3LWBANQBzFq32TGm9OSDoqJDqnyWKaEJ5LTciID7+APA3wiGV9y 6xOnlt0ldINxk0MNDCarDuTA8EeaOJw9bViQWXNRzaz9+CP8g+GkDi4LGtaYRRk5FX MR3VQDkvJrznw== Subject: [PATCH 16/15] ext-ctrls-codec.rst: update note at start of codec section To: linux-media@vger.kernel.org Cc: Ezequiel Garcia , Nicolas Dufresne , Tomasz Figa , Alexandre Courbot References: <20210313144323.143600-1-hverkuil-cisco@xs4all.nl> <20210313144323.143600-16-hverkuil-cisco@xs4all.nl> From: Hans Verkuil Message-ID: Date: Sun, 14 Mar 2021 09:23:38 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Firefox/78.0 Thunderbird/78.7.1 MIME-Version: 1.0 In-Reply-To: <20210313144323.143600-16-hverkuil-cisco@xs4all.nl> Content-Language: en-US X-CMAE-Envelope: MS4xfEeDnXjE2x45TX5OPdibwflTV+u02t4G5n5cdkpn+13jS2+M9e1iIu5a10amsu/vMqTgMRGFyslKPrh8D9EZ5Ozp69tC2bKM9hg3Q5s87++FPg0xC4++ g1XAxi7A7AcpYmBa4k+8aYTNrw9GWERzYDL9izNMwS+FTCGcfcK+I8mCOWsWr2Lk7CpezNykB+AHqyn8JJ2i3KZWUMV28BpQozwwS3A7kNYYcIGYP65lXwwE VO+o1nVYkk+ldICLiTB5LOO0l1Y3Kvw/MoNVSTtsIngqZ/KaCDKOumurH4AWDhwkRB40xNMZXWuucibUorewAQEy5ihNIHidmw95Lc5aCwE= Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org The note at the start of the Codec Control Reference section was changed to explain the prefix naming change. Signed-off-by: Hans Verkuil --- .../userspace-api/media/v4l/ext-ctrls-codec.rst | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst b/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst index 34884a785d76..528b97c989c7 100644 --- a/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst +++ b/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst @@ -11,10 +11,13 @@ the generic controls, then controls specific for certain hardware. .. note:: - These controls are applicable to all codecs and not just MPEG. The - defines are prefixed with V4L2_CID_MPEG/V4L2_MPEG as the controls - were originally made for MPEG codecs and later extended to cover all - encoding formats. + Originally these defines, enum names and struct names were prefixed with + V4L2_CID_MPEG/V4L2_MPEG/v4l2_mpeg instead of + V4L2_CID_CODEC/V4L2_CODEC/v4l2_codec as the codec controls were initially + made for just the MPEG codec and only later extended to cover more codecs. + + The old names are still available to prevent breaking existing code and the + ``v4l2-controls.h`` header redefines them to the new names. Generic Codec Controls