Bugzilla – Attachment 60 Details for
Bug 166
Memory leak with ATI Mobility Radeon 9700
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
Log In
[x]
|
Forgot Password
Login:
[x]
GLEventListener for test case
AnimGLEventListener.java (text/plain), 1.42 KB, created by
Sven Gothel
on 2005-06-22 00:26:00 CEST
(
hide
)
Description:
GLEventListener for test case
Filename:
MIME Type:
Creator:
Sven Gothel
Created:
2005-06-22 00:26:00 CEST
Size:
1.42 KB
patch
obsolete
>import net.java.games.jogl.*; > >public class AnimGLEventListener implements GLEventListener >{ > > float tri = 0.0f; > > > public void init(GLDrawable drawable) > { > GL gl = drawable.getGL(); > gl.setSwapInterval(0); > } > > public void display(GLDrawable drawable) > { > GL gl = drawable.getGL(); > gl.glMatrixMode(GL.GL_MODELVIEW); > gl.glClear(GL.GL_COLOR_BUFFER_BIT | GL.GL_DEPTH_BUFFER_BIT); > gl.glLoadIdentity(); > > gl.glTranslatef(-0.4f,0.0f,0.0f); > gl.glRotatef(tri,0.0f,1.0f,0.0f); > > gl.glBegin(GL.GL_TRIANGLE_FAN); > gl.glColor3f(1.0f,0.0f,0.0f); > gl.glVertex3f(-0.2f,0.0f,0.0f); > gl.glColor3f(0.0f,1.0f,0.0f); > gl.glVertex3f(0.2f,0.0f,0.0f); > gl.glColor3f(0.0f,0.0f,1.0f); > gl.glVertex3f(0.0f,0.6f,0.0f); > gl.glEnd(); > > gl.glLoadIdentity(); > gl.glTranslatef(0.4f,0.0f,0.0f); > gl.glRotatef(tri,1.0f,0.0f,0.0f); > gl.glBegin(GL.GL_TRIANGLE_FAN); > gl.glColor3f(1.0f,0.0f,0.0f); > gl.glVertex3f(-0.2f,0.0f,0.0f); > gl.glColor3f(0.0f,1.0f,0.0f); > gl.glVertex3f(0.2f,0.0f,0.0f); > gl.glColor3f(0.0f,0.0f,1.0f); > gl.glVertex3f(0.0f,0.6f,0.0f); > gl.glEnd(); > > if(tri < 360.f) > tri += 0.5f; > else > tri = 0.0f; > } > > public void reshape(GLDrawable drawable, int x, int y, int width, int height) > { > > } > > public void displayChanged(GLDrawable drawable, boolean modeChanged, boolean deviceChanged) > { > > } > >}
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 166
:
59
| 60