File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed
worldwind/src/main/res/raw Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change 55
66#ifdef GL_FRAGMENT_PRECISION_HIGH
77precision highp float ;
8+ uniform highp sampler2D depthSampler;
89#else
910precision mediump float ;
11+ uniform mediump sampler2D depthSampler;
1012#endif
1113
1214uniform float range;
1315uniform vec4 color[2 ];
14- uniform sampler2D depthSampler;
1516
1617varying vec4 sightlinePosition;
1718varying float sightlineDistance;
@@ -32,7 +33,7 @@ void main() {
3233 /* Compute a mask that's on when the object's depth is less than the sightline's depth. The depth texture contains
3334 the scene's minimum depth at each position, from the sightline's point of view. */
3435 vec3 sightlineCoord = clipCoord * 0.5 + 0.5 ;
35- float sightlineDepth = texture2D (depthSampler, sightlineCoord.xy).z ;
36+ float sightlineDepth = texture2D (depthSampler, sightlineCoord.xy).r ;
3637 float occludeMask = step (sightlineDepth, sightlineCoord.z);
3738
3839 /* Modulate the RGBA color with the computed masks to display fragments according to the sightline's configuration. */
You can’t perform that action at this time.
0 commit comments