You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I love Papaya - its by far the best MRI viewer my lab has experimented with. Out of curiositiy, is it possible to close the current image and load a new one entirely through Javascript, or must a new page be navigated to with the neccessary params block defined?
Ive managed to reverse engineer a number of features into Mango, namely moving the cursor around, but this last issue still troubles me as it seems as if the constructor methods are no longer present once the viewer loads.
Thanks!
The text was updated successfully, but these errors were encountered:
See the below snippet. Edit tests/debug_server.html with the below to run the example. It loads an image, then after 5 seconds closes it and load a new image (I use the atlas image just as an example since it's already part of the project).
I think there's lots to do to make a cleaner API for Papaya. Eventually I'll get around to that along with more documentation...
<scripttype="text/javascript">
/* DO NOT EDIT (start) -- papayaLoadableImages is generated by papaya-builder and is here for debugging purposes only */
var papayaLoadableImages = [
{nicename: "Sample Image",name: "sample_image",url: "../data/sample_image.nii.gz"},
{nicename: "Atlas",name:"Talairach_labels_1mm",url: "../data/Talairach_labels_1mm.nii.gz",hide:true}
];
/* DO NOT EDIT (end) */
var params = [];
params["images"] = ["../data/sample_image.nii.gz"];
params["atlas"] = ["Talairach_labels_1mm"];
setTimeout(function() {papayaContainers[0].viewer.resetViewer();papayaContainers[0].toolbar.updateImageButtons();papayaContainers[0].viewer.loadImage(["../data/Talairach_labels_1mm.nii.gz"],true)}, 5000);
</script>
I love Papaya - its by far the best MRI viewer my lab has experimented with. Out of curiositiy, is it possible to close the current image and load a new one entirely through Javascript, or must a new page be navigated to with the neccessary params block defined?
Ive managed to reverse engineer a number of features into Mango, namely moving the cursor around, but this last issue still troubles me as it seems as if the constructor methods are no longer present once the viewer loads.
Thanks!
The text was updated successfully, but these errors were encountered: