Bug 27266 - Cubosphere: undefined function 'texture2D' / incompatible types in assignment
Summary: Cubosphere: undefined function 'texture2D' / incompatible types in assignment
Status: RESOLVED FIXED
Alias: None
Product: Mesa
Classification: Unclassified
Component: Mesa core (show other bugs)
Version: git
Hardware: Other All
: medium normal
Assignee: mesa-dev
QA Contact:
URL: http://sourceforge.net/projects/cubos...
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-03-23 10:44 UTC by Sven Arvidsson
Modified: 2010-08-17 10:24 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
distglossbump.frag (1.09 KB, text/plain)
2010-03-23 10:44 UTC, Sven Arvidsson
Details

Description Sven Arvidsson 2010-03-23 10:44:54 UTC
Created attachment 34371 [details]
distglossbump.frag

When the game Cubosphere is run with shaders turned on, the following errors occurs:

 Error: problem compiling shader: Error: undefined function 'texture2D' 
 Error: incompatible types in assignment

It seems to happen in the shader distglossbump.frag, which is attached.

I'm not sure if this is a bug in the shader or not, but it seems to run fine in Windows on ATI hardware.
Comment 1 Brian Paul 2010-03-23 15:15:23 UTC
The problem is this line:

  vec4 base = texture2D(base, uv);

base was previously declared as sampler2D.  We're getting the scoping wrong with the initializer.  Perhaps you could suggest to the game's authors to rename 'vec4 base' to something else.  I won't have time to fix the compiler for a while.
Comment 2 Sven Arvidsson 2010-08-17 10:24:37 UTC
The glsl2 merge seems to have solved this.


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.