MIRA
|
#include <image/Img.h>
Classes | |
struct | ImgFormat |
Image storage format description (used e.g. More... | |
Public Member Functions | |
operator const cv::Mat & () const | |
cast operator to const cv::Mat More... | |
operator cv::Mat & () | |
cast operator to cv::Mat More... | |
ImgBase & | operator= (const ImgBase &other) |
Assignment operator, that usually makes a shallow copy of "other". More... | |
void | assignROI (const cv::Rect &roi, const ImgBase &other) |
Copies the content of other into the specified region of interest (ROI) of THIS image. More... | |
void | assignMask (const cv::Rect &roi, const ImgBase &other, const cv::Mat &mask) |
Copies the content of other into the specified region of interest (ROI) of THIS image, where mask has non-zero values. More... | |
void | assignPolygon (const cv::Rect &roi, const ImgBase &other, const Polygon2i &poly) |
Copies the content of other into the specified region of interest (ROI) of THIS image, in area covered by polygon. More... | |
bool | operator== (const cv::Mat &other) const |
Returns true if two images are equal. More... | |
bool | operator!= (const cv::Mat &other) const |
Returns true if two images are different. More... | |
const cv::Mat & | getMat () const |
Returns const access to internal data. More... | |
bool | empty () const |
returns true if internal Mat is empty More... | |
int | width () const |
int | height () const |
std::size_t | step () const |
Number of bytes from one row to the next. More... | |
std::size_t | bytesPerLine () const |
Returns the number of bytes per image line. More... | |
Size2i | size () const |
Returns size of image data. More... | |
int | depth () const |
Returns the bit-depth of the image E.g. More... | |
int | channels () const |
Returns the number of channels of this image. More... | |
bool | isEmpty () const |
returns true if internal Mat is empty More... | |
uint8 * | data () |
Returns pointer to underlying image data. More... | |
const uint8 * | data () const |
Returns const pointer to underlying image data. More... | |
uint8 * | data (int y) |
Returns pointer to underlying image data starting at scanline y. More... | |
const uint8 * | data (int y) const |
Returns const pointer to underlying image data starting at scanline y. More... | |
ImgFormat | format () const |
Return the storage format description. More... | |
void | resize (const Size2i &s) |
Resizes the image to the specified dimensions (without changing its type, i.e. More... | |
void | resize (int width, int height) |
Same as above method. More... | |
void | clear () |
Sets each pixel and each channel to zero. More... | |
TImg | clone () const |
Deep copy of image data. More... | |
std::size_t | total () const |
Returns the total size of the matrix (rows*cols) More... | |
template<typename Derived > | |
void | reflect (BinarySerializer< Derived > &r) |
reflect method for binaryStream serialization This method implements the reflection of width, height, type, and the actual image data serialization. More... | |
template<typename Derived > | |
void | reflect (BinaryDeserializer< Derived > &r) |
reflect method for binaryStream deserialization This method implements the reflection for width, height, type, and the image data deserialization. More... | |
void | reflect (JSONSerializer &r) |
reflect method for json serialization This method implements the reflection of general data like width, height and image format, but not the full image data. More... | |
Protected Member Functions | |
ImgBase () | |
base constructor internal data is empty. More... | |
ImgBase (const cv::Mat &data) | |
constructor to initialize internal data from cv::Mat More... | |
ImgBase (int width, int height, int type) | |
constructor initialize internal data with width, height, and type note: the image data is allocated but not initialized More... | |
ImgBase (const ImgBase &other) | |
Copy constructor, that creates a shallow copy. More... | |
Protected Attributes | |
cv::Mat | mData |
ImgBase class.
Base class implementing functionality for untyped Img<> template class and typed ImgTypedBase template classes. You should not directly create instances of this class. Therefore, the constructor is protected.
|
inlineprotected |
base constructor internal data is empty.
|
inlineprotected |
constructor initialize internal data with width, height, and type note: the image data is allocated but not initialized
Copy constructor, that creates a shallow copy.
Assignment operator, that usually makes a shallow copy of "other".
|
inline |
Copies the content of other into the specified region of interest (ROI) of THIS image.
Note, the number of rows and columns of "other" and "this" ROI must be equal.
|
inline |
Copies the content of other into the specified region of interest (ROI) of THIS image, where mask has non-zero values.
Note, the number of rows and columns of "other", "mask" and "this" ROI must be equal.
|
inline |
Copies the content of other into the specified region of interest (ROI) of THIS image, in area covered by polygon.
The result does not depend on cw/ccw order of polygon points. Note, the number of rows and columns of "other" and "this" ROI must be equal. Polygon points are relative to roi, any polygon points outside roi are ignored! (i.e.they must be >= 0, < roi width/height)!
|
inline |
Returns true if two images are equal.
this methods checks if two images are equal by comparing their dimensions, flags and pixel data (byte wise)
|
inline |
Returns true if two images are different.
See operator==
|
inline |
Returns const access to internal data.
|
inline |
returns true if internal Mat is empty
|
inline |
|
inline |
|
inline |
Number of bytes from one row to the next.
|
inline |
Returns the number of bytes per image line.
|
inline |
Returns size of image data.
|
inline |
Returns the bit-depth of the image E.g.
CV_8U, CV_8S, CV_16U, CV_16S, CV_32S, CV_32F, CV_64F
|
inline |
Returns the number of channels of this image.
Note: typed images also have a static enum value 'Channels'
|
inline |
returns true if internal Mat is empty
|
inline |
Returns pointer to underlying image data.
|
inline |
Returns const pointer to underlying image data.
|
inline |
Returns pointer to underlying image data starting at scanline y.
|
inline |
Returns const pointer to underlying image data starting at scanline y.
|
inline |
Return the storage format description.
|
inline |
Resizes the image to the specified dimensions (without changing its type, i.e.
channels and bit depth remains constant). The method does nothing, if the specified dimensions equal the current size of the image.
|
inline |
Same as above method.
|
inline |
Sets each pixel and each channel to zero.
|
inline |
Deep copy of image data.
|
inline |
Returns the total size of the matrix (rows*cols)
|
inline |
reflect method for binaryStream serialization This method implements the reflection of width, height, type, and the actual image data serialization.
|
inline |
reflect method for binaryStream deserialization This method implements the reflection for width, height, type, and the image data deserialization.
|
inline |
reflect method for json serialization This method implements the reflection of general data like width, height and image format, but not the full image data.
It enables a basic overview in a text visualization.
|
protected |