Interface ITimeFrameProvider

All Known Implementing Classes:
GlobalClock, RealTimeClock

public interface ITimeFrameProvider
  • Method Summary Link icon

    Modifier and Type
    Method
    Description
    double
    The frame time difference in seconds.
    float
    Returns the fixed frame rate if the mode is fixed frame rate.
    double
    The simulation time difference in hours.
    Gets the current time in UTC.
    double
    Gets the current warp factor
    boolean
    Returns whether the frame rate is set to fixed or not
    boolean
    Is the time on?
    void
    update(double dt)
    Updates this time frame with the system time difference
  • Method Details Link icon

    • getHdiff Link icon

      double getHdiff()
      The simulation time difference in hours.
      Returns:
      The simulation time difference in hours.
    • getDt Link icon

      double getDt()
      The frame time difference in seconds.
      Returns:
      The frame time difference in seconds.
    • getTime Link icon

      Instant getTime()
      Gets the current time in UTC.
      Returns:
      The time as an instant, in UTC.
    • update Link icon

      void update(double dt)
      Updates this time frame with the system time difference
      Parameters:
      dt - System time difference in seconds
    • getWarpFactor Link icon

      double getWarpFactor()
      Gets the current warp factor
      Returns:
      The warp factor
    • isTimeOn Link icon

      boolean isTimeOn()
      Is the time on?
      Returns:
      True if time is on
    • isFixedRateMode Link icon

      boolean isFixedRateMode()
      Returns whether the frame rate is set to fixed or not
      Returns:
      Whether fix rate mode is on
    • getFixedRate Link icon

      float getFixedRate()
      Returns the fixed frame rate if the mode is fixed frame rate. Returns -1 otherwise
      Returns:
      The fixed rate