jjdh API

jjdh.opengl.core.counter
Class FixedTimeCounter

java.lang.Object
  extended by jjdh.opengl.core.counter.AbstractFrameCounter
      extended by jjdh.opengl.core.counter.FixedTimeCounter
All Implemented Interfaces:
FrameCounter

public class FixedTimeCounter
extends AbstractFrameCounter


Field Summary
protected  long resolution
           
protected  long startTime
           
 
Fields inherited from class jjdh.opengl.core.counter.AbstractFrameCounter
fps, frames
 
Constructor Summary
FixedTimeCounter()
           
FixedTimeCounter(int milliseconds)
           
FixedTimeCounter(long resolution, TimeUnit timeUnit)
           
 
Method Summary
 void addOneFrame()
          Notifies this counter that another frame was drawn.
 String detailedToString()
           
 
Methods inherited from class jjdh.opengl.core.counter.AbstractFrameCounter
getFrames, getFramesPerSecond, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

resolution

protected long resolution

startTime

protected long startTime
Constructor Detail

FixedTimeCounter

public FixedTimeCounter()

FixedTimeCounter

public FixedTimeCounter(int milliseconds)

FixedTimeCounter

public FixedTimeCounter(long resolution,
                        TimeUnit timeUnit)
Method Detail

addOneFrame

public void addOneFrame()
Description copied from interface: FrameCounter
Notifies this counter that another frame was drawn.

Specified by:
addOneFrame in interface FrameCounter
Specified by:
addOneFrame in class AbstractFrameCounter

detailedToString

public String detailedToString()
Specified by:
detailedToString in interface FrameCounter
Overrides:
detailedToString in class AbstractFrameCounter
Returns:
a detailed textual description of the current frame rate

jjdh API

Copyright © 2006 Jonas Jacobi and Dennis Heidsiek. All Rights Reserved.