[Interest] glGetString from QML-based Wayland compositor

Pier Luigi pierluigi.fiorini at gmail.com
Mon Jan 7 20:22:26 CET 2013


2013/1/2 Samuel Rødal <samuel.rodal at digia.com>:
> On 12/28/2012 09:53 AM, Pier Luigi wrote:
>>
>> However glGetString() always return NULL, I call it from the
>> sceneGraphInitialized() slot and I noticed that despite
>> openglContext() returns a valid pointer,
>> QOpenGLContext::currentContext() is 0.
>>
>> Someone has an idea on what I'm doing wrong?
>
> On which thread do you execute the slot connected to
> sceneGraphInitialized() ? The scene graph might run on a separate thread
> from the main UI thread, and the QOpenGLContext will then be made
> current there.

I first tried to use glGetString() from main after the compositor
creation but that should be a different thread than the rendering
thead:

https://github.com/hawaii-desktop/greenisland/blob/master/src/greenisland/main.cpp

Then I tried to connect the signal on the QQuickView subclass constructor to a
private slot.
The slot should be called from the rendering thread, giving me access
to the context but it doesn't seem to happen.

--
Out of the box experience
http://www.maui-project.org/



More information about the Interest mailing list