diff options
author | Luca Barbato <lu_zero@gentoo.org> | 2004-07-15 20:44:40 +0000 |
---|---|---|
committer | Luca Barbato <lu_zero@gentoo.org> | 2004-07-15 20:44:40 +0000 |
commit | f2c2f6ffd1d570e54f30749347120cb1d3d4a838 (patch) | |
tree | c1aa8d50c47b906ba69294c2c6cda780b4622044 /media-video | |
parent | Fix DEPEND/RDEPENDs. Should close #56756. Thanks to wood-worker@gmx.net for r... (diff) | |
download | historical-f2c2f6ffd1d570e54f30749347120cb1d3d4a838.tar.gz historical-f2c2f6ffd1d570e54f30749347120cb1d3d4a838.tar.bz2 historical-f2c2f6ffd1d570e54f30749347120cb1d3d4a838.zip |
Altivec related fix
Diffstat (limited to 'media-video')
-rw-r--r-- | media-video/mplayer/ChangeLog | 6 | ||||
-rw-r--r-- | media-video/mplayer/Manifest | 67 | ||||
-rw-r--r-- | media-video/mplayer/files/mplayer-1.0_pre5-yuv2rbg_kludge.patch | 348 | ||||
-rw-r--r-- | media-video/mplayer/mplayer-1.0_pre5.ebuild | 5 |
4 files changed, 391 insertions, 35 deletions
diff --git a/media-video/mplayer/ChangeLog b/media-video/mplayer/ChangeLog index 15eefeff51a9..886b845431ff 100644 --- a/media-video/mplayer/ChangeLog +++ b/media-video/mplayer/ChangeLog @@ -1,6 +1,10 @@ # ChangeLog for media-video/mplayer # Copyright 2002-2004 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/media-video/mplayer/ChangeLog,v 1.156 2004/07/15 08:26:31 chriswhite Exp $ +# $Header: /var/cvsroot/gentoo-x86/media-video/mplayer/ChangeLog,v 1.157 2004/07/15 20:44:40 lu_zero Exp $ + + 15 Jul 2004; Luca Barbato <lu_zero@gentoo.org> + +files/mplayer-1.0_pre5-yuv2rbg_kludge.patch, mplayer-1.0_pre5.ebuild: + Fixed the altivec scaler 15 Jul 2004; Chris White <chriswhite@gentoo.org> +files/mplayer-1.0_pre5-mga-kernel-2.6.patch, mplayer-1.0_pre5.ebuild: diff --git a/media-video/mplayer/Manifest b/media-video/mplayer/Manifest index 3cd84ba7b206..3af1e755cd3f 100644 --- a/media-video/mplayer/Manifest +++ b/media-video/mplayer/Manifest @@ -1,46 +1,47 @@ -MD5 fb6109bf1a25a4737e2fafa99c5fe24b ChangeLog 27839 -MD5 9ef4af14dad87b03fde8e43f19e08d26 metadata.xml 225 -MD5 b813a65769af5d2a2ca1ceba1347974d mplayer-0.92-r1.ebuild 11511 -MD5 7eeb1235c1263ecb110925e53de1eb06 mplayer-1.0_pre2-r1.ebuild 11375 -MD5 8fd3c8b66040b26bb9f3963b5fe96bb2 mplayer-1.0_pre3-r3.ebuild 11498 MD5 d40969fad743a58087e55fd5d27d3fcf mplayer-1.0_pre3-r4.ebuild 11799 -MD5 5d11f22039a718f19a725f676e614670 mplayer-1.0_pre3-r5.ebuild 11473 -MD5 1c2c6d32766ce3bf0974895533252491 mplayer-1.0_pre4-r1.ebuild 11659 -MD5 fbdd96b2a3f0f78bdc8cbded3bb3927b mplayer-1.0_pre4-r2.ebuild 11948 -MD5 6b9e16c4f08ac48748812909ed431f31 mplayer-1.0_pre4-r3.ebuild 13034 MD5 d13f33f9022f7abccfe9b14f96531057 mplayer-1.0_pre4-r4.ebuild 13157 +MD5 af608c931d9707b92d8307b9db0e8fd4 ChangeLog 27986 +MD5 7eeb1235c1263ecb110925e53de1eb06 mplayer-1.0_pre2-r1.ebuild 11375 +MD5 5d11f22039a718f19a725f676e614670 mplayer-1.0_pre3-r5.ebuild 11473 +MD5 9ef4af14dad87b03fde8e43f19e08d26 metadata.xml 225 MD5 071a354aa3c0e9290b6dcfc8c3621d87 mplayer-1.0_pre4.ebuild 11319 -MD5 579928b7481c65d86d204a97256de189 mplayer-1.0_pre5.ebuild 13157 +MD5 6b9e16c4f08ac48748812909ed431f31 mplayer-1.0_pre4-r3.ebuild 13034 +MD5 8fd3c8b66040b26bb9f3963b5fe96bb2 mplayer-1.0_pre3-r3.ebuild 11498 +MD5 f8a6795f44546d9f6eb7a6f3e96deff5 mplayer-1.0_pre5.ebuild 13260 +MD5 fbdd96b2a3f0f78bdc8cbded3bb3927b mplayer-1.0_pre4-r2.ebuild 11948 +MD5 b813a65769af5d2a2ca1ceba1347974d mplayer-0.92-r1.ebuild 11511 +MD5 1c2c6d32766ce3bf0974895533252491 mplayer-1.0_pre4-r1.ebuild 11659 +MD5 dc67207241f6a950a4d529557ebd4053 files/digest-mplayer-1.0_pre4-r3 358 +MD5 d74f7136fa5b4fa7d9ef13f8193dfe7c files/digest-mplayer-1.0_pre3-r4 358 +MD5 e2fc2cbbc8ebf183dcb599b66c999331 files/ppc750FX-fix.patch 515 +MD5 fef9f0571da54ae3df2e804100bd2632 files/vuln01-fix.diff 1231 MD5 6c2dab3392aab51766253b416ad2a10c files/default-skin.diff 396 -MD5 deb1dbbf5879ed31e1b83fb7def5b600 files/digest-mplayer-0.92-r1 355 +MD5 a9fa1b94e4e3842e2c5e552644b03eaa files/mplayer-1.0_pre4-alsa-gcc34.patch 299 +MD5 42733acde24d84c1482db03c777360ab files/mplayer-1.0_pre4-help_mp-ro.h.patch 3267 MD5 b0205104d1242fcccdb5dfd2188f5ab2 files/digest-mplayer-1.0_pre2-r1 358 -MD5 d74f7136fa5b4fa7d9ef13f8193dfe7c files/digest-mplayer-1.0_pre3-r3 358 -MD5 d74f7136fa5b4fa7d9ef13f8193dfe7c files/digest-mplayer-1.0_pre3-r4 358 -MD5 d74f7136fa5b4fa7d9ef13f8193dfe7c files/digest-mplayer-1.0_pre3-r5 358 -MD5 dc67207241f6a950a4d529557ebd4053 files/digest-mplayer-1.0_pre4 358 -MD5 dc67207241f6a950a4d529557ebd4053 files/digest-mplayer-1.0_pre4-r1 358 -MD5 dc67207241f6a950a4d529557ebd4053 files/digest-mplayer-1.0_pre4-r2 358 -MD5 dc67207241f6a950a4d529557ebd4053 files/digest-mplayer-1.0_pre4-r3 358 -MD5 e4581f6934f66ccecc8c1682664623d0 files/digest-mplayer-1.0_pre4-r4 358 -MD5 260489267a0ccf01fe300bce0ec1430d files/mencoder-segfault.patch 520 MD5 98c7d58f544829621b15427ad53b98e4 files/mga-kernel-2.6.patch 16767 -MD5 a71fc9832d953424652af1125fb7ea64 files/mplayer-0.90-coreutils-fixup.patch 1857 -MD5 8f18911adcd661e70ad0cd84a94d49ac files/mplayer-0.90-divx.patch 25064 -MD5 26a52f084f4d177580ed9ea0187f54e7 files/mplayer-0.90-ppc-benh-2.patch 2049 -MD5 059e03d1d2c965b04a5e53ed850de64a files/mplayer-0.90_rc4-gtk2.patch 6183 MD5 c54c7ba8e18c8e7f3412c6d6939d010a files/mplayer-1.0-gtk2.patch 5903 MD5 a9fa1b94e4e3842e2c5e552644b03eaa files/mplayer-1.0_pre3-alsa-gcc34.patch 299 -MD5 f998f1cad3da27cac3aea1982dc5c747 files/mplayer-1.0_pre3-libavcodec-gcc34.patch 5010 MD5 fa86dd9d6980ff064efcc9d9f919905e files/mplayer-1.0_pre3-libmatroska063.diff 810 -MD5 8b8084aa31b466c55d15bd06bb77086d files/mplayer-1.0_pre3-xmms.patch 411 -MD5 a9fa1b94e4e3842e2c5e552644b03eaa files/mplayer-1.0_pre4-alsa-gcc34.patch 299 -MD5 a39bd930af792269808dc4bdbc382fbb files/mplayer-1.0_pre4-altivec-gcc34.patch 650 -MD5 aaadaff9756ff85c9855b2bbd50da184 files/mplayer-1.0_pre4-gcc34-mtune.patch 3493 -MD5 42733acde24d84c1482db03c777360ab files/mplayer-1.0_pre4-help_mp-ro.h.patch 3267 -MD5 c2d65649f15837c5a326557ded4e47c5 files/mplayer.desktop 119 -MD5 e2fc2cbbc8ebf183dcb599b66c999331 files/ppc750FX-fix.patch 515 -MD5 fef9f0571da54ae3df2e804100bd2632 files/vuln01-fix.diff 1231 MD5 34f948b8f242a2aadb53a1e2b00e3155 files/vuln02-fix.diff 467 MD5 3aabe241ce3c7d60ea6f607cb7ab033a files/digest-mplayer-1.0_pre5 358 +MD5 8f18911adcd661e70ad0cd84a94d49ac files/mplayer-0.90-divx.patch 25064 +MD5 a39bd930af792269808dc4bdbc382fbb files/mplayer-1.0_pre4-altivec-gcc34.patch 650 +MD5 f998f1cad3da27cac3aea1982dc5c747 files/mplayer-1.0_pre3-libavcodec-gcc34.patch 5010 +MD5 deb1dbbf5879ed31e1b83fb7def5b600 files/digest-mplayer-0.92-r1 355 +MD5 ad254e1f8a5166ae1c5b53bc3c76ffd2 files/mplayer-1.0_pre5-yuv2rbg_kludge.patch 12585 +MD5 d74f7136fa5b4fa7d9ef13f8193dfe7c files/digest-mplayer-1.0_pre3-r3 358 +MD5 e4581f6934f66ccecc8c1682664623d0 files/digest-mplayer-1.0_pre4-r4 358 +MD5 dc67207241f6a950a4d529557ebd4053 files/digest-mplayer-1.0_pre4 358 +MD5 d74f7136fa5b4fa7d9ef13f8193dfe7c files/digest-mplayer-1.0_pre3-r5 358 MD5 d7d214ab46189ad1138a0a37eaa859d4 files/noenca.patch 289 MD5 5cc95d6b380dc27e5ceae0f53ab88f99 files/mplayer-1.0_pre5-mga-kernel-2.6.patch 15043 +MD5 aaadaff9756ff85c9855b2bbd50da184 files/mplayer-1.0_pre4-gcc34-mtune.patch 3493 +MD5 26a52f084f4d177580ed9ea0187f54e7 files/mplayer-0.90-ppc-benh-2.patch 2049 +MD5 059e03d1d2c965b04a5e53ed850de64a files/mplayer-0.90_rc4-gtk2.patch 6183 +MD5 dc67207241f6a950a4d529557ebd4053 files/digest-mplayer-1.0_pre4-r1 358 +MD5 260489267a0ccf01fe300bce0ec1430d files/mencoder-segfault.patch 520 +MD5 c2d65649f15837c5a326557ded4e47c5 files/mplayer.desktop 119 +MD5 8b8084aa31b466c55d15bd06bb77086d files/mplayer-1.0_pre3-xmms.patch 411 +MD5 a71fc9832d953424652af1125fb7ea64 files/mplayer-0.90-coreutils-fixup.patch 1857 +MD5 dc67207241f6a950a4d529557ebd4053 files/digest-mplayer-1.0_pre4-r2 358 diff --git a/media-video/mplayer/files/mplayer-1.0_pre5-yuv2rbg_kludge.patch b/media-video/mplayer/files/mplayer-1.0_pre5-yuv2rbg_kludge.patch new file mode 100644 index 000000000000..69233ea3321b --- /dev/null +++ b/media-video/mplayer/files/mplayer-1.0_pre5-yuv2rbg_kludge.patch @@ -0,0 +1,348 @@ +Files MPlayer-1.0pre5.orig/.tmp.swp and MPlayer-1.0pre5/.tmp.swp differ +diff -ruN MPlayer-1.0pre5.orig/libvo/vo_x11.c MPlayer-1.0pre5/libvo/vo_x11.c +--- MPlayer-1.0pre5.orig/libvo/vo_x11.c 2004-07-15 14:28:07.689498136 +0200 ++++ MPlayer-1.0pre5/libvo/vo_x11.c 2004-07-15 21:55:07.937246584 +0200 +@@ -38,8 +38,18 @@ + #include "fastmemcpy.h" + #include "sub.h" + ++#ifdef HAVE_ALTIVEC_H /* gnu */ ++#include <altivec.h> ++#endif ++ + #include "../postproc/swscale.h" + #include "../postproc/swscale_internal.h" //FIXME ++ ++#ifdef HAVE_ALTIVEC_H /* how NOT to code... FIXME ASAP */ ++#undef __vector ++#endif ++ ++ + #include "../postproc/rgb2rgb.h" + #include "../libmpcodecs/vf_scale.h" + +Files MPlayer-1.0pre5.orig/postproc/.swscale_altivec_template.c.swp and MPlayer-1.0pre5/postproc/.swscale_altivec_template.c.swp differ +diff -ruN MPlayer-1.0pre5.orig/postproc/yuv2rgb.c MPlayer-1.0pre5/postproc/yuv2rgb.c +--- MPlayer-1.0pre5.orig/postproc/yuv2rgb.c 2004-07-15 14:27:46.590705640 +0200 ++++ MPlayer-1.0pre5/postproc/yuv2rgb.c 2004-07-15 14:50:14.103852504 +0200 +@@ -36,6 +36,10 @@ + #include <assert.h> + + #include "config.h" ++ ++#ifdef HAVE_ALTIVEC_H /* gnu */ ++#include <altivec.h> ++#endif + //#include "video_out.h" + #include "rgb2rgb.h" + #include "swscale.h" +diff -ruN MPlayer-1.0pre5.orig/postproc/yuv2rgb_altivec.c MPlayer-1.0pre5/postproc/yuv2rgb_altivec.c +--- MPlayer-1.0pre5.orig/postproc/yuv2rgb_altivec.c 2004-07-15 14:27:46.577707616 +0200 ++++ MPlayer-1.0pre5/postproc/yuv2rgb_altivec.c 2004-07-15 21:50:03.241567368 +0200 +@@ -67,6 +67,12 @@ + #include <inttypes.h> + #include <assert.h> + #include "config.h" ++#ifdef HAVE_ALTIVEC_H /* gnu */ ++#include <altivec.h> ++#define AVV(x...) {x} ++#else ++#define AVV(x...) (x) ++#endif + #include "rgb2rgb.h" + #include "swscale.h" + #include "swscale_internal.h" +@@ -118,14 +124,18 @@ + */ + static + const vector unsigned char +- perm_rgb_0 = (vector unsigned char)(0x00,0x01,0x10,0x02,0x03,0x11,0x04,0x05, +- 0x12,0x06,0x07,0x13,0x08,0x09,0x14,0x0a), +- perm_rgb_1 = (vector unsigned char)(0x0b,0x15,0x0c,0x0d,0x16,0x0e,0x0f,0x17, +- 0x18,0x19,0x1a,0x1b,0x1c,0x1d,0x1e,0x1f), +- perm_rgb_2 = (vector unsigned char)(0x10,0x11,0x12,0x13,0x14,0x15,0x16,0x17, +- 0x00,0x01,0x18,0x02,0x03,0x19,0x04,0x05), +- perm_rgb_3 = (vector unsigned char)(0x1a,0x06,0x07,0x1b,0x08,0x09,0x1c,0x0a, +- 0x0b,0x1d,0x0c,0x0d,0x1e,0x0e,0x0f,0x1f); ++ perm_rgb_0 = (const vector unsigned char) ++ AVV(0x00,0x01,0x10,0x02,0x03,0x11,0x04,0x05, ++ 0x12,0x06,0x07,0x13,0x08,0x09,0x14,0x0a), ++ perm_rgb_1 = (const vector unsigned char) ++ AVV(0x0b,0x15,0x0c,0x0d,0x16,0x0e,0x0f,0x17, ++ 0x18,0x19,0x1a,0x1b,0x1c,0x1d,0x1e,0x1f), ++ perm_rgb_2 = (const vector unsigned char) ++ AVV(0x10,0x11,0x12,0x13,0x14,0x15,0x16,0x17, ++ 0x00,0x01,0x18,0x02,0x03,0x19,0x04,0x05), ++ perm_rgb_3 = (const vector unsigned char) ++ AVV(0x1a,0x06,0x07,0x1b,0x08,0x09,0x1c,0x0a, ++ 0x0b,0x1d,0x0c,0x0d,0x1e,0x0e,0x0f,0x1f); + + #define vec_merge3(x2,x1,x0,y0,y1,y2) \ + do { \ +@@ -197,25 +207,23 @@ + + #define vec_unh(x) \ + (vector signed short) \ +- vec_perm(x,(typeof(x))(0),\ +- (vector unsigned char)(0x10,0x00,0x10,0x01,0x10,0x02,0x10,0x03,\ ++ vec_perm(x,(typeof(x))vec_splat_u32(0),\ ++ (vector unsigned char)AVV(0x10,0x00,0x10,0x01,0x10,0x02,0x10,0x03,\ + 0x10,0x04,0x10,0x05,0x10,0x06,0x10,0x07)) + #define vec_unl(x) \ + (vector signed short) \ +- vec_perm(x,(typeof(x))(0),\ +- (vector unsigned char)(0x10,0x08,0x10,0x09,0x10,0x0A,0x10,0x0B,\ ++ vec_perm(x,(typeof(x))vec_splat_u32(0),\ ++ (vector unsigned char)AVV(0x10,0x08,0x10,0x09,0x10,0x0A,0x10,0x0B,\ + 0x10,0x0C,0x10,0x0D,0x10,0x0E,0x10,0x0F)) + +-#define vec_clip(x) \ +- vec_max (vec_min (x, (typeof(x))(255)), (typeof(x))(0)) +- +-#define vec_packclp_a(x,y) \ +- (vector unsigned char)vec_pack (vec_clip (x), vec_clip (y)) ++#define vec_clip_s16(x) \ ++ vec_max (vec_min (x, (vector signed short)vec_splat_s16(255)),\ ++ (vector signed short)vec_splat_s16(0)) + + #define vec_packclp(x,y) \ + (vector unsigned char)vec_packs \ +- ((vector unsigned short)vec_max (x,(vector signed short) (0)), \ +- (vector unsigned short)vec_max (y,(vector signed short) (0))) ++ ((vector unsigned short)vec_max (x,(vector signed short)vec_splat_u32(0)), \ ++ (vector unsigned short)vec_max (y,(vector signed short)vec_splat_u32(0))) + + //#define out_pixels(a,b,c,ptr) vec_mstrgb32(typeof(a),((typeof (a))(0)),a,a,a,ptr) + +@@ -228,8 +236,10 @@ + + Y = vec_mradds (Y, c->CY, c->OY); + +- U = vec_sub (U,(vector signed short)(128)); +- V = vec_sub (V,(vector signed short)(128)); ++ U = vec_sub (U,(vector signed short)AVV(128,128,128,128, ++ 128,128,128,128)); ++ V = vec_sub (V,(vector signed short)AVV(128,128,128,128, ++ 128,128,128,128)); + + // ux = (CBU*(u<<c->CSHIFT)+0x4000)>>15; + ux = vec_sl (U, c->CSHIFT); +@@ -323,8 +333,16 @@ + align_perm = vec_lvsl (0, vi); \ + v = (vector signed char)vec_perm (vivP[0], vivP[1], align_perm); \ + \ +- u = (vector signed char)vec_sub (u, (vector signed char)(128)); \ +- v = (vector signed char)vec_sub (v, (vector signed char)(128)); \ ++ u = (vector signed char)vec_sub (u, \ ++ (vector signed char)AVV(128,128,128,128, \ ++ 128,128,128,128, \ ++ 128,128,128,128, \ ++ 128,128,128,128)); \ ++ v = (vector signed char)vec_sub (v, \ ++ (vector signed char)AVV(128,128,128,128, \ ++ 128,128,128,128, \ ++ 128,128,128,128, \ ++ 128,128,128,128)); \ + U = vec_unpackh (u); \ + V = vec_unpackh (v); \ + \ +@@ -341,18 +359,18 @@ + \ + /* ux = (CBU*(u<<CSHIFT)+0x4000)>>15 */ \ + ux = vec_sl (U, lCSHIFT); \ +- ux = vec_mradds (ux, lCBU, (vector signed short)(0)); \ ++ ux = vec_mradds (ux, lCBU, (vector signed short)vec_splat_s16(0)); \ + ux0 = vec_mergeh (ux,ux); \ + ux1 = vec_mergel (ux,ux); \ + \ + /* vx = (CRV*(v<<CSHIFT)+0x4000)>>15; */ \ + vx = vec_sl (V, lCSHIFT); \ +- vx = vec_mradds (vx, lCRV, (vector signed short)(0)); \ ++ vx = vec_mradds (vx, lCRV, (vector signed short)vec_splat_s16(0)); \ + vx0 = vec_mergeh (vx,vx); \ + vx1 = vec_mergel (vx,vx); \ + \ + /* uvx = ((CGU*u) + (CGV*v))>>15 */ \ +- uvx = vec_mradds (U, lCGU, (vector signed short)(0)); \ ++ uvx = vec_mradds (U, lCGU, (vector signed short)vec_splat_s16(0)); \ + uvx = vec_mradds (V, lCGV, uvx); \ + uvx0 = vec_mergeh (uvx,uvx); \ + uvx1 = vec_mergel (uvx,uvx); \ +@@ -402,10 +420,14 @@ + } + + +-#define out_abgr(a,b,c,ptr) vec_mstrgb32(typeof(a),((typeof (a))(0)),c,b,a,ptr) +-#define out_bgra(a,b,c,ptr) vec_mstrgb32(typeof(a),c,b,a,((typeof (a))(0)),ptr) +-#define out_rgba(a,b,c,ptr) vec_mstrgb32(typeof(a),a,b,c,((typeof (a))(0)),ptr) +-#define out_argb(a,b,c,ptr) vec_mstrgb32(typeof(a),((typeof (a))(0)),a,b,c,ptr) ++#define out_abgr(a,b,c,ptr) vec_mstrgb32(typeof(a),\ ++ ((typeof (a))vec_splat_u32(0)),c,b,a,ptr) ++#define out_bgra(a,b,c,ptr) vec_mstrgb32(typeof(a),\ ++ c,b,a,((typeof (a))vec_splat_u32(0)),ptr) ++#define out_rgba(a,b,c,ptr) vec_mstrgb32(typeof(a),\ ++ a,b,c,((typeof (a))vec_splat_u32(0)),ptr) ++#define out_argb(a,b,c,ptr) vec_mstrgb32(typeof(a),\ ++ ((typeof (a))vec_splat_u32(0)),a,b,c,ptr) + #define out_rgb24(a,b,c,ptr) vec_mstrgb24(a,b,c,ptr) + #define out_bgr24(a,b,c,ptr) vec_mstrgb24(c,b,a,ptr) + +@@ -421,18 +443,18 @@ + // 0123 4567 89ab cdef + static + const vector unsigned char +- demux_u = (vector unsigned char)(0x10,0x00,0x10,0x00, +- 0x10,0x04,0x10,0x04, +- 0x10,0x08,0x10,0x08, +- 0x10,0x0c,0x10,0x0c), +- demux_v = (vector unsigned char)(0x10,0x02,0x10,0x02, +- 0x10,0x06,0x10,0x06, +- 0x10,0x0A,0x10,0x0A, +- 0x10,0x0E,0x10,0x0E), +- demux_y = (vector unsigned char)(0x10,0x01,0x10,0x03, +- 0x10,0x05,0x10,0x07, +- 0x10,0x09,0x10,0x0B, +- 0x10,0x0D,0x10,0x0F); ++ demux_u = (const vector unsigned char)AVV(0x10,0x00,0x10,0x00, ++ 0x10,0x04,0x10,0x04, ++ 0x10,0x08,0x10,0x08, ++ 0x10,0x0c,0x10,0x0c), ++ demux_v = (const vector unsigned char)AVV(0x10,0x02,0x10,0x02, ++ 0x10,0x06,0x10,0x06, ++ 0x10,0x0A,0x10,0x0A, ++ 0x10,0x0E,0x10,0x0E), ++ demux_y = (const vector unsigned char)AVV(0x10,0x01,0x10,0x03, ++ 0x10,0x05,0x10,0x07, ++ 0x10,0x09,0x10,0x0B, ++ 0x10,0x0D,0x10,0x0F); + + /* + this is so I can play live CCIR raw video +@@ -460,25 +482,25 @@ + for (j=0;j<w/16;j++) { + uyvy = vec_ld (0, img); + U = (vector signed short) +- vec_perm (uyvy, (vector unsigned char)(0), demux_u); ++ vec_perm (uyvy, (vector unsigned char)vec_splat_u32(0), demux_u); + + V = (vector signed short) +- vec_perm (uyvy, (vector unsigned char)(0), demux_v); ++ vec_perm (uyvy, (vector unsigned char)vec_splat_u32(0), demux_v); + + Y = (vector signed short) +- vec_perm (uyvy, (vector unsigned char)(0), demux_y); ++ vec_perm (uyvy, (vector unsigned char)vec_splat_u32(0), demux_y); + + cvtyuvtoRGB (c, Y,U,V,&R0,&G0,&B0); + + uyvy = vec_ld (16, img); + U = (vector signed short) +- vec_perm (uyvy, (vector unsigned char)(0), demux_u); ++ vec_perm (uyvy, (vector unsigned char)vec_splat_u32(0), demux_u); + + V = (vector signed short) +- vec_perm (uyvy, (vector unsigned char)(0), demux_v); ++ vec_perm (uyvy, (vector unsigned char)vec_splat_u32(0), demux_v); + + Y = (vector signed short) +- vec_perm (uyvy, (vector unsigned char)(0), demux_y); ++ vec_perm (uyvy, (vector unsigned char)vec_splat_u32(0), demux_y); + + cvtyuvtoRGB (c, Y,U,V,&R1,&G1,&B1); + +@@ -504,7 +526,7 @@ + */ + SwsFunc yuv2rgb_init_altivec (SwsContext *c) + { +- if (!(c->flags & SWS_CPU_CAPS_ALTIVEC)) ++ if (!(c->flags & SWS_CPU_CAPS_ALTIVEC)) + return NULL; + + /* +@@ -569,15 +591,16 @@ + int yuv2rgb_altivec_init_tables (SwsContext *c, const int inv_table[4]) + { + +- vector signed short ++ vector signed short CY,CRV,CBU,CGU,CGV,OY; ++/* stray code? + CY = (vector signed short)(0x7fff), + CRV = (vector signed short)(22972), + CBU = (vector signed short)(29029), + CGU = (vector signed short)(-11276), + CGV = (vector signed short)(-23400), + OY; +- +- vector unsigned short CSHIFT = (vector unsigned short)(1); ++*/ ++ vector unsigned short CSHIFT = (vector unsigned short)vec_splat_u16(1); + + vector signed short Y0; + int brightness = c->brightness, contrast = c->contrast, saturation = c->saturation; +@@ -589,7 +612,7 @@ + + int64_t cy = (1<<16)-1; + int64_t oy = 0; +- ++/* really needed? FIXME*/ + if ((c->flags & SWS_CPU_CAPS_ALTIVEC) == 0) + return; + +@@ -621,6 +644,7 @@ + //printf("%llx %llx %llx %llx %llx\n", cy, crv, cbu, cgu, cgv); + + // vector signed short CBU,CRV,CGU,CGY,CY; ++ /*why not use vec_splat_${type} ??*/ + tmp = cy; + CY = vec_lde (0, &tmp); + CY = vec_splat (CY, 0); +@@ -643,7 +667,7 @@ + CGV = vec_lde (0, &tmp); + CGV = vec_splat (CGV, 0); + +- CSHIFT = (vector unsigned short)(2); ++ CSHIFT = (vector unsigned short)vec_splat_u16(2); + #if 1 + c->CSHIFT = CSHIFT; + c->CY = CY; +@@ -679,8 +703,8 @@ + + vector unsigned char R,G,B,pels[3]; + vector unsigned char *out,*nout; +- vector signed short RND = (vector signed short)(1<<3); +- vector unsigned short SCL = (vector unsigned short)(4); ++ vector signed short RND = (vector signed short)vec_splat_s16(1<<3); ++ vector unsigned short SCL = (vector unsigned short)vec_splat_u16(4); + unsigned long scratch[16] __attribute__ ((aligned (16))); + + vector signed short *vYCoeffsBank, *vCCoeffsBank; +@@ -736,10 +760,10 @@ + U = vec_sra (U, SCL); + V = vec_sra (V, SCL); + +- Y0 = vec_clip (Y0); +- Y1 = vec_clip (Y1); +- U = vec_clip (U); +- V = vec_clip (V); ++ Y0 = vec_clip_s16 (Y0); ++ Y1 = vec_clip_s16 (Y1); ++ U = vec_clip_s16 (U); ++ V = vec_clip_s16 (V); + + /* now we have + Y0= y0 y1 y2 y3 y4 y5 y6 y7 Y1= y8 y9 y10 y11 y12 y13 y14 y15 +@@ -795,10 +819,10 @@ + U = vec_sra (U, SCL); + V = vec_sra (V, SCL); + +- Y0 = vec_clip (Y0); +- Y1 = vec_clip (Y1); +- U = vec_clip (U); +- V = vec_clip (V); ++ Y0 = vec_clip_s16 (Y0); ++ Y1 = vec_clip_s16 (Y1); ++ U = vec_clip_s16 (U); ++ V = vec_clip_s16 (V); + + /* now we have + Y0= y0 y1 y2 y3 y4 y5 y6 y7 Y1= y8 y9 y10 y11 y12 y13 y14 y15 diff --git a/media-video/mplayer/mplayer-1.0_pre5.ebuild b/media-video/mplayer/mplayer-1.0_pre5.ebuild index c1a3165b2b27..15f2020be856 100644 --- a/media-video/mplayer/mplayer-1.0_pre5.ebuild +++ b/media-video/mplayer/mplayer-1.0_pre5.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2004 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/media-video/mplayer/mplayer-1.0_pre5.ebuild,v 1.4 2004/07/15 08:26:31 chriswhite Exp $ +# $Header: /var/cvsroot/gentoo-x86/media-video/mplayer/mplayer-1.0_pre5.ebuild,v 1.5 2004/07/15 20:44:40 lu_zero Exp $ inherit eutils flag-o-matic kmod @@ -115,6 +115,9 @@ src_unpack() { # GCC 3.4 fixes epatch ${FILESDIR}/mplayer-1.0_pre4-alsa-gcc34.patch # fixes for mga driver with kernel 2.6 + + #Workaround for the altivec softscaler issues + epatch ${FILESDIR}/mplayer-1.0_pre5-yuv2rbg_kludge.patch if use matrox; then get_kernel_info |