![]() |
OpenGL ES SDK for Android
ARM Developer Center
|
A sample to show how to use the various mipmap options in OpenGL ES 2.0. More...
#include <GLES2/gl2.h>#include <GLES2/gl2ext.h>#include <string>#include <sstream>#include <jni.h>#include <android/log.h>#include "ETCMipmap.h"#include "Shader.h"#include "Text.h"#include "Texture.h"#include "ETCHeader.h"#include "AndroidPlatform.h"Go to the source code of this file.
Macros | |
| #define | LOAD_MIPMAPS |
Functions | |
| bool | setupGraphics (int w, int h) |
| void | renderFrame (void) |
| JNIEXPORT void JNICALL | Java_com_arm_malideveloper_openglessdk_etcmipmap_ETCMipmap_init (JNIEnv *env, jclass jcls, jint width, jint height) |
| JNIEXPORT void JNICALL | Java_com_arm_malideveloper_openglessdk_etcmipmap_ETCMipmap_step (JNIEnv *env, jclass jcls) |
| JNIEXPORT void JNICALL | Java_com_arm_malideveloper_openglessdk_etcmipmap_ETCMipmap_uninit (JNIEnv *, jclass) |
Variables | |
| string | resourceDirectory = "/data/data/com.arm.malideveloper.openglessdk.etcmipmap/" |
| string | textureFilename = "good_mip_" |
| string | imageExtension = ".pkm" |
| string | vertexShaderFilename = "ETCMipmap_texture.vert" |
| string | fragmentShaderFilename = "ETCMipmap_texture.frag" |
| GLuint | textureID = 0 |
| GLuint | vertexShaderID = 0 |
| GLuint | fragmentShaderID = 0 |
| GLuint | programID = 0 |
| GLint | iLocPosition = -1 |
| GLint | iLocTexCoord = -1 |
| GLint | iLocSampler = -1 |
| Text * | text |
A sample to show how to use the various mipmap options in OpenGL ES 2.0.
The sample demonstrates three techniques controlled by the LOAD_MIPMAPS and DISABLE_MIPMAPS defines:
Definition in file ETCMipmap.cpp.
| #define LOAD_MIPMAPS |
Definition at line 33 of file ETCMipmap.cpp.
| JNIEXPORT void JNICALL Java_com_arm_malideveloper_openglessdk_etcmipmap_ETCMipmap_init | ( | JNIEnv * | env, |
| jclass | jcls, | ||
| jint | width, | ||
| jint | height | ||
| ) |
Definition at line 222 of file ETCMipmap.cpp.
| JNIEXPORT void JNICALL Java_com_arm_malideveloper_openglessdk_etcmipmap_ETCMipmap_step | ( | JNIEnv * | env, |
| jclass | jcls | ||
| ) |
Definition at line 243 of file ETCMipmap.cpp.
| JNIEXPORT void JNICALL Java_com_arm_malideveloper_openglessdk_etcmipmap_ETCMipmap_uninit | ( | JNIEnv * | , |
| jclass | |||
| ) |
Definition at line 249 of file ETCMipmap.cpp.
Definition at line 192 of file ETCMipmap.cpp.
Definition at line 77 of file ETCMipmap.cpp.
| string fragmentShaderFilename = "ETCMipmap_texture.frag" |
Definition at line 61 of file ETCMipmap.cpp.
| GLuint fragmentShaderID = 0 |
Definition at line 68 of file ETCMipmap.cpp.
| GLint iLocPosition = -1 |
Definition at line 70 of file ETCMipmap.cpp.
| GLint iLocSampler = -1 |
Definition at line 72 of file ETCMipmap.cpp.
| GLint iLocTexCoord = -1 |
Definition at line 71 of file ETCMipmap.cpp.
| string imageExtension = ".pkm" |
Definition at line 58 of file ETCMipmap.cpp.
| GLuint programID = 0 |
Definition at line 69 of file ETCMipmap.cpp.
| string resourceDirectory = "/data/data/com.arm.malideveloper.openglessdk.etcmipmap/" |
Definition at line 56 of file ETCMipmap.cpp.
| Text* text |
Definition at line 75 of file ETCMipmap.cpp.
| string textureFilename = "good_mip_" |
Definition at line 57 of file ETCMipmap.cpp.
| GLuint textureID = 0 |
Definition at line 64 of file ETCMipmap.cpp.
| string vertexShaderFilename = "ETCMipmap_texture.vert" |
Definition at line 60 of file ETCMipmap.cpp.
| GLuint vertexShaderID = 0 |
Definition at line 67 of file ETCMipmap.cpp.