[MPlayer-dev-eng] more questions on integration ALTIVEC colorspace

Marc Hoffman mmh at pleasantst.com
Sun Mar 7 15:58:15 CET 2004


sorry for so many questions but being new to the project I have so many 
questions.
How would the group like me to integrate the color space converter?  
Here is what I currently have.

1. A new module named yuv2rgb_altivec.c
2. the module has been wrapped with
     #ifdef HAVE_ALTIVEC
     #endif
hence compilation on non altivec machines would produce an empty object.

Now thats what I currently have, I guess I can follow the inclusion 
style that is used by the mlib stuff the group would prefer it.

Index: Makefile
===================================================================
RCS file: /cvsroot/mplayer/main/postproc/Makefile,v
retrieving revision 1.19
diff -u -r1.19 Makefile
--- Makefile	28 Jul 2003 15:24:38 -0000	1.19
+++ Makefile	7 Mar 2004 14:52:24 -0000
@@ -3,7 +3,8 @@

  SWSLIB = libswscale.a

-SWSSRCS=swscale.c rgb2rgb.c yuv2rgb.c
+SWSSRCS=swscale.c rgb2rgb.c yuv2rgb.c yuv2rgb_altivec.c
+
  SWSOBJS=$(SWSSRCS:.c=.o)

  CFLAGS  = $(OPTFLAGS) $(MLIB_INC) -I. -I.. $(EXTRA_INC)
Index: yuv2rgb.c
===================================================================
RCS file: /cvsroot/mplayer/main/postproc/yuv2rgb.c,v
retrieving revision 1.22
diff -u -r1.22 yuv2rgb.c
--- yuv2rgb.c	27 Dec 2003 19:54:59 -0000	1.22
+++ yuv2rgb.c	7 Mar 2004 14:52:24 -0000
@@ -607,6 +607,13 @@
  	if(t) return t;
      }
  #endif
+#ifdef HAVE_ALTIVEC
+    {
+	SwsFunc t= yuv2rgb_init_altivec(c);
+	if(t) return t;
+    }
+#endif
+
      MSG_WARN("No accelerated colorspace conversion found\n");

      switch(c->dstFormat){




More information about the MPlayer-dev-eng mailing list