[FFmpeg-devel] [PATCH] swr: handle initial negative sample index outside DSP function.
Michael Niedermayer
michaelni at gmx.at
Fri Jun 13 04:48:20 CEST 2014
On Wed, Jun 11, 2014 at 09:33:43PM -0400, Ronald S. Bultje wrote:
> The new function in struct Resampler and code therefore in resample()
> are admittedly butt-ugly. I'll probably clean it up but at least it
> works so I figured I'd send it out and see what people think. What I'd
> really like to do is to be able to expose ResampleContext to swresample.c
> if people are OK with that.
> ---
> libswresample/resample.c | 47 ++++++++++++++++++++++++++++++-
> libswresample/resample_template.c | 55 ++++---------------------------------
> libswresample/soxr_resample.c | 7 +++++
> libswresample/swresample.c | 6 ++++
> libswresample/swresample_internal.h | 2 ++
> 5 files changed, 66 insertions(+), 51 deletions(-)
This seems to still have a problem with small sample sizes:
./ffmpeg -i tests/data/asynth-44100-1.wav -af asetnsamples=1:p=0,aresample=8000 -f s16le foo1.pcm
produces:
[s16le @ 0x314bb00] Application provided invalid, non monotonically increasing dts to muxer in stream 0: 371 >= 191
[s16le @ 0x314bb00] Application provided invalid, non monotonically increasing dts to muxer in stream 0: 371 >= 203
[s16le @ 0x314bb00] Application provided invalid, non monotonically increasing dts to muxer in stream 0: 371 >= 214
[s16le @ 0x314bb00] Application provided invalid, non monotonically increasing dts to muxer in stream 0: 371 >= 225
[s16le @ 0x314bb00] Application provided invalid, non monotonically increasing dts to muxer in stream 0: 371 >= 236
[s16le @ 0x314bb00] Application provided invalid, non monotonically increasing dts to muxer in stream 0: 371 >= 248
[s16le @ 0x314bb00] Application provided invalid, non monotonically increasing dts to muxer in stream 0: 371 >= 259
[s16le @ 0x314bb00] Application provided invalid, non monotonically increasing dts to muxer in stream 0: 371 >= 270
[s16le @ 0x314bb00] Application provided invalid, non monotonically increasing dts to muxer in stream 0: 371 >= 281
[s16le @ 0x314bb00] Application provided invalid, non monotonically increasing dts to muxer in stream 0: 371 >= 293
[s16le @ 0x314bb00] Application provided invalid, non monotonically increasing dts to muxer in stream 0: 371 >= 304
[s16le @ 0x314bb00] Application provided invalid, non monotonically increasing dts to muxer in stream 0: 371 >= 315
[s16le @ 0x314bb00] Application provided invalid, non monotonically increasing dts to muxer in stream 0: 371 >= 326
[s16le @ 0x314bb00] Application provided invalid, non monotonically increasing dts to muxer in stream 0: 371 >= 338
[s16le @ 0x314bb00] Application provided invalid, non monotonically increasing dts to muxer in stream 0: 371 >= 349
[s16le @ 0x314bb00] Application provided invalid, non monotonically increasing dts to muxer in stream 0: 371 >= 360
[s16le @ 0x314bb00] Application provided invalid, non monotonically increasing dts to muxer in stream 0: 371 >= 371
no such errors seem to occur prior to the patch, the output is identical
though
the invert_initial_buffer() idea LGTM
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
Democracy is the form of government in which you can choose your dictator
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 181 bytes
Desc: Digital signature
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20140613/6817af41/attachment.asc>
More information about the ffmpeg-devel
mailing list