public class JoglNewtCanvas extends JoglNewtAbstractDisplay implements JmeCanvasContext
JmeContext.Type
active, animator, autoFlush, canvas, frameRate, useAwt, wasActive, wasAnimating
clContext, created, createdLock, joyInput, keyInput, listener, mouseInput, renderable, renderer, settings, THREAD_NAME, timer
Constructor and Description |
---|
JoglNewtCanvas() |
Modifier and Type | Method and Description |
---|---|
void |
create(boolean waitFor)
Creates the context and makes it active.
|
void |
destroy(boolean waitFor)
Destroys the context completely, making it inactive.
|
void |
display(com.jogamp.opengl.GLAutoDrawable glad) |
void |
dispose(com.jogamp.opengl.GLAutoDrawable arg0)
Callback
|
com.jogamp.newt.awt.NewtCanvasAWT |
getCanvas() |
JmeContext.Type |
getType() |
void |
init(com.jogamp.opengl.GLAutoDrawable drawable) |
protected void |
initGLCanvas() |
protected void |
onCanvasAdded() |
protected void |
onCanvasRemoved() |
void |
restart()
Destroys and then re-creates the context.
|
void |
setTitle(java.lang.String title)
Sets the title of the display (if available).
|
protected void |
startGLCanvas() |
displayChanged, getKeyInput, getMouseInput, getTouchInput, reshape, setAutoFlushFrames
create, destroy, determineMaxSamples, getJoyInput, getNumSamplesToUse, getOpenCLContext, getRenderer, getSettings, getTimer, initContextFirstTime, initOpenCL, internalCreate, internalDestroy, isCreated, isRenderable, setSettings, setSystemListener, waitFor
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getJoyInput, getKeyInput, getMouseInput, getOpenCLContext, getRenderer, getSettings, getTimer, getTouchInput, isCreated, isRenderable, setAutoFlushFrames, setSettings, setSystemListener
protected final void initGLCanvas()
initGLCanvas
in class JoglNewtAbstractDisplay
public JmeContext.Type getType()
getType
in interface JmeContext
public void setTitle(java.lang.String title)
JmeContext
setTitle
in interface JmeContext
title
- The new title of the display.public void restart()
JmeContext
restart
in interface JmeContext
public void create(boolean waitFor)
JmeContext
create
in interface JmeContext
waitFor
- If true, will wait until context has initialized.public void destroy(boolean waitFor)
JmeContext
destroy
in interface JmeContext
waitFor
- If true, will wait until the context is destroyed fully.protected void onCanvasRemoved()
onCanvasRemoved
in class JoglNewtAbstractDisplay
protected void onCanvasAdded()
onCanvasAdded
in class JoglNewtAbstractDisplay
public void init(com.jogamp.opengl.GLAutoDrawable drawable)
init
in interface com.jogamp.opengl.GLEventListener
protected void startGLCanvas()
startGLCanvas
in class JoglNewtAbstractDisplay
public void display(com.jogamp.opengl.GLAutoDrawable glad)
display
in interface com.jogamp.opengl.GLEventListener
public com.jogamp.newt.awt.NewtCanvasAWT getCanvas()
getCanvas
in interface JmeCanvasContext
public void dispose(com.jogamp.opengl.GLAutoDrawable arg0)
JoglNewtAbstractDisplay
dispose
in interface com.jogamp.opengl.GLEventListener
dispose
in class JoglNewtAbstractDisplay