Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Resize of a window on OSX results in a black screen #73

Closed
smasher164 opened this issue Dec 27, 2017 · 1 comment
Closed

Resize of a window on OSX results in a black screen #73

smasher164 opened this issue Dec 27, 2017 · 1 comment

Comments

@smasher164
Copy link

Resizing a pixel app on OSX results in a black screen until the mouse is released. I believe this is because glfw blocks in PollEvents during the resize, so this loop won't clear the background during that period.

for !win.Closed() {
	win.Clear(colornames.Lightgrey)
	win.Update()
}

However, as mentioned in glfw/glfw#408, one can get the desired behavior by rendering in a refresh callback. Is there anyway for pixel to incorporate this behavior?

@faiface
Copy link
Owner

faiface commented Dec 27, 2017

Hi! Currently, there is no way incorporate this behavior using Pixel. I don't think it ever will. I understand it can be useful, but Pixel's I/O API is not event based and thus this kind of callback falls out of scope.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants