-
Notifications
You must be signed in to change notification settings - Fork 4
Open
Labels
Milestone
Description
Description
We need to extend the 3D viewer of Kompakkt to support the International Image Interoperability Framework (IIIF). The goal is to enable import, display and export of IIIF-compliant 3D objects and provide a compatible data structure and API.
The scope includes:
- Replace the existing parts of the viewer logic that reflects IIIF Presentation API 4.0 model
- Implement background color from manifest.
- Implement parsing and application of IIIF transforms (translation, rotation, position).
- Implement import for loading IIIF manifests (via URL, file or JSON text).
- Implement coordinate system conversion (IIIF right-handed → Babylon.js left-handed on import / vice versa on export, also see [/Adjusting IIIF transforms to Babylon coordinate system #65])
- Implement cameras and lights as defined in IIIF manifests.
- Implement export of the current Kompakkt scene as JSON
- Performing tests using sample IIIF resources
- Creating technical documentation for the implementation
Functionalities
1. Basic Model in Scene
Manifest:
https://raw.githubusercontent.com/IIIF/3d/main/manifests/1_basic_model_in_scene/model_origin.json
Functionality:
- Import a basic IIIF 3D scene with at least one model.
- Correctly position the model at its defined origin.
2. Background Color
Functionality:
- Parse
backgroundcolor from the manifest. - Apply the background color in the Babylon.js scene.
3. Transforms (Rotation, Translation, Position)
Functionality:
- Parse transforms defined in IIIF:
- rotation
- translation
- position
- Apply transforms to the loaded models.
- Ensure coordinate system conversion (right-handed → left-handed) occurs on import.
4. Perspective Camera
Manifest:
https://raw.githubusercontent.com/IIIF/3d/main/manifests/2_cameras/perspective_camera.json
Functionality:
- Parse and construct a perspective camera from the manifest.
- Support camera properties such as:
- field of view
- position
- orientation / lookAt
5. Directional Light (LookAt + Positioned)
Functionality:
- Parse directional light definitions.
- Implement lights with:
- position
- direction
- lookAt target
- intensity
6. Scene Export as JSON (Kompakkt → IIIF-Compatible)
Functionality:
- Export the current Kompakkt scene as JSON (IIIF-compatible structure).
- Include models, transforms, background color, camera(s) and light(s) where applicable.
Acceptance Criteria
- The viewer can load and display IIIF 3D manifests (as listed above).
- The viewer architecture is updated to support IIIF-native scenes (models, lights, cameras, transforms, background).
- Transforms from IIIF manifests are correctly interpreted and applied with proper coordinate conversion.
- Background color is applied from the manifest.
- Camera and light configurations behave as defined in the manifests.
- The current Kompakkt scene can be exported as JSON
- Documentation is updated accordingly.