Commit graph

360 commits

Author SHA1 Message Date
Grant Sanderson
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
Grant Sanderson
e2e785d6c9 Remove init_config.py
It may become a bit unwieldy to make sure this matches the structure of default_config, given the amount of code repetition involved. It seems easier for a user to just create their own custom_config.yml file directly.
2024-12-11 10:50:53 -06:00
Grant Sanderson
fce92347fa Replace get_global_config() with manim_config, and make it an addict Dict 2024-12-11 09:50:17 -06:00
Grant Sanderson
8246d0da5d Fix bug with xelatex rendering 2024-12-11 08:23:17 -06:00
Grant Sanderson
4d7f6093b4 Update how tex configuration default is passed in 2024-12-11 07:18:30 -06:00
Grant Sanderson
0e83c9c0d9
Merge branch 'master' into video-work 2024-12-05 16:50:13 -06:00
Varniex
5d3f730824
Cleaning up some imports + Minor Bug fixed in VectorField (#2253)
* cleaning up imports

* sample_points -> sample_coords
2024-12-05 14:42:46 -08:00
Grant Sanderson
08acfa6f1f Easier use of subdirectories in configuration 2024-12-05 15:52:39 -06:00
Grant Sanderson
75527563de Update where downloads go 2024-12-05 15:27:57 -06:00
Grant Sanderson
71e440be93 Get rid of (no longer used) mobject_data directory reference 2024-12-05 15:08:25 -06:00
Grant Sanderson
8098149006 Remove display_during_execution 2024-12-05 15:05:37 -06:00
Grant Sanderson
85f8456228 If it's worth caching to disk, then might as well do so in memory too during development 2024-12-05 14:56:35 -06:00
Grant Sanderson
3b9ef57b22 Remove utils/customization.py 2024-12-05 11:59:01 -06:00
Grant Sanderson
b593cde317 Make the default size for hash_string an option 2024-12-05 11:53:55 -06:00
Grant Sanderson
34ad61d013 Clean up how configuration is handled
In principle, all we need here is that manim looks to the default_config.yaml file, and updates it based on any local configuration files, whether in the current working directory or as specified by a CLI argument.
2024-12-05 11:53:18 -06:00
Grant Sanderson
cfb7d2fa47 Remove stray prints 2024-12-05 10:09:48 -06:00
Grant Sanderson
43821ab2ba Make caching on disk a decorator, and update implementations for Tex and Text mobjects 2024-12-05 10:09:15 -06:00
Grant Sanderson
89ddfadf6b Allow for a configurable cache location 2024-12-04 20:50:42 -06:00
Grant Sanderson
0c385e820f Get rid of get_tex_dir and get_text_dir 2024-12-04 20:33:43 -06:00
Grant Sanderson
ac01b144e8 Clean up tex_file_writing 2024-12-04 20:30:53 -06:00
Grant Sanderson
129e512b0c Add caching functionality, and have Tex and Text both use it for saved svg strings 2024-12-04 19:51:01 -06:00
Grant Sanderson
ed2f9f3305 Fix import of pyplot 2024-11-25 10:49:05 -07:00
Grant Sanderson
e80b9d0e47 Less collision-prone file names for downloads 2024-11-25 09:31:15 -07:00
Grant Sanderson
64ae1364ca Update the Vector Field interface 2024-11-12 11:21:19 -08:00
Grant Sanderson
0804109301 Flatten uniform arrays 2024-09-21 12:15:37 -04:00
Grant Sanderson
62a4ea5165 Update description of remove_list_redundancies 2024-09-21 12:15:29 -04:00
Grant Sanderson
3e7244b90b Fix bad argument 2024-09-21 12:15:06 -04:00
Grant Sanderson
df9acfb4d5
Merge pull request #2009 from Varniex/patch-1
Correction of indices
2024-09-06 10:59:04 -07:00
Grant Sanderson
6d23df0497 Clean up changes associated with fixing aspect ratio issue 2024-09-06 12:50:19 -05:00
Grant Sanderson
2178ec2b85
Merge branch 'master' into fix-aspect-ratio 2024-09-06 10:24:42 -07:00
Grant Sanderson
a5137a05f1
Merge pull request #2134 from jkjkil4/fix-there_and_back_with_pause
fix: `there_and_back_with_pause`
2024-09-06 09:25:31 -07:00
Grant Sanderson
e7c540f415 Move texture id tracking to ShaderWrapper
Rather than having a globally unique id for each texture, dynamically allocate new texure ids within each ShaderWrapper, so that there is no upper bound on how many textures can be used.
2024-09-06 11:07:38 -05:00
Grant Sanderson
79ec791fc2 Move get_fill_canvas into VShaderWrapper 2024-08-21 09:02:22 -05:00
Grant Sanderson
dfc5f152dd Have border width pre-multiply by alpha, and don't use a separate texture for that border width 2024-08-20 22:03:45 -05:00
Grant Sanderson
5ff80ffc6c Fix matplotlib color map import 2024-08-20 08:54:06 -05:00
Grant Sanderson
6223623b40 Ensure border width blends better within filled VMobject for opacity < 1 2024-08-19 21:39:53 -05:00
Grant Sanderson
7217c9fca5 Reorganize VShaderWrapper.render_fill 2024-08-19 20:51:37 -05:00
Grant Sanderson
3b5d63d2fa Add depth shader to handle winding fill depth test. 2024-08-19 14:09:07 -05:00
Grant Sanderson
4a6e6ca646 Double the size of the fill canvas, to effectively do msaa 2024-08-16 12:04:27 -05:00
Grant Sanderson
c7acbe5de6 Brighten up fill 2024-08-15 10:53:46 -05:00
Grant Sanderson
e130625b9b Handle edge case of single point passed into approx_smooth_quadratic_bezier_handles 2024-08-07 12:12:29 -05:00
jkjkil4
ab28804ae5 fix: there_and_back_with_pause 2024-05-22 16:37:07 +08:00
Grant Sanderson
d3ba101ee5 Change from tracking time_based_updater and non_time_updater lists separately to just tracking one list 2024-03-07 16:39:45 -03:00
Grant Sanderson
83cd5d6246 Clean up updater matters, prune unused functions 2024-03-07 16:07:39 -03:00
Grant Sanderson
4d67361800 Add shuffled 2024-03-07 08:40:19 -03:00
Grant Sanderson
f3571cf2cb Add random import 2024-02-08 14:37:58 -06:00
Grant Sanderson
e4c824e672 Update random_bright_color to operate based on hsl ranges 2024-02-08 14:37:46 -06:00
Grant Sanderson
31b2bcd9e6 Add interpolate_color_by_hsl 2024-02-08 14:37:30 -06:00
Grant Sanderson
41ece958fd Explicitly call out global naure of ID_TO_TEXTURE map 2024-01-17 15:02:19 -06:00
Grant Sanderson
60a4f0e167 Factor out Arc.create_quadratic_bezier_points to quadratic_bezier_points_for_arc 2023-09-04 19:08:13 -04:00