Buffer.view constructor

Buffer.view(
  1. Buffer buffer,
  2. Rect bounds
)

Creates a sub-buffer view into this grid within the given bounds.

The bounds must be within the grid's area.

Implementation

factory Buffer.view(Buffer buffer, Rect bounds) {
  return Buffer._(Grid.view(buffer, bounds));
}