Viskores  1.0
ComputeMoments.h
Go to the documentation of this file.
1 //============================================================================
2 // The contents of this file are covered by the Viskores license. See
3 // LICENSE.txt for details.
4 //
5 // By contributing to this file, all contributors agree to the Developer
6 // Certificate of Origin Version 1.1 (DCO 1.1) as stated in DCO.txt.
7 //============================================================================
8 
9 //============================================================================
10 // Copyright (c) Kitware, Inc.
11 // All rights reserved.
12 // See LICENSE.txt for details.
13 //
14 // This software is distributed WITHOUT ANY WARRANTY; without even
15 // the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
16 // PURPOSE. See the above copyright notice for more information.
17 //=======================================================================
18 #ifndef viskores_filter_image_processing_ComputeMoments_h
19 #define viskores_filter_image_processing_ComputeMoments_h
20 
21 #include <viskores/filter/Filter.h>
23 
24 namespace viskores
25 {
26 namespace filter
27 {
28 namespace image_processing
29 {
30 class VISKORES_FILTER_IMAGE_PROCESSING_EXPORT ComputeMoments : public viskores::filter::Filter
31 {
32 public:
34 
35  VISKORES_CONT void SetRadius(double _radius) { this->Radius = _radius; }
36 
37  VISKORES_CONT void SetSpacing(viskores::Vec3f _spacing) { this->Spacing = _spacing; }
38 
39  VISKORES_CONT void SetOrder(viskores::Int32 _order) { this->Order = _order; }
40 
41 private:
42  VISKORES_CONT viskores::cont::DataSet DoExecute(const viskores::cont::DataSet& input) override;
43 
44  double Radius = 1;
45  viskores::Vec3f Spacing = { 1.0f, 1.0f, 1.0f };
46  viskores::Int32 Order = 0;
47 };
48 } // namespace image_processing
49 } // namespace filter
50 } // namespace viskores
51 
52 #endif //viskores_filter_image_processing_ComputeMoments_h
viskores::cont::DataSet
Contains and manages the geometric data structures that Viskores operates on.
Definition: DataSet.h:66
viskores::filter::Filter
Base class for all filters.
Definition: Filter.h:171
viskores::filter::image_processing::ComputeMoments::SetSpacing
void SetSpacing(viskores::Vec3f _spacing)
Definition: ComputeMoments.h:37
viskores::filter::image_processing::ComputeMoments
Definition: ComputeMoments.h:30
viskores_filter_image_processing_export.h
VISKORES_CONT
#define VISKORES_CONT
Definition: ExportMacros.h:65
viskores
Groups connected points that have the same field value.
Definition: Atomic.h:27
viskores::Int32
int32_t Int32
Base type to use for 32-bit signed integer numbers.
Definition: Types.h:189
viskores::filter::image_processing::ComputeMoments::SetOrder
void SetOrder(viskores::Int32 _order)
Definition: ComputeMoments.h:39
viskores::filter::image_processing::ComputeMoments::SetRadius
void SetRadius(double _radius)
Definition: ComputeMoments.h:35
viskores::Vec< viskores::FloatDefault, 3 >
Filter.h