[FFmpeg-devel] [PATCH] g722 decoder, no licensing fame

Diego Biurrun diego
Thu Apr 2 00:10:49 CEST 2009


On Wed, Apr 01, 2009 at 10:15:18AM -0700, Kenan Gillet wrote:
> On Apr 1, 2009, at 8:58 AM, Diego Biurrun wrote:
> 
> >On Tue, Mar 31, 2009 at 11:34:34PM -0700, Kenan Gillet wrote:
> >>
> >>new patches attached
> >>
> >>--- libavcodec/Makefile	(revision 18292)
> >>+++ libavcodec/Makefile	(working copy)
> >>@@ -324,6 +324,8 @@
> >>OBJS-$(CONFIG_ADPCM_EA_XAS_DECODER)       += adpcm.o
> >>+OBJS-$(CONFIG_ADPCM_G722_DECODER)         += g722.o
> >>+OBJS-$(CONFIG_ADPCM_G722_ENCODER)         += g722.o
> >
> >Maybe it would be worth splitting this into g722dec.c and  
> >g722enc.c.  It
> >would save some #ifdeffery.
> 
> Decoder and encoder sharethe structure definition, most of the code and
> tables. g722.c would need to be split in g722.h, g722dec.c, g722enc.c  
> and g722common.c.
> Are the 3 #if worth the extra complexity ?

Possibly not.  You could, however, move the decoder tables to the bottom
of the file under the decoder #ifdef, that would save you one #ifdef.
Feel free to ignore me if you prefer to sort it out another way.

Diego



More information about the ffmpeg-devel mailing list