add_bitmap_layer: Add a bitmap layer to the deckgl widget

Description Usage Arguments Examples

View source: R/layers_bitmap-layer.R

Description

Add a bitmap layer to the deckgl widget

Usage

1
2
add_bitmap_layer(deckgl, id = "h3-hexagon-layer", image = NULL,
  properties = list(), ...)

Arguments

deckgl

A deckgl widget object.

id

The unique id of the layer.

image

image

properties

A named list of properties with names corresponding to the properties defined in the deckgl-api-reference for the given layer class.

...

More properties that will be added to the properties object. This can be useful if you want to use a properties object for more than one layer.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
image <- paste0(
  "https://raw.githubusercontent.com/",
  "uber-common/deck.gl-data/master/",
  "website/sf-districts.png"
)
bounds <- c(-122.5190, 37.7045, -122.355, 37.829)

deck <- deckgl() %>%
  add_bitmap_layer(image = image, bounds = bounds) %>%
  add_basemap()

if (interactive()) deck

deckgl documentation built on July 1, 2020, 7:36 p.m.