|
JOGL v2.6.0-rc-20250712
JOGL, High-Performance Graphics Binding for Java (public API).
|
An Animator subclass which renders one frame at the time upon calls to the requestRender() method. More...
Public Member Functions | |
| CustomAnimator (final GLAutoDrawable drawable) | |
| Creates an CustomAnimator with an initial drawable to animate. More... | |
| synchronized void | requestRender () |
| final synchronized boolean | isStarted () |
Indicates whether this animator has been started. More... | |
| final synchronized boolean | isAnimating () |
Indicates whether this animator is started and is not paused. More... | |
| synchronized boolean | start () |
| Starts this animator, if not running. More... | |
| synchronized boolean | stop () |
| Stops this CustomAnimator. More... | |
| final synchronized boolean | isPaused () |
Indicates whether this animator is started and either manually paused or paused automatically due to no added GLAutoDrawables. More... | |
| synchronized boolean | resume () |
| Resumes animation if paused. More... | |
| synchronized boolean | pause () |
| Pauses this animator. More... | |
Public Member Functions inherited from com.jogamp.opengl.util.AnimatorBase | |
| AnimatorBase () | |
| Creates a new, empty Animator instance while expecting an AWT rendering thread if AWT is available. More... | |
| AnimatorBase (final int modeBits) | |
| Creates a new, empty Animator instance with given modeBits. More... | |
| final synchronized void | setModeBits (final boolean enable, final int bitValues) throws GLException |
Enables or disables the given bitValues in this Animators modeBits. More... | |
| synchronized int | getModeBits () |
| final synchronized void | add (final GLAutoDrawable drawable) |
| Adds a drawable to this animator's list of rendering drawables. More... | |
| final synchronized void | remove (final GLAutoDrawable drawable) |
| Removes a drawable from the animator's list of rendering drawables. More... | |
| final synchronized Thread | setExclusiveContext (final Thread t) |
Dedicate all GLAutoDrawable's context to the given exclusive context thread. More... | |
| final boolean | setExclusiveContext (final boolean enable) |
Dedicate all GLAutoDrawable's context to this animator thread. More... | |
| final synchronized boolean | isExclusiveContextEnabled () |
Returns true, if the exclusive context thread is enabled, otherwise false. More... | |
| final synchronized Thread | getExclusiveContextThread () |
Returns the exclusive context thread if isExclusiveContextEnabled() and isStarted(), otherwise null. More... | |
| final synchronized Thread | getThread () |
| final void | setUpdateFPSFrames (final int frames, final PrintStream out) |
| final void | resetFPSCounter () |
| Reset all performance counter (startTime, currentTime, frame number) More... | |
| final int | getUpdateFPSFrames () |
| final long | getFPSStartTime () |
Returns the time of the first display call in milliseconds after enabling this feature via setUpdateFPSFrames(int, PrintStream). More... | |
| final long | getLastFPSUpdateTime () |
Returns the time of the last update interval in milliseconds, if this feature is enabled via setUpdateFPSFrames(int, PrintStream). More... | |
| final long | getLastFPSPeriod () |
| final float | getLastFPS () |
| final int | getTotalFPSFrames () |
| final long | getTotalFPSDuration () |
| final float | getTotalFPS () |
| final void | setIgnoreExceptions (final boolean ignoreExceptions) |
| Sets a flag causing this Animator to ignore exceptions produced while redrawing the drawables. More... | |
| final void | setPrintExceptions (final boolean printExceptions) |
Sets a flag indicating that when exceptions are being ignored by this Animator (see setIgnoreExceptions), to print the exceptions' stack traces for diagnostic information. More... | |
| final UncaughtExceptionHandler | getUncaughtExceptionHandler () |
Returns the UncaughtExceptionHandler invoked when this animator abruptly stops due to an uncaught exception from one of its GLAutoDrawables. More... | |
| final void | setUncaughtExceptionHandler (final UncaughtExceptionHandler handler) |
Set the handler invoked when this animator abruptly stops due to an uncaught exception from one of its GLAutoDrawables. More... | |
| synchronized boolean | isStarted () |
Indicates whether this animator has been started. More... | |
| String | toString () |
| boolean | isStarted () |
Indicates whether this animator has been started. More... | |
| boolean | isAnimating () |
Indicates whether this animator is started and is not paused. More... | |
| boolean | isPaused () |
Indicates whether this animator is started and either manually paused or paused automatically due to no added GLAutoDrawables. More... | |
| Thread | getThread () |
| boolean | start () |
| Starts this animator, if not running. More... | |
| boolean | stop () |
| Stops this animator. More... | |
| boolean | pause () |
| Pauses this animator. More... | |
| boolean | resume () |
| Resumes animation if paused. More... | |
| void | add (GLAutoDrawable drawable) |
| Adds a drawable to this animator's list of rendering drawables. More... | |
| void | remove (GLAutoDrawable drawable) |
| Removes a drawable from the animator's list of rendering drawables. More... | |
| UncaughtExceptionHandler | getUncaughtExceptionHandler () |
Returns the UncaughtExceptionHandler invoked when this animator abruptly stops due to an uncaught exception from one of its GLAutoDrawables. More... | |
| void | setUncaughtExceptionHandler (final UncaughtExceptionHandler handler) |
Set the handler invoked when this animator abruptly stops due to an uncaught exception from one of its GLAutoDrawables. More... | |
| void | setUpdateFPSFrames (int frames, PrintStream out) |
| void | resetFPSCounter () |
| Reset all performance counter (startTime, currentTime, frame number) More... | |
| int | getUpdateFPSFrames () |
| long | getFPSStartTime () |
Returns the time of the first display call in milliseconds after enabling this feature via setUpdateFPSFrames(int, PrintStream). More... | |
| long | getLastFPSUpdateTime () |
Returns the time of the last update interval in milliseconds, if this feature is enabled via setUpdateFPSFrames(int, PrintStream). More... | |
| long | getLastFPSPeriod () |
| float | getLastFPS () |
| int | getTotalFPSFrames () |
| long | getTotalFPSDuration () |
| float | getTotalFPS () |
Protected Member Functions | |
| String | getBaseName (final String prefix) |
Protected Member Functions inherited from com.jogamp.opengl.util.AnimatorBase | |
| final synchronized void | initImpl (final boolean force) |
Initializes implementation details post setup, invoked at add(GLAutoDrawable), start(), . More... | |
| abstract String | getBaseName (String prefix) |
| final synchronized void | setDrawablesExclCtxState (final boolean enable) |
Should be called at start() and stop() from within the animator thread. More... | |
| final boolean | validateDrawablesExclCtxState (final Thread expected) |
| final void | display () throws UncaughtAnimatorException |
| Called every frame to cause redrawing of all of the GLAutoDrawables this Animator manages. More... | |
| final synchronized boolean | handleUncaughtException (final UncaughtAnimatorException ue) |
| Should be called in case of an uncaught exception from within the animator thread, throws given exception if no handler has been installed. More... | |
| final void | flushGLRunnables () |
| Should be called in case of an uncaught exception from within the animator thread to flush all animator. More... | |
| final synchronized boolean | finishLifecycleAction (final Condition waitCondition, long pollPeriod) |
Additional Inherited Members | |
Static Public Attributes inherited from com.jogamp.opengl.util.AnimatorBase | |
| static final int | MODE_EXPECT_AWT_RENDERING_THREAD = 1 << 0 |
If present in modeBits field and AWT is available, implementation is aware of the AWT EDT, otherwise not. More... | |
Static Public Attributes inherited from com.jogamp.opengl.FPSCounter | |
| static final int | DEFAULT_FRAMES_PER_INTERVAL = 5*60 |
Static Protected Member Functions inherited from com.jogamp.opengl.util.AnimatorBase | |
| static String | getThreadName () |
Protected Attributes inherited from com.jogamp.opengl.util.AnimatorBase | |
| int | modeBits |
| AnimatorImpl | impl |
| String | baseName |
| ArrayList< GLAutoDrawable > | drawables = new ArrayList<GLAutoDrawable>() |
| boolean | drawablesEmpty |
| Thread | animThread |
| boolean | ignoreExceptions |
| boolean | printExceptions |
| boolean | exclusiveContext |
| Thread | userExclusiveContextThread |
| UncaughtExceptionHandler | uncaughtExceptionHandler |
| FPSCounterImpl | fpsCounter = new FPSCounterImpl() |
Static Protected Attributes inherited from com.jogamp.opengl.util.AnimatorBase | |
| static final boolean | DEBUG = Debug.debug("Animator") |
| static final long | TO_WAIT_FOR_FINISH_LIFECYCLE_ACTION = 1000 |
A 1s timeout while waiting for a native action response, limiting finishLifecycleAction(Condition, long). More... | |
| static final long | POLLP_WAIT_FOR_FINISH_LIFECYCLE_ACTION = 32 |
An Animator subclass which renders one frame at the time upon calls to the requestRender() method.
Definition at line 563 of file TestGLCanvasAWTActionDeadlock02AWT.java.
| com.jogamp.opengl.test.junit.jogl.awt.TestGLCanvasAWTActionDeadlock02AWT.MiniPApplet.CustomAnimator.CustomAnimator | ( | final GLAutoDrawable | drawable | ) |
Creates an CustomAnimator with an initial drawable to animate.
Definition at line 575 of file TestGLCanvasAWTActionDeadlock02AWT.java.
|
protected |
Reimplemented from com.jogamp.opengl.util.AnimatorBase.
Definition at line 569 of file TestGLCanvasAWTActionDeadlock02AWT.java.
| final synchronized boolean com.jogamp.opengl.test.junit.jogl.awt.TestGLCanvasAWTActionDeadlock02AWT.MiniPApplet.CustomAnimator.isAnimating | ( | ) |
Indicates whether this animator is started and is not paused.
Implements com.jogamp.opengl.GLAnimatorControl.
Definition at line 591 of file TestGLCanvasAWTActionDeadlock02AWT.java.
| final synchronized boolean com.jogamp.opengl.test.junit.jogl.awt.TestGLCanvasAWTActionDeadlock02AWT.MiniPApplet.CustomAnimator.isPaused | ( | ) |
Indicates whether this animator is started and either manually paused or paused automatically due to no added GLAutoDrawables.
Implements com.jogamp.opengl.GLAnimatorControl.
Definition at line 659 of file TestGLCanvasAWTActionDeadlock02AWT.java.
| final synchronized boolean com.jogamp.opengl.test.junit.jogl.awt.TestGLCanvasAWTActionDeadlock02AWT.MiniPApplet.CustomAnimator.isStarted | ( | ) |
Indicates whether this animator has been started.
Reimplemented from com.jogamp.opengl.util.AnimatorBase.
Definition at line 586 of file TestGLCanvasAWTActionDeadlock02AWT.java.
| synchronized boolean com.jogamp.opengl.test.junit.jogl.awt.TestGLCanvasAWTActionDeadlock02AWT.MiniPApplet.CustomAnimator.pause | ( | ) |
Pauses this animator.
In most situations this method blocks until completion, except when called from the animation thread itself or in some cases from an implementation-internal thread like the AWT event queue thread.
Implements com.jogamp.opengl.GLAnimatorControl.
Definition at line 663 of file TestGLCanvasAWTActionDeadlock02AWT.java.
| synchronized void com.jogamp.opengl.test.junit.jogl.awt.TestGLCanvasAWTActionDeadlock02AWT.MiniPApplet.CustomAnimator.requestRender | ( | ) |
Definition at line 581 of file TestGLCanvasAWTActionDeadlock02AWT.java.
| synchronized boolean com.jogamp.opengl.test.junit.jogl.awt.TestGLCanvasAWTActionDeadlock02AWT.MiniPApplet.CustomAnimator.resume | ( | ) |
Resumes animation if paused.
In most situations this method blocks until completion, except when called from the animation thread itself or in some cases from an implementation-internal thread like the AWT event queue thread.
If resumed, all counters (time, frames, ..) are reset to zero.
Implements com.jogamp.opengl.GLAnimatorControl.
Definition at line 661 of file TestGLCanvasAWTActionDeadlock02AWT.java.
| synchronized boolean com.jogamp.opengl.test.junit.jogl.awt.TestGLCanvasAWTActionDeadlock02AWT.MiniPApplet.CustomAnimator.start | ( | ) |
Starts this animator, if not running.
In most situations this method blocks until completion, except when called from the animation thread itself or in some cases from an implementation-internal thread like the AWT event queue thread.
Note that an animator w/o added drawables will be paused automatically.
If started, all counters (time, frames, ..) are reset to zero.
Implements com.jogamp.opengl.GLAnimatorControl.
Definition at line 627 of file TestGLCanvasAWTActionDeadlock02AWT.java.
| synchronized boolean com.jogamp.opengl.test.junit.jogl.awt.TestGLCanvasAWTActionDeadlock02AWT.MiniPApplet.CustomAnimator.stop | ( | ) |
Stops this CustomAnimator.
Implements com.jogamp.opengl.GLAnimatorControl.
Definition at line 638 of file TestGLCanvasAWTActionDeadlock02AWT.java.