In file gfx/libmosaic/Mosaic.hxx:

template<class Format> class Mosaic::Raster

A class representing a single raster image.

Documentation

A class representing a single raster image. This is used by Texture2D to hold the contents of a modifiable texture in memory. @todo make this into a template based on pixel format.

Inheritance:

Raster - RasterBase


Public Methods

[more] Raster (int width, int height, vector<ValueType> v)
Create a new raster with the given content.
[more] Raster (int width = 0, int height = 0)
Create a new, empty raster initialized with zeroes
[more] ~Raster ()
Create an empty raster (size 0)
[more]Raster addBorder (int bwidth, ValueType color = Format::nullValue)
Get a new raster which has the same content as this, but with an added border.
[more]ValueType& operator() (int x, int y)
Access (read&write) to a specific pixel in the raster


Inherited from RasterBase:

Public Methods

ovirtual void* getPointer()
ovirtual RasterBase* clone()
ovirtual void setGLPixelModes()

o Raster(int width, int height, vector<ValueType> v)
Create a new raster with the given content. The content should be given in row-major ordering, i.e. v(x,y) = v[x + width*y]

o Raster(int width = 0, int height = 0)
Create a new, empty raster initialized with zeroes

o ~Raster()
Create an empty raster (size 0)

oRaster addBorder(int bwidth, ValueType color = Format::nullValue)
Get a new raster which has the same content as this, but with an added border.
Parameters:
bwidth - The width of the border to add, in pixels.
- color The color value to be placed in the border.
Returns:
The new raster.

oValueType& operator() (int x, int y)
Access (read&write) to a specific pixel in the raster


This class has no child classes.

Alphabetic index Hierarchy of classes



This page was generated with the help of DOC++.