[MPlayer-cvslog] r28942 - in trunk/libmpcodecs: vf_decimate.c vf_divtc.c

reimar subversion at mplayerhq.hu
Fri Mar 13 18:12:40 CET 2009


Author: reimar
Date: Fri Mar 13 18:12:40 2009
New Revision: 28942

Log:
Check for HAVE_EBX_AVAILABLE before enabling MMX code that needs the EBX register.
Makes things a bit simpler for everyone who insists on compiling MPlayer as PIE-code.

Modified:
   trunk/libmpcodecs/vf_decimate.c
   trunk/libmpcodecs/vf_divtc.c

Modified: trunk/libmpcodecs/vf_decimate.c
==============================================================================
--- trunk/libmpcodecs/vf_decimate.c	Fri Mar 13 18:09:39 2009	(r28941)
+++ trunk/libmpcodecs/vf_decimate.c	Fri Mar 13 18:12:40 2009	(r28942)
@@ -19,7 +19,7 @@ struct vf_priv_s {
 	int max, last, cnt;
 };
 
-#if HAVE_MMX
+#if HAVE_MMX && HAVE_EBX_AVAILABLE
 static int diff_MMX(unsigned char *old, unsigned char *new, int os, int ns)
 {
 	volatile short out[4];
@@ -164,7 +164,7 @@ static int open(vf_instance_t *vf, char*
 	p->frac = 0.33;
 	if (args) sscanf(args, "%d:%d:%d:%f", &p->max, &p->hi, &p->lo, &p->frac);
 	diff = diff_C;
-#if HAVE_MMX
+#if HAVE_MMX && HAVE_EBX_AVAILABLE
 	if(gCpuCaps.hasMMX) diff = diff_MMX;
 #endif
 	return 1;

Modified: trunk/libmpcodecs/vf_divtc.c
==============================================================================
--- trunk/libmpcodecs/vf_divtc.c	Fri Mar 13 18:09:39 2009	(r28941)
+++ trunk/libmpcodecs/vf_divtc.c	Fri Mar 13 18:12:40 2009	(r28942)
@@ -33,7 +33,7 @@ struct vf_priv_s
  * diff_MMX and diff_C stolen from vf_decimate.c
  */
 
-#if HAVE_MMX
+#if HAVE_MMX && HAVE_EBX_AVAILABLE
 static int diff_MMX(unsigned char *old, unsigned char *new, int os, int ns)
    {
    volatile short out[4];
@@ -683,7 +683,7 @@ static int open(vf_instance_t *vf, char*
       goto nomem;
 
    diff = diff_C;
-#if HAVE_MMX
+#if HAVE_MMX && HAVE_EBX_AVAILABLE
    if(gCpuCaps.hasMMX) diff = diff_MMX;
 #endif
 



More information about the MPlayer-cvslog mailing list