diff ppc/h264_altivec.c @ 12473:06abedae2906 libavcodec

Merge has_altivec() function into mm_support(), remove it and use mm_support() instead. Reduce complexity and simplify pending move to libavutil.
author stefano
date Wed, 08 Sep 2010 10:02:40 +0000
parents 3cd4cd0509cd
children 9fef0a8ddd63
line wrap: on
line diff
--- a/ppc/h264_altivec.c	Wed Sep 08 05:51:31 2010 +0000
+++ b/ppc/h264_altivec.c	Wed Sep 08 10:02:40 2010 +0000
@@ -969,7 +969,7 @@
 
 void dsputil_h264_init_ppc(DSPContext* c, AVCodecContext *avctx) {
 
-    if (has_altivec()) {
+    if (mm_support() & AV_CPU_FLAG_ALTIVEC) {
         c->put_h264_chroma_pixels_tab[0] = put_h264_chroma_mc8_altivec;
         c->avg_h264_chroma_pixels_tab[0] = avg_h264_chroma_mc8_altivec;
         c->put_no_rnd_vc1_chroma_pixels_tab[0] = put_no_rnd_vc1_chroma_mc8_altivec;
@@ -1001,7 +1001,7 @@
 
 void ff_h264dsp_init_ppc(H264DSPContext *c)
 {
-    if (has_altivec()) {
+    if (mm_support() & AV_CPU_FLAG_ALTIVEC) {
         c->h264_idct_add = ff_h264_idct_add_altivec;
         c->h264_idct_add8 = ff_h264_idct_add8_altivec;
         c->h264_idct_add16 = ff_h264_idct_add16_altivec;