Skip to contentSkip to conversation

New: Problem with resizing OpenGL windows when using XCB

Bug 42131 [email protected] 1 participant 3 messages Oct 23, 2011 – Jan 3, 2012

lore
Share & tools
lore
#0 lore raw

https://bugs.freedesktop.org/show_bug.cgi?id=42131

             Bug #: 42131
           Summary: Problem with resizing OpenGL windows when using XCB
    Classification: Unclassified
           Product: Mesa
           Version: 7.11
          Platform: x86-64 (AMD64)
        OS/Version: Linux (All)
            Status: NEW
          Severity: normal
          Priority: medium
         Component: Drivers/Gallium/r600
        AssignedTo: [email protected]
        ReportedBy: [email protected]

Created attachment 52651
--> https://bugs.freedesktop.org/attachment.cgi?id=52651
Test program demonstrating the problem

The attached program creates a window using XCB and draws a rectangle inside it using OpenGL. When using indirect software rendering (LIBGL_ALWAYS_INDIRECT=1), everything works as expected. But when using the R600 Gallium3D driver, the OpenGL view port doesn't seem to get resized properly and the window contents get screwed up.

Signature · 3 lines
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
#1 lore raw

[Bug 42131] Problem with resizing OpenGL windows when using XCB

https://bugs.freedesktop.org/show_bug.cgi?id=42131

--- Comment #1 from [email protected] 2012-01-03 07:05:34 PST --- I can confirm this bug. It seems that there are some internal events, forwarded to the DRI(2) module that get lost, as xcb doesn't use XEvents. That's why it works, when you use the Xlib Event Loop { if (XPending(D)) XNextEvent(D,&E); } with XSetEventQueueOwner(Xlib...);

When you use the xcb event loop mechanism, mesa does not detect the events, that need to be reacted on by the DRI module.

So after all, this problem has to be solved within mesa, not within xcb. Obviously there where some experiments that care about xcb and mesa, but I haven't found a good development branch yet.

What I do about this problem now is to create a glXCreateWindow (overlay) at full screen size and render my scene into the visible part of the window, by translation and scaling.

Signature · 3 lines
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
#2 lore raw

[Bug 42131] Problem with resizing OpenGL windows when using XCB

In reply to [email protected]

https://bugs.freedesktop.org/show_bug.cgi?id=42131

Alex Deucher <[email protected]> changed:

What |Removed |Added
----------------------------------------------------------------------------

         AssignedTo|[email protected] |[email protected].
                   |.org                        |org
          Component|Drivers/Gallium/r600        |Mesa core
Signature · 3 lines
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.