supermedium / aframe-react

:atom: Build virtual reality experiences with A-Frame and React.
https://ngokevin.github.io/aframe-react-boilerplate/
MIT License
1.42k stars 151 forks source link

Aframe using lots of memory. #83

Closed itsakt closed 7 years ago

itsakt commented 7 years ago

CODE: https://github.com/itsakt/aframe-react-test

App.js

Memory Usage This sample code contains five 360 degree images. ( ~600KB - ~1.8MB, 8192x4096 )

Initial memory usage: Google Chrome chrome initial

Firefox Developer Edition ff initial

After switching through five images Google Chrome chrome after five

Firefox Developer Edition ff after five

My actual project has 24 images

After switching through 24 images Google Chrome after 20 images (chrome tab crashed after that) chrome after 24

Firefox Developer Edition after 24 images. ff after 24

EDIT: Memory usage also increases if I reload the page.

ngokevin commented 7 years ago

https://github.com/aframevr/aframe/issues/2166

http://stackoverflow.com/questions/42427327/how-to-deallocate-texture-from-memory-in-a-frame

cvan commented 7 years ago

@ngokevin you cool with me adding a link to the StackOverflow answer (and/or this issue) to https://aframe.io/docs/0.5.0/introduction/best-practices.html#performance (and/or the FAQ)?

ngokevin commented 7 years ago

Was fixed recently https://github.com/aframevr/aframe/pull/2686

cvan commented 7 years ago

awesome, thanks 👍