Wayland: Cannot draw OpenGL widget beyond window borders (cannot put it inside a viewport) #10

Closed
opened 2026-03-19 15:40:06 +09:00 by IoI_xD · 2 comments
Owner

This is a bug that I'm encountering as I'm finally fixing the Wayland port and it's an obscure enough use case (yet one that shows up in the demos) that I'll just leave it here for posterity and fix it later.

Putting an OpenGL widget inside a viewport (as seen in the tripaint demo) results in undefined behavior because there's some weird situation where Wayland in general accidentally made drawing subsurfaces outside bounds UB. This was a problem for a long time for all widgets, we just finally fixed it for regular widgets, but I don't even know what we'd do for GL.

image

This is a bug that I'm encountering as I'm finally fixing the Wayland port and it's an obscure enough use case (yet one that shows up in the demos) that I'll just leave it here for posterity and fix it later. Putting an OpenGL widget inside a viewport (as seen in the tripaint demo) results in undefined behavior because there's some weird situation where Wayland in general accidentally made drawing subsurfaces outside bounds UB. This was a problem for a long time for all widgets, we just finally fixed it for regular widgets, but I don't even know what we'd do for GL. ![image](/attachments/0178d7c9-dcfa-48a6-adf5-b1d5ef1476fc)
Author
Owner

FWIW too this isn't even reproducable in the examples anymore as I've just made the tripaint demo not use a viewport

image

FWIW too this isn't even reproducable in the examples anymore as I've just made the tripaint demo not use a viewport ![image](/attachments/fe27b0bb-62f8-447a-8032-520c30e0902b)
Owner

wontfix

wontfix
nishi closed this issue 2026-04-20 14:31:19 +09:00
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
pyrite-dev/milsko#10
No description provided.