OSDN Git Service

pcm-dvd: Support channel configuration changes
authorChristian Schmidt <schmidt@digadd.de>
Wed, 11 Sep 2013 14:12:27 +0000 (16:12 +0200)
committerLuca Barbato <lu_zero@gentoo.org>
Fri, 13 Sep 2013 10:14:05 +0000 (12:14 +0200)
commitd9cdb7d8d6d828bb5497ea3f0fd7edd2f3f6cc30
tree494553f4d5f8afeef8c3d423b067e83de1bd8c96
parent00a63bfb87af6cf7bcdf85848830a90c7e052d41
pcm-dvd: Support channel configuration changes

The sample buffering logic does not take into account that the blocksize
could change. Reset the buffer if the channel configuration changes,
since if there are leftover samples, it is most likely a broken or
misconcatenated stream. This could lead to negative numbers for
missing_samples during decoding.

Thanks to Michael Niedermeyer for pointing these out.
libavcodec/pcm-dvd.c