VTK-m
2.3
Main Page
Related Pages
Modules
Classes
Class List
Class Index
Class Hierarchy
Class Members
All
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Functions
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
z
~
Variables
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Typedefs
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
r
s
t
u
v
w
Enumerations
Enumerator
Related Functions
Files
File List
File Members
All
a
c
d
e
f
h
i
k
m
o
p
q
r
s
t
u
v
w
x
y
Variables
Typedefs
Macros
e
k
m
q
s
t
u
v
vtkm
filter
geometry_refinement
Shrink.h
Go to the documentation of this file.
1
//============================================================================
2
// Copyright (c) Kitware, Inc.
3
// All rights reserved.
4
// See LICENSE.txt for details.
5
//
6
// This software is distributed WITHOUT ANY WARRANTY; without even
7
// the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
8
// PURPOSE. See the above copyright notice for more information.
9
//============================================================================
10
11
#ifndef vtk_m_filter_geometry_refinement_Shrink_h
12
#define vtk_m_filter_geometry_refinement_Shrink_h
13
14
#include <
vtkm/filter/Filter.h
>
15
#include <
vtkm/filter/geometry_refinement/vtkm_filter_geometry_refinement_export.h
>
16
17
namespace
vtkm
18
{
19
namespace
filter
20
{
21
namespace
geometry_refinement
22
{
29
class
VTKM_FILTER_GEOMETRY_REFINEMENT_EXPORT
Shrink
:
public
vtkm::filter::Filter
30
{
31
public
:
37
VTKM_CONT
void
SetShrinkFactor
(
vtkm::FloatDefault
factor)
38
{
39
this->ShrinkFactor = vtkm::Min(vtkm::Max(0, factor), 1);
// Clamp shrink factor value
40
}
41
43
VTKM_CONT
vtkm::FloatDefault
GetShrinkFactor
()
const
{
return
this->ShrinkFactor; }
44
45
private
:
46
VTKM_CONT
vtkm::cont::DataSet
DoExecute(
const
vtkm::cont::DataSet
& input)
override
;
47
vtkm::FloatDefault
ShrinkFactor = 0.5f;
48
};
49
}
// namespace geometry_refinement
50
}
// namespace filter
51
}
// namespace vtkm
52
53
#endif // vtk_m_filter_geometry_refinement_Shrink_h
vtkm_filter_geometry_refinement_export.h
vtkm
Groups connected points that have the same field value.
Definition:
Atomic.h:19
vtkm::cont::DataSet
Contains and manages the geometric data structures that VTK-m operates on.
Definition:
DataSet.h:57
vtkm::filter::geometry_refinement::Shrink::SetShrinkFactor
void SetShrinkFactor(vtkm::FloatDefault factor)
Specify the scale factor to size each cell.
Definition:
Shrink.h:37
vtkm::filter::geometry_refinement::Shrink
Shrink cells of an arbitrary dataset by a constant factor.
Definition:
Shrink.h:29
VTKM_FILTER_GEOMETRY_REFINEMENT_EXPORT
#define VTKM_FILTER_GEOMETRY_REFINEMENT_EXPORT
Definition:
vtkm_filter_geometry_refinement_export.h:44
vtkm::filter::geometry_refinement::Shrink::GetShrinkFactor
vtkm::FloatDefault GetShrinkFactor() const
Specify the scale factor to size each cell.
Definition:
Shrink.h:43
vtkm::filter::Filter
Base class for all filters.
Definition:
Filter.h:163
VTKM_CONT
#define VTKM_CONT
Definition:
ExportMacros.h:57
vtkm::FloatDefault
vtkm::Float32 FloatDefault
The floating point type to use when no other precision is specified.
Definition:
Types.h:236
Filter.h
Generated by
1.8.17