MapLibre Native C API
Public C ABI for the MapLibre Native wrapper.
Loading...
Searching...
No Matches
mln_map_options Struct Reference

#include <map.h>

Data Fields

mln_logical_extent initial_extent
uint32_t map_mode
bool fast_pfor_enabled
uint64_t event_mask

Detailed Description

Options used when creating a map.

Field Documentation

◆ event_mask

uint64_t mln_map_options::event_mask

Map-originated event types this map queues, as a bitwise OR of mln_runtime_event_mask values.

This field is always read. MLN_RUNTIME_EVENT_MASK_ALL selects every event type this library reports, and MLN_RUNTIME_EVENT_MASK_NONE queues none. Defaults to MLN_RUNTIME_EVENT_MASK_ALL.

The mask applies throughout construction, including the camera events that MapLibre reports while it initializes the map's size.

◆ fast_pfor_enabled

bool mln_map_options::fast_pfor_enabled

Decodes MapLibre Tile (MLT) tiles whose integer streams use FastPFOR encodings. Defaults to false.

Enable this on maps that read vector sources created with MLN_STYLE_VECTOR_TILE_ENCODING_MLT from a tile set that uses FastPFOR. It is fixed for the lifetime of the map and applies to every MLT source the map loads. A map created with this false decodes every other MLT encoding and logs a tile parse warning for the FastPFOR ones.

◆ initial_extent

mln_logical_extent mln_map_options::initial_extent

Initial logical extent. Width and height must be nonzero, and scale_factor must be finite and positive. scale_factor is fixed for the map's lifetime.

After creation, only mln_map_resize() changes the width and height. A render session submits it to size the map to its target.

◆ map_mode

uint32_t mln_map_options::map_mode

One of mln_map_mode. Defaults to MLN_MAP_MODE_CONTINUOUS.


The documentation for this struct was generated from the following file: