Comments (2)
Hi @coherit,
what you propose is certainly interesting (even though this kind of feature concern mostly PLY models, since usually the raw version of the Nexus geometries is soon visualized in 3DHOP), but unfortunately, at the moment, 3DHOP does not provide this kind of feature.
The main reason is that we suggest to rely on PLY geometries just for small models (so, with short loading times), and to convert in the Nexus format the bigger ones (we discussed a lot instead, and still are discussing, about the opportunity to integrate into 3DHOP a feature enabling a visual feedback for the loading of this last kind of models, that is not an easy task, since the amount of data loaded and to load continuously change depending on the camera position).
However, this does not prevent you to add to 3DHOP a custom component (like for instance, a loading bar) for providing visual feedback on data loading.
To build your own loading bar for PLY models is not too difficult: you just need to add a few code lines to "present.js", exploiting the "onprogress" event handler related to the "XMLHttpRequest" binary request. After doing that, you can add an HTML bar element linked to the data coming from this event handler.
You can find the PLY binary request at line 2909 of "presenter.js" (3DHOP 4.2 master version).
And this is an example of the original function with the "onprogress" event handler added:
sglRequestBinary(mesh.url, {
onSuccess : (function(m){ return function (req) { that._onPlyLoaded(req, m, gl); }; })(mesh),
onProgress : (function(loaded,total,evt){
console.log(evt.url+" loaded: "+loaded+" of "+total);
if (loaded==total) console.log("Model "+ evt.url +" ready!");
})
});
With this change, you can have feedback on the amount of data loaded in the console for browser developers.
If you want a running example of that, take a look at the FCGL 3D data repository.
Hope this can help! :)
from 3dhop.
This is very helpful -- thanks for such a thorough reply! I'll give the loading bar a shot, and we'll reconsider converting to Nexus format again.
from 3dhop.
Related Issues (20)
- Touch control HOT 2
- Modifying Touch Sensitivity HOT 3
- Deformed model when changing trackball position [trackballs paradigm] HOT 3
- Resizing after full screen view in Firefox not working properly HOT 5
- keyboard input disabled HOT 2
- bump/normal etc HOT 1
- loading many nxs files [dynamic scene declaration] HOT 13
- Objects have limited rotation angle in certain axes (usually Y and Z) [trackballs setup] HOT 2
- Implementing 3DHOP in Rails HOT 5
- Implementing 3DHOP in Drupal HOT 3
- Setting tabindex on canvas messes with focus in Firefox HOT 2
- jQuery no-conflict mode + docker + implementing 3DHOP in Clowder HOT 51
- Allow configurable selectors HOT 1
- Data/LODs stop loading in (after using viewer for a few minutes) [nexus setup] HOT 3
- [Feature requests] Screenshot resolution multiplier; rotate plane section tool HOT 3
- Textured objects are not displayed on iOS HOT 1
- Trackballs dragging speed option HOT 3
- Input data for "animateToTrackballPosition"
- Best Tools for Rendering Very Large Meshes with Millions of Vertices/Faces in Browser
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from 3dhop.