STIR 6.5.0
stir::GatedSpatialTransformation Class Reference

Class for spatial transformations for gated images. More...

#include "stir/spatial_transformation/GatedSpatialTransformation.h"

Inheritance diagram for stir::GatedSpatialTransformation:

Public Member Functions

 GatedSpatialTransformation ()
 default constructor
 ~GatedSpatialTransformation () override
 default destructor Construct an empty GatedSpatialTransformation based on a shared_ptr<DiscretisedDensity<3,float> >
 GatedSpatialTransformation (const TimeGateDefinitions &time_gate_definitions, const shared_ptr< DiscretisedDensity< 3, float > > &density_sptr)
void read_from_files (const std::string input_string)
 Implementation to read the transformation vectors will be moved to the IO directory because it should be general. For example it can be in ECAT7 image formant.
void write_to_files (const std::string output_string)
 Implementation to write the transformation vectors.
Functions to get parameters
GatedDiscretisedDensity get_spatial_transformation_z () const
GatedDiscretisedDensity get_spatial_transformation_y () const
GatedDiscretisedDensity get_spatial_transformation_x () const
const TimeGateDefinitions & get_time_gate_definitions () const
Functions to set parameters
void set_spatial_transformations (const GatedDiscretisedDensity &motion_z, const GatedDiscretisedDensity &motion_y, const GatedDiscretisedDensity &motion_x)
void set_gate_defs (const TimeGateDefinitions &gate_defs)
void warp_image (GatedDiscretisedDensity &new_gated_image, const GatedDiscretisedDensity &gated_image) const
 Warping functions from to gated images.
void warp_image (DiscretisedDensity< 3, float > &new_reference_image, const GatedDiscretisedDensity &gated_image) const
void warp_image (GatedDiscretisedDensity &gated_image, const DiscretisedDensity< 3, float > &reference_image) const
void accumulate_warp_image (DiscretisedDensity< 3, float > &new_reference_image, const GatedDiscretisedDensity &gated_image) const
void set_defaults () override
 Set defaults before parsing.
Succeeded set_up () override
Public Member Functions inherited from stir::RegisteredParsingObject< GatedSpatialTransformation, SpatialTransformation >
std::string get_registered_name () const override
 Returns Derived::registered_name.
std::string parameter_info () override
 Returns a string with all parameters and their values, in a form suitable for parsing again.
Public Member Functions inherited from stir::SpatialTransformation
 SpatialTransformation ()
 default constructor
 ~SpatialTransformation () override
 default destructor
Public Member Functions inherited from stir::ParsingObject
 ParsingObject (const ParsingObject &)
ParsingObject & operator= (const ParsingObject &)
bool parse (std::istream &f)
bool parse (const char *const filename)
void ask_parameters ()

Static Public Attributes

static const char *const registered_name = "Gated Spatial Transformation"
Static Public Attributes inherited from stir::SpatialTransformation
static const char *const registered_name = "Motion Field Type"

Additional Inherited Members

Static Public Member Functions inherited from stir::RegisteredParsingObject< GatedSpatialTransformation, SpatialTransformation >
static SpatialTransformation * read_from_stream (std::istream *)
 Construct a new object (of type Derived) by parsing the istream.
Static Public Member Functions inherited from stir::RegisteredObject< SpatialTransformation >
static SpatialTransformation * read_registered_object (std::istream *in, const std::string &registered_name)
 Construct a new object (of a type derived from Root, its actual type determined by the registered_name parameter) by parsing the istream.
static SpatialTransformation * ask_type_and_parameters ()
 ask the user for the type, and then calls read_registered_object(0, type)
static void list_registered_names (std::ostream &stream)
 List all possible registered names to the stream.
Protected Types inherited from stir::RegisteredObject< SpatialTransformation >
typedef SpatialTransformation *(*) RootFactory(std::istream *)
 The type of a root factory is a function, taking an istream* as argument, and returning a Root*.
typedef FactoryRegistry< std::string, RootFactory, interfile_less > RegistryType
 The type of the registry.
virtual void set_key_values ()
 This will be called before parsing or parameter_info is called.
Static Protected Member Functions inherited from stir::RegisteredObject< SpatialTransformation >
static RegistryType & registry ()
 Static function returning the registry.
KeyParser parser

Detailed Description

Class for spatial transformations for gated images.

Constructor & Destructor Documentation

◆ GatedSpatialTransformation()

stir::GatedSpatialTransformation::GatedSpatialTransformation ( )

default constructor

References GatedSpatialTransformation(), and set_defaults().

Referenced by GatedSpatialTransformation().

◆ ~GatedSpatialTransformation()

stir::GatedSpatialTransformation::~GatedSpatialTransformation ( )
override

default destructor Construct an empty GatedSpatialTransformation based on a shared_ptr<DiscretisedDensity<3,float> >

References ~GatedSpatialTransformation().

Referenced by ~GatedSpatialTransformation().

Member Function Documentation

◆ read_from_files()

void stir::GatedSpatialTransformation::read_from_files ( const std::string input_string)

Implementation to read the transformation vectors will be moved to the IO directory because it should be general. For example it can be in ECAT7 image formant.

References stir::error(), and read_from_files().

Referenced by read_from_files().

◆ write_to_files()

void stir::GatedSpatialTransformation::write_to_files ( const std::string output_string)

Implementation to write the transformation vectors.

References write_to_files().

Referenced by write_to_files().

◆ warp_image()

void stir::GatedSpatialTransformation::warp_image ( GatedDiscretisedDensity & new_gated_image,
const GatedDiscretisedDensity & gated_image ) const

◆ accumulate_warp_image()

void stir::GatedSpatialTransformation::accumulate_warp_image ( DiscretisedDensity< 3, float > & new_reference_image,
const GatedDiscretisedDensity & gated_image ) const

todo This is not implemented as sum (or should it be the average?)

References accumulate_warp_image(), and warp_image().

Referenced by accumulate_warp_image().

◆ set_defaults()

void stir::GatedSpatialTransformation::set_defaults ( )
overridevirtual

Set defaults before parsing.

Reimplemented from stir::ParsingObject.

References set_defaults(), and stir::ParsingObject::set_defaults().

Referenced by GatedSpatialTransformation(), and set_defaults().

◆ set_up()

Succeeded stir::GatedSpatialTransformation::set_up ( )
overridevirtual

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