[vlc-commits] Add run-time check for NEON in chroma converter

Rémi Denis-Courmont git at videolan.org
Tue Jul 5 16:56:32 CEST 2011


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Tue Jul  5 13:59:19 2011 +0300| [621f7cd40cfe5b8fc99c5a5ed965bb7654827b0d] | committer: Rémi Denis-Courmont

Add run-time check for NEON in chroma converter

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=621f7cd40cfe5b8fc99c5a5ed965bb7654827b0d
---

 modules/arm_neon/i420_yuy2.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/modules/arm_neon/i420_yuy2.c b/modules/arm_neon/i420_yuy2.c
index 0b8fd94..5cc9907 100644
--- a/modules/arm_neon/i420_yuy2.c
+++ b/modules/arm_neon/i420_yuy2.c
@@ -94,6 +94,8 @@ static int Open (vlc_object_t *obj)
 {
     filter_t *filter = (filter_t *)obj;
 
+    if (!(vlc_CPU() & CPU_CAPABILITY_NEON))
+        return VLC_EGENERIC;
     if (((filter->fmt_in.video.i_width | filter->fmt_in.video.i_height) & 1)
      || (filter->fmt_in.video.i_width != filter->fmt_out.video.i_width)
      || (filter->fmt_in.video.i_height != filter->fmt_out.video.i_height))



More information about the vlc-commits mailing list