linux-media.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Tomasz Figa <tfiga@chromium.org>
To: Nicolas Dufresne <nicolas.dufresne@collabora.com>
Cc: Philipp Zabel <p.zabel@pengutronix.de>,
	Linux Media Mailing List <linux-media@vger.kernel.org>,
	Hans Verkuil <hverkuil@xs4all.nl>,
	Ezequiel Garcia <ezequiel@collabora.com>,
	Jonas Karlman <jonas@kwiboo.se>,
	Paul Kocialkowski <paul.kocialkowski@bootlin.com>,
	Boris Brezillon <boris.brezillon@collabora.com>,
	Sasha Hauer <kernel@pengutronix.de>
Subject: Re: [PATCH 1/2] media: uapi: h264: Add num_ref_idx_active_override_flag
Date: Mon, 9 Sep 2019 16:09:27 +0900	[thread overview]
Message-ID: <CAAFQd5Dv3VhybM5qZHQCBgRQmpLrS1Pi1rmwRnt59q9mRUUTjw@mail.gmail.com> (raw)
In-Reply-To: <cb118783713af210b3ac8a87d00b62dc83cc9c08.camel@collabora.com>

On Thu, Sep 5, 2019 at 11:17 PM Nicolas Dufresne
<nicolas.dufresne@collabora.com> wrote:
>
> Le jeudi 05 septembre 2019 à 12:39 +0200, Philipp Zabel a écrit :
> > On Thu, 2019-09-05 at 19:31 +0900, Tomasz Figa wrote:
> > > On Thu, Sep 5, 2019 at 7:15 PM Philipp Zabel <p.zabel@pengutronix.de> wrote:
> > > > This flag tells the kernel whether the slice header contained the
> > > > num_ref_idx_l[01]_active_minus1 syntax elements, or whether the
> > > > num_ref_idx_l[01]_default_active_minus1 from PPS should be used
> > > > instead.
> > > >
> > > > Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
> > > > ---
> > > >  Documentation/media/uapi/v4l/ext-ctrls-codec.rst | 3 +++
> > > >  include/media/h264-ctrls.h                       | 1 +
> > > >  2 files changed, 4 insertions(+)
> > > >
> > > > diff --git a/Documentation/media/uapi/v4l/ext-ctrls-codec.rst b/Documentation/media/uapi/v4l/ext-ctrls-codec.rst
> > > > index bc5dd8e76567..451a5b0f2a35 100644
> > > > --- a/Documentation/media/uapi/v4l/ext-ctrls-codec.rst
> > > > +++ b/Documentation/media/uapi/v4l/ext-ctrls-codec.rst
> > > > @@ -1860,6 +1860,9 @@ enum v4l2_mpeg_video_h264_hierarchical_coding_type -
> > > >      * - ``V4L2_H264_SLICE_FLAG_SP_FOR_SWITCH``
> > > >        - 0x00000008
> > > >        -
> > > > +    * - ``V4L2_H264_SLICE_FLAG_NUM_REF_IDX_ACTIVE_OVERRIDE
> > > > +      - 0x00000010
> > > > +      - Corresponds to the num_ref_idx_active_override_flag syntax element.
> > > >
> > >
> > > As far as I remember, the idea was for the userspace to always put the
> > > right num_ref_idx in the slice_params and the drivers always use that.
> > > Was there any problem with that?
> >
> > I don't think so, at least for currently known hardware.
> >
> > In that case we should drop the unused
> > num_ref_idx_l[01]_default_active_minus1 fields from struct
> > v4l2_ctrl_h264_pps and document that userspace should fill
> > the defaults into v4l2_ctrl_h264_slice_params themselves if
> > num_ref_idx_active_override_flag wasn't set.
>
> It might have been added in a previous effort to allow reconstructing
> the bitstream from the structures.

Wouldn't one still be able to reconstruct a valid (but not exact)
stream without that flag, given the assumption above?

Best regards,
Tomasz

  reply	other threads:[~2019-09-09  7:09 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-09-05 10:15 [PATCH 1/2] media: uapi: h264: Add num_ref_idx_active_override_flag Philipp Zabel
2019-09-05 10:15 ` [PATCH 2/2] media: hantro: h264: per-slice num_ref_idx_l[01]_active override Philipp Zabel
2019-09-05 10:34   ` Tomasz Figa
2019-09-05 11:04     ` Philipp Zabel
2019-09-05 10:31 ` [PATCH 1/2] media: uapi: h264: Add num_ref_idx_active_override_flag Tomasz Figa
2019-09-05 10:39   ` Philipp Zabel
2019-09-05 14:17     ` Nicolas Dufresne
2019-09-09  7:09       ` Tomasz Figa [this message]
2019-09-09  7:30         ` Philipp Zabel
2019-09-09  9:40           ` Tomasz Figa
2019-10-03 21:06             ` Paul Kocialkowski
2019-10-03 21:07 ` Paul Kocialkowski

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=CAAFQd5Dv3VhybM5qZHQCBgRQmpLrS1Pi1rmwRnt59q9mRUUTjw@mail.gmail.com \
    --to=tfiga@chromium.org \
    --cc=boris.brezillon@collabora.com \
    --cc=ezequiel@collabora.com \
    --cc=hverkuil@xs4all.nl \
    --cc=jonas@kwiboo.se \
    --cc=kernel@pengutronix.de \
    --cc=linux-media@vger.kernel.org \
    --cc=nicolas.dufresne@collabora.com \
    --cc=p.zabel@pengutronix.de \
    --cc=paul.kocialkowski@bootlin.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).