Re: [PATCH 1/2] media: uapi: h264: Add num_ref_idx_active_override_flag

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Sep 5, 2019 at 11:17 PM Nicolas Dufresne
<nicolas.dufresne@xxxxxxxxxxxxx> 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@xxxxxxxxxxxxxx> 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@xxxxxxxxxxxxxx>
> > > > ---
> > > >  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




[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]

  Powered by Linux