I'll see about turning on the warnings.  I actually haven't gotten the warning 
messages, but stepping through the code I found that it went through the case 
where the warning would come out if we were listening.

I've found out more about the situation.  Someone created the object to be near 
the camera (which is using an orthographic projection, by the way).  However, 
part of it extends toward the camera, and I think goes behind the camera.  This 
doesn't set a new calculated near z, and the object is completely clipped out, 
instead of being partly clipped out.

There are a few ways we could work around this.  I've got to think a bit to 
decide whether OSG should have set some near Z from this, even if it couldn't 
set it to the "near" Z that went behind the camera.

thanks,
andy

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Robert Osfield
Sent: Wednesday, May 21, 2008 12:31 PM
To: OpenSceneGraph Users
Subject: Re: [osg-users] question about warning in CullVisitor.cpp

Hi Andy,

I haven't seen warnings like this for a loooong while... they usually
suggest that some internal computation of the near/far distances for
objects in the scene is in some way messed up.

Is it possible to recreate this warning with osgviewer when loading
one of your models?

Robert.

On Wed, May 21, 2008 at 5:04 PM, Andy Skinner
<[EMAIL PROTECTED]> wrote:
> There is an osg::notify at osg::WARN level in the CullVisitor in
> updateCalculatedNearFar(matrix, drawable, isBillboard).
>
>
>
> There are several, actually, but I'm asking about this one:
>
>     if (d_near<0.0) osg::notify(osg::WARN)<<"        2) sett near with
> d_near="<<d_near<< std::endl;
>
>     else _computed_znear = d_near;
>
>
>
> Is there a specific case represented here, when d_near is negative?  Does
> that mean something specific?
>
>
>
> An in-house customer of our code is trying to put an object at (just in, I
> hope) the near clipping plane, and I think it is this object giving the
> d_near < 0.0.  Is the computed_znear not supposed to be < 0, I'd guess?  I'm
> trying to decide what we're seeing here.
>
>
>
> Thanks,
>
> andy
>
>
>
> _______________________________________________
> osg-users mailing list
> [email protected]
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
>
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to