Consolidate developer documentation in mdBook docs (#3115)
This commit is contained in:
@@ -2,7 +2,11 @@
|
||||
|
||||
## Build Locally
|
||||
|
||||
Get the `mdbook` utility, see https://rust-lang.github.io/mdBook/guide/installation.html
|
||||
Get the `mdbook` utility as well as [`mdbook-alerts`](https://github.com/lambdalisue/rs-mdbook-alerts), see https://rust-lang.github.io/mdBook/guide/installation.html
|
||||
|
||||
```
|
||||
cargo install mdbook mdbook-alerts
|
||||
```
|
||||
|
||||
Run
|
||||
|
||||
|
||||
@@ -3,7 +3,9 @@ authors = ["MapLibre Contributors"]
|
||||
language = "en"
|
||||
multilingual = false
|
||||
src = "src"
|
||||
title = "MapLibre Native Documentation"
|
||||
title = "MapLibre Native Developer Documentation"
|
||||
|
||||
[output.html]
|
||||
additional-css = ["diff.css"]
|
||||
|
||||
[preprocessor.alerts]
|
||||
|
||||
@@ -2,6 +2,16 @@
|
||||
|
||||
[Introduction](./introduction.md)
|
||||
|
||||
- [Platforms](./platforms.md)
|
||||
|
||||
- [Android](./android/README.md)
|
||||
- [Tests](./android/android-tests.md)
|
||||
- [Documentation](./android/android-documentation.md)
|
||||
|
||||
- [iOS](./ios/README.md)
|
||||
- [Tests](ios/ios-tests.md)
|
||||
- [Documentation](ios/ios-documentation.md)
|
||||
|
||||
- [Design](./design/README.md)
|
||||
- [Ten Thousand Foot View](design/ten-thousand-foot-view.md)
|
||||
- [Coordinate System](design/coordinate-system.md)
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Developing - MapLibre Native for Android
|
||||
# MapLibre Android Developer Guide
|
||||
|
||||
These instructions are for developers interested in making code-level contributions to MapLibre Native for Android.
|
||||
|
||||
@@ -33,34 +33,6 @@ Run the configuration for the `MapLibreAndroidTestApp` module and select a devic
|
||||
<img src="https://github.com/maplibre/maplibre-native/assets/649392/5494925e-8cbb-4d5d-8033-8a2f141ede3c" alt="Android TestApp menu" width="15%"> <img src="https://github.com/maplibre/maplibre-native/assets/649392/f169db51-615d-4fca-b297-ac6197bec674" alt="Android TestApp showing Demotiles" width="15%">
|
||||
</p>
|
||||
|
||||
## Render Tests
|
||||
|
||||
To run the render tests for Android, run the configuration for the `androidRenderTest.app` module.
|
||||
|
||||
More information on working on the render tests can be found [in the wiki](https://github.com/maplibre/maplibre-native/wiki/Working-on-Android-Render-Tests).
|
||||
|
||||
## Instrumentation Tests
|
||||
|
||||
To run the instrumentation tests, choose the "Instrumentation Tests" run configuration.
|
||||
|
||||
Your device needs remain unlocked for the duration of the tests.
|
||||
|
||||
## C++ Unit Tests
|
||||
|
||||
There is a separate Gradle project that contains a test app which runs the C++ Unit Tests. It does not depend on the Android platform implementations.
|
||||
|
||||
You can find the project in `test/android.` You can open this project in Android Studio and run the C++ Tests on an Android device or Simulator.
|
||||
|
||||
To run a particular set of tests you can modify the `--gtest_filter` flag in `platform/android/src/test/test_runner.cpp`. See the [GoogleTest documentation](https://google.github.io/googletest/advanced.html#running-a-subset-of-the-tests) for details how to use this flag.
|
||||
|
||||
### AWS Device Farm
|
||||
|
||||
The instrumentation tests and C++ unit tests are running on AWS Device Farm. To see the results and the logs, go to:
|
||||
|
||||
https://us-west-2.console.aws.amazon.com/devicefarm/home?region=us-east-1#/mobile/projects/20687d72-0e46-403e-8f03-0941850665bc/runs
|
||||
|
||||
You can log in with the `maplibre` alias, with `maplibre` as username and `maplibre` as password (this is a read-only account).
|
||||
|
||||
## Kotlin
|
||||
|
||||
All new code should be written in [Kotlin](https://kotlinlang.org/).
|
||||
@@ -91,11 +63,4 @@ To run the benchmarks (for Android) include the following line on a PR comment:
|
||||
|
||||
## Profiling
|
||||
|
||||
[maplibre-native/docs/mdbook](https://maplibre.org/maplibre-native/docs/book/) describes how Tracy can be used for profiling.
|
||||
|
||||
|
||||
## Documentation
|
||||
|
||||
We use Dokka for the API documentation.
|
||||
|
||||
The documentation site with examples uses MkDocs along with Material for MkDocs. For more information on how to work on the examples, see [`docs/README.md`](./docs/REAME.md`).
|
||||
See [Tracy Profiling](/profiling/tracy-profiling.md) to understand how Tracy can be used for profiling.
|
||||
49
docs/mdbook/src/android/android-documentation.md
Normal file
49
docs/mdbook/src/android/android-documentation.md
Normal file
@@ -0,0 +1,49 @@
|
||||
# Documentation for MapLibre Android
|
||||
|
||||
## API Documentation
|
||||
|
||||
We use Dokka for the MapLibre Android API documentation. The live documentation site can be found [here](https://maplibre.org/maplibre-native/android/api/).
|
||||
|
||||
## Examples Documentation
|
||||
|
||||
The documentation site with examples uses MkDocs along with [Material for MkDocs](https://squidfunk.github.io/mkdocs-material/). You can check out the site [here](https://maplibre.org/maplibre-native/android/examples/).
|
||||
|
||||
### Building
|
||||
|
||||
To build the Examples Documentation you need to have Docker installed.
|
||||
|
||||
From `platform/android`, run:
|
||||
|
||||
```
|
||||
make mkdocs
|
||||
```
|
||||
|
||||
Next, visit [`http://localhost:8000/maplibre-native/android/examples/`](http://localhost:8000/maplibre-native/android/examples/).
|
||||
|
||||
### Snippets
|
||||
|
||||
We use [a Markdown extension for snippets](https://facelessuser.github.io/pymdown-extensions/extensions/snippets/#snippet-sections). This way code can be referenced instead of copy pasted into the documentation. This avoids code examples from becoming out of date or failing to compile. The syntax is as follows:
|
||||
|
||||
````kotlin
|
||||
// --8<-- [start:fun]
|
||||
fun double(x: Int): Int {
|
||||
return 2 * x
|
||||
}
|
||||
// --8<-- [end:fun]
|
||||
````
|
||||
|
||||
Next, you'll be able to reference that piece of code in Markdown like so:
|
||||
|
||||
```
|
||||
--8<-- "example.kt:fun"
|
||||
```
|
||||
|
||||
Where `example.kt` is the path to the file.
|
||||
|
||||
### Static Assets
|
||||
|
||||
Static assets are ideally uploaded to the [MapLibre Native S3 Bucket](https://maplibre-native.s3.eu-central-1.amazonaws.com/index.html#android-documentation-resources/).
|
||||
|
||||
Please open an issue with the ARN of your AWS account to get upload privileges.
|
||||
|
||||
You can use the macro `{{ s3_url("filename.example") }}` which will use a CDN instead of linking to the S3 bucket directly.
|
||||
91
docs/mdbook/src/android/android-tests.md
Normal file
91
docs/mdbook/src/android/android-tests.md
Normal file
@@ -0,0 +1,91 @@
|
||||
# MapLibre Android Tests
|
||||
|
||||
## Render Tests
|
||||
|
||||
To run the render tests for Android, run the configuration for the `androidRenderTest.app` module.
|
||||
|
||||
### Filtering Render Tests
|
||||
|
||||
You can filter the tests to run by passing a flag to the file `platform/android/src/test/render_test_runner.cpp`:
|
||||
|
||||
```cpp
|
||||
std::vector<std::string> arguments = {..., "-f", "background-color/literal"};
|
||||
```
|
||||
|
||||
### Viewing the Results
|
||||
|
||||
Once the application quits, use the Device Explorer to navigate to `/data/data/org.maplibre.render_test_runner/files`.
|
||||
|
||||
<img width="980" alt="image" src="https://github.com/maplibre/maplibre-native/assets/649392/0dc42d4a-6221-46b6-8352-1eb24d466e91">
|
||||
|
||||
Double click `android-render-test-runner-style.html`. Right click on the opened tab and select _Open In > Browser_. You should see that a single render test passed.
|
||||
|
||||
<img width="801" alt="image" src="https://github.com/maplibre/maplibre-native/assets/649392/33e88999-7787-492f-afd9-f5a3e3fd61f7">
|
||||
|
||||
Alternatively to download (and open) the results from the command line, use:
|
||||
|
||||
```
|
||||
adb shell "run-as org.maplibre.render_test_runner cat files/metrics/android-render-test-runner-style.html" > android-render-test-runner-style.html
|
||||
open android-render-test-runner-style.html
|
||||
```
|
||||
|
||||
### Updating the Render Tests
|
||||
|
||||
Now let's edit `metrics/integration/render-tests/background-color/literal/style.json`, change this line:
|
||||
|
||||
```
|
||||
"background-color": "red"
|
||||
```
|
||||
|
||||
to
|
||||
|
||||
```
|
||||
"background-color": "yellow"
|
||||
```
|
||||
|
||||
We need to make sure that the new `data.zip` with the data for the render tests is installed on the device. You can use the following commands:
|
||||
|
||||
```
|
||||
tar chf render-test/android/app/src/main/assets/data.zip --format=zip --files-from=render-test/android/app/src/main/assets/to_zip.txt
|
||||
adb push render-test/android/app/src/main/assets/data.zip /data/local/tmp/data.zip
|
||||
adb shell chmod 777 /data/local/tmp/data.zip
|
||||
adb shell "run-as org.maplibre.render_test_runner unzip -o /data/local/tmp/data.zip -d files"
|
||||
```
|
||||
|
||||
Rerun the render test app and reload the Device Explorer. When you re-open the HTML file with the results you should now see a failing test:
|
||||
|
||||
<img width="685" alt="image" src="https://github.com/maplibre/maplibre-native/assets/649392/303ad75a-cf74-4b8c-927c-c9bd59a79de4">
|
||||
|
||||
Now download the `actual.png` in `metrics/integration/render-tests/background-color/literal` with the Device Explorer. Replace the corresponding `expected.png` on your local file system. Upload the new render test data again and run the test app once more.
|
||||
|
||||
<img width="800" alt="image" src="https://github.com/maplibre/maplibre-native/assets/649392/04734c6a-9cf1-489a-b9bb-8d857581261c">
|
||||
|
||||
Of we don't want to commit this change. But know you can add and debug (Android) render tests.
|
||||
|
||||
## Instrumentation Tests
|
||||
|
||||
To run the instrumentation tests, choose the "Instrumentation Tests" run configuration.
|
||||
|
||||
Your device needs remain unlocked for the duration of the tests.
|
||||
|
||||
## C++ Unit Tests
|
||||
|
||||
There is a separate Gradle project that contains a test app which runs the C++ Unit Tests. It does not depend on the Android platform implementations.
|
||||
|
||||
You can find the project in `test/android.` You can open this project in Android Studio and run the C++ Tests on an Android device or Simulator.
|
||||
|
||||
To run a particular set of tests you can modify the `--gtest_filter` flag in `platform/android/src/test/test_runner.cpp`. See the [GoogleTest documentation](https://google.github.io/googletest/advanced.html#running-a-subset-of-the-tests) for details how to use this flag.
|
||||
|
||||
### AWS Device Farm
|
||||
|
||||
The instrumentation tests and C++ unit tests are running on AWS Device Farm. To see the results and the logs, go to:
|
||||
|
||||
[https://us-west-2.console.aws.amazon.com/devicefarm/home?region=us-east-1#/mobile/projects/20687d72-0e46-403e-8f03-0941850665bc/runs](https://us-west-2.console.aws.amazon.com/devicefarm/home?region=us-east-1#/mobile/projects/20687d72-0e46-403e-8f03-0941850665bc/runs).
|
||||
|
||||
Use the following login details (this is a read-only account):
|
||||
|
||||
| | |
|
||||
|------------|------------|
|
||||
| Alias | `maplibre` |
|
||||
| Username | `maplibre` |
|
||||
| Password | `maplibre` |
|
||||
@@ -1,3 +1,6 @@
|
||||
> [!NOTE]
|
||||
> These notes are partially outdated since the [renderer modularization](https://github.com/maplibre/maplibre-native/blob/main/design-proposals/2022-10-27-rendering-modularization.md).
|
||||
|
||||
# Design
|
||||
|
||||
This section is dedicated to documenting current state of MapLibre Native. [Architectural Problems and Recommendations](./archictural-problems-and-recommendations.md) section notes recommendations for future improvements from an architectural perspective.
|
||||
This section is dedicated to documenting current state of MapLibre Native as of end 2022. [Architectural Problems and Recommendations](./archictural-problems-and-recommendations.md) section notes recommendations for future improvements from an architectural perspective.
|
||||
|
||||
@@ -3,3 +3,5 @@
|
||||
*[MapLibre Native](https://github.com/maplibre/maplibre-native)* is a community led fork of *Mapbox GL Native*. It's a C++ library that powers
|
||||
vector maps in native applications on multiple platforms by taking stylesheets that conform to the *[MapLibre Style Specification](https://maplibre.org/maplibre-style-spec/)*, a fork of the
|
||||
Mapbox Style Spec. Since it is derived from Mapbox's original work it also uses *Mapbox Vector Tile Specification* as its choice of vector tile format.
|
||||
|
||||
This documentation is intended for developers of MapLibre Native. If you are interested in *using* MapLibre Native, check out the [main `README.md`](https://github.com/maplibre/maplibre-native?tab=readme-ov-file#maplibre-native) on GitHub.
|
||||
|
||||
@@ -1,13 +1,4 @@
|
||||
# Contributing
|
||||
|
||||
## Downloading Source
|
||||
|
||||
Download the source and install all submodules if you have not already, by running the following from the root of the repository.
|
||||
|
||||
```
|
||||
git clone --recurse-submodules git@github.com:maplibre/maplibre-native.git
|
||||
cd maplibre-native
|
||||
```
|
||||
# MapLibre iOS Developer Guide
|
||||
|
||||
## Bazel
|
||||
|
||||
@@ -56,12 +47,22 @@ Try to run the example App in the simulator and on a device to confirm your setu
|
||||
> [!IMPORTANT]
|
||||
> The Bazel configuration files are the source of truth of the build configuration. All changes to the build settings need to be done through Bazel, not in Xcode.
|
||||
|
||||
### Troubleshooting Provisioning Profiles
|
||||
### Troubleshooting
|
||||
|
||||
#### Provisioning Profiles
|
||||
|
||||
If you get a Python `KeyError` when processing provisioning profiles, you probably have some _really_ old or corrupted profiles.
|
||||
|
||||
Have a look through `~/Library/MobileDevice/Provisioning\ Profiles` and remove any expired profiles. Removing all profiles here can also resolve some issues.
|
||||
|
||||
#### Cleaning Bazel environments
|
||||
|
||||
You should almost never have to do this, but sometimes problems can be solved with:
|
||||
|
||||
```
|
||||
bazel clean --expunge
|
||||
```
|
||||
|
||||
## Using Bazel from the Command Line
|
||||
|
||||
It is also possible to build and run the test application in a simulator from the command line without opening Xcode.
|
||||
@@ -72,75 +73,6 @@ bazel run //platform/ios:App --//:renderer=metal
|
||||
|
||||
You can also build targets from the command line. For example, if you want to build your own XCFramework, see the 'Build XCFramework' step in the [iOS CI workflow](../../.github/workflows/ios-ci.yml).
|
||||
|
||||
## Render Tests
|
||||
|
||||
To run the render tests, run the `RenderTest` target from iOS.
|
||||
|
||||
When running in a simulator, use
|
||||
|
||||
```
|
||||
# check for 'DataContainer' of the app with `*.maplibre.RenderTestApp` id
|
||||
xcrun simctl listapps booted
|
||||
```
|
||||
|
||||
to get the data directory of the render test app. This allows you to inspect test results. When adding new tests, the generated expectations and `actual.png` file can be copied into the source directory from here.
|
||||
|
||||
## C++ Unit Tests
|
||||
|
||||
Run the tests from the `CppUnitTests` target in Xcode to run the C++ Unit Tests on iOS.
|
||||
|
||||
## Swift App
|
||||
|
||||
There is also an example app built with Swift instead of Objective-C. The target is called `MapLibreApp` and the source code lives in `platform/ios/app-swift`.
|
||||
|
||||
## Documentation
|
||||
|
||||
We use [DocC](https://www.swift.org/documentation/docc) for documentation. You need to have [aws-cli](https://github.com/aws/aws-cli) installed to download the resources from S3 (see below). Run the following command:
|
||||
|
||||
```
|
||||
aws s3 sync --no-sign-request "s3://maplibre-native/ios-documentation-resources" "platform/ios/MapLibre.docc/Resources"
|
||||
```
|
||||
|
||||
Then, to build the documentation locally, run the following command:
|
||||
|
||||
```
|
||||
platform/ios/scripts/docc.sh preview
|
||||
```
|
||||
|
||||
### Resources
|
||||
|
||||
Resources like images should not be checked in but should be uploaded to the [S3 Bucket](https://s3.eu-central-1.amazonaws.com/maplibre-native/index.html#ios-documentation-resources/). You can share a `.zip` with all files that should be added in the PR.
|
||||
|
||||
If you want to get direct access you need an AWS account to get permissions to upload files. Create an account and authenticate with aws-cli. Share the account ARN that you can get with
|
||||
|
||||
```
|
||||
aws sts get-caller-identity
|
||||
```
|
||||
|
||||
### Examples
|
||||
|
||||
The code samples in the documentation should ideally be compiled on CI so they do not go out of date.
|
||||
|
||||
Fence your example code with
|
||||
|
||||
```swift
|
||||
// #-example-code(LineTapMap)
|
||||
...
|
||||
// #-end-example-code
|
||||
```
|
||||
|
||||
Prefix your documentation code block with
|
||||
|
||||
````md
|
||||
<!-- include-example(LineTapMap) -->
|
||||
|
||||
```swift
|
||||
...
|
||||
```
|
||||
````
|
||||
|
||||
Then the code block will be updated when you run:
|
||||
|
||||
```sh
|
||||
node scripts/update-ios-examples.mjs
|
||||
```
|
||||
53
docs/mdbook/src/ios/ios-documentation.md
Normal file
53
docs/mdbook/src/ios/ios-documentation.md
Normal file
@@ -0,0 +1,53 @@
|
||||
# iOS Documentation
|
||||
|
||||
We use [DocC](https://www.swift.org/documentation/docc) for the MapLibre iOS documentation. The live documentation site can be found [here](https://maplibre.org/maplibre-native/ios/latest/documentation/maplibre/).
|
||||
|
||||
## Resources
|
||||
|
||||
You need to have [aws-cli](https://github.com/aws/aws-cli) installed to download the resources from S3 (see below). Run the following command:
|
||||
|
||||
```
|
||||
aws s3 sync --no-sign-request "s3://maplibre-native/ios-documentation-resources" "platform/ios/MapLibre.docc/Resources"
|
||||
```
|
||||
|
||||
Then, to build the documentation locally, run the following command:
|
||||
|
||||
```
|
||||
platform/ios/scripts/docc.sh preview
|
||||
```
|
||||
|
||||
Resources like images should not be checked in but should be uploaded to the [S3 Bucket](https://s3.eu-central-1.amazonaws.com/maplibre-native/index.html#ios-documentation-resources/). You can share a `.zip` with all files that should be added in the PR.
|
||||
|
||||
If you want to get direct access you need an AWS account to get permissions to upload files. Create an account and authenticate with aws-cli. Share the account ARN that you can get with
|
||||
|
||||
```
|
||||
aws sts get-caller-identity
|
||||
```
|
||||
|
||||
## Examples
|
||||
|
||||
The code samples in the documentation should ideally be compiled on CI so they do not go out of date.
|
||||
|
||||
Fence your example code with
|
||||
|
||||
```swift
|
||||
// #-example-code(LineTapMap)
|
||||
...
|
||||
// #-end-example-code
|
||||
```
|
||||
|
||||
Prefix your documentation code block with
|
||||
|
||||
````md
|
||||
<!-- include-example(LineTapMap) -->
|
||||
|
||||
```swift
|
||||
...
|
||||
```
|
||||
````
|
||||
|
||||
Then the code block will be updated when you run:
|
||||
|
||||
```sh
|
||||
node scripts/update-ios-examples.mjs
|
||||
```
|
||||
18
docs/mdbook/src/ios/ios-tests.md
Normal file
18
docs/mdbook/src/ios/ios-tests.md
Normal file
@@ -0,0 +1,18 @@
|
||||
# iOS Tests
|
||||
|
||||
## Render Tests
|
||||
|
||||
To run the render tests, run the `RenderTest` target from iOS.
|
||||
|
||||
When running in a simulator, use
|
||||
|
||||
```
|
||||
# check for 'DataContainer' of the app with `*.maplibre.RenderTestApp` id
|
||||
xcrun simctl listapps booted
|
||||
```
|
||||
|
||||
to get the data directory of the render test app. This allows you to inspect test results. When adding new tests, the generated expectations and `actual.png` file can be copied into the source directory from here.
|
||||
|
||||
## C++ Unit Tests
|
||||
|
||||
Run the tests from the `CppUnitTests` target in Xcode to run the C++ Unit Tests on iOS.
|
||||
56
docs/mdbook/src/platforms.md
Normal file
56
docs/mdbook/src/platforms.md
Normal file
@@ -0,0 +1,56 @@
|
||||
|
||||
# Platforms
|
||||
|
||||
This page describes the platforms that MapLibre Native is available on.
|
||||
|
||||
## Overview
|
||||
|
||||
MapLibre Native uses a monorepo. Source code for all platforms lives in [`maplibre/maplibre-native`](https://github.com/maplibre/maplibre-native) on GitHub.
|
||||
|
||||
| Platform | Source | Notes |
|
||||
|---|---|---|
|
||||
| Android | [`platform/android`](https://github.com/maplibre/maplibre-native/tree/main/platform/android) | Integrates with the C++ core via JNI. |
|
||||
| iOS | [`platform/ios`](https://github.com/maplibre/maplibre-native/tree/main/platform/ios), [`platform/darwin`](https://github.com/maplibre/maplibre-native/tree/main/platform/darwin) | Integrates with the C++ core via Objective-C++. |
|
||||
| Linux | [`platform/linux`](https://github.com/maplibre/maplibre-native/tree/main/platform/linux) | Used for development. Also widely used in production for raster tile generation. |
|
||||
| Windows | [`platform/windows`](https://github.com/maplibre/maplibre-native/tree/main/platform/windows) | |
|
||||
| macOS | [`platform/macos`](https://github.com/maplibre/maplibre-native/tree/main/platform/macos), [`platform/darwin`](https://github.com/maplibre/maplibre-native/tree/main/platform/darwin) | Mainly used for development. There is some legacy AppKit code. |
|
||||
| Node.js | [`platform/node`](https://github.com/maplibre/maplibre-native/tree/main/platform/node) | Uses [NAN](https://github.com/nodejs/nan). Available as [@maplibre/maplibre-gl-native](https://www.npmjs.com/package/@maplibre/maplibre-gl-native) on npm. |
|
||||
| Qt | [maplibre/maplibre-qt](https://github.com/maplibre/maplibre-native/tree/main/platform/qt), [`platform/qt`](https://github.com/maplibre/maplibre-native) | Only platform that partially split to another repository. |
|
||||
|
||||
Of these, **Android** and **iOS** are considered [core projects](https://github.com/maplibre/maplibre/blob/main/PROJECT_TIERS.md) of the MapLibre Organization.
|
||||
### GLFW
|
||||
|
||||
You can find an app that uses GLFW in [`platform/glfw`](https://github.com/maplibre/maplibre-native/tree/main/platform/glfw). It works on macOS, Linux and Windows. The app shows an interactive map that can be interacted with. Since GLFW adds relatively little complexity this app is used a lot for development. You can also learn about the C++ API by studying the source code of the GLFW app.
|
||||
|
||||
## Rendering Backends
|
||||
|
||||
Originally the project only supported OpenGL 2.0. In 2023, the [renderer was modularized](https://github.com/maplibre/maplibre-native/blob/main/design-proposals/2022-10-27-rendering-modularization.md) allowing for the implementation of alternate rendering backends. The first alternate rendering backend that was implemented was [Metal](https://maplibre.org/news/2024-01-19-metal-support-for-maplibre-native-ios-is-here/), followed by [Vulkan](https://maplibre.org/news/2024-12-12-maplibre-android-vulkan/). In the future other rendering backends could be implemented such as WebGPU.
|
||||
|
||||
What platfroms support which rendering backend can be found below.
|
||||
|
||||
| Platform | OpenGL ES 3.0 | Vulkan 1.0 | Metal |
|
||||
|---|---|---|---|
|
||||
| Android | ✅ | ✅ | ❌ |
|
||||
| iOS | ❌ | ❌ | ✅ |
|
||||
| Linux | ✅ | ✅ | ❌ |
|
||||
| Windows | ✅ | ❌ | ❌ |
|
||||
| macOS | ❌ | ✅ | ✅[^1] |
|
||||
| Node.js | ✅ | ❌ | ✅ [^2] |
|
||||
| Qt | ✅ | ❌ | ❌ |
|
||||
|
||||
[^1]: Requires MoltenVK. Only available when built via CMake.
|
||||
[^2]: Issue reported, see [#2928](https://github.com/maplibre/maplibre-native/issues/2928).
|
||||
|
||||
## Build Tooling
|
||||
|
||||
In 2023 we co-opted Bazel as a build tool (generator), mostly due to it having better support for iOS compared to CMake. Some platforms can use CMake as well as Bazel.
|
||||
|
||||
| Platform | CMake | Bazel |
|
||||
|---|---|---|
|
||||
| Android | ✅ (via Gradle) | ❌ |
|
||||
| iOS | ❌ | ✅ |
|
||||
| Linux | ✅ | ✅ |
|
||||
| Windows | ✅ | ❌ |
|
||||
| macOS | ✅ | ✅ |
|
||||
| Node.js | ✅ | ❌ |
|
||||
| Qt | ✅ | ❌ |
|
||||
@@ -8,10 +8,14 @@ MapLibre Native for Android is a library for embedding interactive map views wit
|
||||
|
||||
Visit [https://maplibre.org/maplibre-native/android/examples/getting-started/](https://maplibre.org/maplibre-native/android/examples/getting-started/) to view the Getting Started Guide for MapLibre Native for Android.
|
||||
|
||||
## Documentation
|
||||
### Examples Documentation
|
||||
|
||||
Visit [https://maplibre.org/maplibre-native/android/api/](https://maplibre.org/maplibre-native/android/api/) to view the current API reference Javadoc files for MapLibre Native for Android.
|
||||
Visit [MapLibre Android Example](https://maplibre.org/maplibre-native/android/examples/) to learn how to use MapLibre Android.
|
||||
|
||||
## API Documentation
|
||||
|
||||
Visit [MapLibre Android Dokka Docs](https://maplibre.org/maplibre-native/android/api/) to view the current API reference for MapLibre Android.
|
||||
|
||||
## Contributing
|
||||
|
||||
See [`DEVELOPING.md`](./DEVELOPING.md) for instructions on how to get started working on the codebase.
|
||||
See the [MapLibre Android Developer Guide](https://maplibre.org/maplibre-native/docs/book/android) for instructions on how to build the project or how to work on the documentation.
|
||||
|
||||
@@ -11,4 +11,4 @@ Embed interactive maps with scalable, customizable vector maps into iOS Applicat
|
||||
|
||||
# Contributing
|
||||
|
||||
See [`CONTRIBUTING.md`](./CONTRIBUTING.md) for instructions on how to build the project or how to work on the documentation.
|
||||
See the [MapLibre iOS Developer Guide](https://maplibre.org/maplibre-native/docs/book/ios) for instructions on how to build the project or how to work on the documentation.
|
||||
|
||||
Reference in New Issue
Block a user