RTK  2.5.0
Reconstruction Toolkit
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Attributes | List of all members
rtk::FieldOfViewImageFilter< TInputImage, TOutputImage > Class Template Reference

#include <rtkFieldOfViewImageFilter.h>

+ Inheritance diagram for rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >:
+ Collaboration diagram for rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >:

Public Types

using ConstPointer = itk::SmartPointer< const Self >
 
using FOVRadiusType = enum { RADIUSINF, RADIUSSUP, RADIUSBOTH }
 
using GeometryConstPointer = typename GeometryType::ConstPointer
 
using GeometryType = rtk::ThreeDCircularProjectionGeometry
 
using OutputImageRegionType = typename TOutputImage::RegionType
 
using Pointer = itk::SmartPointer< Self >
 
using ProjectionsStackPointer = typename ProjectionsStackType::Pointer
 
using ProjectionsStackType = typename TInputImage::Superclass
 
using Self = FieldOfViewImageFilter
 
using Superclass = itk::ImageToImageFilter< TInputImage, TOutputImage >
 

Public Member Functions

void AddCollimationConstraints (const FOVRadiusType type, _lprec *lp)
 
virtual bool ComputeFOVRadius (const FOVRadiusType type, double &x, double &z, double &r)
 
virtual ::itk::LightObject::Pointer CreateAnother () const
 
virtual const char * GetNameOfClass () const
 
virtual const GeometryTypeGetGeometry () const
 
virtual void SetGeometry (const GeometryType *_arg)
 
virtual bool GetMask ()
 
virtual void SetMask (bool _arg)
 
virtual ProjectionsStackPointer GetProjectionsStack ()
 
virtual void SetProjectionsStack (ProjectionsStackType *_arg)
 
virtual bool GetDisplacedDetector ()
 
virtual void SetDisplacedDetector (bool _arg)
 
virtual double GetInsideValue ()
 
virtual void SetInsideValue (double _arg)
 
virtual double GetOutsideValue ()
 
virtual void SetOutsideValue (double _arg)
 

Static Public Member Functions

static Pointer New ()
 

Protected Member Functions

void BeforeThreadedGenerateData () override
 
void DynamicThreadedGenerateData (const OutputImageRegionType &outputRegionForThread) override
 
 FieldOfViewImageFilter ()
 
void VerifyPreconditions () ITKv5_CONST override
 
 ~FieldOfViewImageFilter () override=default
 

Private Attributes

double m_CenterX { 0. }
 
double m_CenterZ { 0. }
 
bool m_DisplacedDetector { false }
 
GeometryConstPointer m_Geometry { nullptr }
 
double m_HatHeightInf
 
double m_HatHeightSup
 
double m_HatTangentInf
 
double m_HatTangentSup
 
double m_InsideValue { 1. }
 
bool m_Mask { false }
 
double m_OutsideValue { 0. }
 
ProjectionsStackPointer m_ProjectionsStack
 
double m_Radius { -1 }
 

Detailed Description

template<class TInputImage, class TOutputImage>
class rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >

Computes the field of view mask for circular 3D geometry.

Masks out the regions that are not included in our field of view or creates the mask if m_Mask is true. Note that the 3 angle parameters are assumed to be 0. in the circular geometry: GantryAngle, OutOfPlaneAngle and InPlaneAngle. The rest is accounted for but the fov is assumed to be cylindrical.

Test:
rtkfovtest.cxx, rtkfdktest.cxx, rtkmotioncompensatedfdktest.cxx
Author
Marc Vila

Definition at line 48 of file rtkFieldOfViewImageFilter.h.

Member Typedef Documentation

◆ ConstPointer

template<class TInputImage , class TOutputImage >
using rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::ConstPointer = itk::SmartPointer<const Self>

Definition at line 57 of file rtkFieldOfViewImageFilter.h.

◆ FOVRadiusType

template<class TInputImage , class TOutputImage >
using rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::FOVRadiusType = enum { RADIUSINF, RADIUSSUP, RADIUSBOTH }

Definition at line 64 of file rtkFieldOfViewImageFilter.h.

◆ GeometryConstPointer

template<class TInputImage , class TOutputImage >
using rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::GeometryConstPointer = typename GeometryType::ConstPointer

Definition at line 63 of file rtkFieldOfViewImageFilter.h.

◆ GeometryType

template<class TInputImage , class TOutputImage >
using rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::GeometryType = rtk::ThreeDCircularProjectionGeometry

Definition at line 62 of file rtkFieldOfViewImageFilter.h.

◆ OutputImageRegionType

template<class TInputImage , class TOutputImage >
using rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::OutputImageRegionType = typename TOutputImage::RegionType

Definition at line 59 of file rtkFieldOfViewImageFilter.h.

◆ Pointer

template<class TInputImage , class TOutputImage >
using rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::Pointer = itk::SmartPointer<Self>

Definition at line 56 of file rtkFieldOfViewImageFilter.h.

◆ ProjectionsStackPointer

template<class TInputImage , class TOutputImage >
using rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::ProjectionsStackPointer = typename ProjectionsStackType::Pointer

Definition at line 61 of file rtkFieldOfViewImageFilter.h.

◆ ProjectionsStackType

template<class TInputImage , class TOutputImage >
using rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::ProjectionsStackType = typename TInputImage::Superclass

Definition at line 60 of file rtkFieldOfViewImageFilter.h.

◆ Self

template<class TInputImage , class TOutputImage >
using rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::Self = FieldOfViewImageFilter

Standard class type alias.

Definition at line 54 of file rtkFieldOfViewImageFilter.h.

◆ Superclass

template<class TInputImage , class TOutputImage >
using rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::Superclass = itk::ImageToImageFilter<TInputImage, TOutputImage>

Definition at line 55 of file rtkFieldOfViewImageFilter.h.

Constructor & Destructor Documentation

◆ FieldOfViewImageFilter()

template<class TInputImage , class TOutputImage >
rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::FieldOfViewImageFilter ( )
protected

◆ ~FieldOfViewImageFilter()

template<class TInputImage , class TOutputImage >
rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::~FieldOfViewImageFilter ( )
overrideprotecteddefault

Member Function Documentation

◆ AddCollimationConstraints()

template<class TInputImage , class TOutputImage >
void rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::AddCollimationConstraints ( const FOVRadiusType  type,
_lprec *  lp 
)

Add collimation constraints. This function is always called from ComputeFOVRadius but it has an effect only if the geometry has the m_CollimationUInf or m_CollimationUSup which are non infinity (default).

◆ BeforeThreadedGenerateData()

template<class TInputImage , class TOutputImage >
void rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::BeforeThreadedGenerateData ( )
overrideprotectedvirtual

Reimplemented from itk::ImageSource< TOutputImage >.

◆ ComputeFOVRadius()

template<class TInputImage , class TOutputImage >
virtual bool rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::ComputeFOVRadius ( const FOVRadiusType  type,
double &  x,
double &  z,
double &  r 
)
virtual

Computes the radius r and the center (x,z) of the disk perpendicular to the y-axis that is covered by:

  • if RADIUSINF: the half plane defined by the line from the source to the two inferior x index corners which cover the opposite two corners.
  • if RADIUSSUP: the half plane defined by the line from the source to the two superior x index corners which cover the opposite two corners.
  • if RADIUSBOTH: the fan defined by the pairs of half planes. Returns true if it managed to find such a disk and false otherwise. The function may be called without out computing the output, but m_Geometry and ProjectionsStack must be set.

◆ CreateAnother()

template<class TInputImage , class TOutputImage >
virtual::itk::LightObject::Pointer rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::CreateAnother ( ) const
virtual

Reimplemented from itk::Object.

◆ DynamicThreadedGenerateData()

template<class TInputImage , class TOutputImage >
void rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::DynamicThreadedGenerateData ( const OutputImageRegionType outputRegionForThread)
overrideprotectedvirtual

Generates a FOV mask which is applied to the reconstruction A call to this function will assume modification of the function.

Reimplemented from itk::ImageSource< TOutputImage >.

◆ GetDisplacedDetector()

template<class TInputImage , class TOutputImage >
virtual bool rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::GetDisplacedDetector ( )
virtual

Assume that a displaced detector image filter, e.g., rtk::DisplacedDetectorImageFilter, has been used.

◆ GetGeometry()

template<class TInputImage , class TOutputImage >
virtual const GeometryType* rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::GetGeometry ( ) const
virtual

Get / Set the object pointer to projection geometry

◆ GetInsideValue()

template<class TInputImage , class TOutputImage >
virtual double rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::GetInsideValue ( )
virtual

Inside value when Mask is true. 1 by default

◆ GetMask()

template<class TInputImage , class TOutputImage >
virtual bool rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::GetMask ( )
virtual

Get / Set of the member Mask. If set, all the pixels in the field of view are set to InsideValue. The data value is kept otherwise. Pixels outside the mask are set to OutsideValue in any case.

◆ GetNameOfClass()

template<class TInputImage , class TOutputImage >
virtual const char* rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::GetNameOfClass ( ) const
virtual

Run-time type information (and related methods).

Reimplemented from itk::InPlaceImageFilter< TInputImage, TOutputImage >.

◆ GetOutsideValue()

template<class TInputImage , class TOutputImage >
virtual double rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::GetOutsideValue ( )
virtual

Outside value. 0 by default

◆ GetProjectionsStack()

template<class TInputImage , class TOutputImage >
virtual ProjectionsStackPointer rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::GetProjectionsStack ( )
virtual

Get / Set the region of projection images, required to determine the FOV radius. Note that only the geometric information is required, the data are therefore not updated.

◆ New()

template<class TInputImage , class TOutputImage >
static Pointer rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::New ( )
static

Method for creation through the object factory.

◆ SetDisplacedDetector()

template<class TInputImage , class TOutputImage >
virtual void rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::SetDisplacedDetector ( bool  _arg)
virtual

Assume that a displaced detector image filter, e.g., rtk::DisplacedDetectorImageFilter, has been used.

◆ SetGeometry()

template<class TInputImage , class TOutputImage >
virtual void rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::SetGeometry ( const GeometryType _arg)
virtual

Get / Set the object pointer to projection geometry

◆ SetInsideValue()

template<class TInputImage , class TOutputImage >
virtual void rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::SetInsideValue ( double  _arg)
virtual

Inside value when Mask is true. 1 by default

◆ SetMask()

template<class TInputImage , class TOutputImage >
virtual void rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::SetMask ( bool  _arg)
virtual

Get / Set of the member Mask. If set, all the pixels in the field of view are set to InsideValue. The data value is kept otherwise. Pixels outside the mask are set to OutsideValue in any case.

◆ SetOutsideValue()

template<class TInputImage , class TOutputImage >
virtual void rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::SetOutsideValue ( double  _arg)
virtual

Outside value. 0 by default

◆ SetProjectionsStack()

template<class TInputImage , class TOutputImage >
virtual void rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::SetProjectionsStack ( ProjectionsStackType _arg)
virtual

Get / Set the region of projection images, required to determine the FOV radius. Note that only the geometric information is required, the data are therefore not updated.

◆ VerifyPreconditions()

template<class TInputImage , class TOutputImage >
void rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::VerifyPreconditions ( )
overrideprotectedvirtual

Checks that inputs are correctly set.

Reimplemented from itk::ProcessObject.

Member Data Documentation

◆ m_CenterX

template<class TInputImage , class TOutputImage >
double rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::m_CenterX { 0. }
private

Definition at line 153 of file rtkFieldOfViewImageFilter.h.

◆ m_CenterZ

template<class TInputImage , class TOutputImage >
double rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::m_CenterZ { 0. }
private

Definition at line 154 of file rtkFieldOfViewImageFilter.h.

◆ m_DisplacedDetector

template<class TInputImage , class TOutputImage >
bool rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::m_DisplacedDetector { false }
private

Definition at line 159 of file rtkFieldOfViewImageFilter.h.

◆ m_Geometry

template<class TInputImage , class TOutputImage >
GeometryConstPointer rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::m_Geometry { nullptr }
private

Definition at line 149 of file rtkFieldOfViewImageFilter.h.

◆ m_HatHeightInf

template<class TInputImage , class TOutputImage >
double rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::m_HatHeightInf
private

Definition at line 157 of file rtkFieldOfViewImageFilter.h.

◆ m_HatHeightSup

template<class TInputImage , class TOutputImage >
double rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::m_HatHeightSup
private

Definition at line 158 of file rtkFieldOfViewImageFilter.h.

◆ m_HatTangentInf

template<class TInputImage , class TOutputImage >
double rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::m_HatTangentInf
private

Definition at line 155 of file rtkFieldOfViewImageFilter.h.

◆ m_HatTangentSup

template<class TInputImage , class TOutputImage >
double rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::m_HatTangentSup
private

Definition at line 156 of file rtkFieldOfViewImageFilter.h.

◆ m_InsideValue

template<class TInputImage , class TOutputImage >
double rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::m_InsideValue { 1. }
private

Definition at line 160 of file rtkFieldOfViewImageFilter.h.

◆ m_Mask

template<class TInputImage , class TOutputImage >
bool rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::m_Mask { false }
private

Definition at line 150 of file rtkFieldOfViewImageFilter.h.

◆ m_OutsideValue

template<class TInputImage , class TOutputImage >
double rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::m_OutsideValue { 0. }
private

Definition at line 161 of file rtkFieldOfViewImageFilter.h.

◆ m_ProjectionsStack

template<class TInputImage , class TOutputImage >
ProjectionsStackPointer rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::m_ProjectionsStack
private

Definition at line 151 of file rtkFieldOfViewImageFilter.h.

◆ m_Radius

template<class TInputImage , class TOutputImage >
double rtk::FieldOfViewImageFilter< TInputImage, TOutputImage >::m_Radius { -1 }
private

Definition at line 152 of file rtkFieldOfViewImageFilter.h.


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