Fixed shader program

p4#: 21506
This commit is contained in:
Magne Sjaastad 2013-04-30 15:07:38 +02:00
parent 1db5d3f03d
commit 3ee26b20ea

View File

@ -76,7 +76,7 @@ void main()
if ( a_colorCell < 0.0)
v_cellColor = vec4(0.75, 0.75, 0.75, 1); // Light grayish
else if ( a_colorCell >= 2.0)
v_cellColor = texture2D(u_cellTexture2D, vec2( a_colorCell-2.0f, 0f)); // Opaque, because the y=0 texcoord points to the opaque part of an modified texture
v_cellColor = texture2D(u_cellTexture2D, vec2( a_colorCell-2.0f, 0.0f)); // Opaque, because the y=0 texcoord points to the opaque part of an modified texture
else
v_cellColor = texture2D(u_cellTexture2D, vec2( a_colorCell, 0.5f)); // Default, transparent if the texture is modified