Bug 311712 - kwin_gles not working with AMD ATI RS690M
Summary: kwin_gles not working with AMD ATI RS690M
Status: RESOLVED FIXED
Alias: None
Product: kwin
Classification: Unclassified
Component: scene-opengl (show other bugs)
Version: 4.9.90 (Beta 2)
Platform: unspecified Linux
: NOR normal (vote)
Target Milestone: 4.10 RC 2
Assignee: KWin default assignee
URL: https://git.reviewboard.kde.org/r/107...
Keywords: regression
Depends on:
Blocks:
 
Reported: 2012-12-14 21:48 UTC by Daniel Nicoletti
Modified: 2013-01-14 14:10 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In: 4.10 RC 2
mgraesslin: ReviewRequest+


Attachments
KWin with KWIN_COMPOSE=O2 (4.76 KB, application/octet-stream)
2013-01-14 03:57 UTC, Daniel Nicoletti
Details
kwin without any env var (2.12 KB, application/octet-stream)
2013-01-14 03:58 UTC, Daniel Nicoletti
Details
kwin set to xrender (3.86 KB, application/octet-stream)
2013-01-14 03:58 UTC, Daniel Nicoletti
Details
OpenGL 2 Shaders enabled and raster (dunno why I didn't set raster before :P ) (4.76 KB, application/octet-stream)
2013-01-14 13:46 UTC, Daniel Nicoletti
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Daniel Nicoletti 2012-12-14 21:48:11 UTC
before 4.10 kwin_gles worked just fine on my:
AMD ATI RS690M [Radeon X1200 Series],
I use it because it's much faster than regular kwin (it keeps around 20fps),
tho after experimenting some options I found that:
KWIN_OPENGL_INTERFACE=egl KWIN_COMPOSE=O1 kwin --replace
make it closer to what kwin_gles offers but is much slower when
moving windows.

Here is the line that make kwin_gles work as before:
KWIN_COMPOSE=O2 kwin_gles --replace

Here is the line that makes kwin_gles fails to enable compositing:
daniel@bart:~/code$ kwin_gles --replace
QDBusConnection: session D-Bus connection created before QCoreApplication. Application may misbehave.
kwin(5256) KWin::Extensions::init: Extensions: shape: 0x "11"  composite: 0x "4"  render: 0x "b"  fixes: 0x "60"  non_native_pixmaps:  false
kwin(5256) KDecorationPlugins::canLoad: kwin : path  "/usr/lib/kde4/kwin3_oxygen.so"  for  "kwin3_oxygen"
kwin(5256) KWin::Workspace::updateClientArea: screens:  1 desktops:  2
kwin(5256) KWin::Workspace::updateClientArea: Done.
QCoreApplication::sendPostedEvents: Cannot send posted events for objects in another thread
QCoreApplication::sendPostedEvents: Cannot send posted events for objects in another thread
kwin(5256) KWin::Client::readUserTimeMapTimestamp: User timestamp, ASN: 5158365
kwin(5256) KWin::Client::readUserTimeMapTimestamp: User timestamp, final: 'ID: 33554957 ;WMCLASS: "plasma" : "plasma" ;Caption: "plasma-desktop" ' : 5158365
kwin(5256) KWin::Workspace::allowClientActivation: Activation: No client active, allowing
kwin(5256) KWin::Workspace::updateClientArea: screens:  1 desktops:  2
kwin(5256) KWin::Workspace::updateClientArea: Done.
kwin(5256) KWin::Client::readUserTimeMapTimestamp: User timestamp, ASN: 1962342
kwin(5256) KWin::Client::readUserTimeMapTimestamp: User timestamp, final: 'ID: 54525998 ;WMCLASS: "kvirc" : "kvirc" ;Caption: "KVIrc 4.1.3 Equilibrium - [#postgresql (+cntj) [dantti_laptop ligado adams.freenode.net]]" ' : 1962342
kwin(5256) KWin::Workspace::allowClientActivation: Activation: No client active, allowing
kwin(5256) KWin::Workspace::updateClientArea: screens:  1 desktops:  2
kwin(5256) KWin::Workspace::updateClientArea: Done.
kwin(5256) KWin::Client::readUserTimeMapTimestamp: User timestamp, ASN: 4294967295
kwin(5256) KWin::Client::readUserTimeMapTimestamp: User timestamp, final: 'ID: 31457333 ;WMCLASS: "skype" : "skype" ;Caption: "dantti85 - Skype™" ' : 4294967295
kwin(5256) KWin::Workspace::allowClientActivation: Activation: No client active, allowing
kwin(5256) KWin::Workspace::updateClientArea: screens:  1 desktops:  2
kwin(5256) KWin::Workspace::updateClientArea: Done.
kwin(5256) KWin::Client::readUserTimeMapTimestamp: User timestamp, ASN: 3481657
kwin(5256) KWin::Client::readUserTimeMapTimestamp: User timestamp, final: 'ID: 37748757 ;WMCLASS: "systemsettings" : "systemsettings" ;Caption: "Impressoras – Configurações do sistema" ' : 3481657
kwin(5256) KWin::Workspace::allowClientActivation: Activation: No client active, allowing
kwin(5256) KWin::Workspace::updateClientArea: screens:  1 desktops:  2
kwin(5256) KWin::Workspace::updateClientArea: Done.
kwin(5256) KWin::Client::readUserTimeMapTimestamp: User timestamp, ASN: 4807863
kwin(5256) KWin::Client::readUserTimeMapTimestamp: User timestamp, final: 'ID: 31457514 ;WMCLASS: "skype" : "skype" ;Caption: "Valentino Crosato - Skype™" ' : 4807863
kwin(5256) KWin::Workspace::allowClientActivation: Activation: No client active, allowing
kwin(5256) KWin::Workspace::updateClientArea: screens:  1 desktops:  2
kwin(5256) KWin::Workspace::updateClientArea: Done.
kwin(5256) KWin::Client::readUserTimeMapTimestamp: User timestamp, ASN: 5924524
kwin(5256) KWin::Client::readUserTimeMapTimestamp: User timestamp, final: 'ID: 29360333 ;WMCLASS: "chromium-browser" : "chromium-browser" ;Caption: "Facebook - Chromium" ' : 5924524
kwin(5256) KWin::Workspace::allowClientActivation: Activation: No client active, allowing
kwin(5256) KWin::Workspace::updateClientArea: screens:  1 desktops:  2
kwin(5256) KWin::Workspace::updateClientArea: Done.                                                                                                                            
kwin(5256) KWin::Client::readUserTimeMapTimestamp: User timestamp, ASN: 5936533                                                                                                
kwin(5256) KWin::Client::readUserTimeMapTimestamp: User timestamp, final: 'ID: 52428826 ;WMCLASS: "konsole" : "konsole" ;Caption: "code : kwin_gles – Konsole" ' : 5936533     
kwin(5256) KWin::Workspace::allowClientActivation: Activation: No client active, allowing                                                                                      
kwin(5256) KWin::Workspace::updateClientArea: screens:  1 desktops:  2                                                                                                         
kwin(5256) KWin::Workspace::updateClientArea: Done.                                                                                                                            
kwin(5256) KWin::Client::readUserTimeMapTimestamp: User timestamp, ASN: 5833072                                                                                                
kwin(5256) KWin::Client::readUserTimeMapTimestamp: User timestamp, final: 'ID: 33554948 ;WMCLASS: "plasma" : "plasma" ;Caption: "plasma-desktop" ' : 5833072                   
kwin(5256) KWin::Workspace::allowClientActivation: Activation: No client active, allowing
kwin(5256) KWin::Workspace::updateClientArea: screens:  1 desktops:  2
kwin(5256) KWin::Workspace::updateClientArea: Done.
kwin(5256) KWin::Workspace::updateClientArea: screens:  1 desktops:  2
kwin(5256) KWin::Workspace::updateClientArea: Done.
kwin(5256) KWin::Compositor::slotCompositingOptionsInitialized: Initializing OpenGL compositing
kwin(5256) KWin::EglOnXBackend::initRenderingContext: EGL version:  1 . 4
OpenGL vendor string:                   X.Org R300 Project
OpenGL renderer string:                 Gallium 0.4 on ATI RS690
OpenGL version string:                  OpenGL ES 2.0 Mesa 8.0.4
OpenGL shading language version string: OpenGL ES GLSL ES 1.0.16
Driver:                                 R300G
GPU class:                              R400
OpenGL version:                         2.0
GLSL version:                           1.0.16
Mesa version:                           8.0.4
X server version:                       1.13
Linux kernel version:                   3.5
Direct rendering:                       yes
Requires strict binding:                no
GLSL shaders:                           limited
Texture NPOT support:                   limited
Virtual Machine:                        no
kwin(5256) KWin::SceneOpenGL2::supported: Driver does not recommend OpenGL 2 compositing
kwin(5256): Failed to initialize compositing, compositing disabled 
kwin(5256): Consult http://techbase.kde.org/Projects/KWin/4.0-release-notes#Setting_up 
QCoreApplication::sendPostedEvents: Cannot send posted events for objects in another thread
QCoreApplication::sendPostedEvents: Cannot send posted events for objects in another thread
kwin(5256)/kdecore (KSycoca) KSycocaPrivate::openDatabase: Trying to open ksycoca from "/var/tmp/kdecache-daniel/ksycoca4"

Please tell what else is important for getting this fixed,
thanks :)

Reproducible: Always
Comment 1 Martin Flöser 2012-12-14 21:55:47 UTC
check for recommended driver in SceneOpenGL2::supported might be put into an ifdef. But I think I did it that way as the environment variable is good enough. Not sure about it.
Comment 2 Martin Flöser 2012-12-22 10:45:47 UTC
Git commit 26fdfac26b0d2a66f14f1169937c8b874cefd6d2 by Martin Gräßlin.
Committed on 20/12/2012 at 21:44.
Pushed by graesslin into branch 'KDE/4.10'.

Do not block OpenGL 2 when build for gles due to driver recommendation

Let's assume a user knows what she is doing when she selects kwin_gles
instead of kwin. Also in gles there is no fallback to OpenGL 1 possible
so blocking is not the proper solution in the first place.
FIXED-IN: 4.10 RC 2
REVIEW: 107824

M  +2    -0    kwin/scene_opengl.cpp

http://commits.kde.org/kde-workspace/26fdfac26b0d2a66f14f1169937c8b874cefd6d2
Comment 3 Daniel Nicoletti 2012-12-22 12:05:04 UTC
Thanks for the quick fix
Em 22/12/2012 08:45, "Martin Gräßlin" <mgraesslin@kde.org> escreveu:

> https://bugs.kde.org/show_bug.cgi?id=311712
>
> Martin Gräßlin <mgraesslin@kde.org> changed:
>
>            What    |Removed                     |Added
>
> ----------------------------------------------------------------------------
>              Status|CONFIRMED                   |RESOLVED
>    Version Fixed In|                            |4.10 RC 2
>          Resolution|---                         |FIXED
>       Latest Commit|                            |
> http://commits.kde.org/kde-
>                    |
>  |workspace/26fdfac26b0d2a66f
>                    |                            |14f1169937c8b874cefd6d2
>
> --- Comment #2 from Martin Gräßlin <mgraesslin@kde.org> ---
> Git commit 26fdfac26b0d2a66f14f1169937c8b874cefd6d2 by Martin Gräßlin.
> Committed on 20/12/2012 at 21:44.
> Pushed by graesslin into branch 'KDE/4.10'.
>
> Do not block OpenGL 2 when build for gles due to driver recommendation
>
> Let's assume a user knows what she is doing when she selects kwin_gles
> instead of kwin. Also in gles there is no fallback to OpenGL 1 possible
> so blocking is not the proper solution in the first place.
> FIXED-IN: 4.10 RC 2
> REVIEW: 107824
>
> M  +2    -0    kwin/scene_opengl.cpp
>
>
> http://commits.kde.org/kde-workspace/26fdfac26b0d2a66f14f1169937c8b874cefd6d2
>
> --
> You are receiving this mail because:
> You reported the bug.
Comment 4 Daniel Nicoletti 2013-01-11 21:13:58 UTC
Was this commited before RC2 came out? if so I still have the issue
Comment 5 Thomas Lübking 2013-01-11 21:33:10 UTC
"seems"

The patch will not skip the warning, but should then proceed with the GLLegcy config option processing
Do you have "opengl 2.0 shaders" activated in "kcmshell4 kwincompositing"?
You'd get a "OpenGL 2 disabled by config option" debug out for it.
Comment 6 Martin Flöser 2013-01-11 21:46:50 UTC
please provide output of
qdbus org.kde.kwin /KWin supportInformation

that should contain all the information
Comment 7 Daniel Nicoletti 2013-01-11 21:54:36 UTC
aniel@bart:~/code/print-manager$ qdbus org.kde.KWin /KWin supportInformation
Informação de suporte do KWin:                                                                                                                                               
A seguinte informação deve ser usada ao pedir suporte, p.ex., no http://forum.kde.org.                                                                                       
Ela fornece informações sobre a instância atualmente em execução, quais as opções usadas,                                                                                    
qual o driver de OpenGL e os efeitos em execução.                                                                                                                            
Por favor, envie a informação oferecida abaixo deste texto introdutório para um serviço de área de transferência remoto,                                                     
tais como o http://paste.kde.org, em vez de colar o texto nos tópicos de suporte.                                                                                            
                                                                                                                                                                             
==========================                                                                                                                                                   

Options
=======
focusPolicy: 0
nextFocusPrefersMouse: false
clickRaise: true
autoRaise: false
autoRaiseInterval: 0
delayFocusInterval: 0
shadeHover: false
shadeHoverInterval: 250
separateScreenFocus: false
activeMouseScreen: false
placement: 4
focusPolicyIsReasonable: true
borderSnapZone: 10
windowSnapZone: 10
centerSnapZone: 0
snapOnlyWhenOverlapping: false
showDesktopIsMinimizeAll: false
rollOverDesktops: true
focusStealingPreventionLevel: 1
legacyFullscreenSupport: false
operationTitlebarDblClick: 
commandActiveTitlebar1: 0
commandActiveTitlebar2: 30
commandActiveTitlebar3: 2
commandInactiveTitlebar1: 4
commandInactiveTitlebar2: 30
commandInactiveTitlebar3: 2
commandWindow1: 7
commandWindow2: 8
commandWindow3: 8
commandWindowWheel: 31
commandAll1: 10
commandAll2: 3
commandAll3: 14
keyCmdAllModKey: 16777251
showGeometryTip: false
condensedTitle: false
electricBorders: false
electricBorderDelay: 150
electricBorderCooldown: 350
electricBorderPushbackPixels: 1
electricBorderMaximize: true
electricBorderTiling: true
electricBorderCornerRatio: 0.25
borderlessMaximizedWindows: false
killPingTimeout: 5000
hideUtilityWindowsForInactive: true
inactiveTabsSkipTaskbar: false
autogroupSimilarWindows: false
autogroupInForeground: true
compositingMode: 1
useCompositing: true
compositingInitialized: true
hiddenPreviews: 1
unredirectFullscreen: false
glSmoothScale: 0
glVSync: false
colorCorrected: false
xrenderSmoothScale: false
maxFpsInterval: 17
refreshRate: 0
vBlankTime: 6144
glDirect: true
glStrictBinding: true
glStrictBindingFollowsDriver: true
glLegacy: true

Compositing
===========
Qt Graphics System: native
Compositing is not active
Comment 8 Daniel Nicoletti 2013-01-11 21:55:48 UTC
>Do you have "opengl 2.0 shaders" activated in "kcmshell4 kwincompositing"?
No that option makes kwin_gles slower here when compositing is working...
Comment 9 Martin Flöser 2013-01-11 22:01:01 UTC
> >Do you have "opengl 2.0 shaders" activated in "kcmshell4 kwincompositing"?
> 
> No that option makes kwin_gles slower here when compositing is working...
:-) Then I dare to say that you never had kwin_gles with OpenGL running. 
kwin_gles only operates with OpenGL 2, the OpenGl 1 code path is ifdefed.

If it has always been like that, it probably just fall back to XRender, which 
would explain why you have graphicssystem native instead of the default.
Comment 10 Daniel Nicoletti 2013-01-14 03:57:33 UTC
Created attachment 76455 [details]
KWin with KWIN_COMPOSE=O2
Comment 11 Daniel Nicoletti 2013-01-14 03:58:26 UTC
Created attachment 76456 [details]
kwin without any env var
Comment 12 Daniel Nicoletti 2013-01-14 03:58:54 UTC
Created attachment 76457 [details]
kwin set to xrender
Comment 13 Daniel Nicoletti 2013-01-14 04:01:41 UTC
>:-) Then I dare to say that you never had kwin_gles with OpenGL running. 
>kwin_gles only operates with OpenGL 2, the OpenGl 1 code path is ifdefed.
Compositing Type: OpenGL ES 2.0

sorry the first time I pasted it was with kwin without the O2 env var (I didn't know
you wanted the output of the working thing...)

Also since it worked in kde 4.9 there would still be some issue, and setting to
xrender makes another difference.

please note that all outputs where made using kwin_gles not kwin

Thanks
Comment 14 Martin Flöser 2013-01-14 06:20:24 UTC
Please enable the OpenGL 2 shaders option and switch the graphics system to raster
Comment 15 Daniel Nicoletti 2013-01-14 13:46:29 UTC
Created attachment 76462 [details]
OpenGL 2 Shaders enabled and raster (dunno why I didn't set raster before :P )
Comment 16 Martin Flöser 2013-01-14 13:51:18 UTC
>(dunno why I didn't set raster before :P
because changing to XRender automatically changes to native.
Comment 17 Martin Flöser 2013-01-14 13:53:31 UTC
@Daniel: is now everything fine or are there still issues?
Comment 18 Daniel Nicoletti 2013-01-14 13:58:20 UTC
Ok, so it seems the regression is actually that in 4.9 if you didn't check "Use OpenGL 2 shaders" it enabled for you, having that checked kwin_gles runs composited, probably that checkbox wasn't reflecting the current state of the compositor?

BTW does the Raster setting there means all Qt apps will run using raster or I still need that env var?
Comment 19 Martin Flöser 2013-01-14 14:10:14 UTC
(In reply to comment #18)
> BTW does the Raster setting there means all Qt apps will run using raster or
> I still need that env var?
no, it only affects KWin, but Qt uses raster by default nowadays.