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

Robert Osfield robert.osfield at gmail.com
Mon Aug 17 00:06:16 PDT 2015


HI Clement,

Curious... but what I don't understand is how the Intel compiler was
progressing on to the if (num_iteration!=num_iterators) as this should only
be run on NVidia cards thank to the #idef NVIDIA_Corportion guard around it,

Are you backporting the shaders to 3,2,x?

Robert.

On 17 August 2015 at 07:33, <Clement.Chu at csiro.au> wrote:

> Hi Robert,
>
>    I got funny volume display problem on intel card (it lost some opacity
> values).  I checked the shader code and I found the problem on handling NaN
> with using if statement.
>
> Your code is :
>
>                      "    if (num_iterations<min_iterations)
> num_iterations = min_iterations;\n"
>                      "    else if (num_iterations>max_iterations)
> num_iterations = max_iterations;\n"
>                      "    else if (num_iterations!=num_iterations)
> num_iterations = max_iterations;\n"
>
>
>    I checked NaN on wiki https://en.wikipedia.org/wiki/NaN.  The
> non-signaling value won't do standard comparison, so I changed the code as
> below.
>
>                      "    if (num_iterations!=num_iterations)
> num_iterations = max_iterations;\n"
>                      "    else if (num_iterations<min_iterations)
> num_iterations = min_iterations;\n"
>                      "    else if (num_iterations>max_iterations)
> num_iterations = max_iterations;\n"
>
>   Check the value whether it is NaN on first condition and it works as
> normal on intel card now.
>
>
>
> Regards,
> Clement
>
>
> ________________________________________
> From: osg-users [osg-users-bounces at lists.openscenegraph.org] on behalf of
> Robert Osfield [robert.osfield at gmail.com]
> Sent: Wednesday, 12 August 2015 23:58
> To: OpenSceneGraph Users
> Subject: Re: [osg-users] Volume image crash on the latest version of
> Nvidia     driver
>
> On 12 August 2015 at 14:47, <Clement.Chu at csiro.au<mailto:
> Clement.Chu at csiro.au>> wrote:
> Hi Robert,
>
>   I have tested on both Intel and Nvidia machines.  The solution works
> without any issue.  Thanks.
>
> I have applied this fix to OSG-svn/trunk, OSG-3.2.3 and OSG-3.4.0 so we
> should now be good to go.
>
> 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/20150817/1e9adcaa/attachment-0003.htm>


More information about the osg-users mailing list