#include <OvImageAdapter.h>
Inheritance diagram for OvImageAdapter:

Public Types | |
| OV_DATA_UNKNOWN | |
| OV_DATA_UINT8 | |
| OV_DATA_INT8 | |
| OV_DATA_UINT16 | |
| OV_DATA_INT16 | |
| OV_DATA_UINT32 | |
| OV_DATA_INT32 | |
| OV_DATA_UINT64 | |
| OV_DATA_INT64 | |
| OV_DATA_FLOAT32 | |
| OV_DATA_DOUBLE64 | |
| enum | OvDataType { OV_DATA_UNKNOWN, OV_DATA_UINT8, OV_DATA_INT8, OV_DATA_UINT16, OV_DATA_INT16, OV_DATA_UINT32, OV_DATA_INT32, OV_DATA_UINT64, OV_DATA_INT64, OV_DATA_FLOAT32, OV_DATA_DOUBLE64 } |
Public Member Functions | |
| OvImageAdapter () | |
| virtual | ~OvImageAdapter () |
| virtual void | getSize (int &height, int &width, int &nColorChannels) const |
| virtual void | getDataType (OvImageAdapter::OvDataType &dataType) const |
| virtual double | getPixel (int row, int column, int channel) const =0 |
| virtual void | setPixel (double value, int row, int column, int channel)=0 |
Protected Attributes | |
| int | mHeight |
| int | mWidth |
| int | mChannels |
| OvDataType | mDataType |
The OvImageAdapter base class defines a very basic interface to an image which provides access to the dimensions and datatype of the image, and provides get and set methods to alter image pixels. A class derived from OvImageAdapter must implement the pixel get/set and information methods. Using OvImageAdapter objects, the library allows the user to interface with any image model. See the OpenCVImageAdapter or MatlabImageAdapter subclasses for interfacing examples.
Enumeration of allowed data types.
| OvImageAdapter::OvImageAdapter | ( | ) |
Default constructor with no parameters
| OvImageAdapter::~OvImageAdapter | ( | ) | [virtual] |
Destructor
| void OvImageAdapter::getDataType | ( | OvImageAdapter::OvDataType & | dataType | ) | const [virtual] |
Returns data type of image.
| dataType | data type of image (from enum OvDataType) |
| virtual double OvImageAdapter::getPixel | ( | int | row, | |
| int | column, | |||
| int | channel | |||
| ) | const [pure virtual] |
Returns a pixel value at a particular row, column and color channel. This is a pure virtual function.
| row | row of the image | |
| column | column of the image | |
| channel | channel of the image |
Implemented in MatlabImageAdapter, and OpenCVImageAdapter.
| void OvImageAdapter::getSize | ( | int & | height, | |
| int & | width, | |||
| int & | nColorChannels | |||
| ) | const [virtual] |
Returns height, width and number of color channels of image.
| height | height of image | |
| width | width of image | |
| nColorChannels | number of color channels of image |
| virtual void OvImageAdapter::setPixel | ( | double | value, | |
| int | row, | |||
| int | column, | |||
| int | channel | |||
| ) | [pure virtual] |
Sets a pixel value at a particular row, column and color channel. This is a pure virtual function.
| value | value to be set | |
| row | row of the image | |
| column | column of the image | |
| channel | channel of the image |
Implemented in MatlabImageAdapter, and OpenCVImageAdapter.
int OvImageAdapter::mChannels [protected] |
number of color channels (e.g., 1 for grayscale, 3 for RGB)
OvDataType OvImageAdapter::mDataType [protected] |
Data format of a pixel channel
int OvImageAdapter::mHeight [protected] |
height of the image
int OvImageAdapter::mWidth [protected] |
width of the image
1.4.7