@xeokit/xeokit-sdk 2.6.90-renderers-refactor-v6 → 2.6.90-renderers-refactor-v7

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xeokit/xeokit-sdk",
3
- "version": "2.6.90-renderers-refactor-v6",
3
+ "version": "2.6.90-renderers-refactor-v7",
4
4
  "description": "3D BIM IFC Viewer SDK for AEC engineering applications. Open Source JavaScript Toolkit based on pure WebGL for top performance, real-world coordinates and full double precision",
5
5
  "module": "./dist/xeokit-sdk.es.js",
6
6
  "main": "./dist/xeokit-sdk.cjs.js",
@@ -193,7 +193,7 @@ export const getRenderers = (function() {
193
193
 
194
194
  const afterFlagsColorLines = [
195
195
  `if (${flagTest}) {`,
196
- " gl_Position = vec4(0.0, 0.0, 0.0, 0.0);", // Cull vertex
196
+ ` gl_Position = vec4(${programSetup.vertexCullX || 0.0}, 0.0, 0.0, 0.0);`, // Cull vertex
197
197
  " return;",
198
198
  "}"
199
199
  ].concat(
@@ -16,6 +16,7 @@ export const SnapProgram = function(programVariables, geometry, isSnapInit, isPo
16
16
  // Improves occlusion accuracy at distance
17
17
  getLogDepth: true && (vFragDepth => (isSnapInit ? `${vFragDepth} + length(vec2(dFdx(${vFragDepth}), dFdy(${vFragDepth})))` : vFragDepth)),
18
18
  renderPassFlag: 3, // PICK
19
+ vertexCullX: (!isSnapInit) && "2.0",
19
20
  dontCullOnAlphaZero: !isSnapInit,
20
21
  appendFragmentOutputs: (src) => {
21
22
  src.push(`${outCoords} = ivec4(${vWorldPosition} * ${coordinateScaler}.xyz, ${isSnapInit ? "-" : ""}${layerNumber});`);