com.jme3.system.lwjgl
Class LwjglOffscreenBuffer

java.lang.Object
  extended by com.jme3.system.lwjgl.LwjglContext
      extended by com.jme3.system.lwjgl.LwjglOffscreenBuffer
All Implemented Interfaces:
JmeContext, java.lang.Runnable

public class LwjglOffscreenBuffer
extends LwjglContext
implements java.lang.Runnable


Nested Class Summary
 
Nested classes/interfaces inherited from interface com.jme3.system.JmeContext
JmeContext.Type
 
Field Summary
protected  java.util.concurrent.atomic.AtomicBoolean needClose
           
 
Fields inherited from class com.jme3.system.lwjgl.LwjglContext
created, createdLock, joyInput, keyInput, listener, mouseInput, renderable, renderer, settings, timer
 
Constructor Summary
LwjglOffscreenBuffer()
           
 
Method Summary
protected  boolean checkGLError()
           
 void create(boolean waitFor)
          Creates the context and makes it active.
protected  void deinitInThread()
           
 void destroy(boolean waitFor)
          Destroys the context completely, making it inactive.
 JoyInput getJoyInput()
           
 KeyInput getKeyInput()
           
 MouseInput getMouseInput()
           
 TouchInput getTouchInput()
           
 JmeContext.Type getType()
           
protected  void initInThread()
           
 void restart()
          Destroys and then re-creates the context.
 void run()
           
protected  void runLoop()
           
 void setAutoFlushFrames(boolean enabled)
           
 void setTitle(java.lang.String title)
          Sets the title of the display (if available).
 
Methods inherited from class com.jme3.system.lwjgl.LwjglContext
create, createContextAttribs, destroy, getRenderer, getSettings, getTimer, initContextFirstTime, internalCreate, internalDestroy, isCreated, isRenderable, printContextInitInfo, setSettings, setSystemListener, waitFor
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

needClose

protected java.util.concurrent.atomic.AtomicBoolean needClose
Constructor Detail

LwjglOffscreenBuffer

public LwjglOffscreenBuffer()
Method Detail

initInThread

protected void initInThread()

checkGLError

protected boolean checkGLError()

runLoop

protected void runLoop()

deinitInThread

protected void deinitInThread()

run

public void run()
Specified by:
run in interface java.lang.Runnable

destroy

public void destroy(boolean waitFor)
Description copied from interface: JmeContext
Destroys the context completely, making it inactive.

Specified by:
destroy in interface JmeContext
Parameters:
waitFor - If true, will wait until the context is destroyed fully.

create

public void create(boolean waitFor)
Description copied from interface: JmeContext
Creates the context and makes it active.

Specified by:
create in interface JmeContext
Parameters:
waitFor - If true, will wait until context has initialized.

restart

public void restart()
Description copied from interface: JmeContext
Destroys and then re-creates the context. This should be called after the display settings have been changed.

Specified by:
restart in interface JmeContext

setAutoFlushFrames

public void setAutoFlushFrames(boolean enabled)
Specified by:
setAutoFlushFrames in interface JmeContext
Parameters:
enabled - If enabled, the context will automatically flush frames to the video card (swap buffers) after an update cycle.

getType

public JmeContext.Type getType()
Specified by:
getType in interface JmeContext
Returns:
The type of the context.

getMouseInput

public MouseInput getMouseInput()
Specified by:
getMouseInput in interface JmeContext
Returns:
Mouse input implementation. May be null if not available.

getKeyInput

public KeyInput getKeyInput()
Specified by:
getKeyInput in interface JmeContext
Returns:
Keyboard input implementation. May be null if not available.

getJoyInput

public JoyInput getJoyInput()
Specified by:
getJoyInput in interface JmeContext
Returns:
Joystick input implementation. May be null if not available.

getTouchInput

public TouchInput getTouchInput()
Specified by:
getTouchInput in interface JmeContext
Returns:
Touch device input implementation. May be null if not available.

setTitle

public void setTitle(java.lang.String title)
Description copied from interface: JmeContext
Sets the title of the display (if available). This does nothing for fullscreen, headless, or canvas contexts.

Specified by:
setTitle in interface JmeContext
Parameters:
title - The new title of the display.