MapSnapshotOptions

public struct MapSnapshotOptions

Set of options for taking map snapshot with Snapshotter.

  • Dimensions of the snapshot in points.

    Declaration

    Swift

    public var size: CGSize
  • Ratio between the number device-independent and screen pixels.

    Declaration

    Swift

    public var pixelRatio: CGFloat
  • Glyphs rasterization options to use for client-side text rendering. By default, GlyphsRasterizationOptions will use .ideographsRasterizedLocally

    Declaration

    Swift

    public var glyphsRasterizationOptions: GlyphsRasterizationOptions
  • Resource fetching options to be used by the snapshotter.

    Declaration

    Swift

    public var resourceOptions: ResourceOptions
  • Flag that determines if the logo should be shown on the snapshot

    Declaration

    Swift

    public var showsLogo: Bool
  • Flag that determines if attribution should be shown on the snapshot

    Declaration

    Swift

    public var showsAttribution: Bool
  • Initializes a MapSnapshotOptions

    Declaration

    Swift

    public init(size: CGSize,
                pixelRatio: CGFloat,
                glyphsRasterizationOptions: GlyphsRasterizationOptions = GlyphsRasterizationOptions(),
                resourceOptions: ResourceOptions = ResourceOptionsManager.default.resourceOptions,
                showsLogo: Bool = true,
                showsAttribution: Bool = true)

    Parameters

    size

    Dimensions of the snapshot in points

    pixelRatio

    Ratio of device-independent and screen pixels.

    glyphsRasterizationOptions

    Glyphs rasterization options to use for client-side text rendering. Default mode is .ideographsRasterizedLocally

    resourceOptions

    Resource fetching options to be used by the snapshotter. Default uses the access token provided by ResourceOptionsManager.default

    showsLogo

    Flag that determines if the logo should be shown on the snapshot

    showsAttribution

    Flag that determines if attribution should be shown on the snapshot