]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/ulti.c
VP8: faster MV clipping
[ffmpeg] / libavcodec / ulti.c
index ac21f415412582b38a7d4cba485a7c3b160f2b2d..bb1270f05524b02e38723ce989da0863eda6b509 100644 (file)
@@ -20,7 +20,7 @@
  */
 
 /**
- * @file libavcodec/ulti.c
+ * @file
  * IBM Ultimotion Video Decoder.
  */
 
@@ -55,6 +55,16 @@ static av_cold int ulti_decode_init(AVCodecContext *avctx)
     return 0;
 }
 
+static av_cold int ulti_decode_end(AVCodecContext *avctx){
+    UltimotionDecodeContext *s = avctx->priv_data;
+    AVFrame *pic = &s->frame;
+
+    if (pic->data[0])
+        avctx->release_buffer(avctx, pic);
+
+    return 0;
+}
+
 static const int block_coords[8] = // 4x4 block coords in 8x8 superblock
     { 0, 0, 0, 4, 4, 4, 4, 0};
 
@@ -394,16 +404,9 @@ static int ulti_decode_frame(AVCodecContext *avctx,
     return buf_size;
 }
 
-static av_cold int ulti_decode_end(AVCodecContext *avctx)
-{
-/*    UltimotionDecodeContext *s = avctx->priv_data;*/
-
-    return 0;
-}
-
-AVCodec ulti_decoder = {
+AVCodec ff_ulti_decoder = {
     "ultimotion",
-    CODEC_TYPE_VIDEO,
+    AVMEDIA_TYPE_VIDEO,
     CODEC_ID_ULTI,
     sizeof(UltimotionDecodeContext),
     ulti_decode_init,