[osg-users] Volume image crash on the latest version of Nvidia driver

Robert Osfield robert.osfield at gmail.com
Mon Aug 10 23:53:11 PDT 2015


HI Clement,

Good investigation.  This suggested workaround would sure be cleaner than
my approach of toggling between float and int types.  The only problem with
it would be how widely the isnan is supported.  I've done a quick internet
search and haven't come up with a clear answer, it would seem there are
systems that don't support it.

Robert.

On 11 August 2015 at 06:51, <Clement.Chu at csiro.au> wrote:

> Hi Robert,
>
>    Finally, I found out where causes the crash problem.  The problem is
> not related to the type casting.  See the source code below:
>
> float num_iterations = ceil(length((te-t0).xyz)/SampleDensityValue);
>
>
>    The problem is the value of num_iterations is a NaN float value (not a
> number), so that why it makes an infinite running in the loop and then
> crashed.  I think the problem is on the method length().  In some condition
> (different values of t0 and te) makes the method length() to return a NaN
> value.  I added a line of code to check variable num_iterations.
>
>   if (isnan(num_iterations)) num_iterations = 2.0;
>
>
>   So far it works on both nvidia and intel cards.
>
>
>
> Regards,
> Clement
>
>
> ________________________________________
> From: osg-users [osg-users-bounces at lists.openscenegraph.org] on behalf of
> Robert Osfield [robert.osfield at gmail.com]
> Sent: Monday, 10 August 2015 17:42
> To: OpenSceneGraph Users
> Subject: Re: [osg-users] Volume image crash on the latest version of
> Nvidia     driver
>
> Hi Clement,
>
> I have been looking GLSL for what might help us determine when to use
> float vs ints.  The follow info might be useful:
>
>    https://github.com/mattdesl/lwjgl-basics/wiki/GLSL-Versions
>
> Perhaps we should just add a #version 130 (OpenGL Version >= 3.0) to the
> top of the fragment shaders to make sure they support ints.  This may mean
> that the Intel driver fails though.
>
> What Intel hardware, drivers and OpenGL version support by the drivers do
> you have on your system?
>
> Robert.
> _______________________________________________
> osg-users mailing list
> osg-users at lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openscenegraph.org/pipermail/osg-users-openscenegraph.org/attachments/20150811/1f41f195/attachment-0003.htm>


More information about the osg-users mailing list