3D Tiles: Difference between revisions

From Maria GDK Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 7: Line 7:
[[File:M3 import 3DTiles.PNG|right]]
[[File:M3 import 3DTiles.PNG|right]]
Importing models is handled by the library assimp. A full list of supported formats can be found at https://github.com/assimp/assimp/blob/master/doc/Fileformats.md, however many of the formats have not yet been tested in Maria Map Maker.
Importing models is handled by the library assimp. A full list of supported formats can be found at https://github.com/assimp/assimp/blob/master/doc/Fileformats.md, however many of the formats have not yet been tested in Maria Map Maker.
The imported 3D tileset will consist of the models themselves in the format b3dm, as well as texture files, and several text files which define the position, and relationships between the models.


=== Parameters ===
=== Parameters ===

Revision as of 12:22, 23 September 2021

From version 4.2

Maria Map Maker is capable of importing, rendering and editing 3D models from a variety of sources. The format used for storage is 3D Tiles. A collection of models in the 3D Tiles format is called a 3D Tileset, and contains all information about geographical position, textures and transformations to correctly place and render a model on a 3D globe.


Import

M3 import 3DTiles.PNG

Importing models is handled by the library assimp. A full list of supported formats can be found at https://github.com/assimp/assimp/blob/master/doc/Fileformats.md, however many of the formats have not yet been tested in Maria Map Maker. The imported 3D tileset will consist of the models themselves in the format b3dm, as well as texture files, and several text files which define the position, and relationships between the models.

Parameters

  • 3D Tileset - Choose an existing 3D tileset as a destination for the model, or create a new tileset.
  • Model - Choose an existing model as a parent for the current import, or define it as a top-level model.
  • Compress textures - Compress textures into a DirectDraw Surface container file. This reduces file size, but should not be used if you intend to use the tileset in the Cesium platform, as it's not supported there.
  • Auto place - Attempt to find geographic position for the model in the source files.
  • Latitude / Longitude / Elevation - Manually enter position and elevation for the placement of the model. Only used if "Auto place" is disabled or unable to find geographic position in the source files.
  • Unit select - Unit in the source data - meters or feet.


3D Tileset editor

Navigation

When you open a 3D tileset, Maria Map Maker will enable 3D mode, which will render the background map on top of the highest resolution elevation data available in your workspace (or external sources). There are several ways to navigate the 3D environment:

Movement Mouse / keyboard
Move along the surface Left mouse button on the terrain / keyboard arrow keys / WASD keys. Hold Ctrl to move slower.
Tilt and rotate camera around a point Right mouse button
Move along the camera direction Mouse wheel up/down

Model hierarchy

The 3D tileset is represented as a hierarchy of models. Double-click any model in the hierarchy to open its properties.

You can delete models from the tileset by right-clicking it and selecting "Delete". You can import a new top-level model with the "Add" button, or you can create a sub-model by right-clicking a specific level in the model hierarchy and clicking "Add model from file".

M3 3d tileset submodel.PNG


Model placement

An important feature of the 3D tilset is that any translation or rotation of a top-level model will also apply to all is sub-models.

To adjust the placement of a model, double click any model to open its properties. The top bar of this window gives you a few convenient buttons:

  • Camera to Model - Move the camera to the position of the model. Only the position of the camera is moved, not the altitude.
  • Model to Camera - Move the model to the position of the camera.
  • Place on Terrain - Calculates the average height of the model and places it on the terrain at the current position

A top-level model's placement on the globe is defined by geographical coordinates (latitude and longitude) and an altitude above the surface of the globe. Vertical datum is not considered.

To change the position of a top-level model, hold Ctrl and left dragging it along the terrain. The altitude can be adjusted using Ctrl and the mousewheel. Pressing Shift + Ctrl gives more precision.

The position and altitude of a sub-model is only defined as an offset from its parent model. The offset can be adjusted using the arrows in the model widget. The model can also be rotated using the widget.


The model can also be rotated using the 3D widget which appears over the model. Left-click and drag one of the axis to rotate the model.

The model can be scaled by a user-defined scale factor. This is mostly relevant for instanced models - for instance vehicles which are placed around the 3D environment for added realism.



M3 3dtiles model properties.PNG