VTK  9.3.20240418
vtkVolumePicker.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2 // SPDX-License-Identifier: BSD-3-Clause
24 #ifndef vtkVolumePicker_h
25 #define vtkVolumePicker_h
26 
27 #include "vtkCellPicker.h"
28 #include "vtkRenderingVolumeModule.h" // For export macro
29 
30 VTK_ABI_NAMESPACE_BEGIN
31 class VTKRENDERINGVOLUME_EXPORT vtkVolumePicker : public vtkCellPicker
32 {
33 public:
34  static vtkVolumePicker* New();
36  void PrintSelf(ostream& os, vtkIndent indent) override;
37 
39 
46  vtkSetMacro(PickCroppingPlanes, vtkTypeBool);
47  vtkBooleanMacro(PickCroppingPlanes, vtkTypeBool);
48  vtkGetMacro(PickCroppingPlanes, vtkTypeBool);
50 
52 
59  vtkGetMacro(CroppingPlaneId, int);
61 
62 protected:
64  ~vtkVolumePicker() override;
65 
66  void ResetPickInfo() override;
67 
68  double IntersectVolumeWithLine(const double p1[3], const double p2[3], double t1, double t2,
69  vtkProp3D* prop, vtkAbstractVolumeMapper* mapper) override;
70 
71  static int ClipLineWithCroppingRegion(const double bounds[6], const int extent[6], int flags,
72  const double x1[3], const double x2[3], double t1, double t2, int& extentPlaneId,
73  int& numSegments, double* t1List, double* t2List, double* s1List, int* planeIdList);
74 
77 
78 private:
79  vtkVolumePicker(const vtkVolumePicker&) = delete;
80  void operator=(const vtkVolumePicker&) = delete;
81 };
82 
83 VTK_ABI_NAMESPACE_END
84 #endif
Abstract class for a volume mapper.
ray-cast cell picker for all kinds of Prop3Ds
Definition: vtkCellPicker.h:91
a simple class to control print indentation
Definition: vtkIndent.h:108
represents an 3D object for placement in a rendered scene
Definition: vtkProp3D.h:89
ray-cast picker enhanced for volumes
void ResetPickInfo() override
double IntersectVolumeWithLine(const double p1[3], const double p2[3], double t1, double t2, vtkProp3D *prop, vtkAbstractVolumeMapper *mapper) override
~vtkVolumePicker() override
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
static vtkVolumePicker * New()
static int ClipLineWithCroppingRegion(const double bounds[6], const int extent[6], int flags, const double x1[3], const double x2[3], double t1, double t2, int &extentPlaneId, int &numSegments, double *t1List, double *t2List, double *s1List, int *planeIdList)
vtkTypeBool PickCroppingPlanes
@ extent
Definition: vtkX3D.h:345
int vtkTypeBool
Definition: vtkABI.h:64