Bug 17079 - glGetUniformLocation doesn't work for sampler types
Summary: glGetUniformLocation doesn't work for sampler types
Status: RESOLVED FIXED
Alias: None
Product: Mesa
Classification: Unclassified
Component: Mesa core (show other bugs)
Version: git
Hardware: All All
: medium normal
Assignee: mesa-dev
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-08-11 09:34 UTC by Neil Roberts
Modified: 2009-08-24 12:30 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
Add sampler types to sizeof_glsl_type (594 bytes, patch)
2008-08-11 09:34 UTC, Neil Roberts
Details | Splinter Review
Test case (1.79 KB, text/x-csrc)
2008-08-11 09:37 UTC, Neil Roberts
Details

Description Neil Roberts 2008-08-11 09:34:49 UTC
Created attachment 18220 [details] [review]
Add sampler types to sizeof_glsl_type

If you use glGetUniformLocation on a sampler type uniform then you get a warning about an invalid type. It calls a function called sizeof_glsl_type which seems to be missing handlers for the sampler types. In older git revisions this function would return zero and you would get a floating point exception.
Comment 1 Neil Roberts 2008-08-11 09:37:56 UTC
Created attachment 18221 [details]
Test case

Test case calling glGetUniformLocation on a sampler2D uniform. Under Mesa 7.0.3 it causes a floating point exception but under git master it just prints a warning.
Comment 2 Brian Paul 2008-08-11 14:11:56 UTC
Fixed in git.  Thanks.
Comment 3 Adam Jackson 2009-08-24 12:30:47 UTC
Mass version move, cvs -> git


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.