7#ifndef MAPLIBRE_NATIVE_C_MAP_H
8#define MAPLIBRE_NATIVE_C_MAP_H
26 MLN_CAMERA_OPTION_CENTER = 1U << 0U,
27 MLN_CAMERA_OPTION_ZOOM = 1U << 1U,
28 MLN_CAMERA_OPTION_BEARING = 1U << 2U,
29 MLN_CAMERA_OPTION_PITCH = 1U << 3U,
30 MLN_CAMERA_OPTION_CENTER_ALTITUDE = 1U << 4U,
31 MLN_CAMERA_OPTION_PADDING = 1U << 5U,
32 MLN_CAMERA_OPTION_ANCHOR = 1U << 6U,
33 MLN_CAMERA_OPTION_ROLL = 1U << 7U,
34 MLN_CAMERA_OPTION_FOV = 1U << 8U,
39 MLN_ANIMATION_OPTION_DURATION = 1U << 0U,
40 MLN_ANIMATION_OPTION_VELOCITY = 1U << 1U,
41 MLN_ANIMATION_OPTION_MIN_ZOOM = 1U << 2U,
42 MLN_ANIMATION_OPTION_EASING = 1U << 3U,
43 MLN_ANIMATION_OPTION_TRANSITION_ID = 1U << 4U,
48 MLN_CAMERA_FIT_OPTION_PADDING = 1U << 0U,
49 MLN_CAMERA_FIT_OPTION_BEARING = 1U << 1U,
50 MLN_CAMERA_FIT_OPTION_PITCH = 1U << 2U,
61 MLN_BOUND_OPTION_MIN_ZOOM = 1U << 1U,
62 MLN_BOUND_OPTION_MAX_ZOOM = 1U << 2U,
63 MLN_BOUND_OPTION_MIN_PITCH = 1U << 3U,
64 MLN_BOUND_OPTION_MAX_PITCH = 1U << 4U,
77 MLN_FREE_CAMERA_OPTION_POSITION = 1U << 0U,
78 MLN_FREE_CAMERA_OPTION_ORIENTATION = 1U << 1U,
83 MLN_PROJECTION_MODE_AXONOMETRIC = 1U << 0U,
84 MLN_PROJECTION_MODE_X_SKEW = 1U << 1U,
85 MLN_PROJECTION_MODE_Y_SKEW = 1U << 2U,
90 MLN_MAP_DEBUG_TILE_BORDERS = 1U << 1U,
91 MLN_MAP_DEBUG_PARSE_STATUS = 1U << 2U,
92 MLN_MAP_DEBUG_TIMESTAMPS = 1U << 3U,
93 MLN_MAP_DEBUG_COLLISION = 1U << 4U,
94 MLN_MAP_DEBUG_OVERDRAW = 1U << 5U,
95 MLN_MAP_DEBUG_STENCIL_CLIP = 1U << 6U,
96 MLN_MAP_DEBUG_DEPTH_BUFFER = 1U << 7U,
101 MLN_NORTH_ORIENTATION_UP = 0,
102 MLN_NORTH_ORIENTATION_RIGHT = 1,
103 MLN_NORTH_ORIENTATION_DOWN = 2,
104 MLN_NORTH_ORIENTATION_LEFT = 3,
109 MLN_CONSTRAIN_MODE_NONE = 0,
110 MLN_CONSTRAIN_MODE_HEIGHT_ONLY = 1,
111 MLN_CONSTRAIN_MODE_WIDTH_AND_HEIGHT = 2,
112 MLN_CONSTRAIN_MODE_SCREEN = 3,
117 MLN_VIEWPORT_MODE_DEFAULT = 0,
118 MLN_VIEWPORT_MODE_FLIPPED_Y = 1,
123 MLN_MAP_VIEWPORT_OPTION_NORTH_ORIENTATION = 1U << 0U,
124 MLN_MAP_VIEWPORT_OPTION_CONSTRAIN_MODE = 1U << 1U,
125 MLN_MAP_VIEWPORT_OPTION_VIEWPORT_MODE = 1U << 2U,
126 MLN_MAP_VIEWPORT_OPTION_FRUSTUM_OFFSET = 1U << 3U,
131 MLN_TILE_LOD_MODE_DEFAULT = 0,
132 MLN_TILE_LOD_MODE_DISTANCE = 1,
137 MLN_MAP_TILE_OPTION_PREFETCH_ZOOM_DELTA = 1U << 0U,
138 MLN_MAP_TILE_OPTION_LOD_MIN_RADIUS = 1U << 1U,
139 MLN_MAP_TILE_OPTION_LOD_SCALE = 1U << 2U,
140 MLN_MAP_TILE_OPTION_LOD_PITCH_THRESHOLD = 1U << 3U,
141 MLN_MAP_TILE_OPTION_LOD_ZOOM_SHIFT = 1U << 4U,
142 MLN_MAP_TILE_OPTION_LOD_MODE = 1U << 5U,
205 double center_altitude;
220 double field_of_view;
336 MLN_GEOMETRY_TYPE_EMPTY = 0,
337 MLN_GEOMETRY_TYPE_POINT = 1,
338 MLN_GEOMETRY_TYPE_LINE_STRING = 2,
339 MLN_GEOMETRY_TYPE_POLYGON = 3,
340 MLN_GEOMETRY_TYPE_MULTI_POINT = 4,
341 MLN_GEOMETRY_TYPE_MULTI_LINE_STRING = 5,
342 MLN_GEOMETRY_TYPE_MULTI_POLYGON = 6,
343 MLN_GEOMETRY_TYPE_GEOMETRY_COLLECTION = 7,
350 size_t coordinate_count;
371 size_t polygon_count;
378 size_t geometry_count;
407 MLN_JSON_VALUE_TYPE_NULL = 0,
408 MLN_JSON_VALUE_TYPE_BOOL = 1,
409 MLN_JSON_VALUE_TYPE_UINT = 2,
410 MLN_JSON_VALUE_TYPE_INT = 3,
411 MLN_JSON_VALUE_TYPE_DOUBLE = 4,
412 MLN_JSON_VALUE_TYPE_STRING = 5,
413 MLN_JSON_VALUE_TYPE_ARRAY = 6,
414 MLN_JSON_VALUE_TYPE_OBJECT = 7,
464 MLN_FEATURE_STATE_SELECTOR_SOURCE_LAYER_ID = 1U << 0U,
465 MLN_FEATURE_STATE_SELECTOR_FEATURE_ID = 1U << 1U,
466 MLN_FEATURE_STATE_SELECTOR_STATE_KEY = 1U << 2U,
486 MLN_FEATURE_IDENTIFIER_TYPE_NULL = 0,
487 MLN_FEATURE_IDENTIFIER_TYPE_UINT = 1,
488 MLN_FEATURE_IDENTIFIER_TYPE_INT = 2,
489 MLN_FEATURE_IDENTIFIER_TYPE_DOUBLE = 3,
490 MLN_FEATURE_IDENTIFIER_TYPE_STRING = 4,
503 size_t property_count;
516 MLN_GEOJSON_TYPE_GEOMETRY = 1,
517 MLN_GEOJSON_TYPE_FEATURE = 2,
518 MLN_GEOJSON_TYPE_FEATURE_COLLECTION = 3,
525 size_t feature_count;
583 bool include_ideographs;
600 bool include_ideographs;
617 mln_offline_region_id id;
622 size_t metadata_size;
644 const uint8_t* metadata,
size_t metadata_size,
664 mln_runtime* runtime, mln_offline_region_id region_id,
698 mln_runtime* runtime,
const char* side_database_path,
717 mln_runtime* runtime, mln_offline_region_id region_id,
718 const uint8_t* metadata,
size_t metadata_size,
734 mln_runtime* runtime, mln_offline_region_id region_id,
755 mln_runtime* runtime, mln_offline_region_id region_id,
bool observed,
777 mln_runtime* runtime, mln_offline_region_id region_id, uint32_t state,
795 mln_runtime* runtime, mln_offline_region_id region_id,
813 mln_runtime* runtime, mln_offline_region_id region_id,
839 mln_offline_region_snapshot** out_region
864 mln_offline_region_snapshot** out_region,
bool* out_found
888 mln_offline_region_list** out_regions
912 mln_offline_region_list** out_regions
937 mln_offline_region_snapshot** out_region
982 mln_offline_region_snapshot* snapshot
995 const mln_offline_region_list* list,
size_t* out_count
1011 const mln_offline_region_list* list,
size_t index,
1017 mln_offline_region_list* list
1069 double lod_min_radius;
1071 double lod_pitch_threshold;
1072 double lod_zoom_shift;
1096 mln_runtime* runtime,
const mln_map_options* options, mln_map** out_map
1119 mln_map* map, uint32_t* out_width, uint32_t* out_height,
1120 double* out_scale_factor
mln_status
Definition base.h:39
void mln_offline_region_list_destroy(mln_offline_region_list *list)
mln_geometry_type
Definition map.h:335
mln_status mln_offline_region_list_count(const mln_offline_region_list *list, size_t *out_count)
mln_geojson_type
Definition map.h:515
mln_status mln_runtime_offline_region_set_download_state_start(mln_runtime *runtime, mln_offline_region_id region_id, uint32_t state, mln_offline_operation_id *out_operation_id)
mln_map_mode
Definition map.h:146
@ MLN_MAP_MODE_STATIC
Definition map.h:150
@ MLN_MAP_MODE_TILE
Definition map.h:152
@ MLN_MAP_MODE_CONTINUOUS
Definition map.h:148
mln_status mln_runtime_offline_region_create_take_result(mln_runtime *runtime, mln_offline_operation_id operation_id, mln_offline_region_snapshot **out_region)
mln_feature_identifier_type
Definition map.h:485
mln_status mln_map_get_size(mln_map *map, uint32_t *out_width, uint32_t *out_height, double *out_scale_factor)
mln_status mln_runtime_offline_region_delete_start(mln_runtime *runtime, mln_offline_region_id region_id, mln_offline_operation_id *out_operation_id)
mln_status mln_runtime_offline_region_get_status_start(mln_runtime *runtime, mln_offline_region_id region_id, mln_offline_operation_id *out_operation_id)
mln_status mln_map_request_repaint(mln_map *map)
mln_status mln_offline_region_list_get(const mln_offline_region_list *list, size_t index, mln_offline_region_info *out_info)
mln_status mln_runtime_offline_region_update_metadata_start(mln_runtime *runtime, mln_offline_region_id region_id, const uint8_t *metadata, size_t metadata_size, mln_offline_operation_id *out_operation_id)
mln_map_options mln_map_options_default(void)
mln_feature_state_selector_field
Definition map.h:463
mln_status mln_runtime_offline_regions_merge_database_start(mln_runtime *runtime, const char *side_database_path, mln_offline_operation_id *out_operation_id)
mln_status mln_runtime_offline_region_get_take_result(mln_runtime *runtime, mln_offline_operation_id operation_id, mln_offline_region_snapshot **out_region, bool *out_found)
mln_status mln_runtime_offline_regions_merge_database_take_result(mln_runtime *runtime, mln_offline_operation_id operation_id, mln_offline_region_list **out_regions)
mln_camera_option_field
Definition map.h:25
mln_viewport_mode
Definition map.h:116
mln_projection_mode_field
Definition map.h:82
mln_status mln_runtime_offline_region_get_status_take_result(mln_runtime *runtime, mln_offline_operation_id operation_id, mln_offline_region_status *out_status)
mln_camera_fit_option_field
Definition map.h:47
void mln_offline_region_snapshot_destroy(mln_offline_region_snapshot *snapshot)
mln_tile_lod_mode
Definition map.h:130
mln_status mln_runtime_offline_regions_list_take_result(mln_runtime *runtime, mln_offline_operation_id operation_id, mln_offline_region_list **out_regions)
mln_status mln_map_set_style_url(mln_map *map, const char *url)
mln_status mln_runtime_offline_region_invalidate_start(mln_runtime *runtime, mln_offline_region_id region_id, mln_offline_operation_id *out_operation_id)
mln_bound_option_field
Definition map.h:54
@ MLN_BOUND_OPTION_UNBOUNDED
Definition map.h:72
@ MLN_BOUND_OPTION_BOUNDS
Definition map.h:60
mln_status mln_map_destroy(mln_map *map)
mln_map_viewport_option_field
Definition map.h:122
mln_animation_option_field
Definition map.h:38
mln_constrain_mode
Definition map.h:108
mln_map_tile_option_field
Definition map.h:136
mln_status mln_runtime_offline_regions_list_start(mln_runtime *runtime, mln_offline_operation_id *out_operation_id)
mln_status mln_map_request_still_image(mln_map *map)
mln_json_value_type
Definition map.h:406
mln_map_debug_option
Definition map.h:89
mln_north_orientation
Definition map.h:100
mln_status mln_runtime_offline_region_set_observed_start(mln_runtime *runtime, mln_offline_region_id region_id, bool observed, mln_offline_operation_id *out_operation_id)
mln_status mln_runtime_offline_region_update_metadata_take_result(mln_runtime *runtime, mln_offline_operation_id operation_id, mln_offline_region_snapshot **out_region)
mln_status mln_map_create(mln_runtime *runtime, const mln_map_options *options, mln_map **out_map)
mln_status mln_runtime_offline_region_get_start(mln_runtime *runtime, mln_offline_region_id region_id, mln_offline_operation_id *out_operation_id)
mln_free_camera_option_field
Definition map.h:76
mln_status mln_runtime_offline_region_create_start(mln_runtime *runtime, const mln_offline_region_definition *definition, const uint8_t *metadata, size_t metadata_size, mln_offline_operation_id *out_operation_id)
mln_status mln_offline_region_snapshot_get(const mln_offline_region_snapshot *snapshot, mln_offline_region_info *out_info)
mln_status mln_map_set_style_json(mln_map *map, const char *json)
uint64_t mln_offline_operation_id
Definition runtime.h:51
double duration_ms
Definition map.h:243
double velocity
Definition map.h:248
double min_zoom
Definition map.h:250
uint64_t transition_id
Definition map.h:280
mln_lat_lng_bounds bounds
Definition map.h:563
mln_screen_point anchor
Definition map.h:215
const mln_lat_lng * coordinates
Definition map.h:349
const mln_feature * features
Definition map.h:524
mln_string_view source_id
Definition map.h:474
mln_string_view source_layer_id
Definition map.h:476
mln_string_view feature_id
Definition map.h:479
mln_string_view state_key
Definition map.h:481
uint32_t identifier_type
Definition map.h:505
const mln_json_member * properties
Definition map.h:502
const mln_geometry * geometry
Definition map.h:500
const mln_feature * feature
Definition map.h:547
const mln_geometry * geometry
Definition map.h:542
uint32_t type
Definition map.h:536
const mln_geometry * geometries
Definition map.h:377
uint32_t type
Definition map.h:393
const mln_json_value * values
Definition map.h:420
const mln_json_value * value
Definition map.h:428
const mln_json_member * members
Definition map.h:434
uint32_t type
Definition map.h:450
double longitude
Definition map.h:321
double latitude
Definition map.h:319
uint32_t height
Definition map.h:169
uint32_t map_mode
Definition map.h:182
double scale_factor
Definition map.h:180
uint32_t width
Definition map.h:167
uint32_t lod_mode
Definition map.h:1074
uint32_t prefetch_zoom_delta
Definition map.h:1068
uint32_t viewport_mode
Definition map.h:1059
uint32_t north_orientation
Definition map.h:1055
uint32_t constrain_mode
Definition map.h:1057
const mln_coordinate_span * lines
Definition map.h:363
const mln_polygon_geometry * polygons
Definition map.h:370
const mln_geometry * geometry
Definition map.h:592
const char * style_url
Definition map.h:590
double max_zoom
Definition map.h:598
uint32_t type
Definition map.h:607
const uint8_t * metadata
Definition map.h:621
const char * style_url
Definition map.h:574
double max_zoom
Definition map.h:581
const mln_coordinate_span * rings
Definition map.h:356
double northing
Definition map.h:1028
double easting
Definition map.h:1030
double x_skew
Definition map.h:1045
bool axonometric
Definition map.h:1043
double y_skew
Definition map.h:1047
const char * data
Definition map.h:327