[vlc-devel] [PATCH 1/1] daala: add support for 422 and 444

Tristan Matthews le.businessman at gmail.com
Fri Sep 26 02:02:53 CEST 2014


On Thu, Sep 25, 2014 at 7:22 PM, Francois Cartegnie <fcvlcdev at free.fr>
wrote:

> Le 26/09/2014 01:04, Tristan Matthews a écrit :
>
> > +static const char *const enc_chromafmt_list_text[] = {
> > +    N_("4:2:0"), N_("4:2:2"), N_("4:4:4")
> > +};
> >  #endif
>
> i18n, Really ?
>

Yeah it seems like it's not translated for schroedinger either, so it could
be dropped.


>
>
> > +static void SetEncChromaFormat( encoder_t *p_enc, uint32_t i_codec )
> > +{
> > +    p_enc->fmt_in.i_codec = i_codec;
> > +
> > +    switch( i_codec ) {
> > +    case VLC_CODEC_I420:
> > +        p_enc->fmt_in.video.i_bits_per_pixel = 12;
> > +        break;
> > +    case VLC_CODEC_I422:
> > +        p_enc->fmt_in.video.i_bits_per_pixel = 16;
> > +        break;
> > +    case VLC_CODEC_I444:
> > +        p_enc->fmt_in.video.i_bits_per_pixel = 24;
> > +        break;
> > +    }
> > +}
> > +
>
> I believe there's a function that already returns that kind of info.
> video_format_Setup()


Seems like it might be overkill for this case, as we're only changing one
parameter and invocation looks like:

        video_format_Setup( &p_enc->fmt_in, i_codec,
                            p_enc->fmt_in.video.i_width,
                            p_enc->fmt_in.video.i_height,
                            p_enc->fmt_in.video.i_visible_width,
                            p_enc->fmt_in.video.i_visible_height,
                            p_enc->fmt_in.video.i_sar_num,
                            p_enc->fmt_in.video.i_sar_den );

but ok.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20140925/2025d11d/attachment.html>


More information about the vlc-devel mailing list