![]() |
ubuntu.com - launchpad.net - ubuntu help
|
|
|||||||
Ubuntu 9.10 is out!!!
When downloading Ubuntu 9.10 please consider using bittorrent to get your copy of Ubuntu. The Ubuntu Developers Summit for Lucid Lynx will be held the week of 16-Nov-2009 till 20-Nov-2009 in Dallas, TX USA. Visit the the Ubuntu wiki for more information about UDS and how to participate remotely. |
|
Tutorials & Tips The place to find Ubuntu related Tips & Tricks. |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Ubuntu addict and loving it
![]() Join Date: Jun 2006
Location: $ pwd _
Beans: 3,974
Ubuntu 9.04 Jaunty Jackalope
|
HOW TO: Nvidia/Xgl/Compiz - Improve video playback performance/Eliminate Jaggies
About:
1. How to eliminate choppiness and tearing in fullscreen Video/DVD playback and Cube rotation. 2. How to eliminate jaggies from compiz cube and window edges (wobbly plugin) - antialiasing Prequisites: 1. Nvidia graphics card 2. Binary "nvidia" driver. 3. Ubuntu 6.06 4. Xgl/Compiz Step 1: Verify OpenGL Part 1 Open a terminal and do: Code:
$ glxinfo | grep OpenGL Code:
OpenGL vendor string: NVIDIA Corporation OpenGL renderer string: GeForce Go 7800 GTX/PCI/SSE2 OpenGL version string: 1.2 (2.0.2 NVIDIA 87.62) If, otherwise, you see Code:
OpenGL vendor string: Mesa project: www.mesa3d.org OpenGL renderer string: Mesa GLX Indirect OpenGL version string: 1.2 (1.5 Mesa 6.5.1) Part 2 Now, check if opengl libraries are linked properly: Code:
$ ls -al /usr/lib/libGL.* Code:
lrwxrwxrwx 1 root root 19 2006-08-19 09:39 /usr/lib/libGL.so -> /usr/lib/libGL.so.1 lrwxrwxrwx 1 root root 17 2006-07-11 20:08 /usr/lib/libGL.so.1 -> libGL.so.1.0.8762 -rw-r--r-- 1 root root 540136 2006-07-10 07:10 /usr/lib/libGL.so.1.0.8762 Code:
$ sudo ln -s /usr/lib/libGL.so.1 /usr/lib/libGL.so Step 2: Eliminate "tearing" in DVD and other video playback Now that OpenGL has been setup properly, lets get the "tearing" fixed in fullscreen DVD playback. Part 1 Enable vsync: Code:
$ gksudo gedit /etc/init.d/gdm Code:
if [ -r /etc/environment ]; then
if LANG=$(pam_getenv -l LANG); then
export LANG
fi
if LANGUAGE=$(pam_getenv -l LANGUAGE); then
export LANGUAGE
fi
fi
Code:
export __GL_SYNC_TO_VBLANK="1" Code:
export __GL_SYNC_TO_VBLANK="1"
if [ -r /etc/environment ]; then
if LANG=$(pam_getenv -l LANG); then
export LANG
fi
if LANGUAGE=$(pam_getenv -l LANGUAGE); then
export LANGUAGE
fi
fi
Enable tripple buffering in xorg.conf: Code:
$ gksudo gedit /etc/X11/xorg.conf Code:
Section "Device"
Identifier "NVIDIA Corporation NVIDIA Default Card"
Driver "nvidia"
BusID "PCI:1:0:0"
Option "RenderAccel" "true"
Option "TripleBuffer" "true"
Option "NoLogo"
EndSection
Part 2 Enable opengl driver in your favorite player. I personally prefer Totem-xine. Code:
$ gedit ./.gnome2/totem_config Code:
video.driver:opengl Now, play your favorite video/DVD movie fullscreen in Totem-xine and enjoy tearless smooth playback. Did you notice that cube rotation is also free from tearing? I'm sure you did. If not, try it now. Step 3: Eliminate jagged cube edges [OPTIONAL] Its also possible to eliminate the jaggies we get along the edges of the cube. Enable antialiasing by adding Code:
export __GL_FSAA_MODE="2" Here is a setting that works best for me: Code:
export __GL_SYNC_TO_VBLANK="1"
export __GL_FSAA_MODE="4"
export __GL_LOG_MAX_ANISO="4"
if [ -r /etc/environment ]; then
if LANG=$(pam_getenv -l LANG); then
export LANG
fi
if LANGUAGE=$(pam_getenv -l LANGUAGE); then
export LANGUAGE
fi
fi
EDIT: This guide also helps improving the cool animations available in the latest version of compiz (quinn's). Try it to belive it.
__________________
Last edited by kpkeerthi; September 25th, 2006 at 12:20 AM.. Reason: Typo corrections |
|
|
|
|
|
#2 |
|
First Cup of Ubuntu
![]() Join Date: May 2006
Beans: 6
|
Re: HOW TO: Nvidia/Xgl/Compiz - Improve video playback performance/Eliminate Jaggies
Will ATI cards work with this tutorial past step 2 with the ATI binary drivers? Thanks!
|
|
|
|
|
|
#3 |
|
Ubuntu addict and loving it
![]() Join Date: Jun 2006
Location: $ pwd _
Beans: 3,974
Ubuntu 9.04 Jaunty Jackalope
|
Re: HOW TO: Nvidia/Xgl/Compiz - Improve video playback performance/Eliminate Jaggies
Unfortunately, no. The environment variables are nvidia specific.
__________________
|
|
|
|
|
|
#4 |
|
First Cup of Ubuntu
![]() Join Date: Jul 2006
Beans: 7
|
Re: HOW TO: Nvidia/Xgl/Compiz - Improve video playback performance/Eliminate Jaggies
Hm, I did everything this said, but I still have tearing in cube and wobbly. Any ideas?
I've got a PCI-E 7900 GT OC, 4 GB DDR2 4200 ram, dual 250 SATA 7200s, Pentium D 940 - 3.2 GHz. Everything works great except the vsync. |
|
|
|
|
|
#5 |
|
Ubuntu addict and loving it
![]() Join Date: Jun 2006
Location: $ pwd _
Beans: 3,974
Ubuntu 9.04 Jaunty Jackalope
|
Re: HOW TO: Nvidia/Xgl/Compiz - Improve video playback performance/Eliminate Jaggies
Can you post the output of
Code:
$ glxinfo | grep OpenGL $ ls -al /usr/lib/libGL.*
__________________
|
|
|
|
|
|
#6 |
|
First Cup of Ubuntu
![]() Join Date: Jul 2006
Beans: 7
|
Re: HOW TO: Nvidia/Xgl/Compiz - Improve video playback performance/Eliminate Jaggies
$ glxinfo | grep OpenGL
OpenGL vendor string: NVIDIA Corporation OpenGL renderer string: GeForce 7900 GT/PCI/SSE2 OpenGL version string: 1.2 (2.0.2 NVIDIA 87.62) OpenGL extensions: $ ls -al /usr/lib/libGL.* lrwxrwxrwx 1 root root 19 2006-08-24 12:09 /usr/lib/libGL.so -> /usr/lib/libGL.so.1 lrwxrwxrwx 1 root root 17 2006-08-08 17:07 /usr/lib/libGL.so.1 -> libGL.so.1.0.8762 -rw-r--r-- 1 root root 540136 2006-07-10 10:10 /usr/lib/libGL.so.1.0.8762 Here's my whole GDM file, I'm not very Linux savvy so I wasn't sure exactly what to post. - #! /bin/sh # # Originally based on: # Version: @(#)skeleton 1.8 03-Mar-1998 miquels@cistron.nl # # Modified for gdm, Steve Haslam <steve@arise.dmeon.co.uk> 14mar99 # modified to remove --exec, as it does not work on upgrades. 18jan2000 # modified to use --name, to detect stale PID files 18mar2000 # sleep until gdm dies, then restart it 16jul2000 # get along with other display managers (Branden Robinson, Ryan Murray) 05sep2001 set -e # To start gdm even if it is not the default display manager, change # HEED_DEFAULT_DISPLAY_MANAGER to "false." HEED_DEFAULT_DISPLAY_MANAGER=true DEFAULT_DISPLAY_MANAGER_FILE=/etc/X11/default-display-manager PATH=/sbin:/bin:/usr/sbin:/usr/bin DAEMON=/usr/sbin/gdm PIDFILE=/var/run/gdm.pid UPGRADEFILE=/var/run/gdm.upgrade if [ -e $UPGRADEFILE -a "$1" != "restart" -a "$1" != "force-reload" ]; then SSD_ARG="--startas $DAEMON" rm -f $UPGRADEFILE else SSD_ARG="--exec $DAEMON" fi # Allow cdd to override the config if [ -f /etc/gdm/gdm-cdd.conf ]; then CONFIG_FILE="--config=/etc/gdm/gdm-cdd.conf" fi test -x $DAEMON || exit 0 export __GL_SYNC_TO_VBLANK="1" if [ -r /etc/environment ]; then if LANG=$(pam_getenv -l LANG); then export LANG fi if LANGUAGE=$(pam_getenv -l LANGUAGE); then export LANGUAGE fi fi . /lib/lsb/init-functions case "$1" in start) if [ -e "$DEFAULT_DISPLAY_MANAGER_FILE" -a "$HEED_DEFAULT_DISPLAY_MANAGER" = "true" -a "$(cat $DEFAULT_DISPLAY_MANAGER_FILE 2>/dev/null)" != "$DAEMON" ]; then log_warning_msg "Not starting GNOME Display Manager (gdm); it is not the default display manager." else # if usplash is runing, make sure to stop it now, yes "start" kills it. if pidof usplash > /dev/null; then /etc/init.d/usplash start fi log_begin_msg "Starting GNOME Display Manager..." start-stop-daemon --start --quiet --oknodo --pidfile $PIDFILE --name gdm $SSD_ARG -- $CONFIG_FILE >/dev/null 2>&1 || log_end_msg 1 log_end_msg 0 fi ;; stop) log_begin_msg "Stopping GNOME Display Manager..." start-stop-daemon --stop --quiet --oknodo --pidfile $PIDFILE --name gdm $SSD_ARG --retry 30 >/dev/null 2>&1 log_end_msg 0 ;; reload) log_begin_msg "Reloading GNOME Display Manager configuration..." log_warning_msg "Changes will take effect when all current X sessions have ended." start-stop-daemon --stop --signal USR1 --quiet --pidfile \ $PIDFILE --name gdm $SSD_ARG >/dev/null 2>&1 log_end_msg 0 ;; restart|force-reload) $0 stop || true $0 start ;; *) log_success_msg "Usage: /etc/init.d/gdm {start|stop|restart|reload|force-reload}" exit 1 ;; esac exit 0 Thanks for the quick reply |
|
|
|
|
|
#7 |
|
Just Give Me the Beans!
![]() Join Date: Jan 2006
Beans: 64
|
Re: HOW TO: Nvidia/Xgl/Compiz - Improve video playback performance/Eliminate Jaggies
Would anyone happen to know how would I go about enabling openGL for VLC media player?
|
|
|
|
|
|
#8 |
|
5 Cups of Ubuntu
![]() Join Date: Apr 2006
Location: France
Beans: 16
|
Re: HOW TO: Nvidia/Xgl/Compiz - Improve video playback performance/Eliminate Jaggies
I already knew this tips and it really increase image quality, tearing in video, and cube edge aliasing...
But there is a disadvantage to use Code:
export __GL_FSAA_MODE="2" In fact it affects everything displayed on the screen for example the toolbar of this form become blur... ![]() |
|
|
|
|
|
#9 |
|
5 Cups of Ubuntu
![]() Join Date: Nov 2005
Location: Casselberry, FL USA
Beans: 38
Ubuntu 6.06
|
Re: HOW TO: Nvidia/Xgl/Compiz - Improve video playback performance/Eliminate Jaggies
Great Guide!!!! ThX
__________________
Global Warming is OUR PROBLEM!!! |
|
|
|
|
|
#10 | |
|
Ubuntu addict and loving it
![]() Join Date: Jun 2006
Location: $ pwd _
Beans: 3,974
Ubuntu 9.04 Jaunty Jackalope
|
Re: HOW TO: Nvidia/Xgl/Compiz - Improve video playback performance/Eliminate Jaggies
Quote:
http://download.nvidia.com/solaris/1...ppendix-e.html FSAA="2" seems to have different effect in different cards. May be that should explain why. Just wondering? ![]()
__________________
|
|
|
|
|
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|