mirror of
https://github.com/scratchfoundation/bgfx.git
synced 2024-11-29 02:55:36 -05:00
17 lines
459 B
Text
17 lines
459 B
Text
uniform sampler2D _CameraDepthTexture;
|
|
uniform vec4 _ZBufferParams;
|
|
void main ()
|
|
{
|
|
gl_FragData[0] = vec4((1.0 - (1.0/((
|
|
(_ZBufferParams.x * texture2D (_CameraDepthTexture, gl_TexCoord[0].xy).x)
|
|
+ _ZBufferParams.y)))));
|
|
}
|
|
|
|
|
|
// stats: 4 alu 1 tex 0 flow
|
|
// inputs: 1
|
|
// #0: gl_TexCoord (high float) 4x1 [1] loc 4
|
|
// uniforms: 1 (total size: 0)
|
|
// #0: _ZBufferParams (high float) 4x1 [-1]
|
|
// textures: 1
|
|
// #0: _CameraDepthTexture (high 2d) 0x0 [-1]
|