[FFmpeg-devel] [PATCH] lavc: add fixed point mp2 encoder

Paul B Mahol onemda at gmail.com
Fri Aug 3 16:15:30 CEST 2012


On 8/3/12, Michael Niedermayer <michaelni at gmx.at> wrote:
> On Fri, Aug 03, 2012 at 03:07:39AM +0000, Paul B Mahol wrote:
>> On 8/3/12, Michael Niedermayer <michaelni at gmx.at> wrote:
>> > On Mon, Jul 30, 2012 at 03:02:20PM +0000, Paul B Mahol wrote:
>> > [...]
>> >> diff --git a/libavcodec/mpegaudioenc_fixed.c
>> >> b/libavcodec/mpegaudioenc_fixed.c
>> >> new file mode 100644
>> >> index 0000000..fdcaa78
>> >> --- /dev/null
>> >> +++ b/libavcodec/mpegaudioenc_fixed.c
>> >> @@ -0,0 +1,39 @@
>> >> +/*
>> >> + * Fixed point MPEG Audio layer 2 encoder
>> >> + *
>> >> + * This file is part of FFmpeg.
>> >> + *
>> >> + * FFmpeg is free software; you can redistribute it and/or
>> >> + * modify it under the terms of the GNU Lesser General Public
>> >> + * License as published by the Free Software Foundation; either
>> >> + * version 2.1 of the License, or (at your option) any later version.
>> >> + *
>> >> + * FFmpeg is distributed in the hope that it will be useful,
>> >> + * but WITHOUT ANY WARRANTY; without even the implied warranty of
>> >> + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
>> >> + * Lesser General Public License for more details.
>> >> + *
>> >> + * You should have received a copy of the GNU Lesser General Public
>> >> + * License along with FFmpeg; if not, write to the Free Software
>> >> + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
>> >> 02110-1301 USA
>> >> + */
>> >> +
>> >> +#define USE_FLOATS 0
>> >> +#include "mpegaudioenc.c"
>> >
>> > the code uses #ifdef USE_FLOATS, thus this wont work
>> > also what speed and quality difference is there between the 2 ?
>>
>> There is already integer and float version of decoder.
>
> yes, but it appeared that your patch would change the default from
> float to fixed

"Default" decoder is fixed so i really do not see any "real" problem.


More information about the ffmpeg-devel mailing list