Package gaiasky.util.gravwaves
Class RelativisticEffectsManager
- java.lang.Object
-
- gaiasky.util.gravwaves.RelativisticEffectsManager
-
-
Field Summary
Fields Modifier and Type Field Description com.badlogic.gdx.math.Vector3gwCartesian coordinates from the origin of the grav wave.com.badlogic.gdx.math.Matrix3gwmat3Rotation of gwcom.badlogic.gdx.math.Matrix4gwmat4Rotation of gwfloatgwtimeTime in seconds, synced to the simulation time.float[]htermsHterms: hpluscos, hplussin, htimescos, htimessinfloatomgwWave frequencyfloatvcv/ccom.badlogic.gdx.math.Vector3velDirCamera velocity direction vector
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static RelativisticEffectsManagergetInstance()Vector3dgravitationalWavePos(Vector3d pos)Applies the gravitational wave transformation to the given positionbooleangravWavesOn()static voidinitialize(ITimeFrameProvider time)voidnotify(Events event, java.lang.Object... data)booleanrelAberrationOn()voidupdate(ITimeFrameProvider time, ICamera camera)This must be called every cycle, it updates the needed parameters for the gravitational waves
-
-
-
Field Detail
-
velDir
public com.badlogic.gdx.math.Vector3 velDir
Camera velocity direction vector
-
vc
public float vc
v/c
-
gw
public com.badlogic.gdx.math.Vector3 gw
Cartesian coordinates from the origin of the grav wave. Unit vector
-
gwmat3
public com.badlogic.gdx.math.Matrix3 gwmat3
Rotation of gw
-
gwmat4
public com.badlogic.gdx.math.Matrix4 gwmat4
Rotation of gw
-
gwtime
public float gwtime
Time in seconds, synced to the simulation time. Ready to pass to the shader
-
omgw
public float omgw
Wave frequency
-
hterms
public float[] hterms
Hterms: hpluscos, hplussin, htimescos, htimessin
-
-
Method Detail
-
getInstance
public static RelativisticEffectsManager getInstance()
-
initialize
public static void initialize(ITimeFrameProvider time)
-
relAberrationOn
public boolean relAberrationOn()
-
gravWavesOn
public boolean gravWavesOn()
-
update
public void update(ITimeFrameProvider time, ICamera camera)
This must be called every cycle, it updates the needed parameters for the gravitational waves- Parameters:
time-
-
gravitationalWavePos
public Vector3d gravitationalWavePos(Vector3d pos)
Applies the gravitational wave transformation to the given position- Parameters:
pos- The position for chaining
-
-