ManimCommunity / ManimCommunity/manim
ValueTracker: turn value into a property, replace get_value / set_value
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 40.9k
- Forks
- 3.1k
- Avg merge
- 3d 12h
- Merged PRs (30d)
- 25
Description
ValueTracker needs a refactor.
Quoting @leotrs :
there's many other things left to do. For example, get_value and set_value should all go away in favor of a property. And increment_value should be changed to also make use of that property, such that the code self.play(tracker.increment_value, 4.0) doesn't break.
AND THEN, there's the question of whether we even want self.play(tracker.increment_value, 4.0) to continue working at all. It's always been a mystery to me why sometimes you need
ApplyMethodand not at other times.
In a nutshell :
- getting rid of
get_valueandset_valuein favor of a property; - Changing
increment_value, maybe getting rid of it as we have now += operator for ValueTracker - ?
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating ValueTracker and all references to get_value, set_value, and increment_value. Read the surrounding animation usage, including self.play(tracker.increment_value, 4.0), and resolve whether that API should remain. Done means the property-based design and increment behavior are decided and all affected references are consistently updated.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- computer-graphics
- Issue type
- Refactor
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100