ManimCommunity / ManimCommunity/manim

Error in OpenGL SurfaceExample: `'Sphere' object has no attribute 'uv_func'`

Open
#3,705 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
40.9k
Forks
3.1k
Avg merge
3d 12h
Merged PRs (30d)
25

Description

Hi! I'm running [this scene (`SurfaceExample`)](https://github.com/ManimCommunity/manim/blob/04bfa221075166a00eaa11fc9e9f0757f56625d2/example_scenes/opengl.py#L447) in the OpenGL examples, and I'm unable to create the `OpenGLTexturedSurface` because the `Sphere` object is not of type `OpenGLSurface` and has no `uv_func` as far as I can see.

This is on `manim==0.18.0`, Python 3.12, Apple M1. I've tried downgrading `manim` (and Python) to `<0.18`, `<0.17`, since this was shown to be working [in this video](https://www.youtube.com/watch?v=KeXBLPC1tns), but then started running into other issues when the latter installed `0.15.0`, so I've abandoned that for now.

Any help would be much appreciated — happy to PR any changes back to the examples!

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with SurfaceExample in example_scenes/opengl.py around line 447 and run the scene on the reported Manim version to reproduce the AttributeError. Trace how Sphere is passed to OpenGLTexturedSurface and compare the expected surface interface. Done means the example runs without the missing uv_func error.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
computer-graphics
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.