mirror of
https://github.com/3b1b/manim.git
synced 2025-08-02 11:03:03 +08:00
Use non-window fbo in scene.get_image
This commit is contained in:
@ -288,13 +288,12 @@ class Scene(object):
|
||||
|
||||
def get_image(self) -> Image:
|
||||
if self.window is not None:
|
||||
self.window.size = self.camera.get_pixel_shape()
|
||||
self.window.swap_buffers()
|
||||
self.update_frame()
|
||||
self.window.swap_buffers()
|
||||
self.camera.use_window_fbo(False)
|
||||
self.camera.clear()
|
||||
self.camera.capture(*self.mobjects)
|
||||
image = self.camera.get_image()
|
||||
if self.window is not None:
|
||||
self.window.to_default_position()
|
||||
self.camera.use_window_fbo(True)
|
||||
return image
|
||||
|
||||
def show(self) -> None:
|
||||
|
Reference in New Issue
Block a user