-
Notifications
You must be signed in to change notification settings - Fork 2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixed opengl Surface with reordering initialization process (#3089)
* Fixed opengl Surface with disabling refresh of shader wrapper id in constructor * Reordered Elements in constructor of opengl_vectorized_mobject to fix initialization dependency issues
- Loading branch information
Showing
4 changed files
with
26 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
import numpy as np | ||
|
||
from manim.mobject.opengl.opengl_surface import OpenGLSurface | ||
from manim.mobject.opengl.opengl_three_dimensions import OpenGLSurfaceMesh | ||
|
||
|
||
def test_surface_initialization(using_opengl_renderer): | ||
surface = OpenGLSurface( | ||
lambda u, v: (u, v, u * np.sin(v) + v * np.cos(u)), | ||
u_range=(-3, 3), | ||
v_range=(-3, 3), | ||
) | ||
|
||
mesh = OpenGLSurfaceMesh(surface) |