STIR  6.2.0
PresmoothingForwardProjectorByBin.h
Go to the documentation of this file.
1 
10 /*
11  Copyright (C) 2002- 2007, Hammersmith Imanet
12  Copyright (C) 2019, University College London
13 
14  This file is part of STIR.
15 
16  SPDX-License-Identifier: Apache-2.0
17 
18 
19  See STIR/LICENSE.txt for details
20 */
21 #ifndef __stir_recon_buildblock_PresmoothingForwardProjectorByBin__H__
22 #define __stir_recon_buildblock_PresmoothingForwardProjectorByBin__H__
23 
26 #include "stir/shared_ptr.h"
27 
28 START_NAMESPACE_STIR
29 
30 template <typename elemT>
31 class Viewgram;
32 template <typename DataT>
33 class DataProcessor;
40 class PresmoothingForwardProjectorByBin : public RegisteredParsingObject<PresmoothingForwardProjectorByBin, ForwardProjectorByBin>
41 {
42 #ifdef SWIG
43  // work-around swig problem. It gets confused when using a private (or protected)
44  // typedef in a definition of a public typedef/member
45 public:
46 #else
47 private:
48 #endif
50 
51 public:
53  static const char* const registered_name;
54 
57 
59 
61 
63  void set_up(const shared_ptr<const ProjDataInfo>& proj_data_info_ptr,
64  const shared_ptr<const DiscretisedDensity<3, float>>& density_info_ptr // TODO should be Info only
65  ) override;
66 
67  PresmoothingForwardProjectorByBin(const shared_ptr<ForwardProjectorByBin>& original_forward_projector_ptr,
68  const shared_ptr<DataProcessor<DiscretisedDensity<3, float>>>&);
69 
70  // Informs on which symmetries the projector handles
71  // It should get data related by at least those symmetries.
72  // Otherwise, a run-time error will occur (unless the derived
73  // class has other behaviour).
74  const DataSymmetriesForViewSegmentNumbers* get_symmetries_used() const override;
75 
76 private:
77  shared_ptr<ForwardProjectorByBin> original_forward_projector_ptr;
78 
79 #ifdef STIR_PROJECTORS_AS_V3
80  void actual_forward_project(RelatedViewgrams<float>&,
82  const int min_axial_pos_num,
83  const int max_axial_pos_num,
84  const int min_tangential_pos_num,
85  const int max_tangential_pos_num);
86 #endif
87  void actual_forward_project(RelatedViewgrams<float>&,
88  const int min_axial_pos_num,
89  const int max_axial_pos_num,
90  const int min_tangential_pos_num,
91  const int max_tangential_pos_num) override;
92 
93 #if 0 // disabled as currently not used. needs to be written in the new style anyway
94  void actual_forward_project(Bin&,
96 #endif
97 
98  void set_defaults() override;
99  void initialise_keymap() override;
100  bool post_processing() override;
101 };
102 
103 END_NAMESPACE_STIR
104 
105 #endif
static const char *const registered_name
Name which will be used when parsing a PresmoothingForwardProjectorByBin object.
Definition: PresmoothingForwardProjectorByBin.h:53
Import of std::shared_ptr, std::dynamic_pointer_cast and std::static_pointer_cast (or corresponding b...
Base class that defines an interface for classes that do data processing.
Definition: DataProcessor.h:46
A class for encoding/finding symmetries. Works only on ViewSegmentNumbers (instead of Bin)...
Definition: DataSymmetriesForViewSegmentNumbers.h:49
Abstract base class for all forward projectors.
Definition: ForwardProjectorByBin.h:53
A class for storing coordinates and value of a single projection bin.
Definition: Bin.h:48
Parent class for all leaves in a RegisteredObject hierarchy that do parsing of parameter files...
Definition: RegisteredParsingObject.h:77
Base class for forward projectors which work on &#39;large&#39; collections of bins: given the whole image...
Declaration of class stir::RegisteredParsingObject.
A very preliminary class that first smooths the image, then forward projects.
Definition: PresmoothingForwardProjectorByBin.h:40