STIR  6.2.0
MedianArrayFilter3D.h
Go to the documentation of this file.
1 //
2 //
13 /*
14  Copyright (C) 2000- 2009, Hammersmith Imanet Ltd
15  This file is part of STIR.
16 
17  SPDX-License-Identifier: Apache-2.0
18 
19  See STIR/LICENSE.txt for details
20 */
21 
22 #ifndef __stir_MedianArrayFilter3D_H__
23 #define __stir_MedianArrayFilter3D_H__
24 
26 
27 START_NAMESPACE_STIR
28 
29 template <typename coordT>
30 class Coordinate3D;
31 
52 template <typename elemT>
54 {
55 public:
56  explicit MedianArrayFilter3D(const Coordinate3D<int>& mask_radius);
58  bool is_trivial() const override;
59 
60 private:
61  int mask_radius_x;
62  int mask_radius_y;
63  int mask_radius_z;
64 
65  void do_it(Array<3, elemT>& out_array, const Array<3, elemT>& in_array) const override;
66 
68 
70  int extract_neighbours(Array<1, elemT>&, const Array<3, elemT>& array, const Coordinate3D<int>&) const;
71 };
72 
73 END_NAMESPACE_STIR
74 
75 #endif
A convenience class for children of ArrayFunctionObject. It implements the in-place operator() in ter...
Definition: ArrayFunctionObject_2ArgumentImplementation.h:41
Declaration of class stir::ArrayFunctionObject_2ArgumentImplementation.
The 1-dimensional (partial) specialisation of Array.
Definition: Array.h:339
Implements median filtering on 3D arrays.
Definition: MedianArrayFilter3D.h:53