Go Back   nV News Forums > Linux Support Forums > NVIDIA Linux

Newegg Daily Deals

Reply
 
Thread Tools
Old 05-31-10, 05:30 PM   #1
xazero
Registered User
 
Join Date: May 2010
Posts: 22
Default KDE + Nvidia = Tearing

Hi all

Ive been experiencing tearing (whole screen not only xv), when composite is enabled and the nvidia drivers installed, even if i have vsync turned on .


also i have to say that if i enable the snow effect the tearing completely disappears and the fps plugin says kwin is running exactly at 61 fps (which is the right value) but if i turn of the snow effect the tearing eventually comes back.
that makes me think that only opengl apps are getting the vsync. (and the snow effect makes the whole desktop to be opengl drawn i guess).

i know that this is probably not a nvidia bug but no one have been able to help me in the kde forums nor in the ubuntu forums.

http://forum.kde.org/viewtopic.php?f=15&t=88200
http://ohioloco.ubuntuforums.org/sho....php?t=1493721

HW:macbook pro 5,5
-GPU: nvidia geforce 9400m

SW: Kubuntu 10.04
-nvidia drivers: 195.36.15
-Xorg(server vendor version): 1.7.6
-KDE SC: 4.4.3
-QT:4.6.dontknow

Config:

-xorg.conf
Quote:
...
Option "NoLogo" "True"
Option "TripleBuffer" "True"
Option "DynamicTwinView" "False"
Option "BackingStore" "True"
Option "RenderAccel" "True"
Option "DamageEvents" "True"
Option "PixmapCacheSize" "1024000"
Option "AddARGBGLXVisuals" "True"
Option "AllowIndirectPixmaps" "True"
...
Driver "nvidia"
...

-~/.xinitrc
Quote:
export __GL_SYNC_TO_VBLANK=1
#export QT_GRAPHICSSYSTEM=opengl ##I KNOW IT DOESN'T WORK BUT I WISH IT DID
nvidia-settings --load-config-only
nvidia-settings -a InitialPixmapPlacement=2 -a GlyphCache=1
. /etc/X11/xinit/xinitrc

kwinrc
Quote:
[Compositing]
AnimationSpeed=2
Backend=OpenGL
CheckIsSafe=true
DisableChecks=true
Enabled=true
GLDirect=true
GLMode=TFP
GLTextureFilter=2
GLVSync=true
HiddenPreviews=6
RefreshRate=60
UnredirectFullscreen=true
#XRenderSmoothScale=true
...

.nvidia-settings-rc
Quote:
...
0/SyncToVBlank=1
...
0/OpenGLImageSettings=1 # dont know what's this for
...
0/XVideoTextureSyncToVBlank=1
...
xazero is offline   Reply With Quote
Old 05-31-10, 06:15 PM   #2
thefirstm
Registered User
 
Join Date: Feb 2009
Posts: 226
Default Re: KDE + Nvidia = Tearing

You might want to check on PowerMizer to see what it is doing while you get the tearing. With my card, compositors will tear horribly unless the GPU is in its highest performance mode, which is induced by launching an OpenGL application.
thefirstm is offline   Reply With Quote
Old 06-01-10, 06:10 AM   #3
xazero
Registered User
 
Join Date: May 2010
Posts: 22
Default Re: KDE + Nvidia = Tearing

Quote:
Originally Posted by thefirstm View Post
You might want to check on PowerMizer to see what it is doing while you get the tearing. With my card, compositors will tear horribly unless the GPU is in its highest performance mode, which is induced by launching an OpenGL application.
Thanks, i changed the preferred mode to maximum performance and it actually seems to be helping somehow.
But i just realized that if i run glxgears the kwin fps plugin reports ~30 fps while
the output of glxgears reports ~300 frames per 5 seconds (~60fps) that makes me think that kwins vsync and
nvidias vsync dont get along.

any thoughts?
xazero is offline   Reply With Quote
Old 06-01-10, 05:07 PM   #4
Dragoran
Registered User
 
Join Date: May 2004
Posts: 711
Default Re: KDE + Nvidia = Tearing

Quote:
Originally Posted by xazero View Post
Thanks, i changed the preferred mode to maximum performance and it actually seems to be helping somehow.
But i just realized that if i run glxgears the kwin fps plugin reports ~30 fps while
the output of glxgears reports ~300 frames per 5 seconds (~60fps) that makes me think that kwins vsync and
nvidias vsync dont get along.

any thoughts?
Well 30 fps indicates that there is a double wait ... i.e enable either kwin's sync to vblank or enable at the driver level but not *both*.
Dragoran is offline   Reply With Quote
Old 06-01-10, 05:43 PM   #5
ledoc
Registered User
 
Join Date: Jan 2008
Posts: 330
Default Re: KDE + Nvidia = Tearing

Something I would definitely start with is to scrap ALL the weird, partially obsolete and conflicting extra settings in ALL the config files you quoted.
ledoc is offline   Reply With Quote
Old 06-01-10, 09:17 PM   #6
xazero
Registered User
 
Join Date: May 2010
Posts: 22
Default Re: KDE + Nvidia = Tearing

Quote:
Originally Posted by ledoc View Post
Something I would definitely start with is to scrap ALL the weird, partially obsolete and conflicting extra settings in ALL the config files you quoted.
can you place be more specific?


export __GL_SYNC_TO_VBLANK=1 #If you have vsync enabled in the nvidia settings this gets exported anyway
nvidia-settings --load-config-only #making sure the settings load
nvidia-settings -a InitialPixmapPlacement=2 -a GlyphCache=1 # from the kde website, to make plasma smoother

Option "TripleBuffer" "True" #make gl to be triple buffered
Option "DynamicTwinView" "False" # fixes the xrandr/nvidia problem (without this kwin tries to run at 50 fps)
Option "BackingStore" "True" # on by default
Option "RenderAccel" "True" # on by default
Option "DamageEvents" "True" # on by default
Option "PixmapCacheSize" "1024000" #increasing cache size
Option "AddARGBGLXVisuals" "True" # on by default
Option "AllowIndirectPixmaps" "True" # on by default

as for kwinrc and nvidia-settings-rc everything comes from the gui
xazero is offline   Reply With Quote
Old 06-01-10, 10:59 PM   #7
xazero
Registered User
 
Join Date: May 2010
Posts: 22
Default Re: KDE + Nvidia = Tearing

Quote:
Originally Posted by Dragoran View Post
Well 30 fps indicates that there is a double wait ... i.e enable either kwin's sync to vblank or enable at the driver level but not *both*.
thanks for helping

but i have a problem that goes beyond that
(and i have this exact problem in two computers)

more info:

kwin vsync on, nvidia vsync on:

kwin goes at 60 fps as long as i have an opengl effect running
glxgears 60 fps (but kwin gets only 30 fps (double waiting?))

kwin vsync on, nvidia vsync off:

kwin ~50-60 (60 most the time) (still tearing)
glxgears 60 fps (kwin ~30 fps (double wait))

kwin vsync off, nvidia vsync on:

kwin ~100 fps (nvidia vsync not working?)
glxgears 60 fps (kwin 30-62 fps (WTF?))


kwin vsync off, nvidia vsync off:

kwin ~100 fps
glxgears ~55 fps (kwin ~30-55 fps)
__GL_SYNC_TO_VBLANK=1 is making glxgears to vsync? (see PS!)

PS
for the tests i disabled triplebuffering in xorg.conf
and commented the __GL_SYNC_TO_VBLANK=1 in my xinitrc but somehow it
still gets loaded acording to printenv.
and before each test i restarted X.


Im going somehow to disable the __GL_SYNC_TO_VBLANK=1 and post back later
xazero is offline   Reply With Quote
Reply


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 07:59 AM.


Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Copyright 1998 - 2014, nV News.