Hi Robert,

USE_EYE_POINT_FOR_LOD_LEVEL_SELECTION seams to not have effect no matter if
it is selected or not. I traced the code and as is written now
IntersectionVisitor::apply(osg::PagedLOD& plod) is working always with the
highest res.

// Perform an intersection test only on children that display
// at the maximum resolution.

I need this functionality to be able to pick on the level of detail based
on the distance from the eyepoint. I am seeing there is a override for that
but it is never used

float IntersectionVisitor::getDistanceToEyePoint(const osg::Vec3& pos, bool
/*withLODScale*/) const
{
    if (_lodSelectionMode==USE_EYE_POINT_FOR_LOD_LEVEL_SELECTION)
    {
        return (pos-getEyePoint()).length();
    }
    else
    {
        return 0.0f;
    }
}

If you are very busy and give some hints I can try to implement this
functionality

Thanks a lot!

-- 
trajce nikolov nick
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to