diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2012-03-25 05:58:31 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2012-03-25 06:37:01 +0200 |
commit | 8b11ae8a9a3c88dee475477a0c6fcd17c970efcc (patch) | |
tree | c06cf93d6e5e06c1bcd1578d055b543b05478da1 /libswresample/swresample.c | |
parent | 19342bc725025a572c3e0bf1a3f27ba310d50d5c (diff) | |
download | ffmpeg-8b11ae8a9a3c88dee475477a0c6fcd17c970efcc.tar.gz |
swr: Fix partial flushing.
Found-by: durandal_1707
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libswresample/swresample.c')
-rw-r--r-- | libswresample/swresample.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libswresample/swresample.c b/libswresample/swresample.c index 5ce377fd6f..1a384aab13 100644 --- a/libswresample/swresample.c +++ b/libswresample/swresample.c @@ -160,6 +160,8 @@ int swr_init(struct SwrContext *s){ swri_audio_convert_free(&s->out_convert); swri_audio_convert_free(&s->full_convert); + s->flushed = 0; + s-> in.planar= av_sample_fmt_is_planar(s-> in_sample_fmt); s->out.planar= av_sample_fmt_is_planar(s->out_sample_fmt); s-> in_sample_fmt= av_get_alt_sample_fmt(s-> in_sample_fmt, 0); @@ -529,8 +531,6 @@ int swr_convert(struct SwrContext *s, uint8_t *out_arg[SWR_CH_MAX], int out_coun //FIXME packed doesnt need more than 1 chan here! swri_audio_convert(s->out_convert, out, preout, out_count); } - if(!in_arg) - s->in_buffer_count = 0; return out_count; } |