¡@

Home 

2014/10/16 ¤W¤È 08:14:16

android Programming Glossary: gl.glmatrixmode

How to use onSensorChanged sensor data in combination with OpenGL

http://stackoverflow.com/questions/2881128/how-to-use-onsensorchanged-sensor-data-in-combination-with-opengl

set target matrix to modelview matrix gl.glMatrixMode GL10.GL_MODELVIEW init modelview matrix gl.glLoadIdentity move.. gl.glViewport 0 0 width height float r float width height gl.glMatrixMode GL10.GL_PROJECTION gl.glLoadIdentity gl.glFrustumf r r 1 1 1..

Overlay images onto Camera preview SurfaceView

http://stackoverflow.com/questions/3548666/overlay-images-onto-camera-preview-surfaceview

GL10.GL_COLOR_BUFFER_BIT GL10.GL_DEPTH_BUFFER_BIT gl.glMatrixMode GL10.GL_MODELVIEW gl.glLoadIdentity gl.glTranslatef 0 0 5.0f.. 0 0 width height float ratio float width height gl.glMatrixMode GL10.GL_PROJECTION gl.glLoadIdentity gl.glFrustumf ratio ratio..

Using OpenGL to replace Canvas - Android

http://stackoverflow.com/questions/3597323/using-opengl-to-replace-canvas-android

gl int width int height gl.glViewport 0 0 width height gl.glMatrixMode GL10.GL_PROJECTION gl.glLoadIdentity gl.glOrthof 0.0f width.. gl.glViewport 0 0 mViewWidth mViewHeight gl.glMatrixMode GL10.GL_PROJECTION gl.glLoadIdentity gl.glEnable GL10.GL_BLEND..

Problem drawing a sphere in OPENGL ES

http://stackoverflow.com/questions/6072308/problem-drawing-a-sphere-in-opengl-es

if height 0 height 1 gl.glViewport 0 0 width height gl.glMatrixMode GL10.GL_PROJECTION gl.glLoadIdentity Calculate The Aspect Ratio.. gl 45.0f float width float height 0.1f 100.0f gl.glMatrixMode GL10.GL_MODELVIEW Select The Modelview Matrix gl.glLoadIdentity..

Android OpenGL 3D picking

http://stackoverflow.com/questions/6699387/android-opengl-3d-picking

GL10.GL_COLOR_BUFFER_BIT GL10.GL_DEPTH_BUFFER_BIT gl.glMatrixMode GL10.GL_PROJECTION gl.glLoadIdentity GLU.gluPerspective gl.. 55.0f float screenWidth float screenHeight 10.0f 10000.0f gl.glMatrixMode GL10.GL_MODELVIEW gl.glLoadIdentity GLU.gluLookAt gl eyeX eyeY..

How to use onSensorChanged sensor data in combination with OpenGL

http://stackoverflow.com/questions/2881128/how-to-use-onsensorchanged-sensor-data-in-combination-with-opengl

and color buffer gl.glClear GL10.GL_COLOR_BUFFER_BIT GL10.GL_DEPTH_BUFFER_BIT set target matrix to modelview matrix gl.glMatrixMode GL10.GL_MODELVIEW init modelview matrix gl.glLoadIdentity move camera away a little bit if MODUS 1 MODUS 2 MODUS 3 MODUS.. public void onSurfaceChanged GL10 gl int width int height gl.glViewport 0 0 width height float r float width height gl.glMatrixMode GL10.GL_PROJECTION gl.glLoadIdentity gl.glFrustumf r r 1 1 1 10 public void onSurfaceCreated GL10 gl EGLConfig config gl.glDisable..

Overlay images onto Camera preview SurfaceView

http://stackoverflow.com/questions/3548666/overlay-images-onto-camera-preview-surfaceview

mCube new Cube public void onDrawFrame GL10 gl gl.glClear GL10.GL_COLOR_BUFFER_BIT GL10.GL_DEPTH_BUFFER_BIT gl.glMatrixMode GL10.GL_MODELVIEW gl.glLoadIdentity gl.glTranslatef 0 0 5.0f gl.glRotatef mAngle 0 1 0 gl.glRotatef mAngle 0.25f 1 0 0.. void onSurfaceChanged GL10 gl int width int height gl.glViewport 0 0 width height float ratio float width height gl.glMatrixMode GL10.GL_PROJECTION gl.glLoadIdentity gl.glFrustumf ratio ratio 1 1 1 10 public void onSurfaceCreated GL10 gl EGLConfig..

Using OpenGL to replace Canvas - Android

http://stackoverflow.com/questions/3597323/using-opengl-to-replace-canvas-android

looks as follows @Override public void onSurfaceChanged GL10 gl int width int height gl.glViewport 0 0 width height gl.glMatrixMode GL10.GL_PROJECTION gl.glLoadIdentity gl.glOrthof 0.0f width 0.0f height 0.0f 1.0f gl.glShadeModel GL10.GL_FLAT gl.glEnable.. GL10.GL_BLEND gl.glBlendFunc GL10.GL_ONE GL10.GL_ONE_MINUS_SRC_ALPHA gl.glViewport 0 0 mViewWidth mViewHeight gl.glMatrixMode GL10.GL_PROJECTION gl.glLoadIdentity gl.glEnable GL10.GL_BLEND gl.glBlendFunc GL10.GL_SRC_ALPHA GL10.GL_ONE_MINUS_SRC_ALPHA..

Problem drawing a sphere in OPENGL ES

http://stackoverflow.com/questions/6072308/problem-drawing-a-sphere-in-opengl-es

gl public void onSurfaceChanged GL10 gl int width int height if height 0 height 1 gl.glViewport 0 0 width height gl.glMatrixMode GL10.GL_PROJECTION gl.glLoadIdentity Calculate The Aspect Ratio Of The Window GLU.gluPerspective gl 45.0f float width float.. Calculate The Aspect Ratio Of The Window GLU.gluPerspective gl 45.0f float width float height 0.1f 100.0f gl.glMatrixMode GL10.GL_MODELVIEW Select The Modelview Matrix gl.glLoadIdentity Reset The Modelview Matrix Used to stop the FPS counter..

Android OpenGL 3D picking

http://stackoverflow.com/questions/6699387/android-opengl-3d-picking

setupEnvironment Clears the screen and depth buffer. gl.glClear GL10.GL_COLOR_BUFFER_BIT GL10.GL_DEPTH_BUFFER_BIT gl.glMatrixMode GL10.GL_PROJECTION gl.glLoadIdentity GLU.gluPerspective gl 55.0f float screenWidth float screenHeight 10.0f 10000.0f gl.glMatrixMode.. GL10.GL_PROJECTION gl.glLoadIdentity GLU.gluPerspective gl 55.0f float screenWidth float screenHeight 10.0f 10000.0f gl.glMatrixMode GL10.GL_MODELVIEW gl.glLoadIdentity GLU.gluLookAt gl eyeX eyeY eyeZ centerX centerY centerZ upX upY upZ if pickPointTrigger..