You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

11 lines
234 B
GLSL

varying vec3 v_cubeMapCoordinates;
uniform samplerCube cubeMap;
void main()
{
vec4 rgbm = textureCube(cubeMap, v_cubeMapCoordinates);
float m = rgbm.a * 16.0;
vec3 r = rgbm.rgb * m;
gl_FragColor = vec4(r * r, 1.0);
}