mirror of
https://github.com/3b1b/manim.git
synced 2025-04-13 09:47:07 +00:00
Move camera.clear call into 'capture'
This commit is contained in:
parent
5803a00598
commit
e9333a908c
2 changed files with 1 additions and 2 deletions
|
@ -210,6 +210,7 @@ class Camera(object):
|
|||
|
||||
# Rendering
|
||||
def capture(self, *mobjects: Mobject) -> None:
|
||||
self.clear()
|
||||
self.refresh_uniforms()
|
||||
self.fbo.use()
|
||||
for mobject in mobjects:
|
||||
|
|
|
@ -289,7 +289,6 @@ class Scene(object):
|
|||
def get_image(self) -> Image:
|
||||
if self.window is not None:
|
||||
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:
|
||||
|
@ -311,7 +310,6 @@ class Scene(object):
|
|||
|
||||
if self.window:
|
||||
self.window.clear()
|
||||
self.camera.clear()
|
||||
self.camera.capture(*self.mobjects)
|
||||
|
||||
if self.window:
|
||||
|
|
Loading…
Add table
Reference in a new issue