Class VolumeClipEffect
- java.lang.Object
-
- WildMagic.LibGraphics.ObjectSystem.GraphicsObject
-
- WildMagic.LibGraphics.Effects.Effect
-
- WildMagic.LibGraphics.Effects.ShaderEffect
-
- gov.nih.mipav.view.renderer.WildMagic.Render.VolumeClipEffect
-
- All Implemented Interfaces:
java.io.Serializable
,WildMagic.LibGraphics.ObjectSystem.NameIdInterface
,WildMagic.LibGraphics.ObjectSystem.StreamInterface
- Direct Known Subclasses:
SurfaceClipEffect
,SurfaceLightingEffect
,VolumeCalcEffect
,VolumeShaderEffectMultiPass
public abstract class VolumeClipEffect extends WildMagic.LibGraphics.Effects.ShaderEffect
Clipping effect for Volume Objects.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static int
CLIP_A
static int
CLIP_A_INV
static int
CLIP_EYE
static int
CLIP_EYE_INV
static int
CLIP_X
static int
CLIP_X_INV
static int
CLIP_Y
static int
CLIP_Y_INV
static int
CLIP_Z
static int
CLIP_Z_INV
protected float[][]
m_aafClipData
stores t=clip plane information:protected boolean[]
m_afClipAll
Turn clipping on/off per-axis aligned clip plane, eye-clip planes and arbitrary plane.protected float[]
m_afClipOBBAxis0
protected float[]
m_afClipOBBAxis1
protected float[]
m_afClipOBBAxis2
protected float[]
m_afClipOBBExtent
protected float[]
m_afClipSphereCenter
protected float[]
m_afClipSphereScale
protected float[]
m_afDoClip
Turn clipping on/off.protected float[]
m_afVolumeMatrix
private static java.lang.String[]
m_akClip
Axis-aligned clip plane shader parameter names:protected boolean
m_bClipOBB
protected boolean
m_bClipSphere
static int
MAX_CLIP_PLANES
private static long
serialVersionUID
-
Constructor Summary
Constructors Constructor Description VolumeClipEffect()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
dispose()
private void
EnableClip()
Enable clipping.WildMagic.LibFoundation.Mathematics.Vector3f
getClip()
WildMagic.LibFoundation.Mathematics.Vector4f
getClipArb()
WildMagic.LibFoundation.Mathematics.Vector4f
getClipArbInv()
boolean[]
getClipEnable()
WildMagic.LibFoundation.Mathematics.Vector4f
getClipEye()
WildMagic.LibFoundation.Mathematics.Vector4f
getClipEyeInv()
WildMagic.LibFoundation.Mathematics.Vector3f
getClipInv()
boolean[]
getClipInvEnable()
boolean
isClip()
boolean
isClipAE()
boolean
isClipOBB()
boolean
isClipSphere()
void
OnLoadPrograms(int iPass, WildMagic.LibGraphics.Shaders.Program pkVProgram, WildMagic.LibGraphics.Shaders.Program pkPProgram, WildMagic.LibGraphics.Shaders.Program pkCProgram)
void
ResetClip()
Reset the axis-aligned clip planes, eye, inverse-eye and arbitrary clip planes to neutral.void
SetClip(int iWhich, float data, boolean bEnable)
Enable and set the axis-aligned clip plane.void
SetClipArb(float[] afEquation, boolean bEnable)
Enable and set the arbitrary clip plane.void
SetClipArbInv(float[] afEquation, boolean bEnable)
Enable and set the arbitrary clip plane.void
SetClipEye(float[] afEquation, boolean bEnable)
Enable and set the eye clip plane.void
SetClipEyeInv(float[] afEquation, boolean bEnable)
Enable and set the inverse-eye clip plane.void
SetClipOBB(WildMagic.LibFoundation.Mathematics.Vector3f center, WildMagic.LibFoundation.Mathematics.Vector3f scale, WildMagic.LibFoundation.Mathematics.Vector3f[] axes, float[] extents, boolean bEnable)
void
SetClipSphere(WildMagic.LibFoundation.Mathematics.Vector3f center, WildMagic.LibFoundation.Mathematics.Vector3f scale, float radius, boolean bEnable)
void
setVolumeMatrix(float[] volumeMatrix)
-
Methods inherited from class WildMagic.LibGraphics.Effects.ShaderEffect
GetAllObjectsByName, GetBlending, GetCProgram, GetDiskUsed, GetObjectByID, GetObjectByName, GetPassQuantity, GetPProgram, GetSamplerInformation, GetTexture, GetTexture, GetTextureQuantity, GetVProgram, Link, Load, LoadPrograms, LoadResources, OnReleasePrograms, Register, ReleasePrograms, ReleaseResources, RestoreGlobalState, Save, SaveStrings, SetCProgram, SetDefaultAlphaState, SetGlobalState, SetPassQuantity, SetPShader, SetVShader
-
-
-
-
Field Detail
-
serialVersionUID
private static final long serialVersionUID
- See Also:
- Constant Field Values
-
CLIP_X
public static final int CLIP_X
- See Also:
- Constant Field Values
-
CLIP_X_INV
public static final int CLIP_X_INV
- See Also:
- Constant Field Values
-
CLIP_Y
public static final int CLIP_Y
- See Also:
- Constant Field Values
-
CLIP_Y_INV
public static final int CLIP_Y_INV
- See Also:
- Constant Field Values
-
CLIP_Z
public static final int CLIP_Z
- See Also:
- Constant Field Values
-
CLIP_Z_INV
public static final int CLIP_Z_INV
- See Also:
- Constant Field Values
-
CLIP_EYE
public static final int CLIP_EYE
- See Also:
- Constant Field Values
-
CLIP_EYE_INV
public static final int CLIP_EYE_INV
- See Also:
- Constant Field Values
-
CLIP_A
public static final int CLIP_A
- See Also:
- Constant Field Values
-
CLIP_A_INV
public static final int CLIP_A_INV
- See Also:
- Constant Field Values
-
MAX_CLIP_PLANES
public static final int MAX_CLIP_PLANES
- See Also:
- Constant Field Values
-
m_akClip
private static final java.lang.String[] m_akClip
Axis-aligned clip plane shader parameter names:
-
m_afDoClip
protected float[] m_afDoClip
Turn clipping on/off.
-
m_afClipAll
protected boolean[] m_afClipAll
Turn clipping on/off per-axis aligned clip plane, eye-clip planes and arbitrary plane.
-
m_aafClipData
protected float[][] m_aafClipData
stores t=clip plane information:
-
m_afVolumeMatrix
protected float[] m_afVolumeMatrix
-
m_bClipSphere
protected boolean m_bClipSphere
-
m_afClipSphereCenter
protected float[] m_afClipSphereCenter
-
m_afClipSphereScale
protected float[] m_afClipSphereScale
-
m_afClipOBBAxis0
protected float[] m_afClipOBBAxis0
-
m_afClipOBBAxis1
protected float[] m_afClipOBBAxis1
-
m_afClipOBBAxis2
protected float[] m_afClipOBBAxis2
-
m_afClipOBBExtent
protected float[] m_afClipOBBExtent
-
m_bClipOBB
protected boolean m_bClipOBB
-
-
Method Detail
-
dispose
public void dispose()
- Overrides:
dispose
in classWildMagic.LibGraphics.Effects.ShaderEffect
-
OnLoadPrograms
public void OnLoadPrograms(int iPass, WildMagic.LibGraphics.Shaders.Program pkVProgram, WildMagic.LibGraphics.Shaders.Program pkPProgram, WildMagic.LibGraphics.Shaders.Program pkCProgram)
- Overrides:
OnLoadPrograms
in classWildMagic.LibGraphics.Effects.ShaderEffect
-
ResetClip
public void ResetClip()
Reset the axis-aligned clip planes, eye, inverse-eye and arbitrary clip planes to neutral.
-
SetClip
public void SetClip(int iWhich, float data, boolean bEnable)
Enable and set the axis-aligned clip plane.- Parameters:
iWhich
- one of 6 clip-planes to set.data
- the distance to the clip-plane.
-
SetClipArb
public void SetClipArb(float[] afEquation, boolean bEnable)
Enable and set the arbitrary clip plane.- Parameters:
afEquation
- the clip-plane equation.
-
SetClipArbInv
public void SetClipArbInv(float[] afEquation, boolean bEnable)
Enable and set the arbitrary clip plane.- Parameters:
afEquation
- the clip-plane equation.
-
SetClipEye
public void SetClipEye(float[] afEquation, boolean bEnable)
Enable and set the eye clip plane.- Parameters:
afEquation
- the clip-plane equation.
-
SetClipEyeInv
public void SetClipEyeInv(float[] afEquation, boolean bEnable)
Enable and set the inverse-eye clip plane.- Parameters:
afEquation
- the clip-plane equation.
-
SetClipSphere
public void SetClipSphere(WildMagic.LibFoundation.Mathematics.Vector3f center, WildMagic.LibFoundation.Mathematics.Vector3f scale, float radius, boolean bEnable)
-
SetClipOBB
public void SetClipOBB(WildMagic.LibFoundation.Mathematics.Vector3f center, WildMagic.LibFoundation.Mathematics.Vector3f scale, WildMagic.LibFoundation.Mathematics.Vector3f[] axes, float[] extents, boolean bEnable)
-
setVolumeMatrix
public void setVolumeMatrix(float[] volumeMatrix)
-
EnableClip
private void EnableClip()
Enable clipping.
-
isClipAE
public boolean isClipAE()
-
isClipSphere
public boolean isClipSphere()
-
isClipOBB
public boolean isClipOBB()
-
getClip
public WildMagic.LibFoundation.Mathematics.Vector3f getClip()
-
getClipEnable
public boolean[] getClipEnable()
-
getClipEye
public WildMagic.LibFoundation.Mathematics.Vector4f getClipEye()
-
getClipEyeInv
public WildMagic.LibFoundation.Mathematics.Vector4f getClipEyeInv()
-
getClipArb
public WildMagic.LibFoundation.Mathematics.Vector4f getClipArb()
-
getClipArbInv
public WildMagic.LibFoundation.Mathematics.Vector4f getClipArbInv()
-
getClipInv
public WildMagic.LibFoundation.Mathematics.Vector3f getClipInv()
-
getClipInvEnable
public boolean[] getClipInvEnable()
-
isClip
public boolean isClip()
-
-