Skip to content

Strokes are not rendered in some installations of Manim using OpenGL renderer #1240

Open
@Darylgolden

Description

@Darylgolden

Description of bug / unexpected behavior

from manim import *
from manim.opengl import *

class Test(Scene):
    def construct(self):
        circle = OpenGLCircle()
        circle.set_fill(BLUE, opacity=0.5)
        circle.set_stroke(BLUE_E, width=4)
        square = OpenGLSquare(fill_opacity=0, stroke_opacity=1, stroke_color=RED, stroke_width=5, draw_stroke_behind_fill=False)

        self.play(FadeIn(square))
        self.wait()

Gives a blank black screen:

Test.mp4

While

from manim import *
from manim.opengl import *

class Test(Scene):
    def construct(self):
        circle = OpenGLCircle()
        circle.set_fill(BLUE, opacity=0.5)
        circle.set_stroke(BLUE_E, width=4)
        square = OpenGLSquare(fill_opacity=1, stroke_opacity=1, stroke_color=RED, stroke_width=5, draw_stroke_behind_fill=False)

        self.play(FadeIn(square))
        self.wait()

Gives this:

Test.mp4

This shows that the problem in my local installation lies with rendering strokes.

Expected behavior

Strokes should render correctly.

How to reproduce the issue

Code for reproducing the problem
Paste your code here.

Additional media files

Images/GIFs

Logs

Terminal output
PASTE HERE OR PROVIDE LINK TO https://pastebin.com/ OR SIMILAR

System specifications

System Details
  • OS Microsoft Windows 10 Home Insider Preview Version10.0.21343 Build 21343
  • RAM: Is this relevant?
  • Python version (python/py/python3 --version): Python 3.9.2
  • Installed modules (provide output from pip list):
Package                       Version
----------------------------- -----------
alabaster                     0.7.12
ansicon                       1.89.0
anyio                         2.2.0
appdirs                       1.4.4
argon2-cffi                   20.1.0
astroid                       2.5.2
async-generator               1.10
attrs                         20.3.0
Babel                         2.9.0
backcall                      0.2.0
bleach                        3.3.0
blessed                       1.18.0
certifi                       2020.12.5
cffi                          1.14.5
chardet                       4.0.0
colorama                      0.4.4
colour                        0.1.5
commonmark                    0.9.1
decorator                     4.4.2
defusedxml                    0.7.0
dnspython                     1.16.0
docopt                        0.6.2
docutils                      0.16
entrypoints                   0.3
fett                          0.3.2
flyingcircus                  0.1.3.2
glcontext                     2.3.3
grpcio                        1.33.2
grpcio-tools                  1.33.2
idna                          2.10
imagesize                     1.2.0
ipykernel                     5.5.0
ipython                       7.21.0
ipython-genutils              0.2.0
isort                         5.8.0
jedi                          0.18.0
Jinja2                        2.11.3
jinxed                        1.0.1
json5                         0.9.5
jsonschema                    3.2.0
jupyter-client                6.1.11
jupyter-core                  4.7.1
jupyter-packaging             0.7.12
jupyter-server                1.4.1
jupyterlab                    3.0.9
jupyterlab-pygments           0.1.2
jupyterlab-server             2.3.0
lazy-object-proxy             1.6.0
livereload                    2.6.3
manim                         0.5.0
ManimPango                    0.2.4
mapbox-earcut                 0.12.10
MarkupSafe                    1.1.1
mccabe                        0.6.1
mistune                       0.8.4
moderngl                      5.6.4
moderngl-window               2.3.0
multipledispatch              0.6.0
nbclassic                     0.2.6
nbclient                      0.5.3
nbconvert                     6.0.7
nbformat                      5.1.2
nest-asyncio                  1.5.1
networkx                      2.5
notebook                      6.2.0
numpy                         1.20.1
packaging                     20.9
pandocfilters                 1.4.3
parso                         0.8.1
pickleshare                   0.7.5
Pillow                        8.1.0
pip                           21.0.1
prometheus-client             0.9.0
prompt-toolkit                3.0.16
protobuf                      3.15.5
pycairo                       1.20.0
pycparser                     2.20
pydub                         0.24.1
pyglet                        1.5.15
Pygments                      2.8.0
pylint                        2.7.3
pymongo                       3.11.3
pyparsing                     2.4.7
pyrr                          0.10.3
pyrsistent                    0.17.3
python-dateutil               2.8.1
python-jsonrpc-server         0.3.4
pytk                          0.0.2.1
pytz                          2021.1
pywin32                       300
pywinpty                      0.5.7
PyYAML                        5.4.1
pyzmq                         22.0.3
requests                      2.25.1
rich                          6.2.0
rstcheck                      3.3.1
scipy                         1.6.1
Send2Trash                    1.5.0
setuptools                    53.1.0
setuptools-scm                5.0.2
six                           1.15.0
sniffio                       1.2.0
snooty-lextudio               1.8.10.dev0
snowballstemmer               2.1.0
Sphinx                        3.5.3
sphinx-autobuild              2021.3.14
sphinxcontrib-applehelp       1.0.2
sphinxcontrib-devhelp         1.0.2
sphinxcontrib-htmlhelp        1.0.3
sphinxcontrib-jsmath          1.0.1
sphinxcontrib-qthelp          1.0.3
sphinxcontrib-serializinghtml 1.1.4
terminado                     0.9.2
testpath                      0.4.4
toml                          0.10.2
tornado                       6.1
tqdm                          4.58.0
traitlets                     5.0.5
typing-extensions             3.7.4.3
urllib3                       1.26.3
watchdog                      1.0.2
wcwidth                       0.2.5
webencodings                  0.5.1
wheel                         0.36.2
wrapt                         1.12.1
LaTeX details
  • LaTeX distribution (e.g. TeX Live 2020):
  • Installed LaTeX packages:
FFMPEG

Output of ffmpeg -version:


Additional comments

Metadata

Metadata

Assignees

No one assigned

    Labels

    issue:bugSomething isn't working... For use in issues

    Type

    No type

    Projects

    Status

    🆕 New

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions