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

Spurious Flush() in display.capture() #548

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

ggcrunchy
Copy link
Contributor

Basically, display.capture() and friends seem to be the only cases where the second overload of Scene::Render() is called. From what I can tell these never need the Flush(); I believe it's just a copy-paste artifact.

It's a no-op on most platforms.[1] On Windows, though, it calls SwapBuffers(). You can see this if you try the CaptureToFile code sample, where you get a black image for a frame; without the Flush() you don't. From my admittedly foggy recollection the other exceptions were similar "end of frame" / vsync logic.


[1] - I'd have to review them to see where it isn't. I did the actual analysis almost a year ago, probably while investigating the Discord streaming crashes. I'm trying to distill a big diff into branches / PRs now, and had this on hand due to testing something or other with display.capture().

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

Successfully merging this pull request may close these issues.

None yet

2 participants