Class VolumeClip
- java.lang.Object
- 
- gov.nih.mipav.view.renderer.WildMagic.Render.VolumeObject
- 
- gov.nih.mipav.view.renderer.WildMagic.Render.VolumeClip
 
 
- 
 public class VolumeClip extends VolumeObject Displays the Clipping frames in the VolumeViewer.- See Also:
- VolumeObject.java,- GPUVolumeRender.java
 
- 
- 
Field SummaryFields Modifier and Type Field Description static intCLIP_Astatic intCLIP_EYEstatic intCLIP_EYE_INVstatic intCLIP_Xstatic intCLIP_X_INVstatic intCLIP_Ystatic intCLIP_Y_INVstatic intCLIP_Zstatic intCLIP_Z_INVprivate boolean[]m_abDisplayPolylineenables/disables displaying clip planesprivate WildMagic.LibGraphics.SceneGraph.Polyline[]m_akPolylineaxis-aligned clip plane polylines:private floatm_fMaxMaximum dimension.private WildMagic.LibGraphics.SceneGraph.Nodem_kArbRotateNode for rotating the arbitrary clip plane with the mouse trackball:private WildMagic.LibGraphics.Effects.VertexColor3Effectm_kVertexColor3ShaderShaderEffect for displaying the clip planes.private WildMagic.LibGraphics.Rendering.Cameram_spkEyeCameraScreen camera for displaying the eye clip planes in screen-coordinates:static intMAX_CLIP_PLANES- 
Fields inherited from class gov.nih.mipav.view.renderer.WildMagic.Render.VolumeObjectm_bDisplay, m_bPickable, m_bTransparent, m_fVolumeDiv, m_fVolumeMult, m_fX, m_fY, m_fZ, m_kAlpha, m_kAlphaTransparency, m_kCull, m_kDeleteList, m_kLightShader, m_kLocalScale, m_kPolygonOffset, m_kResolutions, m_kScene, m_kTranslate, m_kVolumeImageA, m_kVolumeImageB, m_kVolumeScale, m_kVolumeTrans, m_kWireframe, m_kZBuffer, m_kZBufferTransparency
 
- 
 - 
Constructor SummaryConstructors Constructor Description VolumeClip(VolumeImage kImageA, WildMagic.LibFoundation.Mathematics.Vector3f kTranslate, float fX, float fY, float fZ)Creates a new VolumeClip object.
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description WildMagic.LibGraphics.SceneGraph.NodeArbRotate()Scene-graph node for rotating the arbitrary clipping plane.private voidCreateClipPlanes()Creates the clipping planes.booleanDisplayArb()Return true if the arbitrary clip plane is current being displayed.voidDisplayArb(boolean bDisplay)Turns displaying the arbitrary clip plane on/off.voiddisplayClipPlane(int iWhich, boolean bDisplay)Called from JPanelClip.voidDisplayEye(boolean bDisplay)Turns displaying the eye clip plane on/off.voidDisplayEyeInv(boolean bDisplay)Turns displaying the inverse-eye clip plane on/off.voiddispose(WildMagic.LibGraphics.Rendering.Renderer kRenderer)Delete local memory.WildMagic.LibFoundation.Mathematics.Vector3fGetArbInverse(float fX)java.awt.Color[]getClipColor()boolean[]getDisplay()booleangetDisplayArb()boolean[]getDisplayEye()boolean[]getDisplayInv()floatGetValue(int iWhich)Returns the value of the specified axis-aligend clip plane.voidPostRender(WildMagic.LibGraphics.Rendering.Renderer kRenderer, WildMagic.LibGraphics.SceneGraph.Culler kCuller)Render the object after all other objects have been rendererd.private voidreCreateClipPlanes()voidreCreateScene(VolumeImage kImageA, WildMagic.LibFoundation.Mathematics.Vector3f kTranslate, float fX, float fY, float fZ)voidRender(WildMagic.LibGraphics.Rendering.Renderer kRenderer, WildMagic.LibGraphics.SceneGraph.Culler kCuller, boolean bPreRender, boolean bSolid)Render the object.voidsetArbColor(WildMagic.LibFoundation.Mathematics.ColorRGB kColor)Sets the arbitrary clip plane color.WildMagic.LibFoundation.Mathematics.Vector3fSetArbPlane(float fX)Set the position of the arbitrary clipping plane, before rotation.voidsetClipPlane(int iWhich, float fValue)Sets the axis-aligned clip plane clipping position.voidsetClipPlaneColor(int iWhich, WildMagic.LibFoundation.Mathematics.ColorRGB kColor)Sets the axis-aligned clip plane color.voidsetEyeClipPlane(float fZ)Sets the eye clip plane position.voidsetEyeInvClipPlane(float fZ)Sets the eye clip plane position.- 
Methods inherited from class gov.nih.mipav.view.renderer.WildMagic.Render.VolumeObjectBlend, Dropper, Erase, GetBackface, getDepth, GetDisplay, GetMesh, GetName, GetPickable, GetPolygonMode, GetScene, getTexCoord, GetTranslate, localToScannerCoords, localToVolumeCoords, Paint, scale, SetBackface, SetColor, SetDisplay, SetFrontface, setImageB, SetLight, SetPickable, SetPolygonMode, SetTranslate, Translate, volumeToLocalCoords
 
- 
 
- 
- 
- 
Field Detail- 
CLIP_Xpublic static final int CLIP_X - See Also:
- Constant Field Values
 
 - 
CLIP_X_INVpublic static final int CLIP_X_INV - See Also:
- Constant Field Values
 
 - 
CLIP_Ypublic static final int CLIP_Y - See Also:
- Constant Field Values
 
 - 
CLIP_Y_INVpublic static final int CLIP_Y_INV - See Also:
- Constant Field Values
 
 - 
CLIP_Zpublic static final int CLIP_Z - See Also:
- Constant Field Values
 
 - 
CLIP_Z_INVpublic static final int CLIP_Z_INV - See Also:
- Constant Field Values
 
 - 
CLIP_EYEpublic static final int CLIP_EYE - See Also:
- Constant Field Values
 
 - 
CLIP_EYE_INVpublic static final int CLIP_EYE_INV - See Also:
- Constant Field Values
 
 - 
CLIP_Apublic static final int CLIP_A - See Also:
- Constant Field Values
 
 - 
MAX_CLIP_PLANESpublic static final int MAX_CLIP_PLANES - See Also:
- Constant Field Values
 
 - 
m_kVertexColor3Shaderprivate WildMagic.LibGraphics.Effects.VertexColor3Effect m_kVertexColor3Shader ShaderEffect for displaying the clip planes.
 - 
m_akPolylineprivate WildMagic.LibGraphics.SceneGraph.Polyline[] m_akPolyline axis-aligned clip plane polylines:
 - 
m_abDisplayPolylineprivate boolean[] m_abDisplayPolyline enables/disables displaying clip planes
 - 
m_spkEyeCameraprivate WildMagic.LibGraphics.Rendering.Camera m_spkEyeCamera Screen camera for displaying the eye clip planes in screen-coordinates:
 - 
m_kArbRotateprivate WildMagic.LibGraphics.SceneGraph.Node m_kArbRotate Node for rotating the arbitrary clip plane with the mouse trackball:
 - 
m_fMaxprivate float m_fMax Maximum dimension.
 
- 
 - 
Constructor Detail- 
VolumeClippublic VolumeClip(VolumeImage kImageA, WildMagic.LibFoundation.Mathematics.Vector3f kTranslate, float fX, float fY, float fZ) Creates a new VolumeClip object.- Parameters:
- kImageA- the VolumeImage containing shared data and textures for rendering.
- kTranslate- translation in the scene-graph for this object.
- fX- the size of the volume in the x-dimension (extent * resolutions)
- fY- the size of the volume in the y-dimension (extent * resolutions)
- fZ- the size of the volume in the z-dimension (extent * resolutions)
 
 
- 
 - 
Method Detail- 
ArbRotatepublic WildMagic.LibGraphics.SceneGraph.Node ArbRotate() Scene-graph node for rotating the arbitrary clipping plane.- Returns:
- Scene-graph node for rotating the arbitrary clipping plane.
 
 - 
DisplayArbpublic boolean DisplayArb() Return true if the arbitrary clip plane is current being displayed.- Returns:
- true if the arbitrary clip plane is current being displayed.
 
 - 
DisplayArbpublic void DisplayArb(boolean bDisplay) Turns displaying the arbitrary clip plane on/off.- Parameters:
- bDisplay- when true display the arbitrary clip plane.
 
 - 
displayClipPlanepublic void displayClipPlane(int iWhich, boolean bDisplay)Called from JPanelClip. Sets the axis-aligned clip plane display on/off.- Parameters:
- iWhich- the clip plane to set.
- bDisplay- on/off.
 
 - 
DisplayEyepublic void DisplayEye(boolean bDisplay) Turns displaying the eye clip plane on/off.- Parameters:
- bDisplay- when true display the eye clip plane.
 
 - 
DisplayEyeInvpublic void DisplayEyeInv(boolean bDisplay) Turns displaying the inverse-eye clip plane on/off.- Parameters:
- bDisplay- when true display the inverse-eye clip plane.
 
 - 
disposepublic void dispose(WildMagic.LibGraphics.Rendering.Renderer kRenderer) Delete local memory.- Overrides:
- disposein class- VolumeObject
 
 - 
getDisplaypublic boolean[] getDisplay() 
 - 
getDisplayInvpublic boolean[] getDisplayInv() 
 - 
getClipColorpublic java.awt.Color[] getClipColor() 
 - 
getDisplayEyepublic boolean[] getDisplayEye() 
 - 
getDisplayArbpublic boolean getDisplayArb() 
 - 
GetValuepublic float GetValue(int iWhich) Returns the value of the specified axis-aligend clip plane.- Parameters:
- iWhich- one of the 6 clip planes
- Returns:
- the value of the specified axis-aligend clip plane.
 
 - 
PostRenderpublic void PostRender(WildMagic.LibGraphics.Rendering.Renderer kRenderer, WildMagic.LibGraphics.SceneGraph.Culler kCuller)Render the object after all other objects have been rendererd. Useful for screen-space objects such as the eye-clip plane.- Overrides:
- PostRenderin class- VolumeObject
- Parameters:
- kRenderer- the OpenGLRenderer object.
- kCuller- the Culler object.
 
 - 
Renderpublic void Render(WildMagic.LibGraphics.Rendering.Renderer kRenderer, WildMagic.LibGraphics.SceneGraph.Culler kCuller, boolean bPreRender, boolean bSolid)Render the object.- Specified by:
- Renderin class- VolumeObject
- Parameters:
- kRenderer- the OpenGLRenderer object.
- kCuller- the Culler object.
 
 - 
setArbColorpublic void setArbColor(WildMagic.LibFoundation.Mathematics.ColorRGB kColor) Sets the arbitrary clip plane color.- Parameters:
- kColor- the new color.
 
 - 
SetArbPlanepublic WildMagic.LibFoundation.Mathematics.Vector3f SetArbPlane(float fX) Set the position of the arbitrary clipping plane, before rotation.- Parameters:
- fX- the position of the arbitrary clipping plane, before rotation.
 
 - 
GetArbInversepublic WildMagic.LibFoundation.Mathematics.Vector3f GetArbInverse(float fX) 
 - 
setClipPlanepublic void setClipPlane(int iWhich, float fValue)Sets the axis-aligned clip plane clipping position.- Parameters:
- iWhich- one of the 6 clip planes
- fValue- the clipping position.
 
 - 
setClipPlaneColorpublic void setClipPlaneColor(int iWhich, WildMagic.LibFoundation.Mathematics.ColorRGB kColor)Sets the axis-aligned clip plane color.- Parameters:
- iWhich- one of the 6 clip planes
- kColor- the new color.
 
 - 
setEyeClipPlanepublic void setEyeClipPlane(float fZ) Sets the eye clip plane position.- Parameters:
- f4- clip position (same value as sSlice in JPanelClip)
- bDisplay- on/off.
 
 - 
setEyeInvClipPlanepublic void setEyeInvClipPlane(float fZ) Sets the eye clip plane position.- Parameters:
- f4- clip position (same value as sSlice in JPanelClip)
- bDisplay- on/off.
 
 - 
CreateClipPlanesprivate void CreateClipPlanes() Creates the clipping planes.
 - 
reCreateScenepublic void reCreateScene(VolumeImage kImageA, WildMagic.LibFoundation.Mathematics.Vector3f kTranslate, float fX, float fY, float fZ) 
 - 
reCreateClipPlanesprivate void reCreateClipPlanes() 
 
- 
 
-