de.grogra.imp3d.glsl
public class Measures extends java.lang.Object
ViewComponentAdapter.repaint(int)
and GLSLDisplay.render(int). This class is a singleton
and will only produce correct results if not more than one Display-Window
is open. The methods may be called within the XL-Console.| Modifier and Type | Method and Description |
|---|---|
static Measures |
getInstance() |
void |
printRPSummary()
Print a summary of collected renderpass time.
|
void |
printSummary()
Print a summary of collected render times.
|
void |
restartNow()
This will reset the measurement.
|
void |
saveTimeDiffSummary()
Store the rendertimes obtained from the used Display class to
a csv-File in the current working directory.
|
void |
setCounter(int counter) |
void |
setCurrentFileName(java.lang.String s)
Sets the name for a file into which measures may be saved.
|
void |
setData(int all,
int rend) |
void |
setRedraw(boolean redraw)
Changes behavior of measuring method.
|
void |
setRPTimeDiff(int rpID,
long value)
Stores the time used to process a renderpass.
|
boolean |
shouldRedraw()
Check if scene should be redrawn.
|
void |
startTimer() |
void |
stopTimer(RenderState rs) |
public static Measures getInstance()
public void printRPSummary()
public void printSummary()
public void restartNow()
public void saveTimeDiffSummary()
setCurrentFileName(String).public void setCounter(int counter)
public void setCurrentFileName(java.lang.String s)
s - The filename.public void setData(int all,
int rend)
public void setRedraw(boolean redraw)
redraw - If set to true, the scene will be redrawn after
each call of the render method resulting in continuous drawing.public void setRPTimeDiff(int rpID,
long value)
rpID - The ID of the renderpass. Renderpasses are arbitrarily
categorized into groups ranging from 0 to 6.value - The time to be stored.public boolean shouldRedraw()
ViewComponent.repaint(int) method.public void startTimer()
public void stopTimer(RenderState rs)