All of lore.kernel.org
 help / color / mirror / Atom feed
From: Hans Verkuil <hverkuil@xs4all.nl>
To: Smitha T Murthy <smitha.t@samsung.com>,
	linux-arm-kernel@lists.infradead.org,
	linux-media@vger.kernel.org, linux-kernel@vger.kernel.org
Cc: kyungmin.park@samsung.com, kamil@wypas.org, jtp.park@samsung.com,
	a.hajda@samsung.com, mchehab@kernel.org,
	pankaj.dubey@samsung.com, krzk@kernel.org,
	m.szyprowski@samsung.com, s.nawrocki@samsung.com
Subject: Re: [Patch v7 12/12] Documention: v4l: Documentation for HEVC CIDs
Date: Wed, 24 Jan 2018 15:16:40 +0100	[thread overview]
Message-ID: <127cfd7f-113f-6724-297c-6f3c3746a8ff@xs4all.nl> (raw)
In-Reply-To: <1516791584-7980-13-git-send-email-smitha.t@samsung.com>

On 24/01/18 11:59, Smitha T Murthy wrote:
> Added V4l2 controls for HEVC encoder
> 
> Signed-off-by: Smitha T Murthy <smitha.t@samsung.com>
> ---
>  Documentation/media/uapi/v4l/extended-controls.rst | 400 +++++++++++++++++++++
>  1 file changed, 400 insertions(+)
> 
> diff --git a/Documentation/media/uapi/v4l/extended-controls.rst b/Documentation/media/uapi/v4l/extended-controls.rst
> index dfe49ae..46ee2bf 100644
> --- a/Documentation/media/uapi/v4l/extended-controls.rst
> +++ b/Documentation/media/uapi/v4l/extended-controls.rst
> @@ -1960,6 +1960,406 @@ enum v4l2_vp8_golden_frame_sel -
>      1, 2 and 3 corresponding to encoder profiles 0, 1, 2 and 3.
>  
>  
> +High Efficiency Video Coding (HEVC/H.265) Control Reference
> +-----------------------------------------------------------
> +
> +The HEVC/H.265 controls include controls for encoding parameters of HEVC/H.265
> +video codec.
> +
> +
> +.. _hevc-control-id:
> +
> +HEVC/H.265 Control IDs
> +^^^^^^^^^^^^^^^^^^^^^^
> +
> +``V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP (integer)``
> +    Minimum quantization parameter for HEVC.
> +    Valid range: from 0 to 51.
> +
> +``V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP (integer)``
> +    Maximum quantization parameter for HEVC.
> +    Valid range: from 0 to 51.

You probably should mention the default values for MIN_QP and MAX_QP
(I assume those are 0 and 51 and are not driver specific).

> +
> +``V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_QP (integer)``
> +    Quantization parameter for an I frame for HEVC.
> +    Valid range: from 0 to 51.
> +
> +``V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_QP (integer)``
> +    Quantization parameter for a P frame for HEVC.
> +    Valid range: from 0 to 51.
> +
> +``V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_QP (integer)``
> +    Quantization parameter for a B frame for HEVC.
> +    Valid range: from 0 to 51.

Sorry, this still isn't clear to me.

If I set V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP to 50, can I then still set
V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_QP to 51? Or is 50 then the maximum?

In other words, what is the relationship between these three controls
and the MIN_QP/MAX_QP controls.

> +
> +``V4L2_CID_MPEG_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
> +    control value to 1 enables setting of the QP values for the layers.
> +
> +.. _v4l2-hevc-hier-coding-type:
> +
> +``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_TYPE``
> +    (enum)
> +
> +enum v4l2_mpeg_video_hevc_hier_coding_type -
> +    Selects the hierarchical coding type for encoding. Possible values are:
> +
> +.. raw:: latex
> +
> +    \begin{adjustbox}{width=\columnwidth}
> +
> +.. tabularcolumns:: |p{11.0cm}|p{10.0cm}|
> +
> +.. flat-table::
> +    :header-rows:  0
> +    :stub-columns: 0
> +
> +    * - ``V4L2_MPEG_VIDEO_HEVC_HIERARCHICAL_CODING_B``
> +      - Use the B frame for hierarchical coding.
> +    * - ``V4L2_MPEG_VIDEO_HEVC_HIERARCHICAL_CODING_P``
> +      - Use the P frame for hierarchical coding.
> +
> +.. raw:: latex
> +
> +    \end{adjustbox}
> +
> +
> +``V4L2_CID_MPEG_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)``
> +    Indicates quantization parameter for hierarchical coding layer 0.
> +    For HEVC it can have a value of 0-51.
> +
> +``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L1_QP (integer)``
> +    Indicates quantization parameter for hierarchical coding layer 1.
> +    For HEVC it can have a value of 0-51.
> +
> +``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L2_QP (integer)``
> +    Indicates quantization parameter for hierarchical coding layer 2.
> +    For HEVC it can have a value of 0-51.
> +
> +``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L3_QP (integer)``
> +    Indicates quantization parameter for hierarchical coding layer 3.
> +    For HEVC it can have a value of 0-51.
> +
> +``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L4_QP (integer)``
> +    Indicates quantization parameter for hierarchical coding layer 4.
> +    For HEVC it can have a value of 0-51.
> +
> +``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L5_QP (integer)``
> +    Indicates quantization parameter for hierarchical coding layer 5.
> +    For HEVC it can have a value of 0-51.
> +
> +``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L6_QP (integer)``
> +    Indicates quantization parameter for hierarchical coding layer 6.
> +    For HEVC it can have a value of 0-51.

Same here: how does MIN_QP/MAX_QP influence these controls, if at all.

Regards,

	Hans

WARNING: multiple messages have this Message-ID (diff)
From: hverkuil@xs4all.nl (Hans Verkuil)
To: linux-arm-kernel@lists.infradead.org
Subject: [Patch v7 12/12] Documention: v4l: Documentation for HEVC CIDs
Date: Wed, 24 Jan 2018 15:16:40 +0100	[thread overview]
Message-ID: <127cfd7f-113f-6724-297c-6f3c3746a8ff@xs4all.nl> (raw)
In-Reply-To: <1516791584-7980-13-git-send-email-smitha.t@samsung.com>

On 24/01/18 11:59, Smitha T Murthy wrote:
> Added V4l2 controls for HEVC encoder
> 
> Signed-off-by: Smitha T Murthy <smitha.t@samsung.com>
> ---
>  Documentation/media/uapi/v4l/extended-controls.rst | 400 +++++++++++++++++++++
>  1 file changed, 400 insertions(+)
> 
> diff --git a/Documentation/media/uapi/v4l/extended-controls.rst b/Documentation/media/uapi/v4l/extended-controls.rst
> index dfe49ae..46ee2bf 100644
> --- a/Documentation/media/uapi/v4l/extended-controls.rst
> +++ b/Documentation/media/uapi/v4l/extended-controls.rst
> @@ -1960,6 +1960,406 @@ enum v4l2_vp8_golden_frame_sel -
>      1, 2 and 3 corresponding to encoder profiles 0, 1, 2 and 3.
>  
>  
> +High Efficiency Video Coding (HEVC/H.265) Control Reference
> +-----------------------------------------------------------
> +
> +The HEVC/H.265 controls include controls for encoding parameters of HEVC/H.265
> +video codec.
> +
> +
> +.. _hevc-control-id:
> +
> +HEVC/H.265 Control IDs
> +^^^^^^^^^^^^^^^^^^^^^^
> +
> +``V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP (integer)``
> +    Minimum quantization parameter for HEVC.
> +    Valid range: from 0 to 51.
> +
> +``V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP (integer)``
> +    Maximum quantization parameter for HEVC.
> +    Valid range: from 0 to 51.

You probably should mention the default values for MIN_QP and MAX_QP
(I assume those are 0 and 51 and are not driver specific).

> +
> +``V4L2_CID_MPEG_VIDEO_HEVC_I_FRAME_QP (integer)``
> +    Quantization parameter for an I frame for HEVC.
> +    Valid range: from 0 to 51.
> +
> +``V4L2_CID_MPEG_VIDEO_HEVC_P_FRAME_QP (integer)``
> +    Quantization parameter for a P frame for HEVC.
> +    Valid range: from 0 to 51.
> +
> +``V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_QP (integer)``
> +    Quantization parameter for a B frame for HEVC.
> +    Valid range: from 0 to 51.

Sorry, this still isn't clear to me.

If I set V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP to 50, can I then still set
V4L2_CID_MPEG_VIDEO_HEVC_B_FRAME_QP to 51? Or is 50 then the maximum?

In other words, what is the relationship between these three controls
and the MIN_QP/MAX_QP controls.

> +
> +``V4L2_CID_MPEG_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
> +    control value to 1 enables setting of the QP values for the layers.
> +
> +.. _v4l2-hevc-hier-coding-type:
> +
> +``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_TYPE``
> +    (enum)
> +
> +enum v4l2_mpeg_video_hevc_hier_coding_type -
> +    Selects the hierarchical coding type for encoding. Possible values are:
> +
> +.. raw:: latex
> +
> +    \begin{adjustbox}{width=\columnwidth}
> +
> +.. tabularcolumns:: |p{11.0cm}|p{10.0cm}|
> +
> +.. flat-table::
> +    :header-rows:  0
> +    :stub-columns: 0
> +
> +    * - ``V4L2_MPEG_VIDEO_HEVC_HIERARCHICAL_CODING_B``
> +      - Use the B frame for hierarchical coding.
> +    * - ``V4L2_MPEG_VIDEO_HEVC_HIERARCHICAL_CODING_P``
> +      - Use the P frame for hierarchical coding.
> +
> +.. raw:: latex
> +
> +    \end{adjustbox}
> +
> +
> +``V4L2_CID_MPEG_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)``
> +    Indicates quantization parameter for hierarchical coding layer 0.
> +    For HEVC it can have a value of 0-51.
> +
> +``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L1_QP (integer)``
> +    Indicates quantization parameter for hierarchical coding layer 1.
> +    For HEVC it can have a value of 0-51.
> +
> +``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L2_QP (integer)``
> +    Indicates quantization parameter for hierarchical coding layer 2.
> +    For HEVC it can have a value of 0-51.
> +
> +``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L3_QP (integer)``
> +    Indicates quantization parameter for hierarchical coding layer 3.
> +    For HEVC it can have a value of 0-51.
> +
> +``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L4_QP (integer)``
> +    Indicates quantization parameter for hierarchical coding layer 4.
> +    For HEVC it can have a value of 0-51.
> +
> +``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L5_QP (integer)``
> +    Indicates quantization parameter for hierarchical coding layer 5.
> +    For HEVC it can have a value of 0-51.
> +
> +``V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L6_QP (integer)``
> +    Indicates quantization parameter for hierarchical coding layer 6.
> +    For HEVC it can have a value of 0-51.

Same here: how does MIN_QP/MAX_QP influence these controls, if at all.

Regards,

	Hans

  reply	other threads:[~2018-01-24 14:16 UTC|newest]

Thread overview: 41+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CGME20180124112324epcas2p246e0983b55ae9d6923b537cb34d7346f@epcas2p2.samsung.com>
2018-01-24 10:59 ` [Patch v7 00/12] Add MFC v10.10 support Smitha T Murthy
2018-01-24 10:59   ` Smitha T Murthy
     [not found]   ` <CGME20180124112327epcas2p361633d6729ddef97cef1388701024f5b@epcas2p3.samsung.com>
2018-01-24 10:59     ` [Patch v7 01/12] [media] s5p-mfc: Rename IS_MFCV8 macro Smitha T Murthy
2018-01-24 10:59       ` Smitha T Murthy
     [not found]   ` <CGME20180124112330epcas1p3aae1b9cb2a301cc25e41356c3ce73dd3@epcas1p3.samsung.com>
2018-01-24 10:59     ` [Patch v7 02/12] [media] s5p-mfc: Adding initial support for MFC v10.10 Smitha T Murthy
2018-01-24 10:59       ` Smitha T Murthy
2018-01-24 10:59       ` Smitha T Murthy
     [not found]   ` <CGME20180124112332epcas2p1dbc1ec3e76a21193c6524e614a448092@epcas2p1.samsung.com>
2018-01-24 10:59     ` [Patch v7 03/12] [media] s5p-mfc: Use min scratch buffer size as provided by F/W Smitha T Murthy
2018-01-24 10:59       ` Smitha T Murthy
     [not found]   ` <CGME20180124112335epcas1p3545e2c08141f593d6056b91c7a4ee92e@epcas1p3.samsung.com>
2018-01-24 10:59     ` [Patch v7 04/12] [media] s5p-mfc: Support MFCv10.10 buffer requirements Smitha T Murthy
2018-01-24 10:59       ` Smitha T Murthy
     [not found]   ` <CGME20180124112337epcas1p492f7efc58b30253a881eae3d991d72b1@epcas1p4.samsung.com>
2018-01-24 10:59     ` [Patch v7 05/12] [media] videodev2.h: Add v4l2 definition for HEVC Smitha T Murthy
2018-01-24 10:59       ` Smitha T Murthy
     [not found]   ` <CGME20180124112340epcas2p4051efc01bcc004b78ef4f5a9cd810303@epcas2p4.samsung.com>
2018-01-24 10:59     ` [Patch v7 06/12] [media] v4l2-ioctl: add HEVC format description Smitha T Murthy
2018-01-24 10:59       ` Smitha T Murthy
     [not found]   ` <CGME20180124112342epcas1p151c1c463c0d31efc6d15da38172ed01d@epcas1p1.samsung.com>
2018-01-24 10:59     ` [Patch v7 07/12] Documentation: v4l: Documentation for HEVC v4l2 definition Smitha T Murthy
2018-01-24 10:59       ` Smitha T Murthy
     [not found]   ` <CGME20180124112346epcas2p39eec7e548f87fe5db5f48c547704a10d@epcas2p3.samsung.com>
2018-01-24 10:59     ` [Patch v7 08/12] [media] s5p-mfc: Add support for HEVC decoder Smitha T Murthy
2018-01-24 10:59       ` Smitha T Murthy
     [not found]   ` <CGME20180124112351epcas2p2e111be35495863530b11043b3fccd795@epcas2p2.samsung.com>
2018-01-24 10:59     ` [Patch v7 09/12] [media] s5p-mfc: Add VP9 decoder support Smitha T Murthy
2018-01-24 10:59       ` Smitha T Murthy
     [not found]   ` <CGME20180124112356epcas1p241c27446e9646b457fea474fdd5a9c6e@epcas1p2.samsung.com>
2018-01-24 10:59     ` [Patch v7 10/12] [media] v4l2: Add v4l2 control IDs for HEVC encoder Smitha T Murthy
2018-01-24 10:59       ` Smitha T Murthy
2018-01-24 14:06       ` Hans Verkuil
2018-01-24 14:06         ` Hans Verkuil
     [not found]   ` <CGME20180124112401epcas2p438e89e9c1914aa421ade444c479540ba@epcas2p4.samsung.com>
2018-01-24 10:59     ` [Patch v7 11/12] [media] s5p-mfc: Add support " Smitha T Murthy
2018-01-24 10:59       ` Smitha T Murthy
     [not found]   ` <CGME20180124112406epcas2p3820cea581731825c7ad72ebbb1ca060c@epcas2p3.samsung.com>
2018-01-24 10:59     ` [Patch v7 12/12] Documention: v4l: Documentation for HEVC CIDs Smitha T Murthy
2018-01-24 10:59       ` Smitha T Murthy
2018-01-24 14:16       ` Hans Verkuil [this message]
2018-01-24 14:16         ` Hans Verkuil
2018-01-29 12:42         ` Smitha T Murthy
2018-01-29 12:42           ` Smitha T Murthy
2018-01-29 13:27           ` Hans Verkuil
2018-01-29 13:27             ` Hans Verkuil
2018-01-29 13:13             ` Smitha T Murthy
2018-01-29 13:13               ` Smitha T Murthy
2018-01-29 13:15             ` Smitha T Murthy
2018-01-29 13:15               ` Smitha T Murthy
2018-01-29 13:39               ` Hans Verkuil
2018-01-29 13:39                 ` Hans Verkuil

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=127cfd7f-113f-6724-297c-6f3c3746a8ff@xs4all.nl \
    --to=hverkuil@xs4all.nl \
    --cc=a.hajda@samsung.com \
    --cc=jtp.park@samsung.com \
    --cc=kamil@wypas.org \
    --cc=krzk@kernel.org \
    --cc=kyungmin.park@samsung.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=m.szyprowski@samsung.com \
    --cc=mchehab@kernel.org \
    --cc=pankaj.dubey@samsung.com \
    --cc=s.nawrocki@samsung.com \
    --cc=smitha.t@samsung.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.