void main()
{
- vec4 itexel = textureCube(dstex, normalize(world_normal));
+ vec4 itexel = texture(dstex, normalize(world_normal));
float dist = -pos.z;
float fog = clamp(exp(-s.fog_density * dist), 0.0, 1.0);
- vec4 texel = texture2D(tex, tex_coord);
+ vec4 texel = texture(tex, tex_coord);
// vec3 object_color = (diffuse.xyz * cdiff * texel.xyz + specular.xyz * cspec) * itexel.xyz;
vec3 object_color = s.diffuse.xyz * texel.xyz * itexel.xyz;