Img

Undocumented in source.

Constructors

this
this(uint width, uint height, bool noAlloc)
Undocumented in source.
this
this(uint width, uint height, ubyte[] data)
Undocumented in source.

Members

Functions

copy
Img!F copy()
Undocumented in source. Be warned that the author may not have intended to support it.
getPixel
Pixel getPixel(size_t x, size_t y, bool scaleToByte)
Undocumented in source. Be warned that the author may not have intended to support it.
opIndex
Pixel opIndex(size_t x, size_t y, bool scaleToByte)

Get the pixel at the given index. If scaleToByte is set, 16 bit formats will only return the high bytes, effectively reducing precision to 8bit.

resize
bool resize(uint newWidth, uint newHeight, ResizeAlgo algo)
Undocumented in source. Be warned that the author may not have intended to support it.
setPixel
void setPixel(size_t x, size_t y, Pixel p)
Undocumented in source. Be warned that the author may not have intended to support it.
setPixel
void setPixel(size_t x, size_t y, const(ubyte[]) data)
Undocumented in source. Be warned that the author may not have intended to support it.
setRow
void setRow(size_t y, const(ubyte[]) data)
Undocumented in source. Be warned that the author may not have intended to support it.
write
bool write(string filename, ImageFormat fmt)

Write this image to disk with the given filename. Format can be inferred from filename extension by default, or supplied explicitly.

Properties

bitDepth
const(uint) bitDepth [@property getter]
Undocumented in source. Be warned that the author may not have intended to support it.
height
const(uint) height [@property getter]
Undocumented in source. Be warned that the author may not have intended to support it.
pixelFormat
const(Px) pixelFormat [@property getter]
Undocumented in source. Be warned that the author may not have intended to support it.
pixels
const(ubyte[]) pixels [@property getter]
Undocumented in source. Be warned that the author may not have intended to support it.
pixels
ubyte[] pixels [@property getter]
Undocumented in source. Be warned that the author may not have intended to support it.
pixelsPtr
ubyte* pixelsPtr [@property getter]
Undocumented in source. Be warned that the author may not have intended to support it.
stride
const(int) stride [@property getter]
Undocumented in source. Be warned that the author may not have intended to support it.
width
const(uint) width [@property getter]
Undocumented in source. Be warned that the author may not have intended to support it.

Inherited Members

From Image

ResizeAlgo
enum ResizeAlgo
Undocumented in source.
opIndex
Pixel opIndex(size_t x, size_t y, bool scaleToByte)
Undocumented in source.
getPixel
Pixel getPixel(size_t x, size_t y, bool scaleToByte)
Undocumented in source.
setPixel
void setPixel(size_t x, size_t y, Pixel p)
Undocumented in source.
setPixel
void setPixel(size_t x, size_t y, const(ubyte[]) data)
Undocumented in source.
setRow
void setRow(size_t y, const(ubyte[]) data)
Undocumented in source.
copy
Image copy()
Undocumented in source.
resize
bool resize(uint newWidth, uint newHeight, ResizeAlgo algo)
Undocumented in source.
write
bool write(string filename, ImageFormat fmt)
Undocumented in source.
width
const(uint) width [@property getter]
Undocumented in source.
height
const(uint) height [@property getter]
Undocumented in source.
stride
const(int) stride [@property getter]
Undocumented in source.
bitDepth
const(uint) bitDepth [@property getter]
Undocumented in source.
pixelFormat
const(Px) pixelFormat [@property getter]
Undocumented in source.
pixels
const(ubyte[]) pixels [@property getter]
Undocumented in source.
pixels
ubyte[] pixels [@property getter]
Undocumented in source.
pixelsPtr
ubyte* pixelsPtr [@property getter]
Undocumented in source.

Meta