Welcome to mirror list, hosted at ThFree Co, Russian Federation.

depth_2d_update_int32_frag.glsl « kernels « metal « gpu « blender « source - git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 15271ab2cddcbd3853a9d70450cce81edfae231d (plain)
1
2
3
4
5
6
7
8
9
10
11
12

uniform isampler2D source_data;
uniform int mip;

in vec2 texCoord_interp;

void main()
{
  uint val = textureLod(source_data, texCoord_interp, mip).r;
  uint depth = (val) & (0xFFFFFFFFu);
  gl_FragDepth = float(depth) / float(0xFFFFFFFFu);
}