Skip to main content

render

Function render 

Source
pub fn render(
    style: &Value,
    sources: &SourceTiles,
    assets: &SymbolAssets,
    bbox: [f64; 4],
    width: u32,
    height: u32,
    ratio: f64,
) -> Result<RenderOutput, String>
Expand description

Render tiles (raw MVT bytes) with style over bbox at width × height. assets holds glyphs and sprite images for symbol layers (may be empty). Each tile carries its world-copy wrap (see covering_tiles). width and height are CSS pixels; the image is ratio times larger (MapLibre’s devicePixelRatio: same view and layout, drawn denser).