28package com.jogamp.opengl.demos.android;
30import com.jogamp.opengl.GLCapabilities;
31import com.jogamp.opengl.GLProfile;
32import com.jogamp.opengl.demos.es2.GearsES2;
34import jogamp.newt.driver.android.NewtBaseActivity;
36import com.jogamp.newt.NewtFactory;
37import com.jogamp.newt.Screen;
38import com.jogamp.newt.event.MonitorEvent;
39import com.jogamp.newt.event.MonitorModeListener;
40import com.jogamp.newt.opengl.GLWindow;
42import com.jogamp.opengl.util.Animator;
44import android.os.Bundle;
45import android.util.Log;
48 static String TAG =
"NEWTGearsES2TransActivity";
51 public void onCreate(
final Bundle savedInstanceState) {
52 Log.d(TAG,
"onCreate - 0");
53 super.onCreate(savedInstanceState);
59 Log.d(TAG,
"req caps: "+caps);
65 setContentView(getWindow(), glWindow);
70 public void monitorModeChangeNotify(
final MonitorEvent me) { }
72 public void monitorModeChanged(
final MonitorEvent me,
final boolean success) {
73 System.err.println(
"MonitorMode Changed (success "+success+
"): "+me);
86 Log.d(TAG,
"onCreate - X");
void setBackgroundOpaque(final boolean opaque)
Sets whether the surface shall be opaque or translucent.
static Display createDisplay(final String name)
Create a Display entity.
static Screen createScreen(final Display display, final int index)
Create a Screen entity.
A screen may span multiple MonitorDevices representing their combined virtual size.
abstract int addReference()
See Display#addReference().
abstract void addMonitorModeListener(MonitorModeListener sml)
abstract int removeReference()
See Display#removeReference().
An implementation of GLAutoDrawable and Window interface, using a delegated Window instance,...
final void setVisible(final boolean visible)
Calls setVisible(true, visible), i.e.
final void setSurfaceSize(final int pixelWidth, final int pixelHeight)
Sets the size of the window's surface in pixel units which claims the window's client area excluding ...
final void setUndecorated(final boolean value)
static GLWindow create(final GLCapabilitiesImmutable caps)
Creates a new GLWindow attaching a new Window referencing a new default Screen and default Display wi...
Specifies a set of OpenGL capabilities.
Specifies the the OpenGL profile.
static final String GL2ES2
The intersection of the desktop GL3, GL2 and embedded ES2 profile.
static GLProfile get(final AbstractGraphicsDevice device, String profile)
Returns a GLProfile object.
void onCreate(final Bundle savedInstanceState)
final void resetFPSCounter()
Reset all performance counter (startTime, currentTime, frame number)
final void setUpdateFPSFrames(final int frames, final PrintStream out)
void resetFPSCounter()
Reset all performance counter (startTime, currentTime, frame number)
void addGLEventListener(GLEventListener listener)
Adds the given listener to the end of this drawable queue.