2017-10-04 17:37:55 +02:00
|
|
|
#version 450 core
|
|
|
|
|
|
|
|
//! type fragment
|
2017-12-29 11:33:15 +01:00
|
|
|
//! include dof.glsl
|
2017-10-04 17:37:55 +02:00
|
|
|
|
2017-10-01 18:51:02 +02:00
|
|
|
void main()
|
|
|
|
{
|
|
|
|
vec2 uv = gl_FragCoord.xy / uResolution;
|
|
|
|
vec2 blurvec = vec2( 0 , 1 ) / uResolution;
|
|
|
|
|
|
|
|
float z = texture( u_Depth , uv ).x;
|
2017-10-04 18:40:15 +02:00
|
|
|
o_Color = DOF_Blur( z , DOF_CoC( z ) , uv , blurvec );
|
2017-10-01 18:51:02 +02:00
|
|
|
}
|