Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

If you like this, also check out the Haskell reanimate[1] library. It's a library for animated diagrams inspired by Manim but with a different API design and feature set.

Here's a snippet to trace out a rotating rectangle:

    do s <- fork $ newSpriteA drawBox
       v <- spriteVar s 0 rotate
       tweenVar v 2 $ \val -> fromToS val 90
The API docs[2] have a bunch of small examples like this illustrated with inline gifs, which I think is a great touch.

[1]: https://github.com/reanimate/reanimate

[2]: https://hackage.haskell.org/package/reanimate-1.1.2.1/docs/R...



It’s too bad the gifs seem to be just file references instead of real-time animations. Looks like some of the code snippets do not match their animations.

For example, parLoopA and parDropA seem to have the same sample code, but have different animations.


Good catch. Fixed in HEAD.


Thank you for the library tip!




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: