compiz+nvidia: tearing in xvideo (totem/mplayer/VLC/XINE)

Bug #151674 reported by Paulus
136
This bug affects 21 people
Affects Status Importance Assigned to Milestone
compiz (Ubuntu)
Fix Released
Undecided
Unassigned
Nominated for Intrepid by Nicholas Xenakis
Nominated for Jaunty by Nicholas Xenakis
linux-restricted-modules-2.6.22 (Ubuntu)
Fix Released
Undecided
Unassigned
Nominated for Intrepid by Nicholas Xenakis
Nominated for Jaunty by Nicholas Xenakis
linux-restricted-modules-2.6.24 (Ubuntu)
Won't Fix
Undecided
Unassigned
Nominated for Intrepid by Nicholas Xenakis
Nominated for Jaunty by Nicholas Xenakis

Bug Description

Binary package hint: nvidia-glx

The distortion looks as if the screen is updating too slowly, or not synchronized to the refresh rate. That is, you see parts of the old picture and part of the new picture at the same time. I suspect it has to do with "synching to vblank".

The problem only occurs when compiz is enabled (no matter if normal or extra effects).

The problem occurs in all programs using xvideo, mplayer -vo xv included.

mplayer -vo x11 works, but it doesn't support fullscreen, so it's useless.

Changing the settings related to "vsync" in nvida-settings or CCSM does not seem to have any effect.

I supply version information below.

ii compiz 1:0.6.0+git20071004-0ubuntu2 OpenGL window and compositing manager
ii libgnome2-0 2.20.0-1ubuntu4 The GNOME 2 library - runtime files
ii libxv1 2:1.0.3-1ubuntu1 X11 Video extension library
ii mplayer 2:1.0~rc1-0ubuntu12 The Ultimate Movie Player For Linux
ii nvidia-glx 1:1.0.9639+2.6.22.4-13.6 NVIDIA binary XFree86 4.x/X.Org driver
ii xserver-xorg 1:7.2-5ubuntu12 the X.Org X server

Revision history for this message
Paulus (donmatteo) wrote :

My graphics adapter is: nVidia Corporation NV18 [GeForce4 MX 4000] (rev c1)

Revision history for this message
James (jamebus) wrote :

Happens for me too using nVidia Corporation G80 [GeForce 8600 GT]

Revision history for this message
James (jamebus) wrote :

So far I'm getting much better results by enabling Sync to To VBlank in CCSM. Changing settings in nvida-settings doesn't appear to help things any.

XVideo by default will sync to vblank, which is what you want if you're rendering directly to the display without the use of a composite manager. When a composite manager is in effect there's probably extra steps involved and you're no longer rendering directly to the display. Instead you're rendering the video to a texture in your video hardware and the composite manager takes care of rendering the display with the assistance GPU. If the composite manager isn't syncing the display you're going to have shabby results because the video playing and display painting is no longer in sync.

If you try this also verify CCSM shows the correct Refresh Rate for your display. If it's wrong, disable Detect Refresh Rate and set the Refresh Rate manually. TwinView users (like me) often have the wrong Refresh rate displayed due to the way the nVidia drivers abstract the displays in a TwinView configuration.

Revision history for this message
Paulus (donmatteo) wrote :

Enabling "Sync to VBlank" in CCSM has the drawback of breaking resuming from suspend-to-disk. What's more, it doesn't really remove the tearing.

What does help is using the Compiz Video Plugin and a player that supports it. As to players that do support this, I'm aware only of mplayer using some patches found on the net. Instructions are here: http://smspillaz.wordpress.com/2007/10/18/unlocking-the-full-video-potential-of-your-video-card/

In any event, this is almost certainly a bug in NVidia's binary blob, as evidenced by the fact that on nvnews.net forums, there are similar reports in other distributions. In fact they've acknowledged this and claim to fix this in a later release. NVidia's internal bug number is 353274. As far as I know, this isn't fixed in the latest driver release.

Revision history for this message
unggnu (unggnu) wrote :

I can confirm this with latest Hardy. I have enabled vblank for OpenGL and it works fine, compiz runs with 60 fps and everything looks great but all XV video players have a tearing and choppy output. It seems that XV Syn to vblank doesn't work with compiz. It works fine if I disable compiz or use gl output instead.

VGA compatible controller: nVidia Corporation GeForce 8800 GTS 512 (rev a2)

nvidia-glx-new:
  Installiert:169.12+2.6.24.10-11.29
  Mögliche Pakete:169.12+2.6.24.10-11.29

It could be easily tested with mplayer benchmark. If vblank is enabled for OpenGL the video with gl2 output runs smoothly and at normal speed but the one with XV runs very fast since there is no sync.

mplayer -benchmark -nosound -frames 1234 -vo gl2 VIDEOFILE
mplayer -benchmark -nosound -frames 1234 -vo xv VIDEOFILE

More information to the problem: http://www.nvnews.net/vbulletin/showthread.php?t=85301

Changed in linux-restricted-modules-2.6.24:
status: New → Confirmed
Revision history for this message
Kyle M Weller (kylew) wrote :

I confirm this bug as well, I have to disable compiz to watch movies because the tearing is so bad, I use compiz-switch for that:
http://forlong.blogage.de/article/pages/Compiz-Switch

Revision history for this message
unggnu (unggnu) wrote :

I can confirm this with Nvidia Geforce 440 Go too. It makes video watching very uncomfortable.

Revision history for this message
Sven Berkvens-Matthijsse (sven-launchpad) wrote :

Compiling a custom version of mplayer with a patch allowed me to use at least mplayer. Instructions are here:
http://forum.compiz-fusion.org/showthread.php?t=7212

Revision history for this message
jac3n (jacen-mail) wrote :

Append to a Nvidia GeForce 4 MX Integrated (64 mo shared memory) with nvidia-glx

Revision history for this message
vervelover (alessiopangos) wrote :

Enabling sync to vblank under compiz advanced settings does completely solve the issue for me with vlc (I have the latest nvidia drivers 173.14.05 and a geforce go 7400). Also checking unredirect fullscreen windows does work, but only on fullscreen videos so I prefer the first method.

Revision history for this message
Dereck Wonnacott (dereck) wrote :

As per umggmu's test:
mplayer -benchmark -nosound -frames 1234 -vo xv VIDEOFILE : 5.325s
mplayer -benchmark -nosound -frames 1234 -vo gl2 VIDEOFILE : 18.406s

under compiz xv disregards vsymc apparently.

Changed in linux-restricted-modules-2.6.22:
status: New → Invalid
Revision history for this message
Dereck Wonnacott (dereck) wrote :

As per umggmu's test:
mplayer -benchmark -nosound -frames 1234 -vo xv VIDEOFILE : 5.325s
mplayer -benchmark -nosound -frames 1234 -vo gl2 VIDEOFILE : 18.406s

under compiz xv disregards vsymc apparently.

Changed in compiz:
status: New → Confirmed
Revision history for this message
mardi (mardi) wrote :

Hi,

IMHO, I think this is a problem affecting only Ubuntu (and/or maybe other Debian
-based distros). I make this (somewhat) bold statement due to one simple reason:
I ran Fedora Core-8 for 6 months prior to installing Ubuntu... and never, ever
had this tearing problem (or the hue/blueing/greening problem). And to be clear,
I played tons of videos of all types and at fullscreen when I was using Fedora.

My guess is that it has something to do with the drivers provided. The only
difference between Ubuntu and Fedora is in the nVidia driver packages. I recall
that Fedora uses a special repository called Livna to install proprietary
drivers. My understanding is that the Livna guys "cook up" the driver a little
bit before releasing it as an RPM. So that may be the big clue here.

Also, I humbly suggest changing the priority of this bug to something more than
"undecided". This, to me, is a serious issue. I have tried all the suggested
workarounds (disable compiz, output to OpenGL, use VLC, etc...) and nothing
seems to work. This effectively means I am not able to watch any form of video
on my PC (unless I use another distro or go back to Windows).

The only things I have yet to try is :
- install a simpler WM (e.g., IceWM) and see if that helps any
- install Fedora in a VirtualBox VM and run videos from it

Both are... unappetizing to say the least. Anyways my setup is :
- Hardy 8.04.1, x86_64, 2.6.24-19
- nVidia 8800GT, 169.12

Thanks.

Revision history for this message
jac3n (jacen-mail) wrote :

I've recently changed of PC. I has hope that this tearing would dessappear with my new graphic card (and more recent drivers !) but it is still there.

NVIDIA UNIX x86_64 Kernel Module 169.12 Thu Feb 14 17:51:09 PST 2008
GeForce 7100 GS

In debian etch package, the probleme is unexistent but the drvier doesn't allow compositing. In debian "sid" package, the problem is the same as in ubuntu.

I hope this will help someone to identify the problem...

Revision history for this message
mardi (mardi) wrote :

Hi,

Just to give additional info to any would-be bug-squasher :

So... been grappling with this problem the last couple of days and I may have
found the problem. It seems to be something to do with my dual-monitor setup.
Simply, if I remove my 2nd monitor from the X-server (via the nVidia drivers),
the tearing goes away. The moment I re-enable it, the tearing comes back. This
is independent of whether I had compiz-effects on or off. I.e. :

- When I disable compiz but still have two monitors active, videos still screen-tears).
- Same behaviour in XCFE and IceWM too (and all scenarios where compiz/composites have been disabled)
- None of the other fixes work (e.g, de-interlacing, output to OpenGL, sync-to-vblank, etc...)

Thus, my earlier suggestion about it being something to do with Fedora's
"special" livna drivers is wrong.

So far, only turning on/off that 2nd monitor works. Perhaps... can any of the
prior fellow bug-reporters confirm this please? Did they have this problem with
single or dual-monitor setups?

Also, for those not aware, there is an Ubuntu-Forums thread linked to this bug :
http://ubuntuforums.org/showthread.php?p=5866224

HTH

Revision history for this message
Hew (hew) wrote :

Closing against compiz based on previous comments about the problem being independent of compiz usage.

Does the problem still exist with Intrepid?

Changed in compiz:
status: Confirmed → Invalid
Revision history for this message
Gaspard Leon (gaspard.leon) wrote :

I noticed this issue with videos under compiz about a year ago, and I now don't use compiz, because that's one of the main uses of my computer is to watch videos.

I've been investigating suspend recently and was reading through the docs for nvidia driver package and stumbled across this:
http://us.download.nvidia.com/XFree86/Linux-x86/173.14.12/README/chapter-23.html

"On X.Org 7.1 and higher, the driver will properly redirect video into offscreen pixmaps. Note that the Xv adaptors will ignore the sync-to-vblank option when drawing into a redirected window."

So NVidia notes this doesn't work.

I guess we'll have to wait for the code-base to improve before this feature of redirected video works correctly.

Gaspard

Revision history for this message
mardi (mardi) wrote :

Hi,

@ Gaspard : Curiously, compiz is not the problem for me,

- turn off compiz via [Visual Effects] in [Appearance Preferences]
- reboot PC (or restart X)
- videos/graphics _still_ show screen-tearing

In my case, Compiz doesn't seem to be the cause. The only way I could get rid of
the tearing was to disable my 2nd monitor in [xorg.conf] (see my previous posts).

Everyone seems to point the finger at Compiz. I think its something to do with X.
However, nobody else has confirmed or replicated my 2-monitor problem scenario.

Also, this screen-tearing is not limited to just videos. It happens in graphics
applications as well. I do a lot of OpenGL programming for my assignments, and
anything drawn in the GL-context window screen-tears as well. Even when I'm
rendering some simple triangles and with [Sync to vblank] turned on.

Hope this helps.

Revision history for this message
adz21c (adz21c) wrote :

Mardi,
I believe my issue with video tearing sounds _very_ similar to yours and like you suspect everyone else's is the same. I believe the problem is when compositing is enabled (and I think even when effects are disabled in compiz compositing is still enabled). To confirm try the following:

Switch to a different window manager that is not compositing enabled (such as MetaCity or KWin(for KDE3, or KDE 4 with desktop effects disabled as that does disable compositing).
Switch to xinerama for dual monitor support, again compositing should be disabled and you should find no video tearing.

Also for me I find that tearing only happens on one monitor, I have one at 1680x1050 (59.9hz) and another at 1280x1024 (60hz) and get tearing on the larger of the 2 but not the smaller (however if I disable dual monitor I don't get it on either of the monitors, which ever is enabled).
Also I don't just get the tearing with video, its more noticeable with video, but on the monitor with tearing if I shake a window around a lot for a long time with wobbly windows (and sometimes even without) you can see the tearing there too.

Finally I think it is compositing not compiz since I am using KWin-kde4 and get the tearing.

Revision history for this message
belovedmonster (jd-hartland) wrote :

I can confirm that I am getting video tearing when using compiz (I have an nVidia card). For my the tearing goes away as soon as I switch 'Visual Effects' to 'None'.

Revision history for this message
Alex Karpenko (alexkarpenko) wrote :

I can confirm that this issue still exists on Hardy with a GeForce 8600M GT. Sync to vblank for video rendering does not currently work.
Note that I have sync to vblank enabled in CCSM. That fixes the window tearing while moving, but not video tearing.

The comments by an NVIDIA representative might be relevant in the following thread: http://www.nvnews.net/vbulletin/showthread.php?t=113599

Seems to me NVIDIA is blaming compiz. Someone should contact them directly and sort out how best to fix this issue.

Revision history for this message
Gaspard Leon (gaspard.leon) wrote :

perhaps we (people affected by this bug) should test the work around suggested in:
http://www.nvnews.net/vbulletin/showpost.php?p=1724807&postcount=16

The poster there says to use OpenGL for everything, with a specific combination of settings...

I will try this out when I get home tonight and report if I have non-tearing videos.. if it's the case, perhaps this can be the default configuration for Nvidia cards at least (not sure how widespread this issue is)

Revision history for this message
mardi (mardi) wrote :

Hi, sorry for this late late reply. Was really busy these past few weeks... I
had just given up hope and stuck to manually disabling the second monitor
every time I wanted to see videos (not that I actually had the time).

@ adz21c
I actually tried what you suggested with different window managers, installed
and tried both IceWM and Xfce, to no avail. Same tearing. I'm pretty sure
compositing was disabled when I was conducting my troubleshooting.

There is a possibility, that it is because we have two different monitors with
two different refresh rates. Your setup is very similar to mine. I have a
1920x1200 (59.95Hz) main monitor, and a 1280x1024 (60.02Hz) older LCD. You're
right! The tearing only appears on the larger screen!

Its still a bummer tho... I prefer to watch vids on my larger screen. But,
perhaps this is a big clue to the bug-squasher squad?

@ belovedmonster & Alex Karpenko & Gaspard Leon
None of the suggested workarounds... uhm, work. I think I exhausted all the
methods mentioned. I basically went crazy for a week trying to fix the problem.
:P

The OpenGL method also did'nt work. I do a lot of GL programming for my real-
time rendering classes and test my games on this PC. The tearing still happens.
So, even pure, basic OpenGL applications are affected.

Besides, from what I've learned, tearing is controlled via the graphic-card
drivers and how they sync with the monitor refresh rates. So, it doesn't really
matter what software switch shenaniguns you input into your settings and the
graphic-card :P If the driver screws up the syncing, you'll get the tearing.

HTH,
eeg

Revision history for this message
adz21c (adz21c) wrote :

Hi,

@mardi
Your right, not long after sending this message (and forgetting I had :-) ) I tried switching Window manager and disabling compisiting etc and I still got the tearing (although it was far less noticable when doing stuff like moving windows). I believe you are right about the refresh rate issue, I have suspected that for a long time and I believe in my search for a solution someone confirmed it. I did a little while ago manage to switch the tearing to my other monitor I think. I can't remember how, I believe instead of using TwinView via xorg.conf, I simply enabled it via nvidia-settings (so had a plain xorg.conf) and the option to select what monitor xv adapter syncs too did its job, so I got tearing on the smaller monitor instead. I shall try checking that when I get home :-).

Adam

Revision history for this message
adz21c (adz21c) wrote :

@mardi
Well I was wrong, I got confused. I think it was a mixture of 2 things. First depending on my mood I switch between vsync and none vsync, sometimes I could tolerate seeing a big tear and sometimes I couldn't so felt happier seeing random mini tears for a split second :-). Secondly I had recently cleaned behind my computer and in the process plugged my monitors into different ports (without realising it obviously). Testing this today I found that when I switched the monitors from one port to another the tearing jumped monitors. Previously my setup was below.

DFP-0: 1280x1024 (Sony 17", no tearing, only used for DVDs when watching while working, so half paying attention ;))
DFP-1: 1680x1050 (LG 22", this is where I had the tearing, annoyingly the monitor I use for DVDs when chilling with people)

I swapped the cables so it is now the opposite.

DFP-0: 1680x1050 (LG 22", no-longer tearing, even composite effects are not tearing)
DFP-1: 1280x1024 (Sony 17", now tearing, including composite, which means its atleast tolerable now since I only use this for video when half watching :-))

So it seems the refresh rate info for the DFP-0 monitor is used (not the default monitor that can be configured in nvidia-settings). I would guess that the monitor your getting tearing on is DFP-1 (or atleast is in the secondary monitor port, not the primary). Might be worth a try, as if this is the case I think its likely this is all down to nVidia, seems too closely tied to twinview related stuff to be xserver compositing or kwin/compiz (again even with the new set up, when I changed to just single monitor mode for either monitor the tearing stops, as that monitor then probably becomes the primary device regardless of what port it is plugged into since the other is not active). I am sure I read somewhere about twinview by default using the default monitors refresh rate for vsync.

Adam

Revision history for this message
Claude Gagné (miltiad) wrote :

I have found a workaround for my configuration...
I have a 1280x1024 LCD screen and a 1920x1080 plasma.

Using the lastest beta Nvidia driver (180.11). I use the settings as seen in the screenshot attach to this comment.

With compiz enabled in full-screen or not I have tearing on both display with totem.

The only way to stop the tearing I have found is:
- Disable Compiz
- ALT+F2 nvidia-settings -l (to load the nvidia settings)

And I can watch video without tearing on my plasma and my LCD.

Revision history for this message
PsYcHoK9 (psychok9) wrote :

I can't understand how this bug affect for a long time... without a fix from the team.
It's very BIG bug, and I know this bug from 1-2 years... and my all computer tested have this bug.
With compiz disabled, the video output works perfectly (VBlank enabled, OpenGL vsync enabled on nVidia settings). No driver related (173.xx/177.xx/180.xx tested).
I've tested on this PCs:
1) Geforce 8800 GT, Q6600@3.2GHz, Asus P5Q Deluxe, 4Gb RAM, Ubuntu Intrepid 8.10 x86_64,
2) Acer 5920g, Geforce 8600M GT, Intel Core 2 Duo 2.2GHz, 2Gb RAM, Ubuntu Intrepid 8.10 i386,
3) and with old my configurations.

Revision history for this message
PsYcHoK9 (psychok9) wrote :

Very surprising... After I wrote my comment, I get an idea.
I've open Ubuntu tweak, and added latest Compiz repository
"deb http://ppa.launchpad.net/compiz/ubuntu intrepid main #Compiz Fusion"
for a try of luck...
downloaded the updates, restarted Ubuntu, I have see on "General -> Display settings" of compizconfig, the option "Sync to VBlank" :O
I've enabled it, I've corrected the refresh rate (wrong 50Hz to 60Hz of my/all LCD)... and now the problem seem to be gone!
World of Warcraft on Wine, work correctly with Vsync ON!
Obviously compiz is enabled.
Now I'll test better with other pcs.

Revision history for this message
Claude Gagné (miltiad) wrote :

Nice !

Let us know your software/hardware configuration !

Revision history for this message
PsYcHoK9 (psychok9) wrote :

After shutdown. And power-up the tearing are back... but I've fixed with a simple "nvidia-settings -l" on "session" of Ubuntu (the application started on boot up).
Now Vsync work perfectly.
My os is Ubuntu 8.10 amd64/x86_64, kernel 2.6.27-9-generic, nVidia 8800 GT, 177.80 nVidia drivers, LCD connected on DVI port, at 60Hz, the model is LG L204WT.

Revision history for this message
karlottofritz (max-jakob) wrote :

unfortunately the "Sync to VBlank" option did not solve the problem in my case.

Revision history for this message
PsYcHoK9 (psychok9) wrote :

You must load the nvidia-settings at every reboot/boot (ALT+F2 -> type "nvidia-settings -l" without quote), and you must ensure:
1) VBlank enabled on OpenGL Settings and XVideo settings of the nVidia panel (ALT+F2 -> and type "nvidia-settings").
2) VSync enabled on CompizConfig -> General Options -> Display Settings (and check the refresh is set 60Hz).
Check all passes, if don't work. I tested this workaround on others pc/laptop and work with a single display connected or enabled.

Revision history for this message
mardi (mardi) wrote :

@adam
Sorry mate, been away for the past months (summer vacation here in Aussieland).
I did try the old switcheroo with the video cables... no joy. It actually got
weirder, so to those who want to try that... dont do it.

I gave up on this issue a while back. Am using 2 copies of "xorg.conf", one for
dual monitors and one for single. I overwrite the main file manually everytime
I need to, then restart X. Its stupid but it works :D

Besides, a friend showed me how to use VLC media player in WinXP to watch all
my DVDs and vids. Never looked back :D

@PsYcHoK9
Glad it worked out for ya. Had a few questions from the Ubuntu forums and will
direct them to your posts. It seems that several people still have this problem,
so I dont think the bug is gone. (e.g, karlottofritz)

> I can't understand how this bug affect for a long time... without a fix from
> the team. It's very BIG bug, and I know this bug from 1-2 year...

I think its a difficult bug to squash. Look at the layers of sub-systems
involved (e.g., is it X11, or is it the Nvidia drivers, or is it Compiz?).
Plus there are so many different monitor configurations and so many purported
work-arounds and fixes that claim to work. If I was the bug-squasher, I'd
rather poke my eyes out with dirty toothbrushes then fix it. :D

Its obviously not a high priority for the team(s) anyways. It should,
considering people like to hook up their laptops with secondary monitors, but
hey... what can you do aye? *shrugs*

Revision history for this message
shaddin (shaddin) wrote :

I had a similar problem. The issue was that my two monitors were at slightly different refresh rates, despite the fact that I set both to 60hz. If you can set your monitors to the same refresh rate exactly, then you should be fine (check each monitor via its own interface). Otherwise, if you are like me your monitors don't sync at exactly the same rate (one was 60hz, the other was 59.9). In this case, running one compiz instance to manage both monitors results in vertical tearing with or without sync-to-vblank enabled. When enabled, single tear moves down the screen; when disabled multiple tears appear and disappear hap-hazardly... test by dragging a window left and right.

Solution is to run two different compiz processes, one for each monitor. Add the following script to your gnome startup:

#!/bin/bash
DISPLAY=:0.0 compiz --only-current-screen &
DISPLAY=:0.1 compiz --only-current-screen &

Hope that helps

Revision history for this message
Nicholas Xenakis (xnicholas) wrote :

I have something to add... I have done testing with compiz disabled...

 i move a dark window against a light background rapidly, and i get tearing...

http://img7.imageshack.us/img7/2005/vsyncbrokenlatesti386.png

perhaps tearing is always occuring even with compiz off, but it is far less obvious. when you turn compiz on any existing tearing gets severly exxagerated.

tearing also seems to occur with the open source nv drivers. something must be done.

http://img7.imageshack.us/img7/2005/vsyncbrokenlatesti386.png

Revision history for this message
krul (krul) wrote :

I know this is already an old thread, however could be useful for someone else.

I had same issue with tearing on TV, but it disappeared after launching the Compiz settings manager (ccsm) on the secondary (TV) screen using alt + f2 and ccsm.
Relevant settings are:
-detect refresh rate off
-refresh rate fixed to 60
-vsync enabled

This works for me! No more tearing! The strange thing is that the the compiz settings manager seems to be for both screens no matter from which you launch it as there is a dropdown in the top left where you can select the screen (screen 0 and screen 1).

I would say this is a bug in the Compiz Settings manager.

j2snowden (j2snowden)
tags: added: anything of regardless tearing video
Hew (hew)
tags: removed: anything of regardless tearing video
Revision history for this message
Felix Gladisch (murky) wrote :

I was searching for a solution for more than one year and I was very frustrated about all these "Enable Sync To VBlank in Compiz"-Answers. So I started to get into this Compiz- and nVidia-Constellation and searched for a solution on my own. And I finally can say: I found it. The Problem is, that Ubuntu is starting Compiz with the session immediatly and is ignoring the VSync of Nvidia. So you have to start Compiz after 'nvidia-settings -l'.

Let's Start.

(I am using the german version of Ubuntu 9.10, so the names of programs can be different, than explained)

1. You have to disable Compiz in Appereance by turning off the Desktop Effects.
2. Create a new Entry in your StartUp-Programs with the command: nvidia-settings -l
3 Create another Entry in your StartUp-Programs with the command: compiz-wait
4. Now open your Terminal and type: sudo gedit /usr/local/bin/compiz-wait

Now copy this text into the Editor:

#!/bin/bash
sleep 3
compiz --replace --sm-disable --ignore-desktop-hints
emerald --replace

Save & Exit.

The last line is optional, it is only necessary, if you are using Emerald.

5. Type in the Terminal: sudo chmod a+x /usr/local/bin/compiz-wait

You can try the command "compiz-wait", if it is not working you must customize the parameter after
compiz. In my case, they are dong the job.

Now restart your computer, after logging in it takes 3 seconds before starting compiz, so wait for that. You can
change the amount of seconds in the script above, if your computer is slow and is showing the Ubuntu Logo, when
compiz starts. In some cases its breaking the script.

I hope, that will help some of you, and even the developers.

Revision history for this message
yavoh (anish-bramhandkar) wrote :

I get tearing even with Compiz turned off.

NVIDIA GTX 260
Driver version 190.53
Ubuntu 9.10
Single monitor: 1920x1200, 59.95 Hz.

Revision history for this message
ross (ross-rossmoore) wrote :

I also get tearing with Compiz turned off.

Nvidia ION, Driver version 190.53, Ubuntu 9.10.

The only way I have got tearing to go away is add a section to xorg.conf to disable compositing.

I have tried something similar to Murky's solution without success. I didn't follow his instructions exactly though, so I might give that a whirl and will let you know if I have any success.

Revision history for this message
Felix Gladisch (murky) wrote :

I have to add, that my solution only work, when a OpenGL-Video is running. So make sure you are using it in VLC, Mplayer or whatever. I am using SMPlayer with "gl (fast)"-Output and Direct Rendering. As Media Center (and my primary interface for video) XBMC with "VDPAU"-Output and VSync. Still no tearing!

Revision history for this message
fa2k (pmb) wrote :

The CompizConfig solution works great in 10.4. I set [X] Sync to VBlank, and Refresh Rate=60 Hz in ccsm, and the problem goes away. It even persists across reboots. (I have run with compiz disabled for a long time, because of some compatibility issue, but this is enough to make me switch it on for video playback.)

I did not find this bug when I was frantically troubleshooting this issue a few months ago. I think the solution should be put on a wiki page as a temporary measure, to make it easier to find. I don't have time to put it there now, maybe later.

Thanks for the fix, it made my day!

Revision history for this message
bugbot (bugbot) wrote : linux-restricted-modules-2.6.24 is obsolete

Thank you for reporting this issue about a driver from the
linux-restricted-modules package. lrm-2.4.24 was shipped with Ubuntu
8.04 which reached end-of-life for desktop support on May 12th, 2011.

For that reason, this bug report is being closed at this time. I'm
marking it wontfix because what you describe is probably a valid issue,
but there are no plans to work on lrm 2.4.24 bugs further.

The issue may be resolved in a newer version. If not, aside from filing
a new bug report, another angle may be to file it directly with the
driver vendor.

Changed in linux-restricted-modules-2.6.24 (Ubuntu):
status: Confirmed → Won't Fix
Revision history for this message
mirak (mirak-mirak) wrote :

the problem is not only on compiz, it's more about using the composite extension in Xorg
and now that Unity as gone gpu accelerated and that it's just bad without it, and that gnome-shell also requires gpu acceleration, this bug needs to be fixed.

we are in 2012 there is still no good video playback when gpu accelleration is on, that's really bad for linux.

piotr zimoch (ebytyes)
Changed in compiz (Ubuntu):
status: Invalid → New
status: New → Incomplete
status: Incomplete → Opinion
status: Opinion → Invalid
status: Invalid → Confirmed
status: Confirmed → In Progress
status: In Progress → Fix Committed
status: Fix Committed → Fix Released
Changed in linux-restricted-modules-2.6.22 (Ubuntu):
status: Invalid → New
status: New → Incomplete
status: Incomplete → Opinion
status: Opinion → Invalid
status: Invalid → Confirmed
status: Confirmed → In Progress
status: In Progress → Fix Committed
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.