[FFmpeg-cvslog] Implement reset_codec()
Mashiat Sarker Shakkhar
git at videolan.org
Fri Nov 11 03:42:40 CET 2011
ffmpeg | branch: master | Mashiat Sarker Shakkhar <shahriman_ams at yahoo.com> | Sun Nov 6 03:00:49 2011 +0600| [f12f189638ecd24cc004f46cf80e0a4d2b88c85b] | committer: Michael Niedermayer
Implement reset_codec()
(cherry picked from commit c56313aa7969691f1a779e5ac5666f012676836f)
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=f12f189638ecd24cc004f46cf80e0a4d2b88c85b
---
libavcodec/wmalosslessdec.c | 11 +++++++++++
1 files changed, 11 insertions(+), 0 deletions(-)
diff --git a/libavcodec/wmalosslessdec.c b/libavcodec/wmalosslessdec.c
index 0ed4f05..a60f477 100644
--- a/libavcodec/wmalosslessdec.c
+++ b/libavcodec/wmalosslessdec.c
@@ -746,6 +746,17 @@ static void clear_codec_buffers(WmallDecodeCtx *s)
}
}
+static void reset_codec(WmallDecodeCtx *s)
+{
+ int ich, ilms;
+ s->mclms_recent = s->mclms_order * s->num_channels;
+ for (ich = 0; ich < s->num_channels; ich++)
+ for (ilms = 0; ilms < s->cdlms_ttl[ich]; ilms++)
+ s->cdlms[ich][ilms].recent = s->cdlms[ich][ilms].order;
+}
+
+
+
/**
*@brief Decode a single subframe (block).
*@param s codec context
More information about the ffmpeg-cvslog
mailing list