Skip to contents

vaster 0.7.0

  • New lattice-alignment functions, folded in from the mdsumner/align sketch: is_aligned(), grid_offset(), snap_grid(), resize_grid() and grid_tiles(). Two grids are aligned when their resolutions are commensurate and their origins differ by a whole number of the finer cells; the functions refuse to proceed otherwise, so index arithmetic between aligned grids is exact. One tolerance policy (sqrt(.Machine$double.eps), relative) is used throughout. The align design doc is at inst/design-docs/align-design.md, and these functions are documented in the new “Lattice Alignment & Tiling” vignette.

  • Fixed: extent_vrt() took ymin from the first (top) row and ymax from the last row, so ymin > ymax for every tile, and used cell centres as edges, so each tile was half a cell short on every side. The bundled NASADEM example hid the second problem (3601 px tiles with a one-pixel overlap put the end centres on whole degrees) and plot_extent()/rect() is indifferent to corner order. Now uses the end-cell centres pushed out by half a cell, with y taken the right way round.

vaster 0.6.0

CRAN release: 2026-03-10

  • New function adjacency() for cell-based neighbourhood lookup, replacing the old matrix shift functions (tl(), bl(), tr(), br(), la(), ta(), ra(), ba()). The new function takes dimension and cell arguments consistent with the rest of vaster, returning a matrix of neighbour cell indices with named columns for direction. Supports "queen", "rook", and "bishop" neighbourhood types.

  • Renamed ts() and te() to gdal_ts() and gdal_te() to avoid masking stats::ts().

vaster 0.5.0

  • We now have internal functions col_from_x_c() and row_from_y_c(), x_from_col_c() and y_from_row_c() that use C under the hood, these currently accept and return 0-based indexes.

  • Package now requires compilation, with the R C api.

vaster 0.0.2

  • Speed up x_from_col and y_from_row, fixes #19.

  • New functions rasterio_idx() (was affinity::raster_to_rasterio), rasterio0 (was affinity::raster_io0) and internal for now rasterio_crop().

differences are - no raster objects - arguments dimension, extent as needed - there’s some overlap with vcrop and so on and needs checking - the sf RasterIO stuff now works well with {ximage} - fact and dimension need some thought for how the ux should be

vaster 0.0.1

  • New functions tl(), ta(), tr(), ra(), br(), ba(). br(), la() which are top left, top, top right, right, bottom right, bottom, bottom right, left. These are different from the affinity ones because they don’t keep the extra rows and columns (the variants in affinity might become options with these). The ‘a’ means adjacent, we can’t use t(), r(), l(), b() and top, right, left, bottom seems weird.

  • New function from_xyz() to return a grid (dimension and extent) derived from “XYZ” points, basically are the points (in whatever order, and may be incomplete) on a regular grid within the rounding threshold of the ‘digits’ parameter.

  • New functions ts(), te(), and ts_te() to format dimension,extent for use with GDAL options.

  • plot_extent() is now vectorized, just give it xmin, xmax, ymin, ymax in that order in vector, matrix, or data frame.

  • New function snap_extent() to replace spex::buffer_extent(), aliased to buffer_extent() in this package.

  • Better argument consistency, dimension first, then extent.

  • New function extent_vrt() to obtain tile extents from VRT text.

  • New function vaster_listxyz() to convert extent, dimension, and optionally data to trad image() format.

  • New function vaster_long() to convert extent, dimension, and optionally data to long form XYZ in raster or trad matrix order.

  • All obvious raster functions now included (needs more testing).

  • Version bump to allow {grout} to depend on vaster for cell and extent ops.

  • Added a NEWS.md file to track changes to the package.