{"id":26010565,"url":"https://github.com/jdonszelmann/csanim","last_synced_at":"2025-08-25T08:16:32.531Z","repository":{"id":114826325,"uuid":"139448984","full_name":"jdonszelmann/csanim","owner":"jdonszelmann","description":"it's like manim but for computer science! ","archived":false,"fork":false,"pushed_at":"2018-07-04T11:39:44.000Z","size":399,"stargazers_count":3,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-08-18T05:39:20.702Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jdonszelmann.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-07-02T13:41:06.000Z","updated_at":"2022-08-04T00:43:31.000Z","dependencies_parsed_at":null,"dependency_job_id":"4083a2f1-cdde-43f2-bcbd-d5758b279ff8","html_url":"https://github.com/jdonszelmann/csanim","commit_stats":null,"previous_names":["jdonszelmann/csanim"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/jdonszelmann/csanim","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jdonszelmann%2Fcsanim","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jdonszelmann%2Fcsanim/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jdonszelmann%2Fcsanim/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jdonszelmann%2Fcsanim/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jdonszelmann","download_url":"https://codeload.github.com/jdonszelmann/csanim/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jdonszelmann%2Fcsanim/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":272031341,"owners_count":24861686,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-25T02:00:12.092Z","response_time":1107,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-03-05T22:51:17.000Z","updated_at":"2025-08-25T08:16:32.476Z","avatar_url":"https://github.com/jdonszelmann.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n# CSanim\n\nIt's like manim (the program Grant uses for his channel 3blue1brown) but for computer science! special thanks to Grant Sanderson (3blue1brown, https://github.com/3b1b/manim)\n\n\nCsanim generates videos. Many test videos can be found on our youtube channel [thekeychain](https://www.youtube.com/channel/UCUvhgZVZjBGB5NvLH_M-n9g)\n\n\n## installation:\n\nTo install csanim, clone this repository, and run the install.sh script. (commands below) \nThis script is only tested for Ubuntu.\nTo install csanim on other systems install the following packages:\n\n- ffmpeg\n- python3\n- pyhon3-pip\n- python3-opengl (or use pip3 install pyopengl)\n- dvipng\n- texlive\n- texlive-latex-extra\n\ninstallation commands: (Ubuntu): \n```bash\ngit clone https://github.com/jonay2000/csanim\ncd csanim\n./install.sh\n```\n\n## usage:\n\nTo start, import csanim with \n```python\nfrom csanim import *\n```\n\nAfter this import, you can start a new video by creating a frame manager:\n\n```python\n#FrameManager(fps,width,height,name)\nf = FrameManager(60,1920,1080,\"video.mp4\") #1080p 60fps\nf.set_background(Color(0, 0, 0))\n```\n\nNow you can start defining points in the video at which some change to the seen will happen.\nThis can be done with the @f.second() or @f.frame() decorator.\n\nf.second(sec) will take 1 argument defining on which second the function must be called (this can be a float)\nf.frame(frame)  will take 1 argument defining on which frame the function must be called (this must be an integer)\n\nexample:\n```python\n@f.second(1)\t\ndef second1(manager):\n\n\tmanager.draw(LatexText(120, #visible for 120 frames (2 seconds on 60fps)\n\t\tColor(255,255,255),\t\t#color: white\n\t\t100,100,#x,y \t\t\t#draw on (100,100)\n\t\t1.5,#scale\t\t\t\t#scale up by 50%\n\t\tr'\\int_0^1 e^x\\,dx' \t#latex string (integral from 0 to 1 of e^x dx)\n\t\t))\n\n```\nnow you can start rendering this video by calling the run() method of thye framemanager:\n\n```python\nf.run(2*60) #run takes 1 argument specifying how many frames should be rendered. Since the video is on 60 fps\n#it should run 120 frames for 2 seconds. After the first second the Latex text will be visible\n```\n\nthis last action may take some time, depending on the complexity of the scene. There are currently NO optimizations so slow might mean very slow\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjdonszelmann%2Fcsanim","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjdonszelmann%2Fcsanim","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjdonszelmann%2Fcsanim/lists"}