Skip to content

Commit 65c4008

Browse files
AnthonyGltDesplandis
authored andcommitted
fix(PointCloud): correct some issues after refacto
1 parent cef15ea commit 65c4008

File tree

3 files changed

+3
-5
lines changed

3 files changed

+3
-5
lines changed

examples/3dtiles_pointcloud.html

+1-3
Original file line numberDiff line numberDiff line change
@@ -76,10 +76,8 @@
7676
itowns.View.prototype.addLayer.call(view, $3dTilesLayerSetePC);
7777
function switchMode(){
7878
let pntsLayer = view.getLayerById("3d-tiles-sete");
79-
8079
if(pntsLayer){
81-
pntsLayer = pntsLayer;
82-
pntsLayer.pntsMode = pntsLayer.pntsMode == itowns.PNTS_MODE.COLOR ? itowns.PNTS_MODE.CLASSIFICATION : itowns.PNTS_MODE.COLOR;
80+
pntsLayer.pntsMode = pntsLayer.pntsMode === itowns.PNTS_MODE.COLOR ? itowns.PNTS_MODE.CLASSIFICATION : itowns.PNTS_MODE.COLOR;
8381
view.notifyChange(view.camera3D);
8482
}
8583
}

src/Parser/PntsParser.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -135,6 +135,6 @@ function parseFeatureBinary(array, byteOffset, FTJSONLength) {
135135

136136
function setClassification(point, batchTable) {
137137
if (!point.geometry) { return; }
138-
if (batchTable.content && batchTable.content.Classification) { point.geometry.setAttribute('classification', new THREE.BufferAttribute(new Uint8Array(batchTable.content.Classification), 1, true)); }
138+
if (batchTable.content && batchTable.content.Classification) { point.geometry.setAttribute('classification', new THREE.BufferAttribute(new Uint8Array(batchTable.content.Classification), 1)); }
139139
return point;
140140
}

src/Renderer/PointsMaterial.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -210,7 +210,7 @@ class PointsMaterial extends THREE.ShaderMaterial {
210210
delete options.elevationRange;
211211
delete options.angleRange;
212212
delete options.orientedImageMaterial;
213-
delete options.classificationScheme;
213+
delete options.classification;
214214
delete options.discreteScheme;
215215
delete options.applyOpacityClassication;
216216
delete options.size;

0 commit comments

Comments
 (0)