SourceXtractorPlusPlus  0.16
Please provide a description of the project.
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
SourceXtractor::ImageTile Class Referenceabstract

#include <ImageTile.h>

Inheritance diagram for SourceXtractor::ImageTile:
[legend]
Collaboration diagram for SourceXtractor::ImageTile:
[legend]

Public Types

enum  ImageType {
  AutoType =-1 , FloatImage =0 , DoubleImage , IntImage ,
  UIntImage , LongLongImage
}
 

Public Member Functions

virtual ~ImageTile ()=default
 
bool isPixelInTile (int x, int y) const
 
int getPosX () const
 
int getPosY () const
 
virtual int getTileMemorySize () const =0
 
int getWidth () const
 
int getHeight () const
 
template<typename T >
getValue (int x, int y) const
 
virtual void setValue (int x, int y, float value)=0
 
virtual void setValue (int x, int y, double value)=0
 
virtual void setValue (int x, int y, int value)=0
 
virtual void setValue (int x, int y, unsigned int value)=0
 
virtual void setValue (int x, int y, std::int64_t value)=0
 
virtual void * getDataPtr ()=0
 
void setModified (bool modified)
 
bool isModified () const
 
void saveIfModified ()
 
ImageType getType () const
 

Static Public Member Functions

static std::shared_ptr< ImageTilecreate (ImageType image_type, int x, int y, int width, int height, std::shared_ptr< ImageSource > source=nullptr)
 
static ImageType getTypeValue (float)
 
static ImageType getTypeValue (double)
 
static ImageType getTypeValue (int)
 
static ImageType getTypeValue (unsigned int)
 
static ImageType getTypeValue (std::int64_t)
 
static size_t getTypeSize (ImageType image_type)
 

Protected Member Functions

virtual void getValue (int x, int y, float &value) const =0
 
virtual void getValue (int x, int y, double &value) const =0
 
virtual void getValue (int x, int y, int &value) const =0
 
virtual void getValue (int x, int y, unsigned int &value) const =0
 
virtual void getValue (int x, int y, std::int64_t &value) const =0
 
 ImageTile (ImageType image_type, int x, int y, int width, int height, std::shared_ptr< ImageSource > source=nullptr)
 
 ImageTile (const ImageTile &)=delete
 
 ImageTile (ImageTile &&)=delete
 
ImageTileoperator= (const ImageTile &)=delete
 
ImageTileoperator= (ImageTile &&)=delete
 

Protected Attributes

bool m_modified
 
ImageType m_image_type
 
std::shared_ptr< ImageSourcem_source
 
int m_x
 
int m_y
 
int m_max_x
 
int m_max_y
 

Detailed Description

Definition at line 34 of file ImageTile.h.

Member Enumeration Documentation

◆ ImageType

Enumerator
AutoType 
FloatImage 
DoubleImage 
IntImage 
UIntImage 
LongLongImage 

Definition at line 37 of file ImageTile.h.

Constructor & Destructor Documentation

◆ ~ImageTile()

virtual SourceXtractor::ImageTile::~ImageTile ( )
virtualdefault

◆ ImageTile() [1/3]

SourceXtractor::ImageTile::ImageTile ( ImageType  image_type,
int  x,
int  y,
int  width,
int  height,
std::shared_ptr< ImageSource source = nullptr 
)
inlineprotected

Definition at line 141 of file ImageTile.h.

◆ ImageTile() [2/3]

SourceXtractor::ImageTile::ImageTile ( const ImageTile )
protecteddelete

◆ ImageTile() [3/3]

SourceXtractor::ImageTile::ImageTile ( ImageTile &&  )
protecteddelete

Member Function Documentation

◆ create()

std::shared_ptr< ImageTile > SourceXtractor::ImageTile::create ( ImageType  image_type,
int  x,
int  y,
int  width,
int  height,
std::shared_ptr< ImageSource source = nullptr 
)
static

◆ getDataPtr()

virtual void* SourceXtractor::ImageTile::getDataPtr ( )
pure virtual

◆ getHeight()

int SourceXtractor::ImageTile::getHeight ( ) const
inline

◆ getPosX()

int SourceXtractor::ImageTile::getPosX ( ) const
inline

◆ getPosY()

int SourceXtractor::ImageTile::getPosY ( ) const
inline

◆ getTileMemorySize()

virtual int SourceXtractor::ImageTile::getTileMemorySize ( ) const
pure virtual

◆ getType()

ImageType SourceXtractor::ImageTile::getType ( ) const
inline

Definition at line 130 of file ImageTile.h.

References m_image_type.

◆ getTypeSize()

static size_t SourceXtractor::ImageTile::getTypeSize ( ImageType  image_type)
inlinestatic

◆ getTypeValue() [1/5]

static ImageType SourceXtractor::ImageTile::getTypeValue ( double  )
inlinestatic

Definition at line 101 of file ImageTile.h.

References DoubleImage.

◆ getTypeValue() [2/5]

static ImageType SourceXtractor::ImageTile::getTypeValue ( float  )
inlinestatic

◆ getTypeValue() [3/5]

static ImageType SourceXtractor::ImageTile::getTypeValue ( int  )
inlinestatic

Definition at line 105 of file ImageTile.h.

References IntImage.

◆ getTypeValue() [4/5]

static ImageType SourceXtractor::ImageTile::getTypeValue ( std::int64_t  )
inlinestatic

Definition at line 113 of file ImageTile.h.

References LongLongImage.

◆ getTypeValue() [5/5]

static ImageType SourceXtractor::ImageTile::getTypeValue ( unsigned int  )
inlinestatic

Definition at line 109 of file ImageTile.h.

References UIntImage.

◆ getValue() [1/6]

template<typename T >
T SourceXtractor::ImageTile::getValue ( int  x,
int  y 
) const
inline

Definition at line 73 of file ImageTile.h.

References x, and y.

◆ getValue() [2/6]

virtual void SourceXtractor::ImageTile::getValue ( int  x,
int  y,
double &  value 
) const
protectedpure virtual

◆ getValue() [3/6]

virtual void SourceXtractor::ImageTile::getValue ( int  x,
int  y,
float &  value 
) const
protectedpure virtual

◆ getValue() [4/6]

virtual void SourceXtractor::ImageTile::getValue ( int  x,
int  y,
int &  value 
) const
protectedpure virtual

◆ getValue() [5/6]

virtual void SourceXtractor::ImageTile::getValue ( int  x,
int  y,
std::int64_t value 
) const
protectedpure virtual

◆ getValue() [6/6]

virtual void SourceXtractor::ImageTile::getValue ( int  x,
int  y,
unsigned int &  value 
) const
protectedpure virtual

◆ getWidth()

int SourceXtractor::ImageTile::getWidth ( ) const
inline

◆ isModified()

bool SourceXtractor::ImageTile::isModified ( ) const
inline

Definition at line 91 of file ImageTile.h.

References m_modified.

Referenced by saveIfModified().

◆ isPixelInTile()

bool SourceXtractor::ImageTile::isPixelInTile ( int  x,
int  y 
) const
inline

◆ operator=() [1/2]

ImageTile& SourceXtractor::ImageTile::operator= ( const ImageTile )
protecteddelete

◆ operator=() [2/2]

ImageTile& SourceXtractor::ImageTile::operator= ( ImageTile &&  )
protecteddelete

◆ saveIfModified()

void SourceXtractor::ImageTile::saveIfModified ( )

Definition at line 40 of file ImageTile.cpp.

References isModified(), m_source, and setModified().

Referenced by SourceXtractor::ImageTileWithType< T >::~ImageTileWithType().

Here is the call graph for this function:

◆ setModified()

void SourceXtractor::ImageTile::setModified ( bool  modified)
inline

Definition at line 87 of file ImageTile.h.

References m_modified.

Referenced by saveIfModified().

◆ setValue() [1/5]

virtual void SourceXtractor::ImageTile::setValue ( int  x,
int  y,
double  value 
)
pure virtual

◆ setValue() [2/5]

virtual void SourceXtractor::ImageTile::setValue ( int  x,
int  y,
float  value 
)
pure virtual

◆ setValue() [3/5]

virtual void SourceXtractor::ImageTile::setValue ( int  x,
int  y,
int  value 
)
pure virtual

◆ setValue() [4/5]

virtual void SourceXtractor::ImageTile::setValue ( int  x,
int  y,
std::int64_t  value 
)
pure virtual

◆ setValue() [5/5]

virtual void SourceXtractor::ImageTile::setValue ( int  x,
int  y,
unsigned int  value 
)
pure virtual

Member Data Documentation

◆ m_image_type

ImageType SourceXtractor::ImageTile::m_image_type
protected

Definition at line 151 of file ImageTile.h.

Referenced by getType().

◆ m_max_x

int SourceXtractor::ImageTile::m_max_x
protected

Definition at line 154 of file ImageTile.h.

Referenced by getWidth(), and isPixelInTile().

◆ m_max_y

int SourceXtractor::ImageTile::m_max_y
protected

Definition at line 154 of file ImageTile.h.

Referenced by getHeight(), and isPixelInTile().

◆ m_modified

bool SourceXtractor::ImageTile::m_modified
protected

Definition at line 150 of file ImageTile.h.

Referenced by isModified(), and setModified().

◆ m_source

std::shared_ptr<ImageSource> SourceXtractor::ImageTile::m_source
protected

Definition at line 152 of file ImageTile.h.

Referenced by saveIfModified().

◆ m_x

int SourceXtractor::ImageTile::m_x
protected

◆ m_y

int SourceXtractor::ImageTile::m_y
protected

The documentation for this class was generated from the following files: