vtk
Class vtkTensorGlyph

java.lang.Object
  extended byvtk.vtkObjectBase
      extended byvtk.vtkObject
          extended byvtk.vtkProcessObject
              extended byvtk.vtkSource
                  extended byvtk.vtkPolyDataSource
                      extended byvtk.vtkDataSetToPolyDataFilter
                          extended byvtk.vtkTensorGlyph
All Implemented Interfaces:
java.io.Serializable

public class vtkTensorGlyph
extends vtkDataSetToPolyDataFilter
implements java.io.Serializable

vtkTensorGlyph - scale and orient glyph(s) according to tensor eigenvalues and eigenvectors. vtkTensorGlyph is a filter that copies a geometric representation (specified as polygonal data) to every input point. The geometric representation, or glyph, can be scaled and/or rotated according to the tensor at the input point. Scaling and rotation is controlled by the eigenvalues/eigenvectors of the tensor as follows. For each tensor, the eigenvalues (and associated eigenvectors) are sorted to determine the major, medium, and minor eigenvalues/eigenvectors. If the boolean variable ThreeGlyphs is not set the major eigenvalue scales the glyph in the x-direction, the medium in the y-direction, and the minor in the z-direction. Then, the glyph is rotated so that the glyph's local x-axis lies along the major eigenvector, y-axis along the medium eigenvector, and z-axis along the minor. If the boolean variable ThreeGlyphs is set three glyphs are produced, each of them oriented along an eigenvector and scaled according to the corresponding eigenvector. If the boolean variable Symmetric is set each glyph is mirrored (2 or 6 glyphs will be produced) The x-axis of the source glyph will correspond to the eigenvector on output. Point (0,0,0) in the source will be placed in the data point. Variable Length will normally correspond to the distance from the origin to the tip of the source glyph along the x-axis, but can be changed to produce other results when Symmetric is on, e.g. glyphs that do not touch or that overlap. Please note that when Symmetric is false it will generally be better to place the source glyph from (-0.5,0,0) to (0.5,0,0), i.e. centred at the origin. When symmetric is true the placement from (0,0,0) to (1,0,0) will generally be more convenient. A scale factor is provided to control the amount of scaling. Also, you can turn off scaling completely if desired. The boolean variable ClampScaling controls the maximum scaling (in conjunction with MaxScaleFactor.) This is useful in certain applications where singularities or large order of magnitude differences exist in the eigenvalues. If the boolean variable ColorGlyphs is set to true the glyphs are colored. The glyphs can be colored using the input scalars (SetColorModeToScalars), which is the default, or colored using the eigenvalues (SetColorModeToEigenvalues). Another instance variable, ExtractEigenvalues, has been provided to control extraction of eigenvalues/eigenvectors. If this boolean is false, then eigenvalues/eigenvectors are not extracted, and the columns of the tensor are taken as the eigenvectors (the norm of column, always positive, is the eigenvalue). This allows additional capability over the vtkGlyph3D object. That is, the glyph can be oriented in three directions instead of one. JavaBean wrapper for vtkTensorGlyph object.

Author:
vtk2jbean Automatic JavaBean wrapper for VTK.
See Also:
vtkGlyph3D, vtkPointLoad, Serialized Form

Field Summary
protected  java.beans.PropertyChangeSupport changes
           
 
Fields inherited from class vtk.vtkObjectBase
vtkId
 
Constructor Summary
  vtkTensorGlyph()
           
protected vtkTensorGlyph(int dmy)
           
 
Method Summary
 void clampScalingOff()
          Turn on/off scalar clamping.
 void clampScalingOn()
          Turn on/off scalar clamping.
 void colorGlyphsOff()
          Turn on/off coloring of glyph with input scalar data or eigenvalues.
 void colorGlyphsOn()
          Turn on/off coloring of glyph with input scalar data or eigenvalues.
 void extractEigenvaluesOff()
          Turn on/off extraction of eigenvalues from tensor.
 void extractEigenvaluesOn()
          Turn on/off extraction of eigenvalues from tensor.
 int getClampScaling()
          Turn on/off scalar clamping.
 java.lang.String getClassName()
          Return the class name as a string.
 int getColorGlyphs()
          Turn on/off coloring of glyph with input scalar data or eigenvalues.
 int getColorMode()
          Set the color mode to be used for the glyphs.
 int getColorModeMaxValue()
          Set the color mode to be used for the glyphs.
 int getColorModeMinValue()
          Set the color mode to be used for the glyphs.
 int getExtractEigenvalues()
          Turn on/off extraction of eigenvalues from tensor.
 double getLength()
          Set/Get the distance, along x, from the origin to the end of the source glyph.
 double getMaxScaleFactor()
          Set/Get the maximum allowable scale factor.
 double getScaleFactor()
          Specify scale factor to scale object by.
 int getScaling()
          Turn on/off scaling of glyph with eigenvalues.
 vtkPolyData getSource()
          Specify the geometry to copy to each point.
 int getSymmetric()
          Turn on/off drawing a mirror of each glyph
 vtkTensorGlyph getThisTensorGlyph()
           
 int getThreeGlyphs()
          Turn on/off drawing three glyphs
 int isA(java.lang.String id0)
          Return 1 if this class is the same type of (or a subclass of) the named class.
 void scalingOff()
          Turn on/off scaling of glyph with eigenvalues.
 void scalingOn()
          Turn on/off scaling of glyph with eigenvalues.
 void setClampScaling(int id0)
          Turn on/off scalar clamping.
 void setColorGlyphs(int id0)
          Turn on/off coloring of glyph with input scalar data or eigenvalues.
 void setColorMode(int id0)
          Set the color mode to be used for the glyphs.
 void setColorModeToEigenvalues()
          Set the color mode to be used for the glyphs.
 void setColorModeToScalars()
          Set the color mode to be used for the glyphs.
 void setExtractEigenvalues(int id0)
          Turn on/off extraction of eigenvalues from tensor.
 void setLength(double id0)
          Set/Get the distance, along x, from the origin to the end of the source glyph.
 void setMaxScaleFactor(double id0)
          Set/Get the maximum allowable scale factor.
 void setScaleFactor(double id0)
          Specify scale factor to scale object by.
 void setScaling(int id0)
          Turn on/off scaling of glyph with eigenvalues.
 void setSource(vtkPolyData id0)
          Specify the geometry to copy to each point.
 void setSymmetric(int id0)
          Turn on/off drawing a mirror of each glyph
 void setThreeGlyphs(int id0)
          Turn on/off drawing three glyphs
 void symmetricOff()
          Turn on/off drawing a mirror of each glyph
 void symmetricOn()
          Turn on/off drawing a mirror of each glyph
 void threeGlyphsOff()
          Turn on/off drawing three glyphs
 void threeGlyphsOn()
          Turn on/off drawing three glyphs
protected  void VTKCastInit()
           
 void VTKInit()
           
 
Methods inherited from class vtk.vtkDataSetToPolyDataFilter
computeInputUpdateExtents, getInput, getThisDataSetToPolyDataFilter, setInput
 
Methods inherited from class vtk.vtkPolyDataSource
getOutput, getOutput, getThisPolyDataSource, setOutput
 
Methods inherited from class vtk.vtkSource
getNumberOfOutputs, getOutputIndex, getReleaseDataFlag, getThisSource, inRegisterLoop, propagateUpdateExtent, releaseDataFlagOff, releaseDataFlagOn, setReleaseDataFlag, triggerAsynchronousUpdate, unRegister, unRegisterAllOutputs, update, updateData, updateInformation, updateWholeExtent
 
Methods inherited from class vtk.vtkProcessObject
abortExecuteOff, abortExecuteOn, getAbortExecute, getErrorCode, getNumberOfInputs, getProgress, getProgressMaxValue, getProgressMinValue, getProgressText, getThisProcessObject, removeAllInputs, setAbortExecute, setProgress, setProgressText, squeezeInputArray, updateProgress
 
Methods inherited from class vtk.vtkObject
AddObserver, breakOnError, debugOff, debugOn, getDebug, getGlobalWarningDisplay, getMTime, getThisObject, globalWarningDisplayOff, globalWarningDisplayOn, hasObserver, hasObserver, invokeEvent, invokeEvent, modified, Print, PrintRevisions, register, removeObserver, removeObservers, removeObservers, setDebug, setGlobalWarningDisplay
 
Methods inherited from class vtk.vtkObjectBase
addPropertyChangeListener, finalize, getReferenceCount, getThisObjectBase, isTypeOf, removePropertyChangeListener, setReferenceCount, VTKDelete
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

changes

protected java.beans.PropertyChangeSupport changes
Constructor Detail

vtkTensorGlyph

public vtkTensorGlyph()

vtkTensorGlyph

protected vtkTensorGlyph(int dmy)
Method Detail

getThisTensorGlyph

public vtkTensorGlyph getThisTensorGlyph()

getClassName

public java.lang.String getClassName()
Description copied from class: vtkObjectBase
Return the class name as a string. This method is defined in all subclasses of vtkObjectBase with the vtkTypeRevisionMacro found in vtkSetGet.h.

Overrides:
getClassName in class vtkDataSetToPolyDataFilter

isA

public int isA(java.lang.String id0)
Description copied from class: vtkObjectBase
Return 1 if this class is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeRevisionMacro found in vtkSetGet.h.

Overrides:
isA in class vtkDataSetToPolyDataFilter

setSource

public void setSource(vtkPolyData id0)
Specify the geometry to copy to each point.


getSource

public vtkPolyData getSource()
Specify the geometry to copy to each point.


setScaling

public void setScaling(int id0)
Turn on/off scaling of glyph with eigenvalues.


getScaling

public int getScaling()
Turn on/off scaling of glyph with eigenvalues.


scalingOn

public void scalingOn()
Turn on/off scaling of glyph with eigenvalues.


scalingOff

public void scalingOff()
Turn on/off scaling of glyph with eigenvalues.


setScaleFactor

public void setScaleFactor(double id0)
Specify scale factor to scale object by. (Scale factor always affects output even if scaling is off.)


getScaleFactor

public double getScaleFactor()
Specify scale factor to scale object by. (Scale factor always affects output even if scaling is off.)


setThreeGlyphs

public void setThreeGlyphs(int id0)
Turn on/off drawing three glyphs


getThreeGlyphs

public int getThreeGlyphs()
Turn on/off drawing three glyphs


threeGlyphsOn

public void threeGlyphsOn()
Turn on/off drawing three glyphs


threeGlyphsOff

public void threeGlyphsOff()
Turn on/off drawing three glyphs


setSymmetric

public void setSymmetric(int id0)
Turn on/off drawing a mirror of each glyph


getSymmetric

public int getSymmetric()
Turn on/off drawing a mirror of each glyph


symmetricOn

public void symmetricOn()
Turn on/off drawing a mirror of each glyph


symmetricOff

public void symmetricOff()
Turn on/off drawing a mirror of each glyph


setLength

public void setLength(double id0)
Set/Get the distance, along x, from the origin to the end of the source glyph. It is used to draw the symmetric glyphs.


getLength

public double getLength()
Set/Get the distance, along x, from the origin to the end of the source glyph. It is used to draw the symmetric glyphs.


setExtractEigenvalues

public void setExtractEigenvalues(int id0)
Turn on/off extraction of eigenvalues from tensor.


extractEigenvaluesOn

public void extractEigenvaluesOn()
Turn on/off extraction of eigenvalues from tensor.


extractEigenvaluesOff

public void extractEigenvaluesOff()
Turn on/off extraction of eigenvalues from tensor.


getExtractEigenvalues

public int getExtractEigenvalues()
Turn on/off extraction of eigenvalues from tensor.


setColorGlyphs

public void setColorGlyphs(int id0)
Turn on/off coloring of glyph with input scalar data or eigenvalues. If false, or input scalar data not present, then the scalars from the source object are passed through the filter.


getColorGlyphs

public int getColorGlyphs()
Turn on/off coloring of glyph with input scalar data or eigenvalues. If false, or input scalar data not present, then the scalars from the source object are passed through the filter.


colorGlyphsOn

public void colorGlyphsOn()
Turn on/off coloring of glyph with input scalar data or eigenvalues. If false, or input scalar data not present, then the scalars from the source object are passed through the filter.


colorGlyphsOff

public void colorGlyphsOff()
Turn on/off coloring of glyph with input scalar data or eigenvalues. If false, or input scalar data not present, then the scalars from the source object are passed through the filter.


setColorMode

public void setColorMode(int id0)
Set the color mode to be used for the glyphs. This can be set to use the input scalars (default) or to use the eigenvalues at the point. If ThreeGlyphs is set and the eigenvalues are chosen for coloring then each glyph is colored by the corresponding eigenvalue and if not set the color corresponding to the largest eigenvalue is chosen. The recognized values are: COLOR_BY_SCALARS = 0 (default) COLOR_BY_EIGENVALUES = 1


getColorModeMinValue

public int getColorModeMinValue()
Set the color mode to be used for the glyphs. This can be set to use the input scalars (default) or to use the eigenvalues at the point. If ThreeGlyphs is set and the eigenvalues are chosen for coloring then each glyph is colored by the corresponding eigenvalue and if not set the color corresponding to the largest eigenvalue is chosen. The recognized values are: COLOR_BY_SCALARS = 0 (default) COLOR_BY_EIGENVALUES = 1


getColorModeMaxValue

public int getColorModeMaxValue()
Set the color mode to be used for the glyphs. This can be set to use the input scalars (default) or to use the eigenvalues at the point. If ThreeGlyphs is set and the eigenvalues are chosen for coloring then each glyph is colored by the corresponding eigenvalue and if not set the color corresponding to the largest eigenvalue is chosen. The recognized values are: COLOR_BY_SCALARS = 0 (default) COLOR_BY_EIGENVALUES = 1


getColorMode

public int getColorMode()
Set the color mode to be used for the glyphs. This can be set to use the input scalars (default) or to use the eigenvalues at the point. If ThreeGlyphs is set and the eigenvalues are chosen for coloring then each glyph is colored by the corresponding eigenvalue and if not set the color corresponding to the largest eigenvalue is chosen. The recognized values are: COLOR_BY_SCALARS = 0 (default) COLOR_BY_EIGENVALUES = 1


setColorModeToScalars

public void setColorModeToScalars()
Set the color mode to be used for the glyphs. This can be set to use the input scalars (default) or to use the eigenvalues at the point. If ThreeGlyphs is set and the eigenvalues are chosen for coloring then each glyph is colored by the corresponding eigenvalue and if not set the color corresponding to the largest eigenvalue is chosen. The recognized values are: COLOR_BY_SCALARS = 0 (default) COLOR_BY_EIGENVALUES = 1


setColorModeToEigenvalues

public void setColorModeToEigenvalues()
Set the color mode to be used for the glyphs. This can be set to use the input scalars (default) or to use the eigenvalues at the point. If ThreeGlyphs is set and the eigenvalues are chosen for coloring then each glyph is colored by the corresponding eigenvalue and if not set the color corresponding to the largest eigenvalue is chosen. The recognized values are: COLOR_BY_SCALARS = 0 (default) COLOR_BY_EIGENVALUES = 1


setClampScaling

public void setClampScaling(int id0)
Turn on/off scalar clamping. If scalar clamping is on, the ivar MaxScaleFactor is used to control the maximum scale factor. (This is useful to prevent uncontrolled scaling near singularities.)


getClampScaling

public int getClampScaling()
Turn on/off scalar clamping. If scalar clamping is on, the ivar MaxScaleFactor is used to control the maximum scale factor. (This is useful to prevent uncontrolled scaling near singularities.)


clampScalingOn

public void clampScalingOn()
Turn on/off scalar clamping. If scalar clamping is on, the ivar MaxScaleFactor is used to control the maximum scale factor. (This is useful to prevent uncontrolled scaling near singularities.)


clampScalingOff

public void clampScalingOff()
Turn on/off scalar clamping. If scalar clamping is on, the ivar MaxScaleFactor is used to control the maximum scale factor. (This is useful to prevent uncontrolled scaling near singularities.)


setMaxScaleFactor

public void setMaxScaleFactor(double id0)
Set/Get the maximum allowable scale factor. This value is compared to the combination of the scale factor times the eigenvalue. If less, the scale factor is reset to the MaxScaleFactor. The boolean ClampScaling has to be "on" for this to work.


getMaxScaleFactor

public double getMaxScaleFactor()
Set/Get the maximum allowable scale factor. This value is compared to the combination of the scale factor times the eigenvalue. If less, the scale factor is reset to the MaxScaleFactor. The boolean ClampScaling has to be "on" for this to work.


VTKInit

public void VTKInit()
Overrides:
VTKInit in class vtkObject

VTKCastInit

protected void VTKCastInit()
Overrides:
VTKCastInit in class vtkDataSetToPolyDataFilter


Copyright © 2004 Sydney ViSLAB. All Rights Reserved.