pauloday / quasicrystals Goto Github PK
View Code? Open in Web Editor NEWA program to animate quasicrystals on a 2d plane
A program to animate quasicrystals on a 2d plane
Have this output gifs or videos directly. For gifs rust-image has support, but for videos I'm probably going to have to use some kind of ffmpeg interface.
There are some more ways to colorize it I could investigate. Right now it uses a sawtooth wave, I could look at other waveforms. Or I could adjust the phase spacing to make the colors different as well.
This is kind of reliant/part of #2, but there's a blog article this was based on, I should add that. Also add some examples, I've got some really cool colorizations now.
Use multithreading to speed it up!
Some of the params could change over time. I'm thinking the initial batch will be scale, x/y offset and order. Order might look weird but I think that's fine. I wish there was a way to do fractions of an order. Maybe adjusting the angle from being evenly spaced over the course of the animation?
There needs to be a good commandline interface, so I can pick
This thing is real slow. It does a bunch of different sin/cos/asin operations for each pixel of each frame. Speed it up!
Possible optimziations:
Overall I'm going to try memozing since it's trivial, then a lookup table and compare. The concurrency can wait.
For the Rust rewrite, I need to have good unit tests, and good benchmark tests.
The benchmark tests are most important, #2 needs to be done so I can script them.
This is related to #10, but the code should be split up
After some thought, I've come to the conclusion that it'll probably be more trouble than it's worth. The expressive power of Clojure is nice but doesn't bring much to the table here, since the program is basically just "do math -> place pixel". There is a lot of stuff that makes that process slower though.
I think I could make this a lot more efficient in Clojure, but ultimately I think my effort would be better spent looking at a lower level (i.e. faster) language. Rust is one I've heard great things about, both speed and design wise, so I've wanted to learn it for a while. This project is relatively simple, but it does have some complexity, and it's got plenty of room to really learn about Rust and the features that make it so great.
So yeah, this codebase is moving to Rust.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.