# Structures

The following structures are available globally.
- `


  ### [Camera](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/Camera)


  ` The map camera position and orientation.

  **Usage with the map:**

      // Usage with an initial camera configuration
      Map(
        initialCamera: Camera(center: LatLngAltitude(latitude: 37.7749, longitude: -122.4194, altitude: 0)),
        mode: .hybrid
      )

      // Usage with a camera binding
      @State private var camera = Camera(center: LatLngAltitude(latitude: 37.7749, longitude: -122.4194, altitude: 0))
      Map(camera: $camera, mode: .hybrid)

  **Usage with fly animations:**

      struct FlyAnimationExample: View {
        @State private var animationTrigger = 0
        let targetCamera = Camera(center: LatLngAltitude(latitude: 37.7749, longitude: -122.4194, altitude: 0))

        var body: some View {
          Map(mode: .hybrid)
            .flyCameraTo(targetCamera, trigger: animationTrigger)
            .flyCameraAround(targetCamera, trigger: animationTrigger)
        }
      }

  #### Declaration

  Swift

      struct Camera

      extension Camera : AdditiveArithmetic, Animatable, Copyable, Equatable, Escapable, VectorArithmetic

- `


  ### [CompassControl](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/CompassControl)


  ` A control that displays a compass which rotates with the map's current camera heading,
  and re-orients the map to face north when tapped.

  Add a compass to the map using the `mapControls` modifier:

      Map(mode: .hybrid)
        .mapControls {
          CompassControl()
        }

  #### Declaration

  Swift

      @MainActor
      @preconcurrency
      struct CompassControl

      extension CompassControl : MapControl, Sendable, SendableMetatype, View

- `


  ### [LatLngAltitude](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/LatLngAltitude)


  `

  #### Declaration

  Swift

      struct LatLngAltitude

      extension LatLngAltitude : AdditiveArithmetic, Animatable, Copyable, Equatable, Escapable, Hashable, VectorArithmetic

- `


  ### [LatLngBounds](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/LatLngBounds)


  ` Represents a rectangular region on the Earth's surface defined by latitude and longitude ranges.

  Bounds can restrict both longitude and latitude, or can restrict either latitude or longitude
  only. For latitude-only bounds use longitude range of `(-180.0)...180`. For longitude-only
  bounds use latitude range of `-(90)...90`.

  #### Declaration

  Swift

      struct LatLngBounds

- `


  ### [Map](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/Map)


  `

  #### Declaration

  Swift

      @MainActor
      @preconcurrency
      struct Map

      extension Map : MapAnimatable, Sendable, SendableMetatype, View

- `


  ### [MapControlsBuilder](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/MapControlsBuilder)


  ` Constructs map controls.

  `MapControlsBuilder` is used in the `mapControls` view modifier to allow for a natural,
  declarative syntax when specifying multiple controls.

  #### Declaration

  Swift

      @resultBuilder
      struct MapControlsBuilder

- `


  ### [MapTapInfo](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/MapTapInfo)


  ` The result of a tap gesture on a map.

  #### Declaration

  Swift

      struct MapTapInfo

- `


  ### [Marker](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/Marker)


  ` A type that allows you to display custom SwiftUI content over the Map, anchored to a position on
  the 3D map.

  Default content is a `https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/Pin` view.

      Map(mode: .hybrid) {
        Marker(position: .init(latitude: 37.7749, longitude: -122.4194, altitude: 0)) {
          Image(systemName: "car")
        }
      }

  #### Declaration

  Swift

      @MainActor
      @preconcurrency
      struct Marker<Content> where Content : View

      extension Marker : MapContent, https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Protocols/MapContentAnchorable, Sendable, SendableMetatype, View

- `


  ### [Marker3D](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/Marker3D)


  ` A 3D marker that can be placed on a map.

      Map(mode: .hybrid) {
        Marker3D(position: .init(latitude: 37.7749, longitude: -122.4194, altitude: 0))
      }

  #### Declaration

  Swift

      @MainActor
      @preconcurrency
      struct Marker3D

      extension Marker3D : MapContent, https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Protocols/MapContentAnchorable, https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Protocols#/s:12GoogleMaps3D18MapContentTappableP, Sendable, SendableMetatype, View

- `


  ### [Model](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/Model)


  ` 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

      @MainActor
      @preconcurrency
      struct Model

      extension Model : MapContent, https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Protocols#/s:12GoogleMaps3D18MapContentTappableP, Sendable, SendableMetatype, View

- `


  ### [Orientation3D](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/Orientation3D)


  `

  #### Declaration

  Swift

      struct Orientation3D

      extension Orientation3D : Equatable, Hashable

- `


  ### [PanHorizontalControl](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/PanHorizontalControl)


  ` A control that allows the user to pan the map horizontally (left and right).

      Map(mode: .hybrid)
        .mapControls {
          PanHorizontalControl()
        }

  #### Declaration

  Swift

      @MainActor
      @preconcurrency
      struct PanHorizontalControl

      extension PanHorizontalControl : MapControl, Sendable, SendableMetatype, View

- `


  ### [PanVerticalControl](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/PanVerticalControl)


  ` A control that allows the user to pan the map vertically (up and down).

      Map(mode: .hybrid)
        .mapControls {
          PanVerticalControl()
        }

  #### Declaration

  Swift

      @MainActor
      @preconcurrency
      struct PanVerticalControl

      extension PanVerticalControl : MapControl, Sendable, SendableMetatype, View

- `


  ### [Pin](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/Pin)


  ` A SwiftUI view that renders a map pin.

  The appearance of the pin, including its background color, border color, scale, and glyph, can be
  customized using a `https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/Pin/Configuration` object.

  `Pin` is used internally by `https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/Marker3D`s with the `.pin` style, and as a SwiftUI view with the
  `https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/Marker` type.

  Examples customizing a `Pin` for `https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/Marker`:

      Marker(position: .init(latitude: 0, longitude: 0)) {
          Pin(configuration: .init(backgroundColor: .blue, borderColor: .black))
      }
      Marker(position: .init(latitude: 0, longitude: 0)) {
          Pin(configuration: .red)
      }

  #### Declaration

  Swift

      @MainActor
      @preconcurrency
      struct Pin

      extension Pin : Sendable, SendableMetatype, View

- `


  ### [Polygon](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/Polygon)


  ` A 3D polygon that can be placed on a map.

      Map(mode: .hybrid) {
        Polygon(
          path: [
            .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

      @MainActor
      @preconcurrency
      struct Polygon

      extension Polygon : MapContent, https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Protocols#/s:12GoogleMaps3D18MapContentTappableP, Sendable, SendableMetatype, View

- `


  ### [PolygonGeometry](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/PolygonGeometry)


  ` Represents the geometry definition for a polygon with an outer boundary and optional inner
  boundaries.

      Map(mode: .hybrid) {
        Polygon(
          geometry: PolygonGeometry(path: [
            .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 PolygonGeometry

      extension PolygonGeometry : Equatable, Hashable

- `


  ### [Polyline](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/Polyline)


  ` A 3D polyline that can be placed on a map.

      Map(mode: .hybrid) {
        Polyline(path: [
          .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

      @MainActor
      @preconcurrency
      struct Polyline

      extension Polyline : MapContent, https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Protocols#/s:12GoogleMaps3D18MapContentTappableP, Sendable, SendableMetatype, View

- `


  ### [Popover](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/Popover)


  ` A SwiftUI view that displays content in a "popover" bubble, anchored to a
  position or another piece of map content on the 3D map.

  #### Declaration

  Swift

      @MainActor
      @preconcurrency
      struct Popover<Content> where Content : View

      extension Popover : MapContent, Sendable, SendableMetatype, View

- `


  ### [PopoverStyle](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/PopoverStyle)


  ` Configuration for the visual appearance of a Popover.

  #### Declaration

  Swift

      struct PopoverStyle

      extension PopoverStyle : Equatable

- `


  ### [RotateControl](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/RotateControl)


  ` A control that allows the user to rotate the map.

      Map(mode: .hybrid)
        .mapControls {
          RotateControl()
        }

  #### Declaration

  Swift

      @MainActor
      @preconcurrency
      struct RotateControl

      extension RotateControl : MapControl, Sendable, SendableMetatype, View

- `


  ### [Shadow](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/Shadow)


  ` Configuration for the shadow of a Popover.

  #### Declaration

  Swift

      struct Shadow

      extension Shadow : Equatable

- `


  ### [TiltControl](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/TiltControl)


  ` A control that allows the user to tilt the map.

      Map(mode: .hybrid)
        .mapControls {
          TiltControl()
        }

  #### Declaration

  Swift

      @MainActor
      @preconcurrency
      struct TiltControl

      extension TiltControl : MapControl, Sendable, SendableMetatype, View

- `


  ### [Vector3D](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/Vector3D)


  `

  #### Declaration

  Swift

      struct Vector3D

      extension Vector3D : Equatable, Hashable

- `


  ### [ZoomControl](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/ZoomControl)


  ` A control that allows the user to zoom in and out of the map.

      Map(mode: .hybrid)
        .mapControls {
          ZoomControl()
        }

  #### Declaration

  Swift

      @MainActor
      @preconcurrency
      struct ZoomControl

      extension ZoomControl : MapControl, Sendable, SendableMetatype, View