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

Large stl doesn't display #110

Open
mrweix opened this issue Mar 30, 2016 · 8 comments
Open

Large stl doesn't display #110

mrweix opened this issue Mar 30, 2016 · 8 comments

Comments

@mrweix
Copy link

mrweix commented Mar 30, 2016

Loading a 112 MB stl file is not displayed in the viewer all though in the console it says it finished loading and rendering (in 4000 ms). Is there a file size limit ? Any other idea how to display such large files?

@mrweix
Copy link
Author

mrweix commented Mar 31, 2016

interestingly this issue only occurs on Mac OS (with Firefox 45, Chrome 49, Safari 9.1). In windows on Firefox 45 also larger stl files (112 MB, 185 MB) are displayed and rendered.

@cignoni
Copy link
Member

cignoni commented Mar 31, 2016

The problem is that some browsers put some hard limits to the memory that a javascript process can allocate. It is something that varies a lot between different OS and browsers (some recent versions of chrome for example under win10 cap js memory to less than 1gb)
In future version we will allow different memory choices at startup.

@mrweix
Copy link
Author

mrweix commented Mar 31, 2016

Whats the browser and OS for the best experience in your experience? Do you know of a way how to change this values in some settings or is this hardcoded by the browser per OS?

@mrweix
Copy link
Author

mrweix commented Apr 5, 2016

I have also noticed that whenever I start the browser new it will load also larger objects. But then loading some larger stl files in a row will after some time lead to a memory error even when I delete each layer and make a browser "garbage collect". Is there some sort of webgl reset call that one could integrate when deleting all layers that could reset to the state when the browser is started?

@mrweix
Copy link
Author

mrweix commented Apr 6, 2016

Which files would be affected by compilation with -s ALLOW_MEMORY_GROWTH=1 . Only generated/MeshLabCppCore.js ? Is there a branch with such a file somewhere available?

@cignoni
Copy link
Member

cignoni commented Apr 6, 2016

when -s ALLOW_MEMORY_GROWTH=1 is enabled the tool become a lot slower. No branch for it up to now, but it is an easy change to be tested: just change line 17 of MakefileJS ( https://github.com/cnr-isti-vclab/meshlabjs/blob/master/sources/MakefileJS ) and recompile the cpp files. No other changes needed to have dynamic memory growth...

@mrweix
Copy link
Author

mrweix commented Apr 6, 2016

Thanks for the feedback! How to recompile the cpp files? Just calling MakefileJS?

@cignoni
Copy link
Member

cignoni commented Apr 6, 2016

yes it is a standard makefile. Assuming you have the emscripten environement all setup (and on windows you have installed also the mingw32 package through emskd) just type
make -f MakefileJS from a command line in the meshlabjs/sources folder.

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