Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unsupported value for params.primitiveType #142

Closed
kushal154 opened this issue Apr 13, 2024 · 2 comments
Closed

Unsupported value for params.primitiveType #142

kushal154 opened this issue Apr 13, 2024 · 2 comments

Comments

@kushal154
Copy link

I have a IFC with size of 650MB which I want to convert and use in XKT format.

Here is what I have done:

Step 1: Used ifc2gltfcxconverter (version 3.1) to create glb files.

Command (used default configuration json): linux/bin/ifc2gltfcxconverter -i model.ifc -o model.glb -m metadata.json -s 100 -c linux/bin/ifc2gltfcxconverter.json

  __ IFC to GLTF converter __ version: 3.1 ____________
  Loading input config file: linux/bin/ifc2gltfcxconverter.json
  Loading file "model.ifc": 100%
  Converting IFC geometry: 100%
  Exporting to gltf: 100%
  Accessors: 44356, reused: 201541, compression: 81%
  Exporting to gltf: 100%
  Accessors: 40264, reused: 193040, compression: 82%
  Exporting to gltf: 100%
  Accessors: 14076, reused: 52795, compression: 78%
  Exporting metadata: 100%done in 60 minutes, 17 seconds

Following files are created:
model.glb - 105M
model_1.glb - 104M
model_2.glb - 34M
metadata.json - 22M
model.glb.manifest.json

Step 2: Used xeokit-convert (version v1.1.15-beta-8) to create split xkt files

Command: node xeokit-convert-1.1.15-beta-8/convert2xkt.js -n -a model.glb.manifest.json -o model.xkt.manifest.json -l

[convert2xkt] Running convert2xkt v1.1.15-beta-8...
[convert2xkt] Using configs in ./convert2xkt.conf.js
[convert2xkt] Converting glTF files in manifest model.glb.manifest.json...
[convert2xkt] Reading input file: model.glb
[convert2xkt] Input file size: 109189.61 kB
[convert2xkt] Not embedding metadata in XKT
TextEncoder constructor called with encoding label, which is ignored.
[convert2xkt] Using parser: parseGLTFIntoXKTModel
[convert2xkt] Parsing normals: disabled
[convert2xkt] Parsing textures: enabled
node:internal/process/promises:289
            triggerUncaughtException(err, true /* fromPromise */);
            ^
[UnhandledPromiseRejection: This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). The promise rejected with the reason "Unsupported value for params.primitiveType: line-loop' - supported values are 'triangles', 'points', 'lines', 'line-strip', 'triangle-strip' and 'triangle-fan".] {
  code: 'ERR_UNHANDLED_REJECTION'
}
Node.js v20.12.2

Questions:

  1. Is there a way to reduce the size of glb file?
  2. What is this issue in step 2 and how do I resolve it?
@reno184
Copy link

reno184 commented Apr 23, 2024

I have exactly the same problem with different .glb Unsupported value for params.primitiveType: line-loop

@xeolabs
Copy link
Member

xeolabs commented Apr 24, 2024

@xeolabs xeolabs closed this as completed Apr 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants