UniversalViewer / universalviewer

A community-developed open source project on a mission to help you share your 📚📜📰📽️📻🗿 with the 🌎
http://universalviewer.io
Other
489 stars 184 forks source link

3D glb model #661

Closed exlcodeshare closed 3 years ago

exlcodeshare commented 5 years ago

UV version:

 universalviewer@3.0.33

I'm submitting a:

Current behavior: Trying to load a v3 manifest with a glb file. Have a working manifest with this canvas:

{ "id": "https://example.org/iiif/book1/canvas/p1", "type": "Canvas", "items": [{ "id": "https://example.org/iiif/book1/canvas/p1/annotationpage/0", "type": "AnnotationPage", "items": [{ "id": "https://example.org/iiif/book1/canvas/p1/annotation/0", "type": "Annotation", "motivation": "painting", "body": { "id": "https://example.org/test.glb", "type": "PhysicalObject", "format": "model/gltf+json", "label": { "@none": ["a label"] } }, "target": "https://example.org/iiif/book1/canvas/p1" } ] } ], "label": { "@none": ["a label"] } }

I got the 'PhysicalObject' from the examples on the UV demo site. However, the Presentation v3 does not list 'PhysicalObject' as a valid type, and specifies 'Model' for 3D objects.

Another problem is the format: IANA specifies 'model/gltf-binary' for glb (see also https://github.com/KhronosGroup/glTF/issues/943) but that does not work ('model/gltf+json' does).

Expected behavior: "type": "Model", "format": "model/gltf-binary",

Steps to reproduce:

Related code:

// insert any relevant code here

Other information:

edsilv commented 5 years ago

glb support is currently in the works. Hopefully something to announce soon. Could you link to where the Presentation 3 spec specifies Model for 3D objects? Many thanks.

exlcodeshare commented 5 years ago

Thanks. See https://preview.iiif.io/api/1639-provider/api/presentation/3.0/#32-technical-properties ("type").

fire commented 3 years ago

There is still interest in this.

edsilv commented 3 years ago

Hi, Here's an example manifest using Model: https://iiif-3d-manifests.netlify.app/collection/gltf/flight-helmet/index.json Loading in UV v4: https://uv-v4.netlify.app/#?c=&m=&cv=&manifest=https%3A%2F%2Fiiif-3d-manifests.netlify.app%2Fcollection%2Fgltf%2Fflight-helmet%2Findex.json Here are some examples of how to set up the UV: https://github.com/UniversalViewer/uv-examples Hope this helps!