OTB  9.0.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::VectorDataExtractROI< TVectorData > Class Template Reference

#include <otbVectorDataExtractROI.h>

+ Inheritance diagram for otb::VectorDataExtractROI< TVectorData >:
+ Collaboration diagram for otb::VectorDataExtractROI< TVectorData >:

Public Types

typedef InternalTreeNodeType::ChildrenListType ChildrenListType
 
typedef itk::SmartPointer< const SelfConstPointer
 
typedef DataNodeType::Pointer DataNodePointerType
 
typedef VectorDataType::DataNodeType DataNodeType
 
typedef VectorDataType::DataTreeType DataTreeType
 
typedef RegionType::IndexType IndexType
 
typedef itk::PreOrderTreeIterator< typename VectorDataType::DataTreeType > InputTreeIteratorType
 
typedef VectorDataType::DataTreeType::TreeNodeType InternalTreeNodeType
 
typedef DataNodeType::LinePointerType LinePointerType
 
typedef DataNodeType::LineType LineType
 
typedef itk::SmartPointer< SelfPointer
 
typedef DataNodeType::PointType PointType
 
typedef DataNodeType::PolygonPointerType PolygonPointerType
 
typedef DataNodeType::PolygonType PolygonType
 
typedef itk::Point< typename VertexType::CoordRepType, IndexType::IndexDimension > ProjPointType
 
typedef otb::RemoteSensingRegion< typename VertexType::CoordRepType > RegionType
 
typedef VectorDataExtractROI Self
 
typedef RegionType::SizeType SizeType
 
typedef VectorDataToVectorDataFilter< TVectorData, TVectorData > Superclass
 
typedef TVectorData VectorDataType
 
typedef PolygonType::VertexListPointer VertexListPointer
 
typedef PolygonType::VertexListType VertexListType
 
typedef PolygonType::VertexType VertexType
 
- Public Types inherited from otb::VectorDataToVectorDataFilter< TVectorData, TVectorData >
typedef itk::SmartPointer< const SelfConstPointer
 
typedef itk::DataObject::Pointer DataObjectPointer
 
typedef InputVectorDataType::DataNodeType InputDataNodeType
 
typedef InputVectorDataType::DataTreeType::TreeNodeType InputInternalTreeNodeType
 
typedef InputLineType::Pointer InputLinePointerType
 
typedef InputDataNodeType::LineType InputLineType
 
typedef InputDataNodeType::PointType InputPointType
 
typedef InputPolygonListType::Pointer InputPolygonListPointerType
 
typedef InputDataNodeType::PolygonListType InputPolygonListType
 
typedef InputPolygonType::Pointer InputPolygonPointerType
 
typedef InputDataNodeType::PolygonType InputPolygonType
 
typedef TVectorData ::ConstPointer InputVectorDataPointer
 
typedef TVectorData InputVectorDataType
 
typedef OutputVectorDataType::DataNodeType OutputDataNodeType
 
typedef OutputVectorDataType::DataTreeType::TreeNodeType OutputInternalTreeNodeType
 
typedef OutputLineType::Pointer OutputLinePointerType
 
typedef OutputDataNodeType::LineType OutputLineType
 
typedef OutputDataNodeType::PointType OutputPointType
 
typedef OutputPolygonListType::Pointer OutputPolygonListPointerType
 
typedef OutputDataNodeType::PolygonListType OutputPolygonListType
 
typedef OutputPolygonType::Pointer OutputPolygonPointerType
 
typedef OutputDataNodeType::PolygonType OutputPolygonType
 
typedef TVectorData ::Pointer OutputVectorDataPointer
 
typedef TVectorData OutputVectorDataType
 
typedef itk::SmartPointer< SelfPointer
 
typedef VectorDataToVectorDataFilter Self
 
typedef VectorDataSource< TVectorData > Superclass
 
- Public Types inherited from otb::VectorDataSource< TVectorData >
typedef itk::SmartPointer< const SelfConstPointer
 
typedef itk::ProcessObject::DataObjectPointerArraySizeType DataObjectPointerArraySizeType
 
typedef TVectorData ::Pointer OutputVectorDataPointer
 
typedef TVectorData OutputVectorDataType
 
typedef itk::SmartPointer< SelfPointer
 
typedef VectorDataSource Self
 
typedef itk::ProcessObject Superclass
 

Public Member Functions

virtual ::itk::LightObject::Pointer CreateAnother (void) const
 
virtual const char * GetNameOfClass () const
 
const RegionTypeGetRegion ()
 
void SetRegion (const RegionType &region)
 
- Public Member Functions inherited from otb::VectorDataToVectorDataFilter< TVectorData, TVectorData >
virtual ::itk::LightObject::Pointer CreateAnother (void) const
 
const InputVectorDataTypeGetInput (void)
 
virtual const char * GetNameOfClass () const
 
virtual void SetInput (const InputVectorDataType *input)
 
- Public Member Functions inherited from otb::VectorDataSource< TVectorData >
virtual ::itk::LightObject::Pointer CreateAnother (void) const
 
virtual void GraftOutput (itk::DataObject *output)
 
virtual void GraftNthOutput (unsigned int idx, itk::DataObject *output)
 
virtual OutputVectorDataTypeGetOutput (void)
 
virtual OutputVectorDataTypeGetOutput (DataObjectPointerArraySizeType idx)
 

Static Public Member Functions

static Pointer New ()
 
- Static Public Member Functions inherited from otb::VectorDataToVectorDataFilter< TVectorData, TVectorData >
static Pointer New ()
 
- Static Public Member Functions inherited from otb::VectorDataSource< TVectorData >
static Pointer New ()
 

Protected Member Functions

void PrintSelf (std::ostream &os, itk::Indent indent) const override
 
 VectorDataExtractROI ()
 
 ~VectorDataExtractROI () override=default
 
- Protected Member Functions inherited from otb::VectorDataToVectorDataFilter< TVectorData, TVectorData >
void GenerateOutputInformation (void) override
 
virtual OutputLinePointerType ProcessLine (InputLinePointerType) const
 
virtual OutputPointType ProcessPoint (InputPointType) const
 
virtual OutputPolygonPointerType ProcessPolygon (InputPolygonPointerType) const
 
virtual OutputPolygonListPointerType ProcessPolygonList (InputPolygonListPointerType) const
 
 VectorDataToVectorDataFilter ()
 
 ~VectorDataToVectorDataFilter () override
 
void GenerateData (void) override
 
virtual void ProcessNode (InputInternalTreeNodeType *source, OutputInternalTreeNodeType *destination) const
 
void PrintSelf (std::ostream &os, itk::Indent indent) const override
 
- Protected Member Functions inherited from otb::VectorDataSource< TVectorData >
 VectorDataSource ()
 
 ~VectorDataSource () override
 
void PrintSelf (std::ostream &os, itk::Indent indent) const override
 
virtual void AllocateOutputs ()
 

Private Member Functions

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

Private Attributes

RegionType m_GeoROI
 
unsigned int m_Kept
 
bool m_ProjectionNeeded
 
RegionType m_ROI
 
virtual void CompareInputAndRegionProjection ()
 
virtual void ProjectRegionToInputVectorProjection ()
 
virtual RegionType ComputeVertexListBoundingRegion (typename VertexListType::ConstPointer vertexlist)
 
virtual VertexType PointToContinuousIndex (ProjPointType point)
 
void GenerateData (void) override
 
virtual bool IsPolygonIntersectionNotNull (PolygonPointerType polygon)
 
virtual bool IsLineIntersectionNotNull (LinePointerType line)
 
virtual void ProcessNode (InternalTreeNodeType *source, InternalTreeNodeType *destination)
 
int CounterClockWise (PointType firstPoint, PointType secondPoint, PointType thirdPoint)
 
bool IsSegmentIntersectSegment (LinePointerType segmentLineAB, LinePointerType segmentLineCD)
 

Detailed Description

template<class TVectorData>
class otb::VectorDataExtractROI< TVectorData >

Extract a subset of a Vector Data based on location.

The region to extract is specified by a otb::RemoteSensingRegion object. This region contains its own projection reference that may be different from the projection of the vector data.

The projection of the vector data will not be modified by this filter if you need to change the projection, refer to otb::VectorDataProjectionFilter

Note
Parameter to this class for input and outputs are vectorData
See also
RemoteSensingRegion
VectorDataProjectionFilter
Examples
Projections/VectorDataExtractROIExample.cxx.

Definition at line 54 of file otbVectorDataExtractROI.h.

Member Typedef Documentation

◆ ChildrenListType

template<class TVectorData >
typedef InternalTreeNodeType::ChildrenListType otb::VectorDataExtractROI< TVectorData >::ChildrenListType

Definition at line 94 of file otbVectorDataExtractROI.h.

◆ ConstPointer

template<class TVectorData >
typedef itk::SmartPointer<const Self> otb::VectorDataExtractROI< TVectorData >::ConstPointer

Definition at line 61 of file otbVectorDataExtractROI.h.

◆ DataNodePointerType

template<class TVectorData >
typedef DataNodeType::Pointer otb::VectorDataExtractROI< TVectorData >::DataNodePointerType

Definition at line 72 of file otbVectorDataExtractROI.h.

◆ DataNodeType

template<class TVectorData >
typedef VectorDataType::DataNodeType otb::VectorDataExtractROI< TVectorData >::DataNodeType

Definition at line 71 of file otbVectorDataExtractROI.h.

◆ DataTreeType

template<class TVectorData >
typedef VectorDataType::DataTreeType otb::VectorDataExtractROI< TVectorData >::DataTreeType

Definition at line 73 of file otbVectorDataExtractROI.h.

◆ IndexType

template<class TVectorData >
typedef RegionType::IndexType otb::VectorDataExtractROI< TVectorData >::IndexType

Definition at line 87 of file otbVectorDataExtractROI.h.

◆ InputTreeIteratorType

template<class TVectorData >
typedef itk::PreOrderTreeIterator<typename VectorDataType::DataTreeType> otb::VectorDataExtractROI< TVectorData >::InputTreeIteratorType

Definition at line 92 of file otbVectorDataExtractROI.h.

◆ InternalTreeNodeType

template<class TVectorData >
typedef VectorDataType::DataTreeType::TreeNodeType otb::VectorDataExtractROI< TVectorData >::InternalTreeNodeType

Definition at line 93 of file otbVectorDataExtractROI.h.

◆ LinePointerType

template<class TVectorData >
typedef DataNodeType::LinePointerType otb::VectorDataExtractROI< TVectorData >::LinePointerType

Definition at line 77 of file otbVectorDataExtractROI.h.

◆ LineType

template<class TVectorData >
typedef DataNodeType::LineType otb::VectorDataExtractROI< TVectorData >::LineType

Definition at line 76 of file otbVectorDataExtractROI.h.

◆ Pointer

template<class TVectorData >
typedef itk::SmartPointer<Self> otb::VectorDataExtractROI< TVectorData >::Pointer

Definition at line 60 of file otbVectorDataExtractROI.h.

◆ PointType

template<class TVectorData >
typedef DataNodeType::PointType otb::VectorDataExtractROI< TVectorData >::PointType

Definition at line 78 of file otbVectorDataExtractROI.h.

◆ PolygonPointerType

template<class TVectorData >
typedef DataNodeType::PolygonPointerType otb::VectorDataExtractROI< TVectorData >::PolygonPointerType

Definition at line 74 of file otbVectorDataExtractROI.h.

◆ PolygonType

template<class TVectorData >
typedef DataNodeType::PolygonType otb::VectorDataExtractROI< TVectorData >::PolygonType

Definition at line 75 of file otbVectorDataExtractROI.h.

◆ ProjPointType

template<class TVectorData >
typedef itk::Point<typename VertexType::CoordRepType, IndexType::IndexDimension> otb::VectorDataExtractROI< TVectorData >::ProjPointType

Definition at line 90 of file otbVectorDataExtractROI.h.

◆ RegionType

template<class TVectorData >
typedef otb::RemoteSensingRegion<typename VertexType::CoordRepType> otb::VectorDataExtractROI< TVectorData >::RegionType

TODO : automate the dimension of the region

Definition at line 86 of file otbVectorDataExtractROI.h.

◆ Self

template<class TVectorData >
typedef VectorDataExtractROI otb::VectorDataExtractROI< TVectorData >::Self

Standard class typedefs.

Definition at line 58 of file otbVectorDataExtractROI.h.

◆ SizeType

template<class TVectorData >
typedef RegionType::SizeType otb::VectorDataExtractROI< TVectorData >::SizeType

Definition at line 88 of file otbVectorDataExtractROI.h.

◆ Superclass

template<class TVectorData >
typedef VectorDataToVectorDataFilter<TVectorData, TVectorData> otb::VectorDataExtractROI< TVectorData >::Superclass

Definition at line 59 of file otbVectorDataExtractROI.h.

◆ VectorDataType

template<class TVectorData >
typedef TVectorData otb::VectorDataExtractROI< TVectorData >::VectorDataType

Image type information

Definition at line 67 of file otbVectorDataExtractROI.h.

◆ VertexListPointer

template<class TVectorData >
typedef PolygonType::VertexListPointer otb::VectorDataExtractROI< TVectorData >::VertexListPointer

Definition at line 83 of file otbVectorDataExtractROI.h.

◆ VertexListType

template<class TVectorData >
typedef PolygonType::VertexListType otb::VectorDataExtractROI< TVectorData >::VertexListType

Definition at line 82 of file otbVectorDataExtractROI.h.

◆ VertexType

template<class TVectorData >
typedef PolygonType::VertexType otb::VectorDataExtractROI< TVectorData >::VertexType

Need Vertex and Vertex List Type

Definition at line 81 of file otbVectorDataExtractROI.h.

Constructor & Destructor Documentation

◆ VectorDataExtractROI() [1/2]

template<class TVectorData >
otb::VectorDataExtractROI< TVectorData >::VectorDataExtractROI
protected

Definition at line 43 of file otbVectorDataExtractROI.hxx.

◆ ~VectorDataExtractROI()

template<class TVectorData >
otb::VectorDataExtractROI< TVectorData >::~VectorDataExtractROI ( )
overrideprotecteddefault

◆ VectorDataExtractROI() [2/2]

template<class TVectorData >
otb::VectorDataExtractROI< TVectorData >::VectorDataExtractROI ( const Self )
privatedelete

Member Function Documentation

◆ CompareInputAndRegionProjection()

template<class TVectorData >
void otb::VectorDataExtractROI< TVectorData >::CompareInputAndRegionProjection
protectedvirtual

Method to compare the projection embedded in the cartoRegion And the the InputVectorData

CompareInputAndRegionProjection

Definition at line 409 of file otbVectorDataExtractROI.hxx.

◆ ComputeVertexListBoundingRegion()

template<class TVectorData >
VectorDataExtractROI< TVectorData >::RegionType otb::VectorDataExtractROI< TVectorData >::ComputeVertexListBoundingRegion ( typename VertexListType::ConstPointer  vertexlist)
protectedvirtual

Improve the Projected roi

ComputeVertexListBoundingRegion

Definition at line 496 of file otbVectorDataExtractROI.hxx.

References otb::RemoteSensingRegion< TType >::SetOrigin(), and otb::RemoteSensingRegion< TType >::SetSize().

◆ CounterClockWise()

template<class TVectorData >
int otb::VectorDataExtractROI< TVectorData >::CounterClockWise ( PointType  firstPoint,
PointType  secondPoint,
PointType  thirdPoint 
)
private

Method to compare the projection embedded in the cartoRegion And the the InputVectorData

CompareInputAndRegionProjection

Definition at line 362 of file otbVectorDataExtractROI.hxx.

◆ CreateAnother()

template<class TVectorData >
virtual::itk::LightObject::Pointer otb::VectorDataExtractROI< TVectorData >::CreateAnother ( void  ) const

◆ GenerateData()

template<class TVectorData >
void otb::VectorDataExtractROI< TVectorData >::GenerateData ( void  )
overrideprotected

Prototype of the generate data method

Need to check if it is necessary to project the roi

If Projection of the region is needed, we project on the vectorData coordinate axis

Definition at line 60 of file otbVectorDataExtractROI.hxx.

References otb::Stopwatch::GetElapsedMilliseconds(), otbMsgDevMacro, otb::Stopwatch::StartNew(), and otb::Stopwatch::Stop().

◆ GetNameOfClass()

template<class TVectorData >
virtual const char* otb::VectorDataExtractROI< TVectorData >::GetNameOfClass ( ) const
virtual

Run-time type information (and related methods).

◆ GetRegion()

template<class TVectorData >
const RegionType& otb::VectorDataExtractROI< TVectorData >::GetRegion ( )
inline

Definition at line 102 of file otbVectorDataExtractROI.h.

◆ IsLineIntersectionNotNull()

template<class TVectorData >
bool otb::VectorDataExtractROI< TVectorData >::IsLineIntersectionNotNull ( LinePointerType  line)
protectedvirtual

Method to check if the line Bounding Box ha ve a non-null intersection with the ROI

Definition at line 269 of file otbVectorDataExtractROI.hxx.

References otb::RemoteSensingRegion< TType >::Crop().

◆ IsPolygonIntersectionNotNull()

template<class TVectorData >
bool otb::VectorDataExtractROI< TVectorData >::IsPolygonIntersectionNotNull ( PolygonPointerType  polygon)
protectedvirtual

Method to check if the polygon Bounding Box ha ve a non-null intersection with the ROI

Definition at line 240 of file otbVectorDataExtractROI.hxx.

◆ IsSegmentIntersectSegment()

template<class TVectorData >
bool otb::VectorDataExtractROI< TVectorData >::IsSegmentIntersectSegment ( LinePointerType  segmentLineAB,
LinePointerType  segmentLineCD 
)
private

Method to compare the projection embedded in the cartoRegion And the the InputVectorData

CompareInputAndRegionProjection

Definition at line 333 of file otbVectorDataExtractROI.hxx.

◆ New()

template<class TVectorData >
static Pointer otb::VectorDataExtractROI< TVectorData >::New ( )
static

Method for creation through the object factory.

◆ operator=()

template<class TVectorData >
void otb::VectorDataExtractROI< TVectorData >::operator= ( const Self )
privatedelete

◆ PointToContinuousIndex()

template<class TVectorData >
VectorDataExtractROI< TVectorData >::VertexType otb::VectorDataExtractROI< TVectorData >::PointToContinuousIndex ( ProjPointType  point)
protectedvirtual

Method to transform itk::Point to itk::ContinuousIndex

itk::Point to ContinuousIndex

Definition at line 480 of file otbVectorDataExtractROI.hxx.

◆ PrintSelf()

template<class TVectorData >
void otb::VectorDataExtractROI< TVectorData >::PrintSelf ( std::ostream &  os,
itk::Indent  indent 
) const
overrideprotected

Definition at line 51 of file otbVectorDataExtractROI.hxx.

◆ ProcessNode()

template<class TVectorData >
void otb::VectorDataExtractROI< TVectorData >::ProcessNode ( InternalTreeNodeType source,
InternalTreeNodeType destination 
)
protectedvirtual

Method to compare the projection embedded in the cartoRegion And the the InputVectorData

CompareInputAndRegionProjection

Definition at line 115 of file otbVectorDataExtractROI.hxx.

References otb::DOCUMENT, otb::FEATURE_COLLECTION, otb::FEATURE_LINE, otb::FEATURE_MULTILINE, otb::FEATURE_MULTIPOINT, otb::FEATURE_MULTIPOLYGON, otb::FEATURE_POINT, otb::FEATURE_POLYGON, otb::FOLDER, and otb::ROOT.

◆ ProjectRegionToInputVectorProjection()

template<class TVectorData >
void otb::VectorDataExtractROI< TVectorData >::ProjectRegionToInputVectorProjection
protectedvirtual

Method to project from carto reference to Geo axis

ProjectRegionToInputVectorProjection

Set up the projection

Compute the extremities of the region

Fill the vertex List : First Convert Point To

Due to The projection : the Projected ROI can be rotated

Definition at line 427 of file otbVectorDataExtractROI.hxx.

References otbMsgDevMacro.

◆ SetRegion()

template<class TVectorData >
void otb::VectorDataExtractROI< TVectorData >::SetRegion ( const RegionType region)
inline

Method to Set/Get the Region of interest

Definition at line 97 of file otbVectorDataExtractROI.h.

Member Data Documentation

◆ m_GeoROI

template<class TVectorData >
RegionType otb::VectorDataExtractROI< TVectorData >::m_GeoROI
private

Definition at line 146 of file otbVectorDataExtractROI.h.

◆ m_Kept

template<class TVectorData >
unsigned int otb::VectorDataExtractROI< TVectorData >::m_Kept
private

Definition at line 148 of file otbVectorDataExtractROI.h.

◆ m_ProjectionNeeded

template<class TVectorData >
bool otb::VectorDataExtractROI< TVectorData >::m_ProjectionNeeded
private

Definition at line 144 of file otbVectorDataExtractROI.h.

◆ m_ROI

template<class TVectorData >
RegionType otb::VectorDataExtractROI< TVectorData >::m_ROI
private

Definition at line 145 of file otbVectorDataExtractROI.h.


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