STIR  6.2.0
DataSymmetriesForBins.h
Go to the documentation of this file.
1 //
2 //
3 /*
4  Copyright (C) 2000 PARAPET partners
5  Copyright (C) 2000- 2007, Hammersmith Imanet Ltd
6  This file is part of STIR.
7 
8  SPDX-License-Identifier: Apache-2.0 AND License-ref-PARAPET-license
9 
10  See STIR/LICENSE.txt for details
11 */
24 #ifndef __stir_recon_buildblock_DataSymmetriesForBins_H__
25 #define __stir_recon_buildblock_DataSymmetriesForBins_H__
26 
28 #include "stir/ProjDataInfo.h" // is used in .inl
29 #include "stir/shared_ptr.h"
30 #include "stir/unique_ptr.h"
31 #include <vector>
32 #include <memory>
33 
34 #include "stir/Coordinate2D.h"
35 
36 START_NAMESPACE_STIR
37 
38 class Bin;
39 class SymmetryOperation;
41 
42 #if 0
43 class BinIndexRange;
44 #endif
45 
53 
68 {
69 private:
72 
73 public:
74  DataSymmetriesForBins(const shared_ptr<const ProjDataInfo>& proj_data_info_ptr);
75 
76  ~DataSymmetriesForBins() override;
77 
78  DataSymmetriesForBins* clone() const override = 0;
79 
80 #if 0
81  TODO!
83  virtual BinIndexRange
84  get_basic_bin_index_range() const = 0;
85 #endif
86 
88 
92  // next return value could be a RelatedBins ???
93  // however, both Bin and RelatedBins have data in there (which is not needed here)
94  inline void get_related_bins(std::vector<Bin>&, const Bin& b) const;
95 
97 
99  virtual void get_related_bins(std::vector<Bin>&,
100  const Bin& b,
101  const int min_axial_pos_num,
102  const int max_axial_pos_num,
103  const int min_tangential_pos_num,
104  const int max_tangential_pos_num,
105  const int min_timing_pos_num,
106  const int max_timing_pos_num) const;
107 
109 
114  inline void get_related_bins_factorised(std::vector<AxTangPosNumbers>&, const Bin& b) const;
115 
117 
128  virtual void get_related_bins_factorised(std::vector<AxTangPosNumbers>&,
129  const Bin& b,
130  const int min_axial_pos_num,
131  const int max_axial_pos_num,
132  const int min_tangential_pos_num,
133  const int max_tangential_pos_num) const = 0;
134 
136  virtual int num_related_bins(const Bin& b) const;
137 
143  virtual unique_ptr<SymmetryOperation> find_symmetry_operation_from_basic_bin(Bin&) const = 0;
144 
150  virtual bool find_basic_bin(Bin& b) const;
151 
156  virtual bool is_basic(const Bin& v_s) const;
157 
159  virtual unique_ptr<SymmetryOperation> find_symmetry_operation_from_basic_view_segment_numbers(ViewSegmentNumbers&) const;
160 
161 protected:
163  const shared_ptr<const ProjDataInfo> proj_data_info_ptr;
164 
166  bool blindly_equals(const root_type* const) const override = 0;
167 };
168 
169 END_NAMESPACE_STIR
170 
172 
173 #endif
A class for encoding/finding symmetries common to the geometry of the projection data and the discret...
Definition: DataSymmetriesForBins.h:67
a templated class for 2-dimensional coordinates.
Definition: Coordinate2D.h:41
Declaration of class stir::ProjDataInfo.
const shared_ptr< const ProjDataInfo > proj_data_info_ptr
Member storing the info needed by get_related_bins() et al.
Definition: DataSymmetriesForBins.h:163
inline implementations for class stir::DataSymmetriesForBins
Import of std::shared_ptr, std::dynamic_pointer_cast and std::static_pointer_cast (or corresponding b...
A class for encoding/finding symmetries. Works only on ViewSegmentNumbers (instead of Bin)...
Definition: DataSymmetriesForViewSegmentNumbers.h:49
Declaration of class stir::DataSymmetriesForViewSegmentNumbers.
alias for ViewgramIndices
Definition: ViewSegmentNumbers.h:33
A class for storing coordinates and value of a single projection bin.
Definition: Bin.h:48
Import of std::unique_ptr into the stir namespace, together with work-arounds for other compilers...
An (abstract base) class that contains information on the projection data.
Definition: ProjDataInfo.h:69
defines the stir::Coordinate2D<coordT> class
Coordinate2D< int > AxTangPosNumbers
AxTangPosNumbers as a class that provides the 2 remaining coordinates for a Bin, aside from ViewSegme...
Definition: DataSymmetriesForBins.h:40