[FFmpeg-cvslog] r14692 - in trunk: libavcodec/pcm.c tests/regression.sh

Daniel Serpell daniel.serpell
Thu Aug 14 03:40:57 CEST 2008


Hi!

On Wed, Aug 13, 2008 at 3:43 AM,  <pross at xvid.org> wrote:
> On Tue, Aug 12, 2008 at 08:45:23PM -0400, Daniel Serpell wrote:
>> On Tue, Aug 12, 2008 at 8:40 PM, Daniel Serpell
>> <daniel.serpell at gmail.com> wrote:
>> > Hi!
>> >
>> > On Mon, Aug 11, 2008 at 5:52 AM, pross <subversion at mplayerhq.hu> wrote:
>> >> Author: pross
>> >> Date: Mon Aug 11 11:52:17 2008
>> >> New Revision: 14692
>> >>
>> >> Log:
>> >> Apply PCM ENCODE/DECODE() macros to the S/U,8/24/32,LE/BE PCM codecs.
>> >>
>> >>
>> >> Modified:
>> >>   trunk/libavcodec/pcm.c
>> >>   trunk/tests/regression.sh
>> >>
>> >
>> > This commit also broke transcoding from PCM from 8 bit to 16 bit, I
>> > uploaded a sample to
>> >   ftp://upload.mplayerhq.hu:/MPlayer/incoming/pcm-audio-11024
>> >
>> > The bug can be heard in output.avi from the command line:
>>
>> Sorry, the correct command line is:
>>
>> ffmpeg -y -i pcm-audio-bug-r14692.avi -acodec pcm_s16le -ar 48000
>> -vcodec copy output.avi
>>
>> The bug is not present with only 8-16 bit conversion, you need to resample audio
>> also.
>
> The resampler only supports SAMPLE_FMT_S16, and is performed by conversion
> to the target format. Hence why transcoding U8->S16 fails.
>
> I guess the next step is to make resample.c handle different foramts.
>

I think is better to resample *after* conversion to S16.

This set of patches fixes my issue, first one exits ffmpeg if the resample is
called on any sample format different of S16.

The second patch resamples after sample format conversion, allowing to resample
from U8 to S16.

Please, consider applying.

   Daniel.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: abort-resampler-not16bits.patch
Type: text/x-diff
Size: 614 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-cvslog/attachments/20080813/7d3b7a26/attachment.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: resample-after-conversion-2.patch
Type: text/x-diff
Size: 2150 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-cvslog/attachments/20080813/7d3b7a26/attachment-0001.patch>



More information about the ffmpeg-cvslog mailing list