STIR 6.4.0
SinogramIndices.inl
Go to the documentation of this file.
1
13/*
14 Copyright (C) 2000 PARAPET partners
15 Copyright (C) 2000- 2009, Hammersmith Imanet Ltd
16 This file is part of STIR.
17
18 SPDX-License-Identifier: Apache-2.0 AND License-ref-PARAPET-license
19
20 See STIR/LICENSE.txt for details
21*/
22
23START_NAMESPACE_STIR
24
27 _axial_pos(0)
28{}
29
34
36 : SegmentIndices(bin),
37 _axial_pos(bin.axial_pos_num())
38{}
39
40int
42{
43 return _axial_pos;
44}
45
46int&
48{
49 return _axial_pos;
50}
51
52bool
54{
55 return (_axial_pos < other._axial_pos) || ((_axial_pos == other._axial_pos) && base_type::operator<(other));
56}
57
58bool
60{
61 return (_axial_pos == other._axial_pos) && base_type::operator==(other);
62}
63
64bool
65SinogramIndices::operator!=(const SinogramIndices& other) const
66{
67 return !(*this == other);
68}
69END_NAMESPACE_STIR
A class for storing coordinates and value of a single projection bin.
Definition Bin.h:49
int segment_num() const
get segment number for const objects
Definition SegmentIndices.inl:32
bool operator<(const SegmentIndices &other) const
comparison operator, only useful for sorting
Definition SegmentIndices.inl:56
SegmentIndices(const int segment_num=0, const int timing_pos_num=0)
constructor segment number as arguments
Definition SegmentIndices.inl:26
bool operator==(const SegmentIndices &other) const
test for equality
Definition SegmentIndices.inl:62
int timing_pos_num() const
get TOF index for const objects
Definition SegmentIndices.inl:44
A very simple class to store all dincies to get a (2D) Sinogram.
Definition SinogramIndices.h:34
int axial_pos_num() const
get view number for const objects
Definition SinogramIndices.inl:41
bool operator==(const SinogramIndices &other) const
test for equality
Definition SinogramIndices.inl:59
bool operator<(const SinogramIndices &other) const
comparison operator, only useful for sorting
Definition SinogramIndices.inl:53
SinogramIndices()
an empty constructor (sets everything to 0)
Definition SinogramIndices.inl:25