@xeokit/xeokit-sdk 2.2.1-beta.2 → 2.2.1-beta.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -13611,6 +13611,7 @@ class OcclusionLayer {
13611
13611
 
13612
13612
  const MARKER_COLOR = math.vec3([1.0, 0.0, 0.0]);
13613
13613
  const POINT_SIZE = 20;
13614
+ const MARKER_SPRITE_CLIPZ_OFFSET = -0.01; // Amount that we offset sprite clip Z coords to raise them from surfaces
13614
13615
 
13615
13616
  const tempVec3a$$ = math.vec3();
13616
13617
 
@@ -13820,7 +13821,6 @@ class OcclusionTester {
13820
13821
  src.push(" vWorldPosition = worldPosition;");
13821
13822
  }
13822
13823
  src.push(" vec4 clipPos = projMatrix * viewPosition;");
13823
- src.push(" gl_Position = clipPos;");
13824
13824
  src.push(" gl_PointSize = " + POINT_SIZE + ".0;");
13825
13825
  if (scene.logarithmicDepthBufferEnabled) {
13826
13826
  if (WEBGL_INFO$1.SUPPORTED_EXTENSIONS["EXT_frag_depth"]) {
@@ -13829,7 +13829,10 @@ class OcclusionTester {
13829
13829
  src.push("clipPos.z = log2( max( 1e-6, clipPos.w + 1.0 ) ) * logDepthBufFC - 1.0;");
13830
13830
  src.push("clipPos.z *= clipPos.w;");
13831
13831
  }
13832
+ } else {
13833
+ src.push("clipPos.z -= " + MARKER_SPRITE_CLIPZ_OFFSET + ";");
13832
13834
  }
13835
+ src.push(" gl_Position = clipPos;");
13833
13836
  src.push("}");
13834
13837
  return src;
13835
13838
  }
@@ -13607,6 +13607,7 @@ class OcclusionLayer {
13607
13607
 
13608
13608
  const MARKER_COLOR = math.vec3([1.0, 0.0, 0.0]);
13609
13609
  const POINT_SIZE = 20;
13610
+ const MARKER_SPRITE_CLIPZ_OFFSET = -0.01; // Amount that we offset sprite clip Z coords to raise them from surfaces
13610
13611
 
13611
13612
  const tempVec3a$$ = math.vec3();
13612
13613
 
@@ -13816,7 +13817,6 @@ class OcclusionTester {
13816
13817
  src.push(" vWorldPosition = worldPosition;");
13817
13818
  }
13818
13819
  src.push(" vec4 clipPos = projMatrix * viewPosition;");
13819
- src.push(" gl_Position = clipPos;");
13820
13820
  src.push(" gl_PointSize = " + POINT_SIZE + ".0;");
13821
13821
  if (scene.logarithmicDepthBufferEnabled) {
13822
13822
  if (WEBGL_INFO$1.SUPPORTED_EXTENSIONS["EXT_frag_depth"]) {
@@ -13825,7 +13825,10 @@ class OcclusionTester {
13825
13825
  src.push("clipPos.z = log2( max( 1e-6, clipPos.w + 1.0 ) ) * logDepthBufFC - 1.0;");
13826
13826
  src.push("clipPos.z *= clipPos.w;");
13827
13827
  }
13828
+ } else {
13829
+ src.push("clipPos.z -= " + MARKER_SPRITE_CLIPZ_OFFSET + ";");
13828
13830
  }
13831
+ src.push(" gl_Position = clipPos;");
13829
13832
  src.push("}");
13830
13833
  return src;
13831
13834
  }