aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/ppc/vp8dsp_altivec.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2013-05-01 18:08:13 +0200
committerMichael Niedermayer <michaelni@gmx.at>2013-05-01 18:08:13 +0200
commitcae8f469fee7c32685f04a2b507251119d6875ef (patch)
tree1f0ca385d3ab050c391736551a370184a24dcbf0 /libavcodec/ppc/vp8dsp_altivec.c
parentebd99ff112e8993330dd39959c22dfe1ab17d5c0 (diff)
parent38282149b6ce8f4b8361e3b84542ba9aa8a1f32f (diff)
downloadffmpeg-cae8f469fee7c32685f04a2b507251119d6875ef.tar.gz
Merge commit '38282149b6ce8f4b8361e3b84542ba9aa8a1f32f'
* commit '38282149b6ce8f4b8361e3b84542ba9aa8a1f32f': ppc: More consistent arch initialization Conflicts: libavcodec/fft.h libavcodec/mpegaudiodsp.c libavcodec/mpegaudiodsp.h Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/ppc/vp8dsp_altivec.c')
-rw-r--r--libavcodec/ppc/vp8dsp_altivec.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/libavcodec/ppc/vp8dsp_altivec.c b/libavcodec/ppc/vp8dsp_altivec.c
index 14d87845dc..2401d2a628 100644
--- a/libavcodec/ppc/vp8dsp_altivec.c
+++ b/libavcodec/ppc/vp8dsp_altivec.c
@@ -20,6 +20,7 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#include "config.h"
#include "libavutil/cpu.h"
#include "libavutil/mem.h"
#include "libavutil/ppc/types_altivec.h"
@@ -27,6 +28,7 @@
#include "libavcodec/vp8dsp.h"
#include "dsputil_altivec.h"
+#if HAVE_ALTIVEC
#define REPT4(...) { __VA_ARGS__, __VA_ARGS__, __VA_ARGS__, __VA_ARGS__ }
// h subpel filter uses msum to multiply+add 4 pixel taps at once
@@ -272,8 +274,11 @@ static void put_vp8_pixels16_altivec(uint8_t *dst, ptrdiff_t stride, uint8_t *sr
ff_put_pixels16_altivec(dst, src, stride, h);
}
-av_cold void ff_vp8dsp_init_altivec(VP8DSPContext *c)
+#endif /* HAVE_ALTIVEC */
+
+av_cold void ff_vp8dsp_init_ppc(VP8DSPContext *c)
{
+#if HAVE_ALTIVEC
if (!(av_get_cpu_flags() & AV_CPU_FLAG_ALTIVEC))
return;
@@ -301,4 +306,5 @@ av_cold void ff_vp8dsp_init_altivec(VP8DSPContext *c)
c->put_vp8_epel_pixels_tab[2][1][1] = put_vp8_epel4_h4v4_altivec;
c->put_vp8_epel_pixels_tab[2][1][2] = put_vp8_epel4_h6v4_altivec;
c->put_vp8_epel_pixels_tab[2][2][1] = put_vp8_epel4_h4v6_altivec;
+#endif /* HAVE_ALTIVEC */
}