MSFRasterTileLayer

Objective-C


@interface MSFRasterTileLayer : MSFTileLayer

Swift

class MSFRasterTileLayer : MSFTileLayer

A tile layer where each tile is a bitmap. Should be used together with corresponding data source.

  • Constructs a RasterTileLayer object from a data source.

    Declaration

    Objective-C

    - (id)initWithDataSource:(MSFTileDataSource *)dataSource;

    Swift

    init!(dataSource: MSFTileDataSource!)

    Parameters

    dataSource

    The data source from which this layer loads data.

  • Returns the tile texture cache capacity.

    Declaration

    Objective-C

    - (unsigned long)getTextureCacheCapacity;

    Swift

    func getTextureCacheCapacity() -> UInt

    Return Value

    The tile texture cache capacity in bytes.

  • Sets the tile texture cache capacity (uncompressed GPU textures); too small a cache causes disappearing tiles. An opaque 256x256 tile takes 192KB, a transparent one 256KB; the tile count grows with screen size, tilt and preloading. By default the cache follows the screen: five screens of tiles at the size of the ones in view, as maplibre keeps, and never under 10MB. Setting a capacity fixes it at that value instead.

    Declaration

    Objective-C

    - (void)setTextureCacheCapacity:(unsigned long)capacityInBytes;

    Swift

    func setTextureCacheCapacity(_ capacityInBytes: UInt)

    Parameters

    capacityInBytes

    The new tile bitmap cache capacity in bytes.

  • Returns the current tile filter mode.

    Declaration

    Objective-C

    - (enum MSFRasterTileFilterMode)getTileFilterMode;

    Swift

    func getTileFilterMode() -> MSFRasterTileFilterMode

    Return Value

    The current tile filter mode. The default is bilinear.

  • Sets the current tile filter mode.

    Declaration

    Objective-C

    - (void)setTileFilterMode:(enum MSFRasterTileFilterMode)filterMode;

    Swift

    func setTileFilterMode(_ filterMode: MSFRasterTileFilterMode)

    Parameters

    filterMode

    The new tile filter mode.

  • Returns the current relative tile blending speed.

    Declaration

    Objective-C

    - (float)getTileBlendingSpeed;

    Swift

    func getTileBlendingSpeed() -> Float

    Return Value

    The current relative tile blending speed. Default is 1.0.

  • Sets the relative tile blending speed.

    Declaration

    Objective-C

    - (void)setTileBlendingSpeed:(float)speed;

    Swift

    func setTileBlendingSpeed(_ speed: Float)

    Parameters

    speed

    The new relative speed value. Default is 1.0. Use zero or negative values to disable blending.

  • Returns the raster tile event listener.

    Declaration

    Objective-C

    - (MSFRasterTileEventListener *)getRasterTileEventListener;

    Swift

    func getRasterTileEventListener() -> MSFRasterTileEventListener!

    Return Value

    The raster tile event listener.

  • Sets the raster tile event listener.

    Declaration

    Objective-C

    - (void)setRasterTileEventListener:(MSFRasterTileEventListener *)eventListener;

    Swift

    func setRasterTileEventListener(_ eventListener: MSFRasterTileEventListener!)

    Parameters

    eventListener

    The raster tile event listener.

  • Undocumented

    Declaration

    Objective-C

    -(void)dealloc;

    Swift

    func dealloc()