Update PMTiles docs & bump NDK version (#4278)

Co-authored-by: Bart Louwers <bart@emeel.net>
This commit is contained in:
Stephanie May
2026-07-14 15:12:05 -07:00
committed by GitHub
parent 247c776d26
commit 6c55cef8b0
15 changed files with 420 additions and 28 deletions

View File

@@ -89,10 +89,15 @@ class CustomStyleLayer: MLNCustomStyleLayer {
}
"""
var error: NSError?
let device = resource.device
let library = try? device?.makeLibrary(source: shaderSource, options: nil)
assert(library != nil, "Error compiling shaders: \(String(describing: error))")
var library: MTLLibrary? = nil
var shaderError: Error? = nil
do {
library = try device?.makeLibrary(source: shaderSource, options: nil)
} catch {
shaderError = error
}
assert(library != nil, "Error compiling shaders: \(String(describing: shaderError))")
let vertexFunction = library?.makeFunction(name: "vertexShader")
let fragmentFunction = library?.makeFunction(name: "fragmentShader")