Skip to content

Commit

Permalink
fix: correct IfcPropertiesTiler progress event
Browse files Browse the repository at this point in the history
  • Loading branch information
agviegas committed Jul 13, 2024
1 parent 882e872 commit fe7c112
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
1 change: 0 additions & 1 deletion packages/core/src/core/Cullers/src/mesh-culler-renderer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,6 @@ export class MeshCullerRenderer extends CullerRenderer implements Disposable {

if (!colorMesh || !code) {
this.isProcessing = false;
console.log(mesh.visible);
return;
}

Expand Down
6 changes: 4 additions & 2 deletions packages/core/src/fragments/IfcPropertiesTiler/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -194,12 +194,14 @@ export class IfcPropertiesTiler extends Component implements Disposable {

const currentProgress = typeCounter / allIfcEntities.size;
if (currentProgress > nextProgress) {
nextProgress = Math.round(nextProgress * 100) / 100;
await this.onProgress.trigger(nextProgress);
nextProgress += 0.01;
nextProgress = Math.max(nextProgress, currentProgress);
await this.onProgress.trigger(Math.round(nextProgress * 100) / 100);
}
}

await this.onProgress.trigger(1);

// Stream indices

const relations = this.components.get(IfcRelationsIndexer);
Expand Down

0 comments on commit fe7c112

Please sign in to comment.