Class Trajectory

java.lang.Object
gaiasky.scene.component.Trajectory
All Implemented Interfaces:
com.badlogic.ashley.core.Component

public class Trajectory extends Object implements com.badlogic.ashley.core.Component
  • Field Details Link icon

    • logger Link icon

      public static final Logger.Log logger
    • body Link icon

      public com.badlogic.ashley.core.Entity body
    • curr Link icon

      public Vector3d curr
    • alpha Link icon

      public double alpha
    • localTransformD Link icon

      public Matrix4d localTransformD
    • provider Link icon

      public String provider
    • multiplier Link icon

      public Double multiplier
    • providerClass Link icon

      public Class<? extends IOrbitDataProvider> providerClass
    • providerInstance Link icon

      public IOrbitDataProvider providerInstance
    • oc Link icon

      public OrbitComponent oc
    • bodyRepresentation Link icon

      public Trajectory.OrbitBodyRepresentation bodyRepresentation
      Control the body/trajectory representation for this object. Note that the body can only be represented when using orbital elements.
    • newMethod Link icon

      public boolean newMethod
      Changes the way in which transformations are applied to the orbit objects. Asteroids have this set to true.
    • coord Link icon

      public double coord
    • model Link icon

    • isInOrbitalElementsGroup Link icon

      public boolean isInOrbitalElementsGroup
    • refreshing Link icon

      public boolean refreshing
      Refreshing state
    • numSamples Link icon

      public int numSamples
      Number of samples for the orbit data provider.
    • orbitStartMs Link icon

      public long orbitStartMs
    • orbitEndMs Link icon

      public long orbitEndMs
    • mustRefresh Link icon

      public boolean mustRefresh
      Whether the orbit must be refreshed when out of bounds
    • closedLoop Link icon

      public boolean closedLoop
      Whether to close the trajectory (connect end point to start point) or not
    • orbitTrail Link icon

      public boolean orbitTrail
      Whether to show the orbit as a trail or not. A trail fades the orbit line as it gets further away from the object.
    • trailMap Link icon

      public float trailMap
      The bottom mapping position for the trail. The orbit trail assigns an opacity value to each point of the orbit, where 1 is the location of the object and 0 is the other end. This mapping parameter defines the location in the orbit (in [0,1]) where we map the opacity value of 0. Set to 0 to have a full trail. Set to 0.5 to have a trail that spans half the orbit. Set to 1 to have no orbit at all.
    • trailMinOpacity Link icon

      public float trailMinOpacity
      Minimum opacity value of the trail. Set this > 0 to raise the global opacity level of the orbit. Effectively, the opacity of the orbit will be mapped from this value to 1.
    • params Link icon

    • bodyColor Link icon

      public float[] bodyColor
      Body color. Color to use to represent the body in orbital elements trajectories, when the bodyRepresentation attribute enables the representation of the body for this trajectory.
    • pointSize Link icon

      public float pointSize
      Point size
    • distUp Link icon

      public float distUp
      Orbits with a body fade out as the camera get closer to the body. This is the far distance, in body radius units, where the orbit starts the fade (mapped to 1). This attribute only has effect if this trajectory has a body.
    • distDown Link icon

      public float distDown
      Orbits with a body fade out as the camera get closer to the body. This is the near distance, in body radius units, where the orbit ends the fade (mapped to 0). This attribute only has effect if this trajectory has a body.
    • refreshRate Link icon

      public double refreshRate
      For orbits that need to be refreshed (i.e. not implemented as orbital elements, but via samples), this is the orbit refresh rate, in [0,1]. Set to 0 to recompute only every period, and set to 1 to recompute as often as possible. Set to negative to use the default re-computation heuristic. This can help reduce the seams between the trajectory lines computed in the past cycle and the current cycle in orbits which are very open.
  • Constructor Details Link icon

    • Trajectory Link icon

      public Trajectory()
  • Method Details Link icon

    • setOrientationModel Link icon

      public void setOrientationModel(String model)
      Sets the orientation model as a string.
      Parameters:
      model - The orientation model.
    • setModel Link icon

      public void setModel(String model)
    • setPointSize Link icon

      public void setPointSize(Long pointSize)
    • setPointsize Link icon

      public void setPointsize(Long pointSize)
    • setPointSize Link icon

      public void setPointSize(Double pointSize)
    • setPointsize Link icon

      public void setPointsize(Double pointSize)
    • setBodyColor Link icon

      public void setBodyColor(double[] color)
    • setPointColor Link icon

      public void setPointColor(double[] color)
    • setPointcolor Link icon

      public void setPointcolor(double[] color)
    • setClosedLoop Link icon

      public void setClosedLoop(Boolean closedLoop)
    • setOrbitProvider Link icon

      public void setOrbitProvider(String provider)
    • setProvider Link icon

      public void setProvider(String provider)
    • setOrbit Link icon

      public void setOrbit(OrbitComponent oc)
    • setOrbitScaleFactor Link icon

      public void setOrbitScaleFactor(Double scaleFactor)
    • setMultiplier Link icon

      public void setMultiplier(Double scaleFactor)
    • setOnlyBody Link icon

      @Deprecated public void setOnlyBody(Boolean onlyBody)
      Deprecated.
      Mutes the orbit line in orbital elements trajectories.
      Parameters:
      onlyBody - Whether to display only the body for this trajectory.
    • setOnlybody Link icon

      @Deprecated public void setOnlybody(Boolean onlyBody)
      Deprecated.
      Alias method, @see setOnlyBody(Boolean).
    • isOnlyBody Link icon

      public boolean isOnlyBody()
    • setBodyRepresentation Link icon

      public void setBodyRepresentation(String representation)
      Sets the body representation for this trajectory.
      Parameters:
      representation - The body representation model. See Trajectory.OrbitBodyRepresentation for more information.
    • setNewmethod Link icon

      public void setNewmethod(Boolean newMethod)
    • setTrail Link icon

      public void setTrail(Boolean trail)
    • setTrailMap Link icon

      public void setTrailMap(Double trailMap)
    • setTrailMinOpacity Link icon

      public void setTrailMinOpacity(Double trailMin)
    • setOrbittrail Link icon

      public void setOrbittrail(Boolean trail)
    • setNumSamples Link icon

      public void setNumSamples(Long numSamples)
    • setFadeDistanceUp Link icon

      public void setFadeDistanceUp(Double distUp)
    • setFadeDistanceDown Link icon

      public void setFadeDistanceDown(Double distDown)
    • setRefreshRate Link icon

      public void setRefreshRate(Double refhreshRate)
    • setBody Link icon

      public void setBody(com.badlogic.ashley.core.Entity entity, double radius)
    • setBody Link icon

      public void setBody(com.badlogic.ashley.core.Entity entity, double radius, float distDown, float distUp)