Skip to content

Commit

Permalink
feat(core): adds argument to specify the name of the ifc loaded
Browse files Browse the repository at this point in the history
  • Loading branch information
HoyosJuan committed Sep 10, 2024
1 parent a778e64 commit 2a23a2f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/core/src/fragments/IfcLoader/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -116,11 +116,12 @@ export class IfcLoader extends Component implements Disposable {
* const group = await ifcLoader.load(ifcData);
* ```
*/
async load(data: Uint8Array, coordinate = true) {
async load(data: Uint8Array, coordinate = true, name = "") {
const before = performance.now();
this.onIfcStartedLoading.trigger();
await this.readIfcFile(data);
const group = await this.getAllGeometries();
group.name = name;

const jsonExporter = this.components.get(IfcJsonExporter);
const properties = await jsonExporter.export(this.webIfc, 0);
Expand Down

0 comments on commit 2a23a2f

Please sign in to comment.