import-examples/12-15-import-formats/Ip033.gltf
Sources
- Pattern-mined from cnr-isti-vclab/meshlab#1387 (`confirmed`), ml#1484 (GPL-3.0 — pattern only, no bytes copied).
Description
A minimal, spec-valid glTF 2.0 document defines one mesh primitive with `"mode": 0` (POINTS) and only a `POSITION` accessor — no `indices`, as the glTF spec permits for point-cloud primitives (draw mode 0 renders each vertex as an independent point, no connectivity needed). ml#1387/#1484 report MeshLab's glTF importer feeding every primitive, regardless of declared `mode`, into a templated `populateTriangles<T>()` assembler that assumes triangle connectivity — producing a SEGV on a POINTS primitive with no index buffer to read triangles from. Distinct from the assimp-mined glTF candidates (Ip004/Ip007/Ip008/Ip011/Ip012, all attribute/accessor layout defects): this file has no accessor or buffer defect at all — every accessor is well-formed and in-bounds — the defect is purely that the primitive's declared draw `mode` is never branched on before triangle assembly.
Reproducer recipe
a glTF JSON with one mesh, one primitive whose `attributes` is `{"POSITION": 0}` (no `"indices"` key) and `"mode": 0`, backed by a correctly-sized base64 data-URI buffer holding 3 well-formed VEC3/float32 positions.
Expected kernel behavior
branch on the primitive's declared `mode` before assembling triangle connectivity; render/import POINTS (and LINES/LINE_STRIP/etc.) primitives through a mode-appropriate path, or reject with a diagnostic if only triangle primitives are supported — never assume every primitive has triangle indices.
Notes
Live-verified 2026-07-17 with trimesh 4.12.2: loads cleanly as a `Scene` containing one `trimesh.points.PointCloud` with `vertices.shape=(3,3)` — trimesh correctly branches on `mode: 0` and never attempts triangle assembly. ml#1387 (`confirmed`) and ml#1484 document MeshLab's glTF importer crashing (SEGV) on this same well-formed POINTS-mode pattern by unconditionally routing every primitive through its triangle assembler. Synonyms: "glTF POINTS mode primitive crash", "point cloud primitive routed to triangle assembler", "glTF mode 0 no indices SEGV", "primitive mode not branched before triangulation". Provenance tier: bytes-only.
Expected validation
Provenance tier
bytes-only — defect not fully embodied in fixture bytes.
Byte assertions
contains(b'"mode": 0')
Live oracle output
No live oracle data — run _run_corpus to populate.
Fixture content
Show fixture bytes (with defect highlighting)
1{ 2 "asset": { "version": "2.0" }, 3 "scene": 0, 4 "scenes": [ { "nodes": [0] } ], 5 "nodes": [ { "mesh": 0 } ], 6 "meshes": [ 7 { 8 "primitives": [ 9 { 10 "attributes": { "POSITION": 0 }, 11 "mode": 0 12 } 13 ] 14 } 15 ], 16 "buffers": [ 17 { 18 "uri": "data:application/octet-stream;base64,AAAAAAAAAAAAAAAAAACAPwAAAAAAAAAAAAAAAAAAgD8AAAAA", 19 "byteLength": 36 20 } 21 ], 22 "bufferViews": [ 23 { "buffer": 0, "byteOffset": 0, "byteLength": 36, "target": 34962 } 24 ], 25 "accessors": [ 26 { 27 "bufferView": 0, 28 "componentType": 5126, 29 "count": 3, 30 "type": "VEC3", 31 "max": [1.0, 1.0, 0.0], 32 "min": [0.0, 0.0, 0.0] 33 } 34 ] 35}