MapLibre Native C API
Public C ABI for the MapLibre Native wrapper.
Loading...
Searching...
No Matches
base.h
Go to the documentation of this file.
1
5
6#ifndef MAPLIBRE_NATIVE_C_BASE_H
7#define MAPLIBRE_NATIVE_C_BASE_H
8
9#ifndef __cplusplus
10#include <stdbool.h>
11#endif
12
13#include <stddef.h>
14#include <stdint.h>
15
16#ifdef _WIN32
17#if defined(MLN_STATIC)
18#define MLN_API
19#elif defined(MLN_BUILDING_C)
20#define MLN_API __declspec(dllexport)
21#else
22#define MLN_API __declspec(dllimport)
23#endif
24#else
25#define MLN_API __attribute__((visibility("default")))
26#endif
27
28#ifdef __cplusplus
29#define MLN_NOEXCEPT noexcept
30#else
31#define MLN_NOEXCEPT
32#endif
33
34#ifdef __cplusplus
35extern "C" {
36#endif
37
53
55typedef enum mln_render_backend_flag : uint32_t {
56 MLN_RENDER_BACKEND_FLAG_METAL = 1u << 0u,
57 MLN_RENDER_BACKEND_FLAG_VULKAN = 1u << 1u,
58 MLN_RENDER_BACKEND_FLAG_OPENGL = 1u << 2u,
60
61typedef struct mln_runtime mln_runtime;
62typedef struct mln_map mln_map;
63typedef struct mln_map_projection mln_map_projection;
64typedef struct mln_offline_region_snapshot mln_offline_region_snapshot;
65typedef struct mln_offline_region_list mln_offline_region_list;
66typedef struct mln_json_snapshot mln_json_snapshot;
67typedef struct mln_resource_request_handle mln_resource_request_handle;
68typedef struct mln_render_session mln_render_session;
69typedef struct mln_wake_source mln_wake_source;
70
75MLN_API uint32_t mln_c_version(void) MLN_NOEXCEPT;
76
82MLN_API uint32_t mln_supported_render_backend_mask(void) MLN_NOEXCEPT;
83
84#ifdef __cplusplus
85}
86#endif
87
88#endif // MAPLIBRE_NATIVE_C_BASE_H
mln_status
Definition base.h:39
@ MLN_STATUS_NATIVE_ERROR
Definition base.h:51
@ MLN_STATUS_UNSUPPORTED
Definition base.h:49
@ MLN_STATUS_INVALID_STATE
Definition base.h:44
@ MLN_STATUS_WRONG_THREAD
Definition base.h:47
@ MLN_STATUS_INVALID_ARGUMENT
Definition base.h:42
mln_render_backend_flag
Definition base.h:55
uint32_t mln_supported_render_backend_mask(void)
uint32_t mln_c_version(void)