Struct WritableRasterView

Non-owning writable semantic raster view.

struct WritableRasterView(T);

Plane order is logical band order.

Region coordinates belong to the resident descriptor-space coordinate system used by the stable PlaneDescriptor block.

The view owns neither descriptors nor pixel storage.

Properties

NameTypeDescription
empty[get] boolWhether the represented region has zero area.
height[get] size_tResident height.
planeCount[get] size_tNumber of logical planes/bands represented by this view.
region[get] Region2DResident descriptor-space region represented by this view.
width[get] size_tResident width.

Methods

NameDescription
tryRoi (relative, success) Attempts to create a writable child ROI relative to this view.
trySample (band, x, y, value) Attempts to read one logical sample.
trySetSample (band, x, y, value) Attempts to write one logical sample.

Example

Example using the default writable semantic capability.

import raster;
WritableRasterView!ubyte view;
assert(view.planeCount == 0);
assert(view.empty);