-
Notifications
You must be signed in to change notification settings - Fork 168
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
Unloading files #41
Comments
stage.loadFile( "path" ).then( function( comp ){
stage.removeComponent( comp ); // this removes the just loaded component
}
This should not happen, loading and displaying many structures is generally supported. Depending on how you load them a crash might be caused by the creation of too many WebWorkers. So, limit the number of files loaded in parallel or load them sequentially altogether. Here is how do it for the GUI using the async.js library: async.eachLimit(
e.dataTransfer.files,
4,
function( file, callback ){
stage.loadFile( file, {
defaultRepresentation: true
} ).then( function(){ callback(); } );
}
); I happily consider handling that in the stage object. Would you mind opening a separate issue for it, so that we don't mix topics so much. Thanks! |
@BernierCR any news on this? |
Sorry, no news. I've been focused on my job hunt and other such things. On Fri, Feb 12, 2016 at 12:56 AM, Alexander Rose notifications@github.com
|
Good luck! There is https://experiment.com/, haven't tried it though. |
I'm not sure the best way to unload a file. I only need one mmCIF file loaded at a time, at least in the near future. What code do I run as soon as I know I'm going to need a different file?
Also, when I accidentally loaded a second structure, WebGL crashed. I'm not sure if that is a bug or not. It may just be that my computer ran out of memory when trying to do that. I may experiment with loading multiple large structures another time and test the limits.
The text was updated successfully, but these errors were encountered: