The difference in the handling of 2D and 3D shapes also applies to how LuciadRIA displays icons. For example, 3D positions of flights are displayed exactly where they are, while 2D placemarks are positioned on the terrain.
LuciadRIA automatically drapes icons for 2D points. Draped icons do not look as crisp as non-draped icons, which are visualized as billboard rectangles aligned with your screen.
If you prefer non-draped icons, you can change the default draping behavior: use the
draped flag in
IconStyle to explicitly disable draping.
This is similar to how you disable draping for lines and areas.
To prevent that your non-draped icons are stuck halfway down the terrain, LuciadRIA automatically pushes the icon up when the map is pitched towards the horizon.
Also note that icons for shapes defined with an above-ground vertical reference are automatically moved up or down when the terrain changes detail.
The figures below show a few examples:
Figure 1 shows an icon positioned on the terrain. When the 3D map is tilted, the icon is automatically pushed up to prevent an intersection with the terrain. The red dot was added to indicate the actual point position. The icon is also moved up and down to follow the loaded terrain, so that it always remains positioned on top of the terrain.Figure 1. An icon positioned on the terrain
Figure 2 shows an icon anchored at the bottom, positioned on the terrain. When the view is tilted, the icon does not need to be pushed up as it will not intersect the terrain anyway. The icon is still moved up and down to follow the loaded terrain.Figure 2. An icon anchored at the bottom
Figure 3 shows an airplane in the air. The icon does not need to be pushed or moved because it has an absolute position. The icon can be hidden by the terrain if its position is below the loaded terrain.Figure 3. An icon in the air
Figure 4 shows a large icon that is draped on top of the terrain. This is useful for large icons, or if you do not want icons to shift when the map is tilted.Figure 4. A draped icon
LuciadRIA can automatically rotate icons so that they point to the heading of your domain objects.
You can use
IconStyle.heading to rotate objects moving in a certain direction, such as airplane icons moving along a trajectory.
LuciadRIA rotates your icons in any map reference, even when the map is rotated in 2D or tilted in 3D.
For more details, see the API reference documentation of