Blender
V3.3
|
#include <Image.h>
Public Member Functions | |
FrsImage () | |
FrsImage (const FrsImage &brother) | |
FrsImage (unsigned w, unsigned h) | |
FrsImage (unsigned w, unsigned h, unsigned sw, unsigned sh, unsigned ox, unsigned oy) | |
FrsImage & | operator= (const FrsImage &brother) |
virtual | ~FrsImage () |
unsigned | width () const |
unsigned | height () const |
virtual float | pixel (unsigned x, unsigned y) const =0 |
virtual void | setArray (float *array, unsigned width, unsigned height, unsigned sw, unsigned sh, unsigned x, unsigned y, bool copy=true)=0 |
virtual float * | getArray ()=0 |
Protected Attributes | |
unsigned | _width |
unsigned | _height |
unsigned | _storedWidth |
unsigned | _storedHeight |
unsigned | _Ox |
unsigned | _Oy |
This class allows the storing of part of an image, while allowing a normal access to its pixel values. You can for example only a rectangle of sw*sh, whose lower-left corner is at (ox, oy), of an image of size w*h, and access these pixels using x,y coordinates specified in the whole image coordinate system.
Definition at line 28 of file freestyle/intern/image/Image.h.
|
inline |
Default constructor
Definition at line 31 of file freestyle/intern/image/Image.h.
References _height, _Ox, _Oy, _storedHeight, _storedWidth, and _width.
|
inline |
Copy constructor
Definition at line 42 of file freestyle/intern/image/Image.h.
References _height, _Ox, _Oy, _storedHeight, _storedWidth, and _width.
|
inline |
Builds an FrsImage from its width and height. The memory is allocated consequently.
Definition at line 55 of file freestyle/intern/image/Image.h.
References _height, _Ox, _Oy, _storedHeight, _storedWidth, _width, and w().
|
inline |
Builds a partial-storing image.
w | The width of the complete image |
h | The height of the complete image |
sw | The width of the rectangle that will actually be stored. |
sh | The height of the rectangle that will actually be stored. |
ox | The x-abscissa of the origin of the rectangle that will actually be stored. |
oy | The x-abscissa of the origin of the rectangle that will actually be stored. |
Definition at line 79 of file freestyle/intern/image/Image.h.
References _height, _Ox, _Oy, _storedHeight, _storedWidth, _width, sh, sw, and w().
|
inlinevirtual |
Destructor
Definition at line 102 of file freestyle/intern/image/Image.h.
|
pure virtual |
Returns the array containing the pixels values. Its size is sw*sh, i.e. potentially a smaller rectangular part of the complete image.
Implemented in Freestyle::GrayImage, and Freestyle::RGBImage.
|
inline |
Returns the height of the complete image
Definition at line 113 of file freestyle/intern/image/Image.h.
References _height.
Referenced by Freestyle::GaussianPyramid::BuildPyramid(), Freestyle::Controller::ComputeSteerableViewMap(), Freestyle::ImagePyramid::pixel(), Freestyle::SteerableViewMap::saveSteerableViewMap(), Freestyle::GrayImage::setArray(), and Freestyle::RGBImage::setArray().
Operator=
Definition at line 90 of file freestyle/intern/image/Image.h.
References _height, _Ox, _Oy, _storedHeight, _storedWidth, and _width.
|
pure virtual |
Returns the gray value for pixel x,y
Implemented in Freestyle::GrayImage, and Freestyle::RGBImage.
|
pure virtual |
Sets the array.
array | The array containing the values we wish to store. Its size is sw*sh. |
width | The width of the complete image |
height | The height of the complete image |
sw | The width of the rectangle that will actually be stored. |
sh | The height of the rectangle that will actually be stored. |
ox | The x-abscissa of the origin of the rectangle that will actually be stored. |
oy | The x-abscissa of the origin of the rectangle that will actually be stored. |
copy | If true, the array is copied, otherwise the pointer is copied |
Implemented in Freestyle::RGBImage, and Freestyle::GrayImage.
|
inline |
Returns the width of the complete image
Definition at line 107 of file freestyle/intern/image/Image.h.
References _width.
Referenced by Freestyle::GaussianPyramid::BuildPyramid(), Freestyle::Controller::ComputeSteerableViewMap(), Freestyle::ImagePyramid::pixel(), Freestyle::SteerableViewMap::saveSteerableViewMap(), Freestyle::GrayImage::setArray(), and Freestyle::RGBImage::setArray().
|
protected |
Definition at line 156 of file freestyle/intern/image/Image.h.
Referenced by FrsImage(), Freestyle::GrayImage::GrayImage(), height(), operator=(), Freestyle::RGBImage::RGBImage(), Freestyle::GrayImage::setArray(), and Freestyle::RGBImage::setArray().
|
protected |
Definition at line 159 of file freestyle/intern/image/Image.h.
Referenced by FrsImage(), Freestyle::RGBImage::getB(), Freestyle::RGBImage::getG(), Freestyle::RGBImage::getR(), operator=(), Freestyle::RGBImage::pixel(), Freestyle::GrayImage::pixel(), Freestyle::GrayImage::setArray(), Freestyle::RGBImage::setArray(), Freestyle::RGBImage::setPixel(), and Freestyle::GrayImage::setPixel().
|
protected |
Definition at line 160 of file freestyle/intern/image/Image.h.
Referenced by FrsImage(), Freestyle::RGBImage::getB(), Freestyle::RGBImage::getG(), Freestyle::RGBImage::getR(), operator=(), Freestyle::RGBImage::pixel(), Freestyle::GrayImage::pixel(), Freestyle::GrayImage::setArray(), Freestyle::RGBImage::setArray(), Freestyle::RGBImage::setPixel(), and Freestyle::GrayImage::setPixel().
|
protected |
Definition at line 158 of file freestyle/intern/image/Image.h.
Referenced by FrsImage(), Freestyle::GrayImage::GrayImage(), operator=(), Freestyle::GrayImage::operator=(), Freestyle::RGBImage::operator=(), Freestyle::RGBImage::RGBImage(), Freestyle::GrayImage::setArray(), and Freestyle::RGBImage::setArray().
|
protected |
Definition at line 157 of file freestyle/intern/image/Image.h.
Referenced by FrsImage(), Freestyle::RGBImage::getB(), Freestyle::RGBImage::getG(), Freestyle::RGBImage::getR(), Freestyle::GrayImage::GrayImage(), operator=(), Freestyle::GrayImage::operator=(), Freestyle::RGBImage::operator=(), Freestyle::RGBImage::pixel(), Freestyle::GrayImage::pixel(), Freestyle::RGBImage::RGBImage(), Freestyle::GrayImage::setArray(), Freestyle::RGBImage::setArray(), Freestyle::RGBImage::setPixel(), and Freestyle::GrayImage::setPixel().
|
protected |
Definition at line 155 of file freestyle/intern/image/Image.h.
Referenced by FrsImage(), Freestyle::GrayImage::GrayImage(), operator=(), Freestyle::RGBImage::RGBImage(), Freestyle::GrayImage::setArray(), Freestyle::RGBImage::setArray(), and width().