Bug 10907 - GLSL built-in exp function not functioning correctly
Summary: GLSL built-in exp function not functioning correctly
Status: RESOLVED FIXED
Alias: None
Product: Mesa
Classification: Unclassified
Component: Mesa core (show other bugs)
Version: 6.5
Hardware: All All
: medium major
Assignee: mesa-dev
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-05-10 13:23 UTC by James Burns
Modified: 2007-05-11 09:25 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments

Description James Burns 2007-05-10 13:23:11 UTC
The GLSL exponential function does not generate the correct result.  Symptom - shader working on NV does not perform same on OSMESA.  The following line:

float f = exp(-k*gl_FogFragCoord);

was replaced with:

float f = pow(2.718281828, -k*gl_FogFragCoord);

After making the replacement, the shader performed correctly again.

Test codes have verified this problem.
Comment 1 Brian Paul 2007-05-10 13:50:38 UTC
Fixed in git.  Thanks, Jamie.
Comment 2 James Burns 2007-05-11 09:25:37 UTC
(In reply to comment #1)
> Fixed in git.  Thanks, Jamie.
> 

Tested fix in my application.   All works as expected.  Thanks so much!


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.