Skip to content

Commit

Permalink
Fix snapshot showing the UI
Browse files Browse the repository at this point in the history
  • Loading branch information
sercero committed Apr 27, 2024
1 parent 749108f commit 9294688
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions ogre_mesh_viewer.py
Original file line number Diff line number Diff line change
Expand Up @@ -618,6 +618,8 @@ def _save_screenshot(self):
Ogre.LogManager.getSingleton().logMessage(f"Screenshot saved to folder: {os.path.normpath(self.filedir)}")

self.cam.getViewport().setOverlaysEnabled(False)
# We need two to really hide the Overlay (ImGUI)
self.getRoot().renderOneFrame()
self.getRoot().renderOneFrame()
self.getRenderWindow().writeContentsToTimestampedFile(outpath, ".png")
self.cam.getViewport().setOverlaysEnabled(True)
Expand Down

0 comments on commit 9294688

Please sign in to comment.