diff options
author | Uoti Urpala <uau@symbol.nonexistent.invalid> | 2008-07-25 02:14:16 +0300 |
---|---|---|
committer | Uoti Urpala <uau@symbol.nonexistent.invalid> | 2008-07-25 02:50:58 +0300 |
commit | 3a69d65f8d07c54f4c9eb2d9c89ab50e35d0a50d (patch) | |
tree | 1ba215c9978eadcd6b99b2c696b22ea6a3779e33 | |
parent | 577587ec6ce8dad59c303a76cba03af03db879a3 (diff) | |
parent | 901574e3bf6ff45a46a12dc7884a93970f9d58d1 (diff) | |
download | mpv-3a69d65f8d07c54f4c9eb2d9c89ab50e35d0a50d.tar.bz2 mpv-3a69d65f8d07c54f4c9eb2d9c89ab50e35d0a50d.tar.xz |
Merge svn changes up to r27347
Conflicts:
libvo/x11_common.c
libvo/x11_common.h
Rename the vo_gl macro "vo_border()" to "vo_gl_border" as it conflicts
with the global variable "vo_border"; done in the merge commit because
uses of the macro needed changes anyway to resolve conflicts.
-rw-r--r-- | DOCS/man/en/mplayer.1 | 6 | ||||
-rw-r--r-- | DOCS/man/fr/mplayer.1 | 3 | ||||
-rw-r--r-- | DOCS/man/it/mplayer.1 | 3 | ||||
-rw-r--r-- | DOCS/tech/mirrors/mirror_howto.txt | 41 | ||||
-rwxr-xr-x | configure | 88 | ||||
-rw-r--r-- | etc/codecs.conf | 16 | ||||
-rw-r--r-- | libmpcodecs/ve_lavc.c | 4 | ||||
-rw-r--r-- | libswscale/yuv2rgb_altivec.c | 106 | ||||
-rw-r--r-- | libvo/gl_common.h | 2 | ||||
-rw-r--r-- | libvo/vo_gl.c | 4 | ||||
-rw-r--r-- | libvo/vo_gl2.c | 4 | ||||
-rw-r--r-- | libvo/x11_common.c | 9 | ||||
-rw-r--r-- | libvo/x11_common.h | 1 |
13 files changed, 212 insertions, 75 deletions
diff --git a/DOCS/man/en/mplayer.1 b/DOCS/man/en/mplayer.1 index bd94ed3c93..8fe9601867 100644 --- a/DOCS/man/en/mplayer.1 +++ b/DOCS/man/en/mplayer.1 @@ -2888,7 +2888,6 @@ Only supported by the fbdev, dga, svga, vesa video output drivers. Play movie with window border and decorations. Since this is on by default, use \-noborder to disable the standard window decorations. -Supported by the directx video output driver. . .TP .B \-brightness <\-100\-100> @@ -3237,7 +3236,7 @@ This tells MPlayer to attach to an existing window. Useful to embed MPlayer in a browser (e.g.\& the plugger extension). . .TP -.B \-xineramascreen <\-2\-...> (X11 only) +.B \-xineramascreen <\-2\-...> In Xinerama configurations (i.e.\& a single desktop that spans across multiple displays) this option tells MPlayer which screen to display the movie on. A value of \-2 means fullscreen across the whole virtual display (in this case @@ -3246,6 +3245,9 @@ fullscreen on the display the window currently is on. The initial position set via the \-geometry option is relative to the specified screen. Will usually only work with "\-fstype \-fullscreen" or "\-fstype none". +This option is not suitable to only set the startup screen (and not also the +fullscreen screen), \-geometry is the best that is available for that purpose +currently. . .TP .B \-zrbw (\-vo zr only) diff --git a/DOCS/man/fr/mplayer.1 b/DOCS/man/fr/mplayer.1 index a5144ed389..9479e66411 100644 --- a/DOCS/man/fr/mplayer.1 +++ b/DOCS/man/fr/mplayer.1 @@ -1,4 +1,4 @@ -.\" synced with r27236 +.\" synced with r27337 .\" Encoding: iso-8859-1 .\" MPlayer (C) 2000-2008 MPlayer Team .\" The English man page was/is done by Gabucino, Diego Biurrun, Jonas Jermann @@ -3044,7 +3044,6 @@ Géré uniquement par les pilotes de sortie vidéo fbdev, dga, svga, vesa. Joue la vidéo avec les bordures et décorations de fenêtre (par défaut). Spécifiez \-noborder pour désactiver les décorations de fenêtre standard. -Supporté par le pilote de sortie vidéo directx. . .TP .B \-brightness <\-100\-100> diff --git a/DOCS/man/it/mplayer.1 b/DOCS/man/it/mplayer.1 index 86424a92fe..d765a0e22a 100644 --- a/DOCS/man/it/mplayer.1 +++ b/DOCS/man/it/mplayer.1 @@ -1,4 +1,4 @@ -.\" synced with r27236 +.\" synced with r27337 .\" Encoding: iso-8859-1 .\" MPlayer (C) 2000-2008 MPlayer Team .\" Questa pagina di manuale è stata fatta da Gabucino, Diego Biurrun, @@ -3011,7 +3011,6 @@ Supportato solo dai driver di uscita video fbdev, dga, svga e vesa. Riproduce il filmato in una finestra con bordi e decorazioni. Dato che questo è il default, usa \-noborder per disabilitare le decorazioni standard della finestra. -Supportato dal driver di uscita video directx. . .TP .B \-brightness <\-100\-100> diff --git a/DOCS/tech/mirrors/mirror_howto.txt b/DOCS/tech/mirrors/mirror_howto.txt index 92dbe81fd2..054e8971b9 100644 --- a/DOCS/tech/mirrors/mirror_howto.txt +++ b/DOCS/tech/mirrors/mirror_howto.txt @@ -48,7 +48,7 @@ Requirements ~~~~~~~~~~~~ The requirements for any (official) mirror are: 1) rsync installed and some way to run the sync script periodicaly (eg cron) -2) subscribing to the mplayer-mirror mailinglist (see below) +2) subscribing to the mplayer-mirror mailing list (see below) The requirements for a full website mirror are: 1) 500MB of free disk space (for the ftp and homepage directories). @@ -188,21 +188,46 @@ appear to default to defining a standard charset. This breaks our documentation translations, which are written in different encodings. The second VirtualHost is necessary for the DNS round-robin address. +To check whether this VirtualHost works, you can add a temporary entry into +your /etc/hosts file: + +1.2.3.4 www.mplayerhq.hu + +Replace the IP address by the real IP address of your mirror. Do not forget to +remove the entry after you finish testing. + + +Webserver checklist +~~~~~~~~~~~~~~~~~~~ + +After setting up the web server, please verify that the following things work +both for your mirror address (www#.mplayerhq.hu) and the DNS round-robin +address (www.mplayerhq.hu): + +- The virtual host is reachable by its address. +- The subdirectories MPlayer, DOCS and homepage work. +- The man pages and documentation are served with the correct content-type. + Try Russian or Chinese, you will notice breakage immediately. Setting up an FTP server ~~~~~~~~~~~~~~~~~~~~~~~~ -Any FTP server will do. We use vsftpd, it's fast and secure. You should have -the same directory layout as we do on our server, so there should be a -subdirectory named 'MPlayer' (notice the capitals) that contains the -downloadable files. +Any FTP server will do. We use vsftpd, it is fast and secure. The setup is +similar to the web server setup. The FTP server should listen on both its mirror +address (ftp#.mplayerhq.hu) and the DNS round-robin address (ftp.mplayerhq.hu). +All our mirrors are public, so you should allow anonymous access. +You should have the same directory layout as we do on our server, so there +should be a subdirectory named 'MPlayer' (notice the capitals) that contains +the downloadable files. -Mailinglist -~~~~~~~~~~~ + +Mailing list +~~~~~~~~~~~~ All official mirror admins are required to subscribe to the mplayer-mirror -mailinglist. It's used to coordinate the efforts and distribute information +mailing list. It's used to coordinate the efforts and distribute information among all admins. It is also very low traffic. Please use the webinterface on http://lists.mplayerhq.hu/mailman/listinfo/mplayer-mirror to subscribe. +Please do not top-post on this mailing list. @@ -292,6 +292,9 @@ Codecs: --disable-xvid-lavc disable Xvid in libavcodec [autodetect] --disable-x264 disable x264 [autodetect] --disable-x264-lavc disable x264 in libavcodec [autodetect] + --disable-libdirac-lavc disable Dirac in libavcodec [autodetect] + --disable-libschroedinger-lavc disable Dirac in libavcodec (Schroedinger + decoder) [autodetect] --disable-libnut disable libnut [autodetect] --disable-libavutil_a disable static libavutil [autodetect] --disable-libavcodec_a disable static libavcodec [autodetect] @@ -633,6 +636,8 @@ _xvid=auto _xvid_lavc=auto _x264=auto _x264_lavc=auto +_libdirac_lavc=auto +_libschroedinger_lavc=auto _libnut=auto _lirc=auto _lircc=auto @@ -1044,6 +1049,10 @@ for ac_option do --disable-x264) _x264=no ;; --enable-x264-lavc) _x264_lavc=yes ;; --disable-x264-lavc) _x264_lavc=no ;; + --enable-libdirac-lavc) _libdirac_lavc=yes ;; + --disable-libdirac-lavc) _libdirac_lavc=no ;; + --enable-libschroedinger-lavc) _libschroedinger_lavc=yes ;; + --disable-libschroedinger-lavc) _libschroedinger_lavc=no ;; --enable-libnut) _libnut=yes ;; --disable-libnut) _libnut=no ;; --enable-libavutil_a) _libavutil_a=yes ;; @@ -6659,6 +6668,79 @@ _res_comment="in libavcodec: $_x264_lavc" echores "$_x264" +echocheck "libdirac" +if test "$_libdirac_lavc" = auto; then + _libdirac_lavc=no + if test "$_libavcodec_a" != yes; then + _res_comment="libavcodec (static) is required by libdirac, sorry" + else + cat > $TMPC << EOF +#include <libdirac_encoder/dirac_encoder.h> +#include <libdirac_decoder/dirac_parser.h> +int main(void) +{ + dirac_encoder_context_t enc_ctx; + dirac_decoder_t *dec_handle; + dirac_encoder_context_init(&enc_ctx, VIDEO_FORMAT_SD_576I50); + dec_handle = dirac_decoder_init(0); + if (dec_handle) + dirac_decoder_close(dec_handle); + return 0; +} +EOF + if $_pkg_config --exists dirac ; then + _inc_dirac=`$_pkg_config --silence-errors --cflags dirac` + _ld_dirac=`$_pkg_config --silence-errors --libs dirac` + cc_check $_inc_dirac $_ld_dirac && + _libdirac_lavc=yes && + _inc_extra="$_inc_extra $_inc_dirac" && + _ld_extra="$_ld_extra $_ld_dirac" + fi + fi +fi +if test "$_libdirac_lavc" = yes ; then + _def_libdirac_lavc='#define CONFIG_LIBDIRAC 1' + _libavencoders="$_libavencoders LIBDIRAC_ENCODER" + _libavdecoders="$_libavdecoders LIBDIRAC_DECODER" + _codecmodules="libdirac $_codecmodules" +else + _def_libdirac_lavc='#undef CONFIG_LIBDIRAC' + _nocodecmodules="libdirac $_nocodecmodules" +fi +echores "$_libdirac_lavc" + + +echocheck "libschroedinger" +if test "$_libschroedinger_lavc" = auto ; then + _libschroedinger_lavc=no + if test "$_libavcodec_a" != yes; then + _res_comment="libavcodec (static) is required by libschroedinger, sorry" + else + cat > $TMPC << EOF +#include <schroedinger/schro.h> +int main(void) { schro_init(); return 0; } +EOF + if $_pkg_config --exists schroedinger-1.0 ; then + _inc_schroedinger=`$_pkg_config --silence-errors --cflags schroedinger-1.0` + _ld_schroedinger=`$_pkg_config --silence-errors --libs schroedinger-1.0` + cc_check $_inc_schroedinger $_ld_schroedinger && + _libschroedinger_lavc=yes && + _inc_extra="$_inc_extra $_inc_schroedinger" && + _ld_extra="$_ld_extra $_ld_schroedinger" + fi + fi +fi +if test "$_libschroedinger_lavc" = yes ; then + _def_libschroedinger_lavc='#define CONFIG_LIBSCHROEDINGER 1' + _libavencoders="$_libavencoders LIBSCHROEDINGER_ENCODER" + _libavdecoders="$_libavdecoders LIBSCHROEDINGER_DECODER" + _codecmodules="libschroedinger $_codecmodules" +else + _def_libschroedinger_lavc='#undef CONFIG_LIBSCHROEDINGER' + _nocodecmodules="libschroedinger $_nocodecmodules" +fi +echores "$_libschroedinger_lavc" + echocheck "libnut" if test "$_libnut" = auto ; then cat > $TMPC << EOF @@ -7383,7 +7465,7 @@ else _def_charset="#undef MSG_CHARSET" fi -if test "$_charset" != "UTF-8" ; then +if test -n "$_charset" && test "$_charset" != "UTF-8" ; then echocheck "iconv program" iconv -f UTF-8 -t $_charset ${_mp_help} > /dev/null 2>> "$TMPLOG" if test "$?" -ne 0 ; then @@ -7827,8 +7909,10 @@ CONFIG_MUXERS=$_mencoder CONFIG_LIBAMR=$_libamr CONFIG_LIBAMR_NB=$_libamr_nb CONFIG_LIBAMR_WB=$_libamr_wb +CONFIG_LIBDIRAC=$_libdirac_lavc CONFIG_LIBFAAC=$_faac_lavc CONFIG_LIBMP3LAME=$_mp3lame_lavc +CONFIG_LIBSCHROEDINGER=$_libschroedinger_lavc CONFIG_LIBVORBIS=$_libvorbis CONFIG_LIBX264=$_x264_lavc CONFIG_LIBXVID=$_xvid_lavc @@ -8224,8 +8308,10 @@ $_def_libamr_wb `ff_config_enable "$_libavprotocols_all" "$_libavprotocols"` `ff_config_enable "$_libavbsfs_all" "$_libavbsfs"` +$_def_libdirac_lavc $_def_faac_lavc $_def_mp3lame_lavc +$_def_libschroedinger_lavc $_def_x264_lavc $_def_xvid_lavc diff --git a/etc/codecs.conf b/etc/codecs.conf index 5e3847d243..aa539fbdcf 100644 --- a/etc/codecs.conf +++ b/etc/codecs.conf @@ -708,6 +708,22 @@ videocodec ffwv1f dll mpeg4 out YV12,I420,IYUV flip +videocodec fflibschroedinger + info "Dirac (through FFmpeg libschroedinger)" + status working + fourcc drac + driver ffmpeg + dll libschroedinger + out I420,IYUV,422P,444P + +videocodec fflibdirac + info "Dirac (through FFmpeg libdirac)" + status working + fourcc drac + driver ffmpeg + dll libdirac + out I420,IYUV,422P,444P + videocodec xvid info "Xvid (MPEG-4)" status working diff --git a/libmpcodecs/ve_lavc.c b/libmpcodecs/ve_lavc.c index f217258c0b..535791fdc9 100644 --- a/libmpcodecs/ve_lavc.c +++ b/libmpcodecs/ve_lavc.c @@ -1021,6 +1021,10 @@ static int vf_open(vf_instance_t *vf, char* args){ mux_v->bih->biCompression = mmioFOURCC('d', 'v', 's', 'd'); else if (!strcasecmp(lavc_param_vcodec, "libx264")) mux_v->bih->biCompression = mmioFOURCC('h', '2', '6', '4'); + else if (!strcasecmp(lavc_param_vcodec, "libschroedinger")) + mux_v->bih->biCompression = mmioFOURCC('d', 'r', 'a', 'c'); + else if (!strcasecmp(lavc_param_vcodec, "libdirac")) + mux_v->bih->biCompression = mmioFOURCC('d', 'r', 'a', 'c'); else mux_v->bih->biCompression = mmioFOURCC(lavc_param_vcodec[0], lavc_param_vcodec[1], lavc_param_vcodec[2], lavc_param_vcodec[3]); /* FIXME!!! */ diff --git a/libswscale/yuv2rgb_altivec.c b/libswscale/yuv2rgb_altivec.c index 13b18d10d3..3cba5ab153 100644 --- a/libswscale/yuv2rgb_altivec.c +++ b/libswscale/yuv2rgb_altivec.c @@ -143,14 +143,14 @@ typedef signed char sbyte; */ static const vector unsigned char - perm_rgb_0 = AVV(0x00,0x01,0x10,0x02,0x03,0x11,0x04,0x05, - 0x12,0x06,0x07,0x13,0x08,0x09,0x14,0x0a), - perm_rgb_1 = AVV(0x0b,0x15,0x0c,0x0d,0x16,0x0e,0x0f,0x17, - 0x18,0x19,0x1a,0x1b,0x1c,0x1d,0x1e,0x1f), - perm_rgb_2 = AVV(0x10,0x11,0x12,0x13,0x14,0x15,0x16,0x17, - 0x00,0x01,0x18,0x02,0x03,0x19,0x04,0x05), - perm_rgb_3 = AVV(0x1a,0x06,0x07,0x1b,0x08,0x09,0x1c,0x0a, - 0x0b,0x1d,0x0c,0x0d,0x1e,0x0e,0x0f,0x1f); + perm_rgb_0 = {0x00,0x01,0x10,0x02,0x03,0x11,0x04,0x05, + 0x12,0x06,0x07,0x13,0x08,0x09,0x14,0x0a}, + perm_rgb_1 = {0x0b,0x15,0x0c,0x0d,0x16,0x0e,0x0f,0x17, + 0x18,0x19,0x1a,0x1b,0x1c,0x1d,0x1e,0x1f}, + perm_rgb_2 = {0x10,0x11,0x12,0x13,0x14,0x15,0x16,0x17, + 0x00,0x01,0x18,0x02,0x03,0x19,0x04,0x05}, + perm_rgb_3 = {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 { \ @@ -222,25 +222,25 @@ do { \ #define vec_unh(x) \ (vector signed short) \ - vec_perm(x,(typeof(x))AVV(0),\ - (vector unsigned char)AVV(0x10,0x00,0x10,0x01,0x10,0x02,0x10,0x03,\ - 0x10,0x04,0x10,0x05,0x10,0x06,0x10,0x07)) + vec_perm(x,(typeof(x)){0}, \ + (vector unsigned char){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))AVV(0),\ - (vector unsigned char)AVV(0x10,0x08,0x10,0x09,0x10,0x0A,0x10,0x0B,\ - 0x10,0x0C,0x10,0x0D,0x10,0x0E,0x10,0x0F)) + vec_perm(x,(typeof(x)){0}, \ + (vector unsigned char){0x10,0x08,0x10,0x09,0x10,0x0A,0x10,0x0B,\ + 0x10,0x0C,0x10,0x0D,0x10,0x0E,0x10,0x0F}) #define vec_clip_s16(x) \ - vec_max (vec_min (x, (vector signed short)AVV(235,235,235,235,235,235,235,235)),\ - (vector signed short)AVV( 16, 16, 16, 16, 16, 16, 16, 16)) + vec_max (vec_min (x, (vector signed short){235,235,235,235,235,235,235,235}), \ + (vector signed short){ 16, 16, 16, 16, 16, 16, 16, 16 }) #define vec_packclp(x,y) \ (vector unsigned char)vec_packs \ - ((vector unsigned short)vec_max (x,(vector signed short) AVV(0)), \ - (vector unsigned short)vec_max (y,(vector signed short) AVV(0))) + ((vector unsigned short)vec_max (x,(vector signed short) {0}), \ + (vector unsigned short)vec_max (y,(vector signed short) {0})) -//#define out_pixels(a,b,c,ptr) vec_mstrgb32(typeof(a),((typeof (a))AVV(0)),a,a,a,ptr) +//#define out_pixels(a,b,c,ptr) vec_mstrgb32(typeof(a),((typeof (a)){0}),a,a,a,ptr) static inline void cvtyuvtoRGB (SwsContext *c, @@ -251,9 +251,9 @@ static inline void cvtyuvtoRGB (SwsContext *c, Y = vec_mradds (Y, c->CY, c->OY); U = vec_sub (U,(vector signed short) - vec_splat((vector signed short)AVV(128),0)); + vec_splat((vector signed short){128},0)); V = vec_sub (V,(vector signed short) - vec_splat((vector signed short)AVV(128),0)); + vec_splat((vector signed short){128},0)); // ux = (CBU*(u<<c->CSHIFT)+0x4000)>>15; ux = vec_sl (U, c->CSHIFT); @@ -359,10 +359,10 @@ static int altivec_##name (SwsContext *c, \ \ u = (vector signed char) \ vec_sub (u,(vector signed char) \ - vec_splat((vector signed char)AVV(128),0)); \ + vec_splat((vector signed char){128},0)); \ v = (vector signed char) \ vec_sub (v,(vector signed char) \ - vec_splat((vector signed char)AVV(128),0)); \ + vec_splat((vector signed char){128},0)); \ \ U = vec_unpackh (u); \ V = vec_unpackh (v); \ @@ -380,18 +380,18 @@ static int altivec_##name (SwsContext *c, \ \ /* ux = (CBU*(u<<CSHIFT)+0x4000)>>15 */ \ ux = vec_sl (U, lCSHIFT); \ - ux = vec_mradds (ux, lCBU, (vector signed short)AVV(0)); \ + ux = vec_mradds (ux, lCBU, (vector signed short){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)AVV(0)); \ + vx = vec_mradds (vx, lCRV, (vector signed short){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)AVV(0)); \ + uvx = vec_mradds (U, lCGU, (vector signed short){0}); \ uvx = vec_mradds (V, lCGV, uvx); \ uvx0 = vec_mergeh (uvx,uvx); \ uvx1 = vec_mergel (uvx,uvx); \ @@ -441,10 +441,10 @@ static int altivec_##name (SwsContext *c, \ } -#define out_abgr(a,b,c,ptr) vec_mstrgb32(typeof(a),((typeof (a))AVV(0)),c,b,a,ptr) -#define out_bgra(a,b,c,ptr) vec_mstrgb32(typeof(a),c,b,a,((typeof (a))AVV(0)),ptr) -#define out_rgba(a,b,c,ptr) vec_mstrgb32(typeof(a),a,b,c,((typeof (a))AVV(0)),ptr) -#define out_argb(a,b,c,ptr) vec_mstrgb32(typeof(a),((typeof (a))AVV(0)),a,b,c,ptr) +#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_rgb24(a,b,c,ptr) vec_mstrgb24(a,b,c,ptr) #define out_bgr24(a,b,c,ptr) vec_mstbgr24(a,b,c,ptr) @@ -523,11 +523,11 @@ static int altivec_yuv2_bgra32 (SwsContext *c, v = (vector signed char)vec_perm (vivP[0], vivP[1], align_perm); u = (vector signed char) vec_sub (u,(vector signed char) - vec_splat((vector signed char)AVV(128),0)); + vec_splat((vector signed char){128},0)); v = (vector signed char) vec_sub (v, (vector signed char) - vec_splat((vector signed char)AVV(128),0)); + vec_splat((vector signed char){128},0)); U = vec_unpackh (u); V = vec_unpackh (v); @@ -545,17 +545,17 @@ static int altivec_yuv2_bgra32 (SwsContext *c, /* ux = (CBU*(u<<CSHIFT)+0x4000)>>15 */ ux = vec_sl (U, lCSHIFT); - ux = vec_mradds (ux, lCBU, (vector signed short)AVV(0)); + ux = vec_mradds (ux, lCBU, (vector signed short){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)AVV(0)); + vx = vec_mradds (vx, lCRV, (vector signed short){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)AVV(0)); + uvx = vec_mradds (U, lCGU, (vector signed short){0}); uvx = vec_mradds (V, lCGV, uvx); uvx0 = vec_mergeh (uvx,uvx); uvx1 = vec_mergel (uvx,uvx); @@ -612,18 +612,18 @@ DEFCSP420_CVT (yuv2_bgr24, out_bgr24) // 0123 4567 89ab cdef static const vector unsigned char - demux_u = AVV(0x10,0x00,0x10,0x00, - 0x10,0x04,0x10,0x04, - 0x10,0x08,0x10,0x08, - 0x10,0x0c,0x10,0x0c), - demux_v = AVV(0x10,0x02,0x10,0x02, - 0x10,0x06,0x10,0x06, - 0x10,0x0A,0x10,0x0A, - 0x10,0x0E,0x10,0x0E), - demux_y = AVV(0x10,0x01,0x10,0x03, - 0x10,0x05,0x10,0x07, - 0x10,0x09,0x10,0x0B, - 0x10,0x0D,0x10,0x0F); + demux_u = {0x10,0x00,0x10,0x00, + 0x10,0x04,0x10,0x04, + 0x10,0x08,0x10,0x08, + 0x10,0x0c,0x10,0x0c}, + demux_v = {0x10,0x02,0x10,0x02, + 0x10,0x06,0x10,0x06, + 0x10,0x0A,0x10,0x0A, + 0x10,0x0E,0x10,0x0E}, + demux_y = {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 @@ -650,25 +650,25 @@ static int altivec_uyvy_rgb32 (SwsContext *c, for (j=0;j<w/16;j++) { uyvy = vec_ld (0, img); U = (vector signed short) - vec_perm (uyvy, (vector unsigned char)AVV(0), demux_u); + vec_perm (uyvy, (vector unsigned char){0}, demux_u); V = (vector signed short) - vec_perm (uyvy, (vector unsigned char)AVV(0), demux_v); + vec_perm (uyvy, (vector unsigned char){0}, demux_v); Y = (vector signed short) - vec_perm (uyvy, (vector unsigned char)AVV(0), demux_y); + vec_perm (uyvy, (vector unsigned char){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)AVV(0), demux_u); + vec_perm (uyvy, (vector unsigned char){0}, demux_u); V = (vector signed short) - vec_perm (uyvy, (vector unsigned char)AVV(0), demux_v); + vec_perm (uyvy, (vector unsigned char){0}, demux_v); Y = (vector signed short) - vec_perm (uyvy, (vector unsigned char)AVV(0), demux_y); + vec_perm (uyvy, (vector unsigned char){0}, demux_y); cvtyuvtoRGB (c, Y,U,V,&R1,&G1,&B1); diff --git a/libvo/gl_common.h b/libvo/gl_common.h index a7a4f8c2b1..8b1e4b144c 100644 --- a/libvo/gl_common.h +++ b/libvo/gl_common.h @@ -293,6 +293,7 @@ void glDisableYUVConversion(GLenum target, int type); /** \} */ #ifdef GL_WIN32 +#define vo_gl_border(vo) vo_w32_border() #define vo_check_events() vo_w32_check_events() #define vo_fullscreen() vo_w32_fullscreen() #define vo_gl_ontop() vo_w32_ontop() @@ -300,6 +301,7 @@ void glDisableYUVConversion(GLenum target, int type); int setGlWindow(int *vinfo, HGLRC *context, HWND win); void releaseGlContext(int *vinfo, HGLRC *context); #else +#define vo_gl_border(vo) vo_x11_border(vo) #define vo_check_events() vo_x11_check_events(mDisplay) #define vo_fullscreen() vo_x11_fullscreen() #define vo_gl_ontop() vo_x11_ontop() diff --git a/libvo/vo_gl.c b/libvo/vo_gl.c index d75b7b933f..5a1f3c43ff 100644 --- a/libvo/vo_gl.c +++ b/libvo/vo_gl.c @@ -999,12 +999,10 @@ static int control(uint32_t request, void *data) vo_fullscreen(); resize(vo_dwidth, vo_dheight); return VO_TRUE; -#ifdef GL_WIN32 case VOCTRL_BORDER: - vo_w32_border(); + vo_gl_border(global_vo); resize(vo_dwidth, vo_dheight); return VO_TRUE; -#endif case VOCTRL_GET_PANSCAN: if (!use_aspect) return VO_NOTIMPL; return VO_TRUE; diff --git a/libvo/vo_gl2.c b/libvo/vo_gl2.c index 68885c37c2..9af9b255c5 100644 --- a/libvo/vo_gl2.c +++ b/libvo/vo_gl2.c @@ -889,11 +889,9 @@ static int control(uint32_t request, void *data) initGl(vo_dwidth, vo_dheight); resize(&vo_dwidth, &vo_dheight); return VO_TRUE; -#ifdef GL_WIN32 case VOCTRL_BORDER: - vo_w32_border(); + vo_gl_border(global_vo); return VO_TRUE; -#endif case VOCTRL_GET_PANSCAN: return VO_TRUE; case VOCTRL_SET_PANSCAN: diff --git a/libvo/x11_common.c b/libvo/x11_common.c index d40efd8735..858acda3be 100644 --- a/libvo/x11_common.c +++ b/libvo/x11_common.c @@ -1289,6 +1289,7 @@ void vo_x11_create_vo_window(struct vo *vo, XVisualInfo *vis, int x, int y, hint.flags = PPosition | PSize; XSetStandardProperties(mDisplay, x11->window, title, title, None, NULL, 0, &hint); vo_x11_sizehint(vo, x, y, width, height, 0); + if (!vo_border) vo_x11_decoration(vo, 0); // map window XMapWindow(mDisplay, x11->window); XClearWindow(mDisplay, x11->window); @@ -1546,7 +1547,7 @@ void vo_x11_fullscreen(struct vo *vo) if ( ! (x11->fs_type & vo_wm_FULLSCREEN) ) // not needed with EWMH fs { - vo_x11_decoration(vo, (vo_fs) ? 0 : 1); + vo_x11_decoration(vo, vo_border && !vo_fs); vo_x11_sizehint(vo, x, y, w, h, 0); vo_x11_setlayer(vo, x11->window, vo_fs); @@ -1572,6 +1573,12 @@ void vo_x11_ontop(struct vo *vo) vo_x11_setlayer(vo, vo->x11->window, opts->vo_ontop); } +void vo_x11_border(struct vo *vo) +{ + vo_border = !vo_border; + vo_x11_decoration(vo, vo_border && !vo_fs); +} + /* * XScreensaver stuff */ diff --git a/libvo/x11_common.h b/libvo/x11_common.h index eef178d680..fdd4336924 100644 --- a/libvo/x11_common.h +++ b/libvo/x11_common.h @@ -108,6 +108,7 @@ void vo_x11_clearwindow_part(struct vo *vo, Window vo_window, int img_width, int img_height, int use_fs); void vo_x11_clearwindow(struct vo *vo, Window vo_window); void vo_x11_ontop(struct vo *vo); +extern void vo_x11_border(struct vo *vo); void vo_x11_ewmh_fullscreen(struct vo_x11_state *x11, int action); #endif |