-
Hey so this might be a dumb question, but in the documentation, all examples are always within one Scene/Class. What if I want to split my presentation up into multiple classes, with each one being a new slide? How do I transition between them, and is this intended? Because otherwise I'd have really long scenes to render which takes up too much time. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
Hi @amstrdm, good question! This is actually a common question people have with Manim itself. If you don't mind having distinct classes for different parts of your video, you can always: manim-slides render file.py ClassA ClassB ClassC...
# Then
manim-slides present ClassA ClassB ClassC...
# Or, e.g.
manim-slides convert ClassA ClassB ClassC... out.html As long as all classes have the same width and height, this should work just fine (Manim Slides will automatically concatenate the scenes in one of the two last commands). If you need to share some information between all slides (like a slide number that increases for each slide), then I recommend splitting your code into multiple methods, and only put the ones you want to render in It is possible to concatenate multiple classes into one, e.g., with subclasses, but you must ensure that they have the same type of camera (e.g., you cannot mix 2D and 3D classes), and the resulting code isn't any better than going for separate methods (in my opinion). Let me know if that helped! |
Beta Was this translation helpful? Give feedback.
-
Great thanks a lot! I actually stumbled upon your blog post right after putting the question up so I saw the tip about using multiple methods! I do have another question though. I am aware that it is possible to loop the next slides animation so it goes on until you go over to another slide. Is it possible to somehow loop a certain animation up to a given point? So I want a certain animation to keep lopping up until a specific slide comes up. |
Beta Was this translation helpful? Give feedback.
Hi @amstrdm, good question!
This is actually a common question people have with Manim itself.
If you don't mind having distinct classes for different parts of your video, you can always:
As long as all classes have the same width and height, this should work just fine (Manim Slides will automatically concatenate the scenes in one of the two last commands).
If you need to share some information between all slides (like a slide number that increases for each slide), then I recommend splitting your code into multiple methods,…