Learn R Programming

vectra (version 0.6.2)

vec_build_overviews: Build overview pyramids for a .vec raster

Description

Appends n_levels - 1 reduced-resolution copies of the raster to the file. Each level is computed by 2x downsampling the previous level with the chosen kernel. Reading via vec_read_window(level = L) picks tiles at level L; the file's n_levels is updated in place.

Usage

vec_build_overviews(
  path,
  levels,
  resampling = c("average", "nearest", "bilinear", "mode", "gauss"),
  compression = c("fast", "balanced", "max")
)

Value

Invisible NULL.

Arguments

path

Path to a .vec raster file. The file is modified in place.

levels

Total levels including level 0 (so levels = 5 adds four overviews: levels 1..4). Must be in [2, 16].

resampling

One of "nearest", "average", "bilinear", "mode", "gauss". "average" is the right choice for continuous rasters; "mode" for categorical/land-cover.

compression

Compression effort for the new tiles. Defaults to "fast" because overview tiles are usually one-shot writes.