List of usage examples for org.eclipse.swt.opengl GL glClearColor
public static native void glClearColor(float red, float green, float blue, float alpha);
From source file:org.eclipse.swt.snippets.Snippet174.java
static void init(GLCanvas canvas) { canvas.setCurrent();/*from ww w. ja v a 2s . com*/ resize(canvas); GL.glClearColor(1.0f, 1.0f, 1.0f, 1.0f); GL.glColor3f(0.0f, 0.0f, 0.0f); GL.glClearDepth(1.0f); GL.glEnable(GL.GL_DEPTH_TEST); GL.glHint(GL.GL_PERSPECTIVE_CORRECTION_HINT, GL.GL_NICEST); }
From source file:org.eclipse.swt.snippets.Snippet174.java
static GLContext init(Canvas canvas) { GLContext context = new GLContext(canvas); context.setCurrent();/* w ww . j a v a 2 s. co m*/ resize(canvas); GL.glClearColor(1.0f, 1.0f, 1.0f, 1.0f); GL.glColor3f(0.0f, 0.0f, 0.0f); GL.glClearDepth(1.0f); GL.glEnable(GL.GL_DEPTH_TEST); GL.glHint(GL.GL_PERSPECTIVE_CORRECTION_HINT, GL.GL_NICEST); return context; }