![]() Registered Member ![]()
|
Hi,
I have an Nvidia GPU(8600 GT) and I'm using theVDPAU feature of nvidia binary driver. This feature allows that most of video decoding is done by the GPU. This feature works well only if I disable kwin desktop effects. This seems to be a problem only for kwin, cause it also works well with compiz. The problem is that when playing a HD video file (1080p) using VDPAU when kwin composite is enabled, the CPU usage is extremely high for Xorg(50-70%) and mplayer(20-30%). Instead, if kwin composite is disabled, or if I'm using compiz, the usage for Xorg and Mplayer is extremely low (under 10%) because the video decoding is done by the gpu. Someone from nvidia forum suggested that this could be caused by the fact that kwin doesn't really use Direct Rendering, even if Enabled Direct Rendering is checked on the Advanced Tab of Desktop Effects settings. I don't know how to check this, cause if I'm running
there's no output. I'm using Ubuntu 8.10 and KDE 4.2.1 from ppa. Can someone help? Thanks |
![]() Registered Member ![]()
|
Hi,
Having exactly the same issue (Nvidia GTX260, KDE 4.3.2, proprietary drivers v. 195.30). Also, similar thing happens with OpenGL apps being run with compositing enabled. For example, running simple OpenGL app that shows a triangle makes X process use about 20% CPU and the app itself about the same. If I disable compositing - X process uses max 1% and the same usage has an app. Tried playing with settings (both KDE effects and xorg.conf) - no luck. Does anybody know what is the cause of this? Is this a KDE problem or Nvidia driver bugs? Maybe there are some settings I don't know about? Thanks. UPDATE: Just tried something more serious than a triangle displaying app - a Unigine Tropics demo. Same behavior - about 30% CPU usage by X process while compositing is enabled, and 5% when disabled. Overall FPS is also higher in the latter case. Looks like OpenGL apps (and VDPAU) don't use direct rendering with KDE's compositing. However the compositing itself runs smoothly. |
![]() Registered Member ![]()
|
It seems to work OK here, Nvidia 8500GT, with "Enabling direct rendering" enabled, although I don't use desktop effects that much.
|
![]() Administrator ![]()
|
This is due to a limitation in the Linux DRI infrastructure, which is not designed for multiple applications performing direct rendering at once. DRI2, its successor is designed for this, but it will take time for drivers and applications to migrate to it ( assuming that X ships with it )
Thus, applications cannot use the GPU when KWin is doing desktop effects.
KDE Sysadmin
[img]content/bcooksley_sig.png[/img] |
![]() Registered Member ![]()
|
Thanks for your answer, bcooksley. Makes sense, but does this apply to VDPAU as well? I'm not sure how it relates to DRI. Topic starter noted that it works fine with Compiz, but not KWin. Can't confirm it, but if VDPAU does work with Compiz, it means that either it doesn't use DRI or Compiz somehow lets it use direct rendering instead of itself, right? Which one is more likely? Either way (assuming that it's fine with Compiz), it looks possible to have both effects enabled and good performance with VDPAU.
Just tried disabling direct rendering in KDE's effects settings - X process still has high CPU usage with both VDPAU and OpenGL apps. Or is this setting not related? |
![]() Administrator ![]()
|
Disabling direct rendering will likely not have an effect, except to decrease the performance of KWin's effects.
I do not have any ideas on why Compiz does not affect this, but it is probable they implemented a workaround of some description, or use VDPAU natively if it is available.
KDE Sysadmin
[img]content/bcooksley_sig.png[/img] |
Registered users: bancha, Bing [Bot], Google [Bot], Sogou [Bot]