Image

An in-memory image. Pixels are stored in a flat array.

Constructors

this
this(xy_t w, xy_t h)
Undocumented in source.

Members

Functions

scanline
inout(StorageType)[] scanline(xy_t y)

Returns an array for the pixels at row y.

size
void size(xy_t w, xy_t h)

Does not scale image

Mixins

__anonymous
mixin DirectView
h
xy_t h;
Undocumented in source.

Variables

pixels
StorageType[] pixels;
Undocumented in source.
w
xy_t w;
Undocumented in source.

Mixed In Members

From mixin DirectView

StorageType
alias StorageType = Unqual!(typeof(scanline(0)[0]))
Undocumented in source.
COLOR
alias COLOR = Unqual!(typeof(StorageType.init[0]))
Undocumented in source.
opIndex
inout(COLOR) opIndex(xy_t x, xy_t y)

Implements the view[x, y] operator.

Row
struct Row

Allows array-like viewyx access.

opIndex
Row opIndex(xy_t y)
Undocumented in source. Be warned that the author may not have intended to support it.
opIndexAssign
COLOR opIndexAssign(COLOR value, xy_t x, xy_t y)

Implements the view[x, y] = c operator.

Meta