ManimCommunity / ManimCommunity/manim
Decimal numbers don't work with `self.add_fixed_in_frame_mobjects`
- Dominant language
- Python
- Stars
- 40.9k
- Forks
- 3.1k
- Avg merge
- 3d 12h
- Merged PRs (30d)
- 25
Description
## Description of bug / unexpected behavior
In 3D scene, I added a decimal number mobject by `self.add_fixed_in_frame_mobjects()` but the decimal number is still being affected by the camera view. Here is the test code:
```py
class SquareToCircle(ThreeDScene):
def construct(self):
self.move_camera(theta = 30*DEGREES, phi = 70*DEGREES)
tracker = ValueTracker(0)
circle = Circle()
running = DecimalNumber(np.rint(tracker.get_value())).add_updater(lambda v: v.set_value(np.rint(tracker.get_value())))
self.add_fixed_in_frame_mobjects(running, circle)
self.play(tracker.animate.set_value(100))
self.play(Create(circle))
self.wait()
```
## Expected behavior
The decimal number has to be fixed in the frame, just like the circle.
## Additional media files
https://user-images.githubusercontent.com/86940649/128658772-12db6262-9d16-4700-ae13-90b2cb27efd3.mp4
Contributor guide
Research direction
Start with the ThreeDScene.add_fixed_in_frame_mobjects entry point and reproduce the issue using the Python example in the report. Compare how DecimalNumber and Circle are handled after the camera moves, then verify that the decimal number remains fixed in the frame while its updater runs.
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
- 38/100