Structures
The following structures are available globally.
-
The map camera position and orientation.
Declaration
Swift
struct Cameraextension Camera : AdditiveArithmetic , Animatable , Copyable , Equatable , Escapable , VectorArithmetic -
Declaration
Swift
struct LatLngAltitudeextension LatLngAltitude : Copyable , Equatable , Escapable , Hashable -
Declaration
Swift
@MainActor @preconcurrency struct Mapextension Map : MapAnimatable , Sendable , View -
A 3D marker that can be placed on a map.
Map ( mode : . hybrid ) { Marker ( position : . init ( latitude : 37.7749 , longitude : - 122.4194 , altitude : 0 )) }Declaration
Swift
struct Markerextension Marker : Copyable , Equatable , Escapable , Hashable , Identifiable , MapContent -
A 3D model that can be placed on a map.
Map ( mode : . hybrid ) { Model ( position : . init ( latitude : 37.7749 , longitude : - 122.4194 , altitude : 100 ), url : URL ( string : "path/to/your/model.glb" ) ! ) }Declaration
Swift
struct Modelextension Model : Copyable , Equatable , Escapable , Hashable , Identifiable , MapContent -
Declaration
Swift
struct Orientation3Dextension Orientation3D : Copyable , Equatable , Escapable , Hashable -
Information about a place that was tapped.
Declaration
Swift
struct PlaceTapInfo -
A 3D polygon that can be placed on a map.
Map ( mode : . hybrid ) { Polygon ( outerCoordinates : [ . init ( latitude : 37.7749 , longitude : - 122.4194 , altitude : 0 ), . init ( latitude : 37.7740 , longitude : - 122.4184 , altitude : 0 ), . init ( latitude : 37.7750 , longitude : - 122.4174 , altitude : 0 ), ] ) }Declaration
Swift
struct Polygonextension Polygon : Copyable , Equatable , Escapable , Hashable , Identifiable , MapContent -
A 3D polyline that can be placed on a map.
Map ( mode : . hybrid ) { Polyline ( coordinates : [ . init ( latitude : 37.7749 , longitude : - 122.4194 , altitude : 100 ), . init ( latitude : 37.7750 , longitude : - 122.4193 , altitude : 100 ), . init ( latitude : 37.7751 , longitude : - 122.4192 , altitude : 100 ), ]) }Declaration
Swift
struct Polylineextension Polyline : Copyable , Equatable , Escapable , Hashable , Identifiable , MapContent -
Declaration
Swift
struct Vector3Dextension Vector3D : Copyable , Equatable , Escapable , Hashable

