Adds a 3D model to the map at the specified coordinate.
The Coordinate where the model will be placed.
The URL to the GLTF or GLB model file, or an inline base64 encoded 3D asset from the Mappedin 3D Assets Library.
Optionaloptions: TAddModelOptionsConfiguration options for the model using TAddModelOptions.
A Model instance representing the added 3D model.
const coordinate = mapView.createCoordinate(45, -75);
mapView.Models.add(coordinate, 'https://your-domain.com/assets/model.glb', {
scale: [1, 1, 1],
rotation: [0, 0, 0],
interactive: true
});
3D Models in Mappedin JS
3D models can be used to represent landmarks, assets, or furniture, providing a rich and interactive indoor map experience. Mappedin JS supports models in GLTF and GLB formats. Models with nested meshes are not supported.
Supported Formats
Adding 3D Models
Use the
addmethod to place a model at a specific Coordinate.Mappedin 3D Assets Library
Mappedin provides a library of ready-to-use 3D models for common indoor objects. You can install it via npm:
Usage (Self-hosted GLB files)
Usage (Direct base64 imports)
Performance Tips
More Information
This class is accessed using MapView.Models.