OTB  6.7.0
Orfeo Toolbox
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes | List of all members
otb::Rectangle< TValue > Class Template Reference

#include <otbRectangle.h>

+ Inheritance diagram for otb::Rectangle< TValue >:
+ Collaboration diagram for otb::Rectangle< TValue >:

Public Types

typedef itk::SmartPointer
< const Self
ConstPointer
 
typedef itk::ContinuousIndex
< ValueType, 2 > 
ContinuousIndexType
 
typedef itk::SmartPointer< SelfPointer
 
typedef itk::ImageRegion< 2 > RegionType
 
typedef Rectangle Self
 
typedef itk::Object Superclass
 
typedef TValue ValueType
 
typedef
VertexListType::ConstIterator 
VertexListConstIteratorType
 
typedef VertexListType::Pointer VertexListPointerType
 
typedef itk::VectorContainer
< unsigned, VertexType
VertexListType
 
typedef ContinuousIndexType VertexType
 
- Public Types inherited from itk::Object
typedef SmartPointer< const SelfConstPointer
 
typedef SmartPointer< SelfPointer
 
typedef Object Self
 
typedef LightObject Superclass
 
- Public Types inherited from itk::LightObject
typedef SmartPointer< const SelfConstPointer
 
typedef SmartPointer< SelfPointer
 
typedef LightObject Self
 

Public Member Functions

virtual void AddVertex (const ContinuousIndexType &vertex)
 
virtual ::itk::LightObject::Pointer CreateAnother (void) const
 
virtual const char * GetNameOfClass () const
 
virtual ValueType GetOrientation ()
 
virtual ValueType GetWidth ()
 
virtual void SetOrientation (ValueType _arg)
 
virtual void SetWidth (ValueType _arg)
 
bool IsInside (VertexType point) const
 
- Public Member Functions inherited from itk::Object
unsigned long AddObserver (const EventObject &event, Command *)
 
unsigned long AddObserver (const EventObject &event, Command *) const
 
virtual void DebugOff () const
 
virtual void DebugOn () const
 
CommandGetCommand (unsigned long tag)
 
bool GetDebug () const
 
const MetaDataDictionaryGetMetaDataDictionary () const
 
MetaDataDictionaryGetMetaDataDictionary ()
 
virtual ModifiedTimeType GetMTime () const
 
virtual const std::string & GetObjectName () const
 
virtual const TimeStampGetTimeStamp () const
 
bool HasObserver (const EventObject &event) const
 
void InvokeEvent (const EventObject &)
 
void InvokeEvent (const EventObject &) const
 
virtual void Modified () const
 
virtual void Register () const override
 
void RemoveAllObservers ()
 
void RemoveObserver (unsigned long tag)
 
void SetDebug (bool debugFlag) const
 
void SetMetaDataDictionary (const MetaDataDictionary &rhs)
 
virtual void SetObjectName (std::string _arg)
 
virtual void SetReferenceCount (int) override
 
virtual void UnRegister () const noexceptoverride
 
- Public Member Functions inherited from itk::LightObject
virtual void Delete ()
 
virtual int GetReferenceCount () const
 
 itkCloneMacro (Self)
 
void Print (std::ostream &os, Indent indent=0) const
 

Static Public Member Functions

static Pointer New ()
 
- Static Public Member Functions inherited from itk::Object
static bool GetGlobalWarningDisplay ()
 
static void GlobalWarningDisplayOff ()
 
static void GlobalWarningDisplayOn ()
 
static Pointer New ()
 
static void SetGlobalWarningDisplay (bool flag)
 
- Static Public Member Functions inherited from itk::LightObject
static void BreakOnError ()
 
static Pointer New ()
 

Protected Member Functions

virtual double ComputeEuclideanDistanceMetricToSegment (VertexType q1, VertexType q2, VertexType p) const
 
 ~Rectangle () override
 
 Rectangle ()
 
- Protected Member Functions inherited from itk::Object
 Object ()
 
bool PrintObservers (std::ostream &os, Indent indent) const
 
virtual void SetTimeStamp (const TimeStamp &time)
 
virtual ~Object ()
 
- Protected Member Functions inherited from itk::LightObject
virtual LightObject::Pointer InternalClone () const
 
 LightObject ()
 
virtual void PrintHeader (std::ostream &os, Indent indent) const
 
virtual void PrintTrailer (std::ostream &os, Indent indent) const
 
virtual ~LightObject ()
 

Private Member Functions

void operator= (const Self &)=delete
 
 Rectangle (const Self &)=delete
 

Private Attributes

ValueType m_Orientation
 
VertexListPointerType m_VertexList
 
ValueType m_Width
 
virtual RegionType GetBoundingRegion () const
 
void PrintSelf (std::ostream &os, itk::Indent indent) const override
 

Additional Inherited Members

- Protected Attributes inherited from itk::LightObject
AtomicInt< int > m_ReferenceCount
 

Detailed Description

template<class TValue = double>
class otb::Rectangle< TValue >

This class represent a Rectangle.

A rectangle is defined by the median of the width, an orientation and a width

Definition at line 39 of file otbRectangle.h.

Member Typedef Documentation

template<class TValue = double>
typedef itk::SmartPointer<const Self> otb::Rectangle< TValue >::ConstPointer

Definition at line 47 of file otbRectangle.h.

template<class TValue = double>
typedef itk::ContinuousIndex<ValueType, 2> otb::Rectangle< TValue >::ContinuousIndexType

Derived typedefs

Definition at line 55 of file otbRectangle.h.

template<class TValue = double>
typedef itk::SmartPointer<Self> otb::Rectangle< TValue >::Pointer

Definition at line 46 of file otbRectangle.h.

template<class TValue = double>
typedef itk::ImageRegion<2> otb::Rectangle< TValue >::RegionType

Definition at line 70 of file otbRectangle.h.

template<class TValue = double>
typedef Rectangle otb::Rectangle< TValue >::Self

Standard typedefs

Definition at line 44 of file otbRectangle.h.

template<class TValue = double>
typedef itk::Object otb::Rectangle< TValue >::Superclass

Definition at line 45 of file otbRectangle.h.

template<class TValue = double>
typedef TValue otb::Rectangle< TValue >::ValueType

Definition at line 49 of file otbRectangle.h.

template<class TValue = double>
typedef VertexListType::ConstIterator otb::Rectangle< TValue >::VertexListConstIteratorType

Definition at line 62 of file otbRectangle.h.

template<class TValue = double>
typedef VertexListType::Pointer otb::Rectangle< TValue >::VertexListPointerType

Definition at line 61 of file otbRectangle.h.

template<class TValue = double>
typedef itk::VectorContainer<unsigned, VertexType> otb::Rectangle< TValue >::VertexListType

Definition at line 60 of file otbRectangle.h.

template<class TValue = double>
typedef ContinuousIndexType otb::Rectangle< TValue >::VertexType

Definition at line 59 of file otbRectangle.h.

Constructor & Destructor Documentation

template<class TValue = double>
otb::Rectangle< TValue >::Rectangle ( )
inlineprotected

Constructor

Definition at line 97 of file otbRectangle.h.

template<class TValue = double>
otb::Rectangle< TValue >::~Rectangle ( )
inlineoverrideprotected

Destructor

Definition at line 104 of file otbRectangle.h.

template<class TValue = double>
otb::Rectangle< TValue >::Rectangle ( const Self )
privatedelete

Member Function Documentation

template<class TValue >
void otb::Rectangle< TValue >::AddVertex ( const ContinuousIndexType vertex)
virtual

Definition at line 200 of file otbRectangle.hxx.

template<class TValue >
double otb::Rectangle< TValue >::ComputeEuclideanDistanceMetricToSegment ( VertexType  q1,
VertexType  q2,
VertexType  p 
) const
protectedvirtual

Method to compute the distance between a point and a segment

distance from Point P to Segment Q1Q2

Definition at line 77 of file otbRectangle.hxx.

References CrossProduct().

template<class TValue = double>
virtual::itk::LightObject::Pointer otb::Rectangle< TValue >::CreateAnother ( void  ) const
virtual

Reimplemented from itk::Object.

template<class TValue >
Rectangle< TValue >::RegionType otb::Rectangle< TValue >::GetBoundingRegion ( ) const
virtual

GetBounding region

Method to compute the Bounding region of a rectangle

Compute the four corners of the recatangle

Compute the bounding region

Definition at line 102 of file otbRectangle.hxx.

References itk::Size< VDimension >::Fill(), itk::Index< VIndexDimension >::Fill(), itk::ImageRegion< VImageDimension >::SetIndex(), itk::ImageRegion< VImageDimension >::SetSize(), and itk::VectorContainer< TElementIdentifier, TElement >::ConstIterator::Value().

template<class TValue = double>
virtual const char* otb::Rectangle< TValue >::GetNameOfClass ( ) const
virtual

Creation through object factory macro

Reimplemented from itk::Object.

template<class TValue = double>
virtual ValueType otb::Rectangle< TValue >::GetOrientation ( )
virtual
template<class TValue = double>
virtual ValueType otb::Rectangle< TValue >::GetWidth ( )
virtual

Set/Get the parameters the a rectangle

  • width and orientation
template<class TValue >
bool otb::Rectangle< TValue >::IsInside ( VertexType  point) const

Check whether point is strictly inside the rectangle.

Parameters
pointThe point to check.
Returns
True if the point is inside the polygon.

Check whether point is strictly inside the polygon.

Parameters
pointThe point to check.
Returns
True if the point is inside the polygon.

Compute Length of the rectangle

Orthogonal segment containing the middle of the segment

Compute the distance to the orthogonal median of the rectangle

Definition at line 38 of file otbRectangle.hxx.

References itk::VectorContainer< TElementIdentifier, TElement >::ConstIterator::Value().

template<class TValue = double>
static Pointer otb::Rectangle< TValue >::New ( )
static

Type macro

template<class TValue = double>
void otb::Rectangle< TValue >::operator= ( const Self )
privatedelete
template<class TValue >
void otb::Rectangle< TValue >::PrintSelf ( std::ostream &  os,
itk::Indent  indent 
) const
overrideprotectedvirtual

PrintSelf method

PrintSelf Method

Reimplemented from itk::Object.

Definition at line 215 of file otbRectangle.hxx.

template<class TValue = double>
virtual void otb::Rectangle< TValue >::SetOrientation ( ValueType  _arg)
virtual
template<class TValue = double>
virtual void otb::Rectangle< TValue >::SetWidth ( ValueType  _arg)
virtual

Member Data Documentation

template<class TValue = double>
ValueType otb::Rectangle< TValue >::m_Orientation
private

Definition at line 118 of file otbRectangle.h.

template<class TValue = double>
VertexListPointerType otb::Rectangle< TValue >::m_VertexList
private

Definition at line 121 of file otbRectangle.h.

template<class TValue = double>
ValueType otb::Rectangle< TValue >::m_Width
private

Definition at line 119 of file otbRectangle.h.


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