105 Commits

Author SHA1 Message Date
fd2a6a69e5 Created a method `remove_all_except()` in scene.py and interactive_scene.py, and made default colors easily configurable. (#2346)
* created a method remove_all_except() in scene.py and interactive_scene.py

* Made it such that default mobject colors can be set through the yaml config file.

* * Default color initialisation wasn't working.
Changed conditional expression to `or` instead.

* Added default values to yaml file.

* added set_background_color() function to Scene class

* Changed default font back to Consolas
2025-06-10 08:15:55 -07:00
dbfe7ac75d Performance improved in set_color_by_rgba_func (#2316)
* removing 1 in neg axis if unit_tex is specified

* performance improved in `set_color_by_rgba_func`

* resolving imag axis number mob in ComplexPlane
2025-03-20 11:56:29 -07:00
744e695340 Misc. clean up (#2269)
* Comment tweak

* Directly print traceback

Since the shell.showtraceback is giving some issues

* Make InteracrtiveSceneEmbed into a class

This way it can keep track of it's internal shell; use of get_ipython has a finicky relationship with reloading.

* Move remaining checkpoint_paste logic into scene_embed.py

This involved making a few context managers for Scene: temp_record, temp_skip, temp_progress_bar, which seem useful in and of themselves.

* Change null key to be the empty string

* Ensure temporary svg paths for Text are deleted

* Remove unused dict_ops.py functions

* Remove break_into_partial_movies from file_writer configuration

* Rewrite guarantee_existence using Path

* Clean up SceneFileWriter

It had a number of vestigial functions no longer used, and some setup that could be made more organized.

* Remove --save_pngs CLI arg (which did nothing)

* Add --subdivide CLI arg

* Remove add_extension_if_not_present

* Remove get_sorted_integer_files

* Have find_file return Path

* Minor clean up

* Clean up num_tex_symbols

* Fix find_file

* Minor cleanup for extract_scene.py

* Add preview_frame_while_skipping option to scene config

* Use shell.showtraceback function

* Move keybindings to config, instead of in-place constants

* Replace DEGREES -> DEG
2024-12-12 08:39:54 -08:00
5a70d67b98 Update coordinate_systems.py (#2258) 2024-12-05 14:49:16 -08:00
64ae1364ca Update the Vector Field interface 2024-11-12 11:21:19 -08:00
bcf610d1ad Merge branch 'master' into patch-8 2024-09-06 11:03:19 -07:00
1ff758dea8 Remove (no longer necessary) specifications of non-flat stroke for 3d things 2024-08-07 15:06:10 -05:00
57d4732ef1 Remove unused lines 2024-07-31 15:23:59 +02:00
2cdb85cae9 Don't assign a fixed default depth to ThreeDAxes 2023-11-06 12:32:47 -05:00
0d046a7eab Add an option for a graph to continually update to its defining function 2023-11-06 12:32:27 -05:00
ddf2f7d9bd Fix typo 2023-08-15 20:36:45 -07:00
2337be2318 Remove num_sampled_graph_points_per_tick in Axes __init__ 2023-08-15 20:36:36 -07:00
ce7422f8af Add ThreeDAxes.get_graph and .get_parametric_surface 2023-06-10 09:21:02 -07:00
16f5890fd3 Add CoordianteSystem.get_area_under_graph
This is not perfect, since one could optionally add a different color for negative area.
2023-06-10 09:20:28 -07:00
392019fc6e Specify type in bind_to_graph 2023-03-10 11:04:49 -08:00
169e7a302b Give ThreeDAxes flat stroke by default 2023-02-08 19:39:37 -08:00
0ce972991b Remove num_axis_pieces arg from ThreeDAxes 2023-02-08 19:39:22 -08:00
ab6a7df4af Use typing_extensions to import Self for python versions <3.11 2023-02-02 10:54:47 -08:00
da6875ca55 Add Self type to coordinate_systems.py 2023-01-31 14:08:22 -08:00
c469c6b009 Prevent NumberPlane from double drawing axes 2023-01-30 20:38:23 -08:00
b85c3bd478 Remove stray import 2023-01-30 11:57:09 -08:00
1c2ec03f7d Replace VMobject.make_approximately_smooth with VMobject.make_smooth(approx=True) 2023-01-19 11:34:13 -08:00
e6abff4299 Speed up bind_graph_to_func 2023-01-19 09:50:24 -08:00
c3cd64f68c Package reflectiveness, gloss and shadow into a single uniform "shading" 2023-01-16 19:33:57 -08:00
33682b7199 MTex is the new Tex, Tex is now OldTex
Global replace
Tex -> OldTex
TexText -> OldTexText
MTex -> Tex
MTexText -> TexText
2022-12-21 13:18:20 -08:00
6d5b980d4a Replace Tex and MTex throughout library 2022-12-20 15:22:34 -08:00
c605ac1c83 Better height, width, unit_size behavior for CoordinateSystems 2022-12-19 20:34:42 -08:00
ba93bd0cbf Replace unit_size with get_unit_size() 2022-12-18 19:52:59 -08:00
3c04ffc513 Better functionality for default axis configuration on coordinate systems 2022-12-18 12:19:26 -08:00
c96cdf43a1 Make sure mutability of dict arguments won't cause problems
One could argue that a pattern of "arg: dict | None = None" followed by "self.param = arg or dict()" is better, but that would make for an inconsistent pattern in cases where the default argument is not None.
2022-12-18 09:38:28 -08:00
97f28b34f3 Distinguish Vect3 from Vect3Array types 2022-12-17 13:16:48 -08:00
dec11a4b17 Rename np_vector type to Vect3 or Vect4 to make context clearer 2022-12-16 20:35:26 -08:00
43fd5e1aea Move custom type to manimlib.typing 2022-12-16 20:19:18 -08:00
c00af3c1bf Rename config_ops -> dict_ops 2022-12-16 18:59:23 -08:00
1a0eff05fa Ensure t_range always has three entries 2022-12-16 15:02:21 -08:00
15f03dae7b Small fixes to Axes configuration 2022-12-16 14:47:56 -08:00
c244f8738f Remove stray import 2022-12-15 18:18:59 -08:00
02143001a4 Move RangeSpecifier to constants 2022-12-15 16:46:42 -08:00
5b5b3a7d20 Kill CONFIG in coordinate_system 2022-12-15 16:19:03 -08:00
958002152e Define ManimColor type in constants 2022-12-14 10:55:32 -08:00
83393abb22 Fix bug deleting i from coordinate labels 2022-11-18 09:10:24 -08:00
90e8a397b8 add_axis_labels for ThreeDAxes 2022-11-18 09:09:21 -08:00
6683c9dbca Add get_graph for 3d surfaces off of ThreeDAxes 2022-11-18 09:09:06 -08:00
004b7427f5 Allow bound graphs to track discontinuities 2022-11-18 09:08:30 -08:00
ce77f38bf1 Add CoordinateSystem.bind_graph_to_func 2022-11-03 11:32:25 -07:00
7c4bb9cbbd Include upper endpoint on graphs 2022-07-19 12:36:24 -07:00
3108b49f55 Update coordinate_systems.py 2022-05-21 15:52:56 +08:00
9ef9961d0e Sort imports 2022-04-12 19:19:59 +08:00
a9349057ad Merge branch 'master' of github.com:3b1b/manim into video-work 2022-03-22 11:30:25 -07:00
f690164087 Merge branch 'master' into master 2022-03-22 11:00:33 -07:00