Closed JulieWinchester closed 1 year ago
Based on the notes from https://github.com/IIIF/3d/issues/22, here are my suggestions:
annotations
, value is array of nodes, as used by Voyager JSON.id
, normal
, position
, and value
, most or all of which are included in all demo JSON files.id
is integer ID value, as used by Model Viewer and X3D demos.position
coordinates specified relative to model origin, aligning with how they are specified (in practice) in Aleph, Model Viewer, and X3D demos. normal
coordinates should be unit-length vector. What coordinates specify is implementation-specific, but usually determines annotation visibility and/or placement of annotation label.value
provides node label title. value
and title
are both used for this in current demos, value
is used by Model Viewer and X3D. Suggested example JSON:
{
"annotations": [
{
"id": 0,
"normal": [ 0.294, 0.114, 0.949 ],
"position": [ 0.017, 1.806, 0.341 ],
"value": "visor"
},
{
"id": 1,
"normal": [ 0.472, 0.059, 0.880 ],
"position": [ 0.518, 0.956, 0.122 ],
"value": "glove"
}
]
}
Per 4/19 meeting - Will we include annotation tag offset in the proposed spec? Would that happen through magnitude of normal vector or in another way?
This example JSON is now hosted on IIIF 3D repo: https://github.com/IIIF/3d/blob/main/demo/json/label-annotation-issue-17.json
That's the model-viewer demo updated to use the above annotation json format: https://codesandbox.io/s/model-viewer-annotations-demo-3k5tqo?file=/index.html
Acceptance criteria: