aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/ppc/hpeldsp_altivec.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2013-08-30 11:48:50 +0200
committerMichael Niedermayer <michaelni@gmx.at>2013-08-30 11:48:54 +0200
commit09c94b57ca2c567ed6520c28f20a6a25c2950cb4 (patch)
tree4e13f50392fffbfcd6be8d41e3e1c503db5d2cdb /libavcodec/ppc/hpeldsp_altivec.c
parente45e72f5f89ef5a5791562cfcb935028b46ecd0a (diff)
parenta6b650118543e1580e872896d8976042b7c32d01 (diff)
downloadffmpeg-09c94b57ca2c567ed6520c28f20a6a25c2950cb4.tar.gz
Merge commit 'a6b650118543e1580e872896d8976042b7c32d01'
* commit 'a6b650118543e1580e872896d8976042b7c32d01': ppc: cosmetics: Consistently format CPU flag detection invocations Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/ppc/hpeldsp_altivec.c')
-rw-r--r--libavcodec/ppc/hpeldsp_altivec.c27
1 files changed, 14 insertions, 13 deletions
diff --git a/libavcodec/ppc/hpeldsp_altivec.c b/libavcodec/ppc/hpeldsp_altivec.c
index 4f3c4fafc4..345ec39b95 100644
--- a/libavcodec/ppc/hpeldsp_altivec.c
+++ b/libavcodec/ppc/hpeldsp_altivec.c
@@ -449,18 +449,19 @@ static void avg_pixels8_xy2_altivec(uint8_t *block, const uint8_t *pixels, ptrdi
av_cold void ff_hpeldsp_init_ppc(HpelDSPContext *c, int flags)
{
#if HAVE_ALTIVEC
- if (av_get_cpu_flags() & AV_CPU_FLAG_ALTIVEC) {
- c->avg_pixels_tab[0][0] = ff_avg_pixels16_altivec;
- c->avg_pixels_tab[1][0] = avg_pixels8_altivec;
- c->avg_pixels_tab[1][3] = avg_pixels8_xy2_altivec;
-
- c->put_pixels_tab[0][0] = ff_put_pixels16_altivec;
- c->put_pixels_tab[1][3] = put_pixels8_xy2_altivec;
- c->put_pixels_tab[0][3] = put_pixels16_xy2_altivec;
-
- c->put_no_rnd_pixels_tab[0][0] = ff_put_pixels16_altivec;
- c->put_no_rnd_pixels_tab[1][3] = put_no_rnd_pixels8_xy2_altivec;
- c->put_no_rnd_pixels_tab[0][3] = put_no_rnd_pixels16_xy2_altivec;
- }
+ if (!(av_get_cpu_flags() & AV_CPU_FLAG_ALTIVEC))
+ return;
+
+ c->avg_pixels_tab[0][0] = ff_avg_pixels16_altivec;
+ c->avg_pixels_tab[1][0] = avg_pixels8_altivec;
+ c->avg_pixels_tab[1][3] = avg_pixels8_xy2_altivec;
+
+ c->put_pixels_tab[0][0] = ff_put_pixels16_altivec;
+ c->put_pixels_tab[1][3] = put_pixels8_xy2_altivec;
+ c->put_pixels_tab[0][3] = put_pixels16_xy2_altivec;
+
+ c->put_no_rnd_pixels_tab[0][0] = ff_put_pixels16_altivec;
+ c->put_no_rnd_pixels_tab[1][3] = put_no_rnd_pixels8_xy2_altivec;
+ c->put_no_rnd_pixels_tab[0][3] = put_no_rnd_pixels16_xy2_altivec;
#endif /* HAVE_ALTIVEC */
}