Skip to content

Commit 2058d1b

Browse files
committed
Fix point primitives behind the camera appearing in front of it.
1 parent 6063c95 commit 2058d1b

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

Source/Shaders/PointPrimitiveCollectionVS.glsl

+2-6
Original file line numberDiff line numberDiff line change
@@ -140,12 +140,8 @@ void main()
140140
}
141141
#endif
142142

143-
#ifdef LOG_DEPTH
144-
czm_vertexLogDepth(czm_projection * positionEC);
145-
#endif
146-
147-
vec4 positionWC = czm_eyeToWindowCoordinates(positionEC);
148-
gl_Position = czm_viewportOrthographic * vec4(positionWC.xy, -positionWC.z, 1.0);
143+
gl_Position = czm_projection * positionEC;
144+
czm_vertexLogDepth();
149145

150146
#ifdef DISABLE_DEPTH_DISTANCE
151147
float disableDepthTestDistance = distanceDisplayConditionAndDisableDepth.z;

0 commit comments

Comments
 (0)