#version 150

uniform samplerCube fboBuffer;
 
in vec2 vertexTexCoord;

out vec4 outColor1;
 
void main(void)
{
	vec2 cc = (vertexTexCoord*2)-1;

	float c1 = cc.x;
	float c2 = cc.y;
	float c3 = 0.2f;

	float z = texture(fboBuffer, vec3(c3, c1, c2)).r;
	//float z = texture(fboBuffer, vec3(c1, c3, c2)).x;
	//float z = texture(fboBuffer, vec3(c1, c2, c3)).x;
	
	outColor1 = vec4(z, z, z, 1);
}