SourceXtractorPlusPlus 1.0.3
SourceXtractor++, the next generation SExtractor
Loading...
Searching...
No Matches
SourceXtractor::ConstantImage< T > Class Template Reference

#include <ConstantImage.h>

Inheritance diagram for SourceXtractor::ConstantImage< T >:
Collaboration diagram for SourceXtractor::ConstantImage< T >:

Public Member Functions

virtual ~ConstantImage ()=default
std::string getRepr () const final
 Get a string identifying this image in a human readable manner.
int getHeight () const final
 Returns the height of the image in pixels.
int getWidth () const final
 Returns the width of the image in pixels.
std::shared_ptr< ImageChunk< T > > getChunk (int, int, int width, int height) const final
Public Member Functions inherited from SourceXtractor::Image< T >
virtual ~Image ()=default
 Destructor.
std::shared_ptr< ImageChunk< T > > getChunk (const PixelCoordinate &start, const PixelCoordinate &end) const
bool isInside (int x, int y) const
 Returns true if the given coordinates are inside the image bounds.

Static Public Member Functions

static std::shared_ptr< ConstantImage< T > > create (int width, int height, T constant_value)

Protected Member Functions

 ConstantImage (int width, int height, T constant_value)

Private Attributes

int m_width
int m_height
m_constant_value

Additional Inherited Members

Public Types inherited from SourceXtractor::Image< T >
using PixelType = T

Detailed Description

template<typename T>
class SourceXtractor::ConstantImage< T >

Definition at line 33 of file ConstantImage.h.

Constructor & Destructor Documentation

◆ ConstantImage()

template<typename T>
SourceXtractor::ConstantImage< T >::ConstantImage ( int width,
int height,
T constant_value )
inlineprotected

Definition at line 36 of file ConstantImage.h.

References m_constant_value, m_height, and m_width.

Referenced by create().

◆ ~ConstantImage()

template<typename T>
virtual SourceXtractor::ConstantImage< T >::~ConstantImage ( )
virtualdefault

Member Function Documentation

◆ create()

◆ getChunk()

template<typename T>
std::shared_ptr< ImageChunk< T > > SourceXtractor::ConstantImage< T >::getChunk ( int ,
int ,
int width,
int height ) const
inlinefinalvirtual

Implements SourceXtractor::Image< T >.

Definition at line 61 of file ConstantImage.h.

References SourceXtractor::UniversalImageChunk< T >::create(), and m_constant_value.

Here is the call graph for this function:

◆ getHeight()

template<typename T>
int SourceXtractor::ConstantImage< T >::getHeight ( ) const
inlinefinalvirtual

Returns the height of the image in pixels.

Implements SourceXtractor::Image< T >.

Definition at line 53 of file ConstantImage.h.

References m_height.

◆ getRepr()

template<typename T>
std::string SourceXtractor::ConstantImage< T >::getRepr ( ) const
inlinefinalvirtual

Get a string identifying this image in a human readable manner.

Implements SourceXtractor::Image< T >.

Definition at line 48 of file ConstantImage.h.

References m_constant_value, m_height, m_width, and std::to_string().

Here is the call graph for this function:

◆ getWidth()

template<typename T>
int SourceXtractor::ConstantImage< T >::getWidth ( ) const
inlinefinalvirtual

Returns the width of the image in pixels.

Implements SourceXtractor::Image< T >.

Definition at line 57 of file ConstantImage.h.

References m_width.

Member Data Documentation

◆ m_constant_value

template<typename T>
T SourceXtractor::ConstantImage< T >::m_constant_value
private

Definition at line 69 of file ConstantImage.h.

Referenced by ConstantImage(), getChunk(), and getRepr().

◆ m_height

template<typename T>
int SourceXtractor::ConstantImage< T >::m_height
private

Definition at line 68 of file ConstantImage.h.

Referenced by ConstantImage(), getHeight(), and getRepr().

◆ m_width

template<typename T>
int SourceXtractor::ConstantImage< T >::m_width
private

Definition at line 67 of file ConstantImage.h.

Referenced by ConstantImage(), getRepr(), and getWidth().


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