Package gaiasky.scenegraph
Class FadeNode
java.lang.Object
gaiasky.scenegraph.SceneGraphNode
gaiasky.scenegraph.FadeNode
- All Implemented Interfaces:
com.badlogic.gdx.utils.Disposable,IStarContainer,IVisibilitySwitch,IPosition
- Direct Known Subclasses:
AbstractOctreeWrapper,BackgroundModel,Constellation,GenericCatalog,MeshObject,ParticleGroup,RecursiveGrid,Text2D
Node that offers fade-in and fade-out capabilities.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected CatalogInfoInformation on the catalog this fade node represents (particle group, octree, etc.)protected doubleThe current distance at each cycle, in internal unitsprotected booleanIs it highlighted?protected booleanprotected float[]protected IAttributeprotected intprotected doubleprotected doubleprotected booleanbooleanIs the node already in the scene graph?protected float[]Colour of labelprotected Vector3bPosition of labelFields inherited from class gaiasky.scenegraph.SceneGraphNode
aux3b1, aux3b2, aux3b3, aux3b4, aux3d1, aux3d2, aux3d3, aux3d4, aux3f1, aux3f2, aux3f3, aux3f4, cc, children, computed, coordinates, copy, ct, distToCamera, id, lastStateChangeTimeMs, localTransform, namekey, names, numChildren, octant, octantId, opacity, orientation, parent, parentkey, parentName, pos, posSph, ROOT_NAME, sg, size, translation, viewAngle, viewAngleApparent, visible -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected 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 floatgetHlcma()intgetHlcmi()doubledoublevoidhighlight(boolean hl, float[] color, boolean allVisible)Highlight using a plain colorvoidhighlight(boolean hl, int cmi, IAttribute cma, double cmmin, double cmmax, boolean allVisible)Highlight using a colormapbooleanbooleanbooleanvoidsetCataloginfo(Map<String,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)voidvoidSets the absolute size (diameter) of this entityvoidSets the absolute size (diameter) of this entityvoidsetUp()voidupdate(ITimeFrameProvider time, Vector3b parentTransform, ICamera camera, float opacity)voidupdateLocal(ITimeFrameProvider time, ICamera camera)Updates the transform matrix with the transformations that will apply to the children and the local transform matrix with the transformations that will apply only to this object.voidupdateLocalValues(ITimeFrameProvider time, ICamera camera)This function updates all the local values before the localTransform is updated.protected voidMethods inherited from class gaiasky.scenegraph.SceneGraphNode
add, add, addChild, addChild, addFocusableObjects, addName, addNodes, addToIndex, addToRender, computeFuturePosition, dispose, getAbsoluteOrientation, getAbsolutePosition, getAbsolutePosition, getAggregatedChildren, getAlpha, getChildByName, getChildByNameAndType, getChildrenByComponentType, getChildrenByType, getColor, getComponentType, getCt, getDelta, getDescription, getDistToCamera, getFirstStarAncestor, getHeight, getHeight, getHeight, getHeightScale, getId, getLineCopy, getName, getNames, getNext, getNode, getNode, getOctant, getOpacity, getOrientation, getPos, getPosition, getPosition, getPosSph, getPredictedPosition, getRadius, getRoot, getSceneGraphDepth, getSimpleCopy, getSize, getStarCount, getUnrotatedPos, getVelocity, getViewAngle, getViewAngleApparent, getVisibilityOpacityFactor, hasCt, hasName, hasName, initialize, insert, insert, isCopy, isInRender, isInRender, isValidPosition, isVisibilityOn, isVisible, isVisible, isVisibleGroup, msSinceStateChange, mustAddToIndex, mustUpdatePosition, namesConcat, removeChild, removeFromIndex, removeFromRender, render2DLabel, render2DLabel, render2DLabel, render2DLabel, render3DLabel, render3DLabel, returnToPool, setColor, setColor, setComputedFlag, setCoordinates, setCt, setCt, setDescription, setId, setName, setNamekey, setNames, setParent, setParentkey, setVisible, setVisibleGroup, shouldRender, toString, update, updateNames, updateNamesRec
-
Field Details
-
labelPosition
Position of label -
labelcolor
protected float[] labelcolorColour of label -
currentDistance
protected double currentDistanceThe current distance at each cycle, in internal units -
inSceneGraph
public boolean inSceneGraphIs the node already in the scene graph? -
catalogInfo
Information on the catalog this fade node represents (particle group, octree, etc.) -
highlighted
protected boolean highlightedIs it highlighted? -
hlplain
protected boolean hlplain -
hlc
protected float[] hlc -
hlallvisible
protected boolean hlallvisible -
hlcmi
protected int hlcmi -
hlcma
-
hlcmmin
protected double hlcmmin -
hlcmmax
protected double hlcmmax
-
-
Constructor Details
-
FadeNode
public FadeNode() -
FadeNode
-
-
Method Details
-
doneLoading
public void doneLoading(com.badlogic.gdx.assets.AssetManager manager)- Overrides:
doneLoadingin classSceneGraphNode
-
update
public void update(ITimeFrameProvider time, Vector3b parentTransform, ICamera camera, float opacity)- Overrides:
updatein classSceneGraphNode
-
updateLocal
Description copied from class:SceneGraphNodeUpdates the transform matrix with the transformations that will apply to the children and the local transform matrix with the transformations that will apply only to this object.- Overrides:
updateLocalin classSceneGraphNode
-
updateOpacity
protected void updateOpacity() -
getBaseOpacity
protected float getBaseOpacity() -
addToRenderLists
Description copied from class:SceneGraphNodeAdds this entity to the necessary render lists after the distance to the camera and the view angle have been determined.- Overrides:
addToRenderListsin classSceneGraphNode
-
updateLocalValues
Description copied from class:SceneGraphNodeThis function updates all the local values before the localTransform is updated. Position, rotations and scale must be updated in here.- Overrides:
updateLocalValuesin classSceneGraphNode
-
getFadeIn
-
setFadein
public void setFadein(double[] fadein) -
getFadeOut
-
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 classSceneGraphNode- Parameters:
labelcolor-
-
setLabelcolor
public void setLabelcolor(float[] labelcolor)- Overrides:
setLabelcolorin classSceneGraphNode
-
setPositionobjectname
-
setCatalogInfoBare
-
setCatalogInfo
-
getCatalogInfo
-
setCataloginfo
-
highlight
public void highlight(boolean hl, float[] color, boolean allVisible)Highlight using a plain color- Parameters:
hl- Whether to highlightcolor- The plain colorallVisible- All visible
-
highlight
public void highlight(boolean hl, int cmi, IAttribute cma, double cmmin, double cmmax, boolean allVisible)Highlight using a colormap- Parameters:
hl- Whether to highlightcmi- Color map indexcma- Color map attributecmmin- Min mapping valuecmmax- Max mapping value
-
isHighlighted
public boolean isHighlighted() -
setUp
public void setUp()- Overrides:
setUpin classSceneGraphNode
-
setSize
Description copied from class:SceneGraphNodeSets the absolute size (diameter) of this entity- Overrides:
setSizein classSceneGraphNode- Parameters:
size- The diameter in internal units
-
setSize
Description copied from class:SceneGraphNodeSets the absolute size (diameter) of this entity- Overrides:
setSizein classSceneGraphNode- Parameters:
size- The diameter in internal units
-
isHlplain
public boolean isHlplain() -
getHlcmi
public int getHlcmi() -
getHlcma
-
getHlcmmin
public double getHlcmmin() -
getHlcmmax
public double getHlcmmax() -
isHlAllVisible
public boolean isHlAllVisible()
-