Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
Christian Butz
VTK
Commits
f68cc0bc
Commit
f68cc0bc
authored
Oct 29, 2016
by
David E. DeMarle
Browse files
Options
Browse Files
Download
Plain Diff
Merge commit '
c08a4b50
' into release
parents
15588737
c08a4b50
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
81 additions
and
31 deletions
+81
-31
Rendering/VolumeOpenGL2/vtkSmartVolumeMapper.h
Rendering/VolumeOpenGL2/vtkSmartVolumeMapper.h
+81
-31
No files found.
Rendering/VolumeOpenGL2/vtkSmartVolumeMapper.h
View file @
f68cc0bc
...
...
@@ -334,10 +334,10 @@ public:
};
vtkSetClampMacro
(
VectorMode
,
int
,
-
1
,
1
);
vtk
S
et
Clamp
Macro
(
Vector
Component
,
int
,
0
,
3
);
vtk
G
etMacro
(
Vector
Mode
,
int
);
int
VectorMode
;
int
VectorComponent
;
vtkSetClampMacro
(
VectorComponent
,
int
,
0
,
3
)
;
vtkGetMacro
(
VectorComponent
,
int
)
;
//@}
protected:
...
...
@@ -358,32 +358,52 @@ protected:
*/
void
ConnectFilterInput
(
vtkImageResample
*
f
);
// Window / level ivars
//@{
/**
* Window / level ivars
*/
float
FinalColorWindow
;
float
FinalColorLevel
;
//@}
// GPU mapper-specific memory ivars.
//@{
/**
* GPU mapper-specific memory ivars.
*/
vtkIdType
MaxMemoryInBytes
;
float
MaxMemoryFraction
;
//@}
// Used for downsampling.
/**
* Used for downsampling.
*/
int
InterpolationMode
;
// The requested render mode is used to compute the current render mode. Note
// that the current render mode can be invalid if the requested mode is not
// supported.
//@{
/**
* The requested render mode is used to compute the current render mode. Note
* that the current render mode can be invalid if the requested mode is not
* supported.
*/
int
RequestedRenderMode
;
int
CurrentRenderMode
;
//@}
// Initialization variables.
//@{
/**
* Initialization variables.
*/
int
Initialized
;
vtkTimeStamp
SupportStatusCheckTime
;
int
GPUSupported
;
int
RayCastSupported
;
int
LowResGPUNecessary
;
//@}
// This is the resample filter that may be used if we need to
// create a low resolution version of the volume for GPU rendering
/**
* This is the resample filter that may be used if we need to
* create a low resolution version of the volume for GPU rendering
*/
vtkImageResample
*
GPUResampleFilter
;
//@{
...
...
@@ -400,46 +420,76 @@ protected:
vtkImageData
*
InputDataMagnitude
;
//@}
// The initialize method. Called from ComputeRenderMode whenever something
// relevant has changed.
/**
* The initialize method. Called from ComputeRenderMode whenever something
* relevant has changed.
*/
void
Initialize
(
vtkRenderer
*
ren
,
vtkVolume
*
vol
);
// The method that computes the render mode from the requested render mode
// based on the support status for each render method.
/**
* The method that computes the render mode from the requested render mode
* based on the support status for each render method.
*/
void
ComputeRenderMode
(
vtkRenderer
*
ren
,
vtkVolume
*
vol
);
// The three potential mappers
//@{
/**
* The three potential mappers
*/
vtkGPUVolumeRayCastMapper
*
GPULowResMapper
;
vtkGPUVolumeRayCastMapper
*
GPUMapper
;
vtkFixedPointVolumeRayCastMapper
*
RayCastMapper
;
//@}
// We need to keep track of the blend mode we had when we initialized
// because we need to reinitialize (and recheck hardware support) if
// it changes
/**
* We need to keep track of the blend mode we had when we initialized
* because we need to reinitialize (and recheck hardware support) if
* it changes
*/
int
InitializedBlendMode
;
// The distance between sample points along the ray
/**
* The distance between sample points along the ray
*/
float
SampleDistance
;
// Set whether or not the sample distance should be automatically calculated
// within the internal volume mapper
/**
* Set whether or not the sample distance should be automatically calculated
* within the internal volume mapper
*/
int
AutoAdjustSampleDistances
;
// If the DesiredUpdateRate of the vtkRenderWindow causing the Render is at
// or above this value, the render is considered interactive. Otherwise it is
// considered still.
/**
* If the DesiredUpdateRate of the vtkRenderWindow causing the Render is at
* or above this value, the render is considered interactive. Otherwise it is
* considered still.
*/
double
InteractiveUpdateRate
;
// If the InteractiveAdjustSampleDistances flag is enabled,
// vtkSmartVolumeMapper interactively sets and resets the
// AutoAdjustSampleDistances flag on the internal volume mapper. This flag
// along with InteractiveUpdateRate is useful to adjust volume mapper sample
// distance based on whether the render is interactive or still.
/**
* If the InteractiveAdjustSampleDistances flag is enabled,
* vtkSmartVolumeMapper interactively sets and resets the
* AutoAdjustSampleDistances flag on the internal volume mapper. This flag
* along with InteractiveUpdateRate is useful to adjust volume mapper sample
* distance based on whether the render is interactive or still.
*/
int
InteractiveAdjustSampleDistances
;
//@{
/**
* VectorMode is a special rendering mode for 3-component vectors which makes
* use of GPURayCastMapper's independent-component capabilities. In this mode,
* a single component in the vector can be selected for rendering. In addition,
* the mapper can compute a scalar field representing the magnitude of this vector
* using a vtkImageMagnitude object (MAGNITUDE mode).
*/
int
VectorMode
;
int
VectorComponent
;
//@}
private:
/**
* Adjust the GPUMapper's parameters (ColorTable, Weights, etc.) to render
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment