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

Using Marching.js as the renderer for a js/html website/app? #19

Open
drawtheliner opened this issue Jun 24, 2024 · 1 comment
Open

Comments

@drawtheliner
Copy link

I'd like to use the library as a renderer in web projects, such as websites, apps and games. However I'm not sure how to set this up.

In my js/html projects, I usually have a setup function, and then a function triggered by requestAnimationFrame, which deals with the app/game logic, and updating the scene based on the passage of time and user input.

However in marching.js it seems animation is handled differently. Is it possible to use it for the purposes I described, or is marching.js exclusively meant to be used for live coding?

@charlieroberts
Copy link
Owner

no, that will work fine. take a look at the demo.html file. then make sure you’re using a render preset that supports animation, and you can change whatever you like in your callback.

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

No branches or pull requests

2 participants