changeset 12023:c7455450364d libavcodec

apedec: add flush function
author mru
date Wed, 30 Jun 2010 09:33:59 +0000
parents bf2a317342a2
children fdafbcef52f5
files apedec.c
diffstat 1 files changed, 7 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/apedec.c	Wed Jun 30 06:50:44 2010 +0000
+++ b/apedec.c	Wed Jun 30 09:33:59 2010 +0000
@@ -877,6 +877,12 @@
     return bytes_used;
 }
 
+static void ape_flush(AVCodecContext *avctx)
+{
+    APEContext *s = avctx->priv_data;
+    s->samples= 0;
+}
+
 AVCodec ape_decoder = {
     "ape",
     AVMEDIA_TYPE_AUDIO,
@@ -887,5 +893,6 @@
     ape_decode_close,
     ape_decode_frame,
     .capabilities = CODEC_CAP_SUBFRAMES,
+    .flush = ape_flush,
     .long_name = NULL_IF_CONFIG_SMALL("Monkey's Audio"),
 };