]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/vp56dsp.c
hevc: pass the full HEVCNAL struct to decode_nal_unit
[ffmpeg] / libavcodec / vp56dsp.c
index 7b4a7716769755e8ea7838fdc4e8257a24b15975..5e09d2414e6b95393b1fee467e0f3d27a85ae9f3 100644 (file)
  */
 
 #include <stdint.h>
+
+#include "libavutil/attributes.h"
 #include "avcodec.h"
 #include "vp56dsp.h"
+#include "libavutil/common.h"
 
 /* Gives very similar result than the vp6 version except in a few cases */
 static int vp5_adjust(int v, int t)
@@ -74,9 +77,9 @@ VP56_EDGE_FILTER(vp5, ver, stride, 1)
 VP56_EDGE_FILTER(vp6, hor, 1, stride)
 VP56_EDGE_FILTER(vp6, ver, stride, 1)
 
-void ff_vp56dsp_init(VP56DSPContext *s, enum CodecID codec)
+av_cold void ff_vp56dsp_init(VP56DSPContext *s, enum AVCodecID codec)
 {
-    if (codec == CODEC_ID_VP5) {
+    if (codec == AV_CODEC_ID_VP5) {
         s->edge_filter_hor = vp5_edge_filter_hor;
         s->edge_filter_ver = vp5_edge_filter_ver;
     } else {
@@ -85,9 +88,11 @@ void ff_vp56dsp_init(VP56DSPContext *s, enum CodecID codec)
 
         if (CONFIG_VP6_DECODER) {
             s->vp6_filter_diag4 = ff_vp6_filter_diag4_c;
+
+            if (ARCH_ARM)
+                ff_vp6dsp_init_arm(s, codec);
+            if (ARCH_X86)
+                ff_vp6dsp_init_x86(s, codec);
         }
     }
-
-    if (ARCH_ARM) ff_vp56dsp_init_arm(s, codec);
-    if (HAVE_MMX) ff_vp56dsp_init_x86(s, codec);
 }