Open spacejack opened 6 years ago
Could you please check gl/glutin samples to confirm an upstream issue?
Interesting results...
Anyway the examples are all very simple, just renders one triangle. When resizing the 'window' example on MacOS the triangle is scaled to fit the window at all times. On Windows10 the triangle remains a fixed size, at a fixed position relative to the bottom/left corner of the window. So it gets cropped if the window shrinks. It also flickers and bounces a bit while resizing.
This is the opposite of what I would have expected, but shows there are differences between platforms.
I can confirm that on MacOS, resizing three-rs windows generates flicker, unexpected updates to the viewport, and generally bad behavior (e.g., increasingly long lag times). I don't observe this behavior with the examples from the glutin project.
@kbarros what version of glutin
did you tested? Also I kindly ask you to test gfx/pre-ll
examples (https://github.com/gfx-rs/gfx/tree/pre-ll)
I apologize, but today I can't reproduce the behavior I reported yesterday with three-rs resizing. Today I only observe the projection matrix / viewport issue that spacejack originally reported. Specifically, when resizing the window in the vertical direction, it appears that the viewport becomes vertically off-center. I confirmed that this resizing issue does not appear in the glutin and gfx/pre-ll examples. I tested only on MacOS.
@kbarros thanks, I'll try to look into it.
The projection matrix (or viewport?) is not updated when the window is resized as it is when running on Windows/Linux.