[FFmpeg-devel] [PATCH 07/13] avformat/mxfenc: Add vertical subsampling support
Michael Niedermayer
michael at niedermayer.cc
Tue May 8 20:00:50 EEST 2018
On Tue, May 08, 2018 at 12:45:18PM +0200, Tomas Härdin wrote:
> mån 2018-05-07 klockan 12:38 +0200 skrev Michael Niedermayer:
> > > Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
> >
> > @@ -1149,6 +1151,8 @@ static void mxf_write_cdci_common(AVFormatContext *s, AVStream *st, const UID ke
> > desc_size += 5;
> > if (sc->interlaced)
> > desc_size += 8;
> > + if (sc->v_chroma_sub_sample)
> > + desc_size += 8;
> >
> > mxf_write_generic_desc(s, st, key, desc_size);
> >
> > @@ -1209,6 +1213,12 @@ static void mxf_write_cdci_common(AVFormatContext *s, AVStream *st, const UID ke
> > mxf_write_local_tag(pb, 4, 0x3302);
> > avio_wb32(pb, sc->h_chroma_sub_sample);
> >
> > + // vertical subsampling
> > + if (sc->v_chroma_sub_sample) {
> > + mxf_write_local_tag(pb, 4, 0x3308);
> > + avio_wb32(pb, sc->v_chroma_sub_sample);
> > + }
> > +
> > // color siting
> > mxf_write_local_tag(pb, 1, 0x3303);
> > avio_w8(pb, sc->color_siting);
> > @@ -2273,6 +2283,7 @@ static int mxf_write_header(AVFormatContext *s)
> > if (pix_desc) {
> > sc->component_depth = pix_desc->comp[0].depth;
> > sc->h_chroma_sub_sample = 1 << pix_desc->log2_chroma_w;
> > + sc->v_chroma_sub_sample = 1 << pix_desc->log2_chroma_h;
>
> Looks OK. Had this confused for chrome siting for a while, but I see
> that is actually handled correctly.
will apply
thanks
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
Dictatorship naturally arises out of democracy, and the most aggravated
form of tyranny and slavery out of the most extreme liberty. -- Plato
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: not available
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20180508/81eaf21e/attachment.sig>
More information about the ffmpeg-devel
mailing list