On 9/16/2015 5:48 PM, Ronald S. Bultje wrote: > Hi, > > On Wed, Sep 16, 2015 at 4:31 PM, James Almer <jamr...@gmail.com> wrote: > >> On 9/16/2015 4:17 PM, Ronald S. Bultje wrote: >>> --- >>> libavcodec/x86/Makefile | 5 +- >>> libavcodec/x86/vp9dsp_init.c | 197 +++---------- >>> libavcodec/x86/vp9dsp_init.h | 110 +++++++- >>> libavcodec/x86/vp9dsp_init_10bpp.c | 25 ++ >>> libavcodec/x86/vp9dsp_init_12bpp.c | 25 ++ >>> libavcodec/x86/vp9dsp_init_16bpp.c | 2 +- >>> libavcodec/x86/vp9dsp_init_16bpp_template.c | 63 +++++ >> >> Using a template file seems unnecessarily complex. Why not just call the >> macros >> to declare both 10 and 12 bits prototypes inside vp9dsp_init_16bpp.c, then >> in >> ff_vp9dsp_init_16bpp_x86() do >> >> if (bpp == 10) { init stuff } >> else if (bpp == 12) { init stuff } >> >> Sort of like how h264 and hevc currently do. >> Afaics all 10/12bit function prototypes are going to be the same so the >> above >> approach is probably cleaner (One file instead of four). > > > Well, two of these files are only 2 lines, so it's really just 2 files. The > nice thing is that it's half the code for the bpp-specific stuff. > > If you don't like it I'll remove it, but I personally liked the fact that > it prevents duplicate source code between the 10/12bpp setup.
Keep it like this, then. Since you're the one writing the stuff of course use whatever you like the most. It's just cosmetics and I'm fine either way. _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel