|
ContRap-Libraries
|
Class Image encapsulates (two-dimensional) images. More...
#include <image.h>
Data Structures | |
| class | LineIterator |
| Class LineIterator iterates over a line. More... | |
| class | PrimitiveIterator |
| PrimitiveIterator iterates over the pixels of a primitive. More... | |
| class | RectIterator |
| Class RectIterator iterates over a rectangle. More... | |
Public Member Functions | |
| Image (int width=0, int height=0) | |
| Constructs a new image. | |
| Image (const Image< T > &image) | |
| Copy constructor. | |
| virtual | ~Image () |
| Destructor clears memory. | |
| virtual void | destroy () |
| Destroys the current instance. | |
| virtual Object * | clone () |
| Returns a pointer to a semantical copy of the current object. | |
| virtual const std::string | get_type () |
| Returns the type of the object. | |
| void | subimage (int from_x, int from_y, Image< T > &image) |
| Computes a subimage with respect to a rectangular area. | |
| Image< T > & | operator= (const Image< T > &a) |
| Assignment operator. | |
| PrimitiveIterator * | iterator (Primitive2D *primitive) |
| Returns a primitive iterator corresponding to the to the given primitive or zero if no such iterator exists. | |
Protected Attributes | |
| int | width |
| Width of the image. | |
| int | height |
| Height of the image. | |
| T * | data |
| Data of the image. | |
| bool | own_data |
| Ownerstate of data. | |
| int | size |
| Size of data. | |
Class Image encapsulates (two-dimensional) images.
| crp::Image< T >::Image | ( | int | width = 0, |
| int | height = 0 |
||
| ) | [inline] |
Constructs a new image.
| width | Width of the image |
| height | Height of the image |
| crp::Image< T >::Image | ( | const Image< T > & | image | ) | [inline] |
Copy constructor.
| virtual crp::Image< T >::~Image | ( | ) | [inline, virtual] |
Destructor clears memory.
| virtual Object* crp::Image< T >::clone | ( | ) | [inline, virtual] |
Returns a pointer to a semantical copy of the current object.
Reimplemented from crp::Array< T >.
| virtual void crp::Image< T >::destroy | ( | ) | [inline, virtual] |
Destroys the current instance.
Reimplemented from crp::Array< T >.
| virtual const std::string crp::Image< T >::get_type | ( | ) | [inline, virtual] |
Returns the type of the object.
| PrimitiveIterator* crp::Image< T >::iterator | ( | Primitive2D * | primitive | ) | [inline] |
Returns a primitive iterator corresponding to the to the given primitive or zero if no such iterator exists.
| primitive | Primitive |
| Image<T>& crp::Image< T >::operator= | ( | const Image< T > & | a | ) | [inline] |
Assignment operator.
| void crp::Image< T >::subimage | ( | int | from_x, |
| int | from_y, | ||
| Image< T > & | image | ||
| ) | [inline] |
Computes a subimage with respect to a rectangular area.
| from_x | Start point X-Coordinate |
| from_y | Start point X-Coordinate |
| image | Target image |
T* crp::Image< T >::data [protected] |
Data of the image.
Reimplemented from crp::Array< T >.
int crp::Image< T >::height [protected] |
Height of the image.
Reimplemented from crp::Array< T >.
bool crp::Image< T >::own_data [protected] |
Ownerstate of data.
Reimplemented from crp::Array< T >.
int crp::Image< T >::size [protected] |
Size of data.
Reimplemented from crp::Array< T >.
int crp::Image< T >::width [protected] |
Width of the image.
Reimplemented from crp::Array< T >.
1.7.3