Viskores  1.0
MapperCylinder.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_rendering_MapperCylinder_h
19 #define viskores_rendering_MapperCylinder_h
20 
24 
25 #include <memory>
26 
27 namespace viskores
28 {
29 namespace rendering
30 {
31 
37 class VISKORES_RENDERING_EXPORT MapperCylinder : public Mapper
38 {
39 public:
41 
42  ~MapperCylinder();
43 
44  void SetCanvas(viskores::rendering::Canvas* canvas) override;
45 
46  virtual viskores::rendering::Canvas* GetCanvas() const override;
47 
53  void UseVariableRadius(bool useVariableRadius);
54 
60  void SetRadius(const viskores::Float32& radius);
61 
70  void SetRadiusDelta(const viskores::Float32& delta);
71 
72  void SetCompositeBackground(bool on);
73  viskores::rendering::Mapper* NewCopy() const override;
74 
75 private:
76  struct InternalsType;
77  std::shared_ptr<InternalsType> Internals;
78 
79  struct RenderFunctor;
80 
81  void RenderCellsImpl(const viskores::cont::UnknownCellSet& cellset,
83  const viskores::cont::Field& scalarField,
84  const viskores::cont::ColorTable& colorTable,
85  const viskores::rendering::Camera& camera,
86  const viskores::Range& scalarRange,
87  const viskores::cont::Field& ghostField) override;
88 };
89 }
90 } //namespace viskores::rendering
91 
92 #endif //viskores_rendering_MapperCylinder_h
viskores::cont::CoordinateSystem
Manages a coordinate system for a DataSet.
Definition: CoordinateSystem.h:38
ColorTable.h
viskores
Groups connected points that have the same field value.
Definition: Atomic.h:27
viskores::cont::ColorTable
Color Table for coloring arbitrary fields.
Definition: cont/ColorTable.h:97
viskores::Float32
float Float32
Base type to use for 32-bit floating-point numbers.
Definition: Types.h:165
viskores::rendering::MapperCylinder
MapperCylinder renderers edges from a cell set and renders them as cylinders via ray tracing.
Definition: MapperCylinder.h:37
viskores::rendering::Mapper
Converts data into commands to a rendering system.
Definition: Mapper.h:37
viskores::Range
Represent a continuous scalar range of values.
Definition: Range.h:39
viskores::cont::UnknownCellSet
A CellSet of an unknown type.
Definition: UnknownCellSet.h:56
viskores::rendering::Camera
Specifies the viewport for a rendering.
Definition: Camera.h:45
viskores::rendering::MapperCylinder::Internals
std::shared_ptr< InternalsType > Internals
Definition: MapperCylinder.h:76
Camera.h
Mapper.h
viskores::cont::Field
A Field encapsulates an array on some piece of the mesh, such as the points, a cell set,...
Definition: Field.h:39
viskores::rendering::Canvas
Represents the image space that is the target of rendering.
Definition: Canvas.h:43