From patchwork Wed Sep 7 06:47:05 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Smitha T Murthy X-Patchwork-Id: 12968494 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id A89A3C38145 for ; Wed, 7 Sep 2022 06:39:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:List-Subscribe:List-Help: List-Post:List-Archive:List-Unsubscribe:List-Id:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=O5Blua84t4RTfDE2ABwz+jTym6HvCzeAkQoS2sMhEvo=; b=vSkyMjeU7KQd5h y65q9oI3WJDZd6UcxX+0TxfrgoC+Pz3J2Q+IDQdzQGHmGfx7x2JnQrxt64PNopuTzyA0Q0tDWKYwI 84z8e0FLSRqzBURk78Q8tde881tfiKZ/aAjgRjnw/H2HE0yjdROrLuTJIjpyyzLYJJYyXN09OUDO6 WS53EPPjVX831NBU/WrPUbqowY8LPs0n8h+/mWIDzmIlDwEyknhS1GaYyusj+xRnVMZa0S+L7FKZl B8dpDJcqfaJ8M/W9kjy5kKyinKV9p3JS1Xz7qcaofZ7QJRL1pYEnXIt9oSki+TGOUWYwD/X+HEOvX sb7YMwzcuBWCsB+5kLoQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1oVohT-003Hfg-Tk; Wed, 07 Sep 2022 06:38:16 +0000 Received: from mailout2.samsung.com ([203.254.224.25]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1oVofb-003Gj0-A6 for linux-arm-kernel@lists.infradead.org; Wed, 07 Sep 2022 06:36:21 +0000 Received: from epcas5p4.samsung.com (unknown [182.195.41.42]) by mailout2.samsung.com (KnoxPortal) with ESMTP id 20220907063613epoutp02c25f9142cf2237cee1dee0a40e54bc98~SgJEuaGgw0553305533epoutp024 for ; Wed, 7 Sep 2022 06:36:13 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout2.samsung.com 20220907063613epoutp02c25f9142cf2237cee1dee0a40e54bc98~SgJEuaGgw0553305533epoutp024 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1662532573; bh=4rKiVK/6Yt3Vra5nARLFQQ/Jb6sJP/fyfKEUXWR6JbM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=PprOqZnN2dJ6sMVEc1Td43usXE5FvdyMi95cBeu7WJF7kE7xvzAaBwmnJup5K41C/ Uj8eDwQVPEdrtTVudHP7RhWajRyc9eO4OYLmdJJ0aQvL7KxwbkC2LDH4irdL4B8gZT 1fvpedMFUq9hJLmLGOKhBhkR76CPo2EHcYYT2PI8= Received: from epsnrtp3.localdomain (unknown [182.195.42.164]) by epcas5p2.samsung.com (KnoxPortal) with ESMTP id 20220907063612epcas5p222bde16ed3bca83cd759d384bdaf6aad~SgJD6dXXT3085930859epcas5p2q; Wed, 7 Sep 2022 06:36:12 +0000 (GMT) Received: from epsmges5p3new.samsung.com (unknown [182.195.38.182]) by epsnrtp3.localdomain (Postfix) with ESMTP id 4MMsw90lbHz4x9Q2; Wed, 7 Sep 2022 06:36:09 +0000 (GMT) Received: from epcas5p1.samsung.com ( [182.195.41.39]) by epsmges5p3new.samsung.com (Symantec Messaging Gateway) with SMTP id 97.80.54060.4DB38136; Wed, 7 Sep 2022 15:36:04 +0900 (KST) Received: from epsmtrp1.samsung.com (unknown [182.195.40.13]) by epcas5p2.samsung.com (KnoxPortal) with ESMTPA id 20220907063332epcas5p2d3c4258885b17c6765658702d833a782~SgGueEPZr0898708987epcas5p2R; Wed, 7 Sep 2022 06:33:32 +0000 (GMT) Received: from epsmgms1p1new.samsung.com (unknown [182.195.42.41]) by epsmtrp1.samsung.com (KnoxPortal) with ESMTP id 20220907063332epsmtrp13cf8a7b0e65db68ae99df0f0b42daac6~SgGubtvgI0507305073epsmtrp13; Wed, 7 Sep 2022 06:33:32 +0000 (GMT) X-AuditID: b6c32a4b-be1ff7000000d32c-b5-63183bd4d5ee Received: from epsmtip1.samsung.com ( [182.195.34.30]) by epsmgms1p1new.samsung.com (Symantec Messaging Gateway) with SMTP id F2.DC.14392.B3B38136; Wed, 7 Sep 2022 15:33:31 +0900 (KST) Received: from Jaguar.sa.corp.samsungelectronics.net (unknown [107.109.115.6]) by epsmtip1.samsung.com (KnoxPortal) with ESMTPA id 20220907063328epsmtip19963bb3f35ef783ebbe8ec25fc279b91~SgGqtqlg32625726257epsmtip1w; Wed, 7 Sep 2022 06:33:27 +0000 (GMT) From: Smitha T Murthy To: linux-arm-kernel@lists.infradead.org, linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org Cc: m.szyprowski@samsung.com, andrzej.hajda@intel.com, mchehab@kernel.org, hverkuil-cisco@xs4all.nl, ezequiel@vanguardiasur.com.ar, jernej.skrabec@gmail.com, benjamin.gaignard@collabora.com, stanimir.varbanov@linaro.org, dillon.minfei@gmail.com, david.plowman@raspberrypi.com, mark.rutland@arm.com, robh+dt@kernel.org, krzk+dt@kernel.org, andi@etezian.org, alim.akhtar@samsung.com, aswani.reddy@samsung.com, pankaj.dubey@samsung.com, linux-fsd@tesla.com, smitha.t@samsung.com, aakarsh.jain@samsung.com Subject: [Patch v2 05/15] Documention: v4l: Documentation for VP9 CIDs. Date: Wed, 7 Sep 2022 12:17:05 +0530 Message-Id: <20220907064715.55778-6-smitha.t@samsung.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20220907064715.55778-1-smitha.t@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA0VTe0xTVxj33Hv7ZLA7hHnonDZdZIEJtErrgcFG5usKTnE+lswMrOWmEPpa HwxcFnkHGl5uNQsglADbHKJjPCugvGpAZ4h1jP4xikxkiAJTHkZwkfWB23+/7/s9vpzvnMPG fSeYPHaKSk9rVVKFgMkl2geC3g0ZeR/KhLM1fDRlKWegiep2Jqp7Po2he3WLBOpvaWOh1pFK HP042MtAZuswA3X03SfQLw+drK3cQaBp8xWAZirGmah5cpSB/nz0Kfqt8wITFTW1MdBlq4OF vrfbMPRD8z8Yqm1bYqG8a1YWcnS3A5Sbb8ViINVY3Qgoi6MeUPb6BZy6WuFgUXXdMxjV3FDI pMZGu5lUS/1ZKu/GKkGVtDYA6mV2FYsyWu1MarF5C3VreZEV7/NZalQyLU2itXxaJVMnpajk 0YK4o4m7E8USoShEFIF2CfgqqZKOFuw5GB+yL0XhXIOAnyZVGJyteKlOJwj7IEqrNuhpfrJa p48W0JokhSZcE6qTKnUGlTxUResjRULhDrFTeCo12TrfxNKMh6XbV/IZmaAr0AjYbEiGw+LW VCPgsn3JLgDXyky4p1gA0Fg6ADzFMwBN9T1MI+C4HUsl5nXiGoD5S7WYp8jBYEF+Ie5SMcnt 8Nnfv7odfmQWgJMFepcIJ3MI6Lj9guUiNpL74cqajXBhgtwGx81/ubE3GQG78oZZnnFb4aWm Xncoh4yENtMQwxUEyRwONGVdZnlOsQcOD/l69Bvho8HWdS8PzpTmr2M5vLeYAzxYA6syWzEP /hD2jlwgXDE4GQR/7gzztN+G529dcUtw0gcWv3iwLveGlupXWABrbw+tx0P4+1wbw4MpOPdg jeFZSjGA9uFSvAxsqfh/RA0ADSCA1uiUclon1uxU0V/+d2sytbIZuJ96cJwF3J94EtoPMDbo B5CNC/y8kyx+Ml/vJGn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mSJPDwjXMocD5WLJfIsaXJoYrrECGafF7yiEdzTjYZa AMYBFgA5LJGQn9QoTBTwk8QnTzGy9ARZVhojtwB/Di7y5b9QtScIqGRxJpPKMBmM7L/FONwF uVhM9Y7ovF/fH0TZI7009VkuNfvg1/Iml2fEGKGdfD71ObLaYB6Nu7UlZ3jMN39EudERVdB5 pbekcklO5SUv58e01gsT7dE9OkMoV7/5x8fFXbGbfKIoD2nT0vIly7dVfJaYs+O2H/dwZhfH n5imkiY2jmbra0T3r/lqCg48KBpw6ge1fSZZQEzuxWMxD9XqDbHh5QXTJvtL29sDyzLb4oK6 T4s6vAekQuXvH/Y3+btcQf0eTt5In5K6nq+wzJuvEqrXFLbs3FMGfHriDg36oy+TIIqvvOvh 8tE/TLEcjcjBDoed3d1fm+9nToCfXscvtL4J0KbOnNwfWRHSHuMTYhTh8iPi8GCWTC7+A0Ed 5wErAwAA X-CMS-MailID: 20220907063332epcas5p2d3c4258885b17c6765658702d833a782 X-Msg-Generator: CA X-Sendblock-Type: REQ_APPROVE CMS-TYPE: 105P DLP-Filter: Pass X-CFilter-Loop: Reflected X-CMS-RootMailID: 20220907063332epcas5p2d3c4258885b17c6765658702d833a782 References: <20220907064715.55778-1-smitha.t@samsung.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220906_233619_772761_BB81BB0B X-CRM114-Status: GOOD ( 16.22 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Adds V4l2 controls for VP9 encoder documention. Cc: linux-fsd@tesla.com Signed-off-by: Smitha T Murthy --- .../media/v4l/ext-ctrls-codec.rst | 167 ++++++++++++++++++ 1 file changed, 167 insertions(+) diff --git a/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst b/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst index 2a165ae063fb..2277d83a7cf0 100644 --- a/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst +++ b/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst @@ -2187,6 +2187,16 @@ enum v4l2_mpeg_video_vp8_profile - * - ``V4L2_MPEG_VIDEO_VP8_PROFILE_3`` - Profile 3 +VP9 Control Reference +--------------------- + +The VP9 controls include controls for encoding parameters of VP9 video +codec. + +.. _vp9-control-id: + +VP9 Control IDs + .. _v4l2-mpeg-video-vp9-profile: ``V4L2_CID_MPEG_VIDEO_VP9_PROFILE`` @@ -2253,6 +2263,163 @@ enum v4l2_mpeg_video_vp9_level - * - ``V4L2_MPEG_VIDEO_VP9_LEVEL_6_2`` - Level 6.2 +``V4L2_CID_CODEC_VP9_I_FRAME_QP`` + Quantization parameter for an I frame for VP9. Valid range: from 1 to 255. + +``V4L2_CID_CODEC_VP9_P_FRAME_QP`` + Quantization parameter for an P frame for VP9. Valid range: from 1 to 255. + +``V4L2_CID_CODEC_VP9_MAX_QP`` + Maximum quantization parameter for VP9. Valid range: from 1 to 255. + Recommended range for MFC is from 230 to 255. + +``V4L2_CID_CODEC_VP9_MIN_QP`` + Minimum quantization parameter for VP9. Valid range: from 1 to 255. + Recommended range for MFC is from 1 to 24. + +``V4L2_CID_CODEC_VP9_RC_FRAME_RATE`` + 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_CID_CODEC_VP9_GF_REFRESH_PERIOD`` + Indicates the refresh period of the golden frame for VP9 encoder. + +.. _v4l2-vp9-golden-frame-sel: + +``V4L2_CID_CODEC_VP9_GOLDEN_FRAMESEL`` + (enum) + +enum v4l2_mpeg_vp9_golden_framesel - + Selects the golden frame for encoding. Valid when NUM_OF_REF is 2. + Possible values are: + +.. raw:: latex + + \footnotesize + +.. tabularcolumns:: |p{9.0cm}|p{8.0cm}| + +.. flat-table:: + :header-rows: 0 + :stub-columns: 0 + + * - ``V4L2_CID_CODEC_VP9_GOLDEN_FRAME_USE_PREV`` + - Use the (n-2)th frame as a golden frame, current frame index being + 'n'. + * - ``V4L2_CID_CODEC_VP9_GOLDEN_FRAME_USE_REF_PERIOD`` + - Use the previous specific frame indicated by + ``V4L2_CID_CODEC_VP9_GF_REFRESH_PERIOD`` as a + golden frame. + +.. raw:: latex + + \normalsize + + +``V4L2_CID_CODEC_VP9_HIERARCHY_QP_ENABLE`` + Allows 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 control + value to 1 enables setting of the QP values for the layers. + +.. _v4l2-vp9-ref-number-of-pframes: + +``V4L2_CID_CODEC_VP9_REF_NUMBER_FOR_PFRAMES`` + (enum) + +enum v4l2_mpeg_vp9_ref_num_for_pframes - + Number of reference pictures for encoding P frames. + +.. raw:: latex + + \footnotesize + +.. tabularcolumns:: |p{9.0cm}|p{8.0cm}| + +.. flat-table:: + :header-rows: 0 + :stub-columns: 0 + + * - ``V4L2_CID_CODEC_VP9_1_REF_PFRAME`` + - Indicates one reference frame, last encoded frame will be searched. + * - ``V4L2_CID_CODEC_VP9_GOLDEN_FRAME_USE_REF_PERIOD`` + - Indicates 2 reference frames, last encoded frame and golden frame + will be searched. + +.. raw:: latex + + \normalsize + + +``V4L2_CID_CODEC_VP9_HIERARCHICAL_CODING_LAYER`` + Indicates the number of hierarchial coding layer. + In normal encoding (non-hierarchial coding), it should be zero. + VP9 has upto 3 layer of encoder. + +``V4L2_CID_CODEC_VP9_HIERARCHY_RC_ENABLE`` + Indicates enabling of bit rate for hierarchical coding layers VP9 encoder. + +``V4L2_CID_CODEC_VP9_HIER_CODING_L0_BR`` + Indicates bit rate for hierarchical coding layer 0 for VP9 encoder. + +``V4L2_CID_CODEC_VP9_HIER_CODING_L1_BR`` + Indicates bit rate for hierarchical coding layer 1 for VP9 encoder. + +``V4L2_CID_CODEC_VP9_HIER_CODING_L2_BR`` + Indicates bit rate for hierarchical coding layer 2 for VP9 encoder. + +``V4L2_CID_CODEC_VP9_HIER_CODING_L0_QP`` + Indicates quantization parameter for hierarchical coding layer 0. + Valid range: [V4L2_CID_CODEC_VP9_MIN_QP, + V4L2_CID_CODEC_VP9_MAX_QP]. + +``V4L2_CID_CODEC_VP9_HIER_CODING_L1_QP`` + Indicates quantization parameter for hierarchical coding layer 1. + Valid range: [V4L2_CID_CODEC_VP9_MIN_QP, + V4L2_CID_CODEC_VP9_MAX_QP]. + +``V4L2_CID_CODEC_VP9_HIER_CODING_L2_QP`` + Indicates quantization parameter for hierarchical coding layer 2. + Valid range: [V4L2_CID_CODEC_VP9_MIN_QP, + V4L2_CID_CODEC_VP9_MAX_QP]. + +.. _v4l2-vp9-max-partition-depth: + +``V4L2_CID_CODEC_VP9_MAX_PARTITION_DEPTH`` + (enum) + +enum v4l2_mpeg_vp9_num_partitions - + Indicate maximum coding unit depth. + +.. raw:: latex + + \footnotesize + +.. tabularcolumns:: |p{9.0cm}|p{8.0cm}| + +.. flat-table:: + :header-rows: 0 + :stub-columns: 0 + + * - ``V4L2_CID_CODEC_VP9_0_PARTITION`` + - No coding unit partition depth. + * - ``V4L2_CID_CODEC_VP9_1_PARTITION`` + - Allows one coding unit partition depth. + +.. raw:: latex + + \normalsize + + +``V4L2_CID_CODEC_VP9_DISABLE_INTRA_PU_SPLIT`` + Zero indicates enable intra NxN PU split. + One indicates disable intra NxN PU split. + +``V4L2_CID_CODEC_VP9_DISABLE_IVF_HEADER`` + Indicates IVF header generation. Zero indicates enable IVF format. + One indicates disable IVF format. + High Efficiency Video Coding (HEVC/H.265) Control Reference ===========================================================