diff --git a/examples/annotations/annotations_occlusionEnabled_SceneModel_dtx.html b/examples/annotations/annotations_occlusionEnabled_SceneModel_dtx.html new file mode 100644 index 0000000000..b4cf7266ac --- /dev/null +++ b/examples/annotations/annotations_occlusionEnabled_SceneModel_dtx.html @@ -0,0 +1,344 @@ + + + + + + + xeokit Example + + + + + + + + + + +
+ +

AnnotationsPlugin

+

Annotations with SceneModel


+

Components Used

+ +
+ + + + \ No newline at end of file diff --git a/examples/annotations/annotations_occlusionEnabled_sceneGraph.html b/examples/annotations/annotations_occlusionEnabled_sceneGraph.html new file mode 100644 index 0000000000..8535e884e4 --- /dev/null +++ b/examples/annotations/annotations_occlusionEnabled_sceneGraph.html @@ -0,0 +1,339 @@ + + + + + + + xeokit Example + + + + + + + + + + +
+ +

AnnotationsPlugin

+

Annotations with Node, Mesh and ReadableGeometry


+

Components Used

+ +
+ + + + \ No newline at end of file diff --git a/examples/annotations/index.html b/examples/annotations/index.html index a046855b59..6be7a6409d 100644 --- a/examples/annotations/index.html +++ b/examples/annotations/index.html @@ -269,6 +269,8 @@ ["annotations_occlusionDisabled", "Annotations with occlusion culling disabled"], ["annotations_fullPrecision_MAP", "Annotations with double-precision rendering"], ["annotations_occlusionEnabled_dtx", "Annotations with occlusion culling enabled, DTX enabled"], + ["annotations_occlusionEnabled_sceneGraph", "Annotations with occlusion culling enabled, scene graph"], + ["annotations_occlusionEnabled_SceneModel_dtx", "Annotations with occlusion culling enabled, SceneModel, DTX"], "#Sprite markers", diff --git a/src/viewer/scene/mesh/occlusion/OcclusionRenderer.js b/src/viewer/scene/mesh/occlusion/OcclusionRenderer.js index 475c32f89b..3377bb2286 100644 --- a/src/viewer/scene/mesh/occlusion/OcclusionRenderer.js +++ b/src/viewer/scene/mesh/occlusion/OcclusionRenderer.js @@ -73,6 +73,10 @@ OcclusionRenderer.prototype.drawMesh = function (frameCtx, mesh) { const geometryState = mesh._geometry._state; const origin = mesh.origin; + if (materialState.alpha < 1.0) { + return; + } + if (frameCtx.lastProgramId !== this._program.id) { frameCtx.lastProgramId = this._program.id; this._bindProgram(frameCtx);