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

Cannot create new shapes inside animate function #67

Open
charlesr1971 opened this issue Jun 10, 2019 · 1 comment
Open

Cannot create new shapes inside animate function #67

charlesr1971 opened this issue Jun 10, 2019 · 1 comment

Comments

@charlesr1971
Copy link

When I try and create a new shape inside:

var shapes = [];

function animate(){
push.shapes(new Zdog.Shape({...}));
illo.updateRenderGraph();
window.requestAnimationFrame(animate);
}

Although the array gets populated, the new shapes do not get rendered to the screen.

I am not sure whether this is a bug or a constraint of 'requestAnimationFrame'?

@desandro
Copy link
Member

I'm sorry to see you're having trouble with Zdog. Could you provide a reduced test case? See Submitting Issues in the contributing guidelines.

@desandro desandro changed the title ISSUE: cannot create new shapes inside animate function Cannot create new shapes inside animate function Jun 11, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants