Package gaiasky.scenegraph
Class FadeNode
- java.lang.Object
-
- gaiasky.scenegraph.SceneGraphNode
-
- gaiasky.scenegraph.AbstractPositionEntity
-
- gaiasky.scenegraph.FadeNode
-
- All Implemented Interfaces:
com.badlogic.gdx.utils.Disposable,IStarContainer,IPosition
- Direct Known Subclasses:
AbstractOctreeWrapper,BackgroundModel,Constellation,GenericCatalog,MeshObject,ParticleGroup,Text2D
public class FadeNode extends AbstractPositionEntity
Node that offers fade-in and fade-out capabilities.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class gaiasky.scenegraph.SceneGraphNode
SceneGraphNode.RenderGroup, SceneGraphNode.TLV3, SceneGraphNode.TLV3D
-
-
Field Summary
Fields Modifier and Type Field Description protected CatalogInfocatalogInfoInformation on the catalog this fade node represents (particle group, octree, etc.)protected booleanhighlightedIs it highlighted?protected float[]hlcprotected IAttributehlcmaprotected inthlcmiprotected doublehlcmmaxprotected doublehlcmminprotected booleanhlplainbooleaninSceneGraphIs the node already in the scene graph?protected float[]labelcolorColour of labelprotected Vector3dlabelPositionPosition of label-
Fields inherited from class gaiasky.scenegraph.AbstractPositionEntity
cc, coordinates, copy, distToCamera, octant, octantId, pos, posSph, size, viewAngle, viewAngleApparent
-
Fields inherited from class gaiasky.scenegraph.SceneGraphNode
aux3d1, aux3d2, aux3d3, aux3d4, aux3f1, aux3f2, aux3f3, aux3f4, children, computed, ct, id, localTransform, namekey, names, numChildren, opacity, orientation, parent, parentkey, parentName, ROOT_NAME, sg, translation
-
-
Constructor Summary
Constructors Constructor Description FadeNode()FadeNode(java.lang.String name, SceneGraphNode parent)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidaddToRenderLists(ICamera camera)Adds this entity to the necessary render lists after the distance to the camera and the view angle have been determined.voiddoneLoading(com.badlogic.gdx.assets.AssetManager manager)protected floatgetBaseOpacity()CatalogInfogetCatalogInfo()IAttributegetHlcma()intgetHlcmi()doublegetHlcmmax()doublegetHlcmmin()voidhighlight(boolean hl, float[] color)Highlight using a plain colorvoidhighlight(boolean hl, int cmi, IAttribute cma, double cmmin, double cmmax)Highlight using a colormapbooleanisHighlighted()booleanisHlplain()booleanisVisible()voidsetCataloginfo(java.util.Map<java.lang.String,java.lang.String> map)voidsetCatalogInfo(CatalogInfo info)voidsetCatalogInfoBare(CatalogInfo info)voidsetFadein(double[] fadein)voidsetFadeout(double[] fadeout)voidsetLabelcolor(double[] labelcolor)Sets the label colorvoidsetLabelcolor(float[] labelcolor)voidsetLabelposition(double[] labelposition)Sets the position of the label, in parsecs and in the internal reference framevoidsetPosition(double[] pos)voidsetPositionobjectname(java.lang.String po)voidsetSize(java.lang.Double size)Sets the absolute size (diameter) of this entityvoidsetSize(java.lang.Long size)Sets the absolute size (diameter) of this entityvoidsetUp()voidsetVisible(boolean visible)voidupdate(ITimeFrameProvider time, Vector3d parentTransform, ICamera camera, float opacity)voidupdateLocal(ITimeFrameProvider time, ICamera camera)Updates the local transform matrix.voidupdateLocalValues(ITimeFrameProvider time, ICamera camera)This function updates all the local values before the localTransform is updated.-
Methods inherited from class gaiasky.scenegraph.AbstractPositionEntity
computeFuturePosition, getAbsoluteOrientation, getAbsolutePosition, getAbsolutePosition, getAlpha, getDelta, getDistToCamera, getHeight, getHeight, getHeight, getHeightScale, getNext, getOctant, getPos, getPosition, getPosition, getPosSph, getPredictedPosition, getRadius, getSimpleCopy, getSize, getViewAngle, getViewAngleApparent, isCopy, mustUpdatePosition, render2DLabel, render2DLabel, render2DLabel, render2DLabel, render3DLabel, setColor, setColor, setCoordinates
-
Methods inherited from class gaiasky.scenegraph.SceneGraphNode
add, add, addChild, addChild, addFocusableObjects, addName, addNodes, addToIndex, addToRender, dispose, getAggregatedChildren, getChildByName, getChildByNameAndType, getChildrenByType, getComponentType, getCt, getFirstStarAncestor, getId, getLineCopy, getName, getNames, getNode, getNode, getOpacity, getOrientation, getRoot, getSceneGraphDepth, getStarCount, getVelocity, hasName, hasName, initialize, insert, insert, isInRender, isInRender, isValidPosition, isVisibilityOn, mustAddToIndex, namesConcat, removeChild, removeFromIndex, removeFromRender, returnToPool, setComputedFlag, setCt, setCt, setId, setName, setNamekey, setNames, setParent, setParentkey, toString, update, updateNames, updateNamesRec
-
-
-
-
Field Detail
-
labelPosition
protected Vector3d labelPosition
Position of label
-
labelcolor
protected float[] labelcolor
Colour of label
-
inSceneGraph
public boolean inSceneGraph
Is the node already in the scene graph?
-
catalogInfo
protected CatalogInfo catalogInfo
Information on the catalog this fade node represents (particle group, octree, etc.)
-
highlighted
protected boolean highlighted
Is it highlighted?
-
hlplain
protected boolean hlplain
-
hlc
protected float[] hlc
-
hlcmi
protected int hlcmi
-
hlcma
protected IAttribute hlcma
-
hlcmmin
protected double hlcmmin
-
hlcmmax
protected double hlcmmax
-
-
Constructor Detail
-
FadeNode
public FadeNode()
-
FadeNode
public FadeNode(java.lang.String name, SceneGraphNode parent)
-
-
Method Detail
-
doneLoading
public void doneLoading(com.badlogic.gdx.assets.AssetManager manager)
- Overrides:
doneLoadingin classAbstractPositionEntity
-
update
public void update(ITimeFrameProvider time, Vector3d parentTransform, ICamera camera, float opacity)
- Overrides:
updatein classSceneGraphNode
-
updateLocal
public void updateLocal(ITimeFrameProvider time, ICamera camera)
Description copied from class:AbstractPositionEntityUpdates the local transform matrix.- Overrides:
updateLocalin classAbstractPositionEntity
-
getBaseOpacity
protected float getBaseOpacity()
-
addToRenderLists
protected void addToRenderLists(ICamera camera)
Description copied from class:AbstractPositionEntityAdds this entity to the necessary render lists after the distance to the camera and the view angle have been determined.- Specified by:
addToRenderListsin classAbstractPositionEntity
-
updateLocalValues
public void updateLocalValues(ITimeFrameProvider time, ICamera camera)
Description copied from class:AbstractPositionEntityThis function updates all the local values before the localTransform is updated. Position, rotations and scale must be updated in here.- Specified by:
updateLocalValuesin classAbstractPositionEntity
-
setFadein
public void setFadein(double[] fadein)
-
setFadeout
public void setFadeout(double[] fadeout)
-
setPosition
public void setPosition(double[] pos)
-
setLabelposition
public void setLabelposition(double[] labelposition)
Sets the position of the label, in parsecs and in the internal reference frame- Parameters:
labelposition-
-
setLabelcolor
public void setLabelcolor(double[] labelcolor)
Sets the label color- Overrides:
setLabelcolorin classAbstractPositionEntity- Parameters:
labelcolor-
-
setLabelcolor
public void setLabelcolor(float[] labelcolor)
- Overrides:
setLabelcolorin classAbstractPositionEntity
-
setPositionobjectname
public void setPositionobjectname(java.lang.String po)
-
setVisible
public void setVisible(boolean visible)
-
isVisible
public boolean isVisible()
-
setCatalogInfoBare
public void setCatalogInfoBare(CatalogInfo info)
-
setCatalogInfo
public void setCatalogInfo(CatalogInfo info)
-
getCatalogInfo
public CatalogInfo getCatalogInfo()
-
setCataloginfo
public void setCataloginfo(java.util.Map<java.lang.String,java.lang.String> map)
-
highlight
public void highlight(boolean hl, float[] color)Highlight using a plain color- Parameters:
hl- Whether to highlightcolor- The plain color
-
highlight
public void highlight(boolean hl, int cmi, IAttribute cma, double cmmin, double cmmax)Highlight using a colormap- Parameters:
hl- Whether to highlightcmi- Color map indexcma- Attributecmmin- Min mapping valuecmmax- Max mapping value
-
isHighlighted
public boolean isHighlighted()
-
setUp
public void setUp()
- Overrides:
setUpin classSceneGraphNode
-
setSize
public void setSize(java.lang.Long size)
Description copied from class:AbstractPositionEntitySets the absolute size (diameter) of this entity- Overrides:
setSizein classAbstractPositionEntity- Parameters:
size- The diameter in internal units
-
setSize
public void setSize(java.lang.Double size)
Description copied from class:AbstractPositionEntitySets the absolute size (diameter) of this entity- Overrides:
setSizein classAbstractPositionEntity- Parameters:
size- The diameter in internal units
-
isHlplain
public boolean isHlplain()
-
getHlcmi
public int getHlcmi()
-
getHlcma
public IAttribute getHlcma()
-
getHlcmmin
public double getHlcmmin()
-
getHlcmmax
public double getHlcmmax()
-
-