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

Freezing browser during render #19

Open
bknill opened this issue Feb 19, 2020 · 7 comments
Open

Freezing browser during render #19

bknill opened this issue Feb 19, 2020 · 7 comments

Comments

@bknill
Copy link

bknill commented Feb 19, 2020

I'm having problems where the browser is freezing during new renders.

Is there a way to pre-render and cache the image?

Ideally we could use web workers to render in a new thread, but they don't support canvas.

EDIT - Seems you can render offscreen.
https://developers.google.com/web/updates/2018/08/offscreen-canvas

I'll see if I can get this working.

@bknill
Copy link
Author

bknill commented Mar 1, 2020

Ran into a bug in Chrome which means this isn't currently possible because of a tainted canvas.

I'm running this in Aframe 1.0.2.

I notice your examples don't freeze the browser during render, not sure what I'm doing differently.

Do you get a freeze in newer versions of Aframe?

@aChanEP
Copy link

aChanEP commented Mar 10, 2020

I am running into this issue as well. I can ultimately get the html rendering within the scene but it takes an awfully long time and freezes browser during a re-render as mentioned above. I am using aframe-react: 4.4.0 to render the aframe markup with aframe: 1.0.4 as well as chrome: 80.0.3987.132.

@bknill
Copy link
Author

bknill commented Mar 11, 2020

@aChanEP yep I had to ditch this because of the freezing. Doesn't seem to be any way around it, especially with dynamically rendered content.

@aChanEP
Copy link

aChanEP commented Mar 13, 2020

@bknill good to know. I did the exact same thing. Thanks!

@michaelthatsit
Copy link

Hey I ran into this problem in react as well. It's because the component reloads every stylesheet on the page when it's initialized. I forked the project, and added StyleSheetId to the schema to, which lets you specify the specific style sheet that should be reloaded. I made a pull request to integrate the changes.

@lmcarreiro
Copy link

Same as #22

@lmcarreiro
Copy link

Is there any workaround?

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

4 participants