Triton Intersection - Models not loaded #1909
Unanswered
marcoma9023
asked this question in
Support Q&A
Replies: 1 comment
-
This code is not involved in loading the model. All it does it find the height of the ocean at each point and return that height (and normal vector) in the intersections structure. The "max range" just allows the code to skip intersections are all too far away; this is just a performance optimization. You can set the max range to FLT_MAX to disable this. But again, it has nothing to do with loading the model. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
I'm integrating Triton into OSGEarth and in general everything is fine.
But I'm having the following problem: when the Triton callback passes it calls the addIntersections method on the TritonLayerù+
osg::ref_ptr<osgEarth::Triton::TritonIntersections> isect = new osgEarth::Triton::TritonIntersections; _tritonLayer->addIntersections(isect);
first thing i notice that, as time goes by, the ship models (on which my application is based) are not loaded, but i see as a LOD. In fact, when I approach the model, it is rendered. In the following video it is shown ..
ObwBSE8KoJ.mp4
Let's say this effect can be tolerable.
The real problem is that sometimes, after the application runs for a while, templates don't load anymore.
Seeing the OSGEarth native code related to the intersections I noticed that in the TritonLayer there is a part that generates a kind of LOD for the intersections
`//INTERSECTIONS BETWEEN WAVES AND SHIP
else if (nv.getVisitorType() == nv.CULL_VISITOR && _drawable && _TRITON.valid() && _TRITON->getOcean())
{
in particular the part
if ((eye - anchor).length2() > (m*m)) { continue; }
is it possible that sometimes, if this fails, the model is not loaded?
Thank you
Beta Was this translation helpful? Give feedback.
All reactions