vtkSMBoundsDomain.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: ParaView
4  Module: vtkSMBoundsDomain.h
5 
6  Copyright (c) Kitware, Inc.
7  All rights reserved.
8  See Copyright.txt or http://www.paraview.org/HTML/Copyright.html for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
60 #ifndef vtkSMBoundsDomain_h
61 #define vtkSMBoundsDomain_h
62 
63 #include "vtkRemotingServerManagerModule.h" //needed for exports
64 #include "vtkSMDoubleRangeDomain.h"
65 
67 class vtkSMProxyProperty;
70 
72 {
73 public:
74  static vtkSMBoundsDomain* New();
76  void PrintSelf(ostream& os, vtkIndent indent) override;
77 
82  void Update(vtkSMProperty*) override;
83 
85  vtkSetClampMacro(Mode, int, 0, 3);
86  vtkGetMacro(Mode, int);
88 
92  enum Modes
93  {
103  };
104 
105  vtkGetMacro(ScaleFactor, double);
106 
107  enum Axes
108  {
109  X_AXIS = 1,
110  Y_AXIS = 2,
111  Z_AXIS = 4,
112  X_AND_Y_AXES = X_AXIS | Y_AXIS,
113  Y_AND_Z_AXES = Y_AXIS | Z_AXIS,
114  X_AND_Z_AXES = X_AXIS | Z_AXIS,
115  X_Y_AND_Z_AXES = X_AXIS | Y_AXIS | Z_AXIS
116  };
117 
118  vtkGetMacro(AxisFlags, int);
119 
123  int SetDefaultValues(vtkSMProperty* property, bool use_unchecked_values) override;
124 
125 protected:
127  ~vtkSMBoundsDomain() override;
128 
133  int ReadXMLAttributes(vtkSMProperty* prop, vtkPVXMLElement* element) override;
134 
135  // Obtain the data information from the required property with
136  // function "Input", if any.
137  vtkPVDataInformation* GetInputInformation();
138 
139  // Obtain the information for the "AxisFlags" required property.
140  vtkSMIntVectorProperty* GetAxisFlagsInformation();
141 
142  bool IsAxisEnabled(int axis);
143 
144  void SetDomainValues(double bounds[6]);
145 
146  void UpdateOriented();
147 
148  int Mode;
149  double ScaleFactor; // Used only in SCALED_EXTENT and APPROXIMATE_CELL_LENGTH mode.
151 
152 private:
153  vtkSMBoundsDomain(const vtkSMBoundsDomain&) = delete;
154  void operator=(const vtkSMBoundsDomain&) = delete;
155 
156  vtkSMArrayRangeDomain* ArrayRangeDomain;
157 };
158 
159 #endif
double range domain based on data set bounds
property representing pointer(s) to vtkObject(s)
type specific extension to vtkSMRangeDomainTemplate for doubles.
provides meta data about a vtkDataObject subclass.
#define VTKREMOTINGSERVERMANAGER_EXPORT
void PrintSelf(ostream &os, vtkIndent indent) override
virtual void Update(vtkSMProperty *requestingProperty)
Update self based on the "unchecked" values of all required properties.
superclass for all SM properties
static vtkSMDoubleRangeDomain * New()
property representing a vector of integers
virtual int SetDefaultValues(vtkSMProperty *, bool vtkNotUsed(use_unchecked_values))
A vtkSMProperty is often defined with a default value in the XML itself.
Definition: vtkSMDomain.h:103
virtual int ReadXMLAttributes(vtkSMProperty *prop, vtkPVXMLElement *elem)
Set the appropriate ivars from the xml element.
Modes
SCALED_EXTENT: is used for vtkPVScaleFactorEntry.
double range domain based on array range
This is used by vtkPVXMLParser to represent an XML document starting at the root element.