Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Functional animation #20

Open
wants to merge 7 commits into
base: main
Choose a base branch
from
Open

Functional animation #20

wants to merge 7 commits into from

Conversation

qt1
Copy link

@qt1 qt1 commented Dec 27, 2020

Calculation of pixel color calculated by a function that accepts 4d space+time coordinates of current LED and current time.

Animation is stateless - no state is kept between calls to the animation function or between animation loops. Animation rate and form are determined only by the color function.
The color functions also uses parameters extensively so many aspects of the animation can be set without re-writing the math.

Several samples are provided, starting from a simple blink to a few more complex ones.

Visualization using matplotlib - many thanks to @DutChen18 ! #5

Intended to fix #18

@qt1
Copy link
Author

qt1 commented Dec 27, 2020

Now supports gravitational time dilation.
Example shows how a simple blink changes when the clock runs at different rates depending on height.

Also, running with "--sim" will activate simulation. Otherwise should light the actual tree.

@qt1 qt1 changed the title Funtional animation Functional animation Dec 31, 2020
some more transformations and examples
@oliverdunk
Copy link
Member

Hey @qt1! As mentioned - love the addition of a much needed extra dimension (and some gravitational time dilation too 👀 ).

I've decided to create an examples folder where we can add contributions like this one - you can find some more information in the README.

Would you be up for updating your PR, to move your effect sequence in to a single file in the examples folder? If you want to share some of the extra work, linking to your repository in the "Further Work" section of this repo's README may be a good option.

@dylanmtaylor
Copy link

This is super cool

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Code not functional
4 participants