OpenGL ES SDK for Android ARM Developer Center
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Texture.cpp File Reference
#include "Texture.h"
#include <GLES2/gl2ext.h>
#include <cstdio>
#include <cstdlib>
#include <android/log.h>

Go to the source code of this file.

Macros

#define CHANNELS_PER_PIXEL   3
 
#define LOG_TAG   "libNative"
 
#define LOGI(...)   __android_log_print(ANDROID_LOG_INFO, LOG_TAG, __VA_ARGS__)
 
#define LOGE(...)   __android_log_print(ANDROID_LOG_ERROR, LOG_TAG, __VA_ARGS__)
 

Functions

void loadTexture (const char *texture, unsigned int level, unsigned int width, unsigned int height)
 Loads a desired texture into memory at an appropriate mipmap level. More...
 
void loadCompressedTexture (const char *texture, unsigned int level)
 Loads a compressed texture into memory at an appropriate mipmap level. More...
 

Macro Definition Documentation

#define CHANNELS_PER_PIXEL   3

Definition at line 28 of file Texture.cpp.

#define LOG_TAG   "libNative"

Definition at line 30 of file Texture.cpp.

#define LOGE (   ...)    __android_log_print(ANDROID_LOG_ERROR, LOG_TAG, __VA_ARGS__)

Definition at line 32 of file Texture.cpp.

#define LOGI (   ...)    __android_log_print(ANDROID_LOG_INFO, LOG_TAG, __VA_ARGS__)

Definition at line 31 of file Texture.cpp.

Function Documentation

void loadCompressedTexture ( const char *  texture,
unsigned int  level 
)

Loads a compressed texture into memory at an appropriate mipmap level.

Parameters
textureThe name of the texture file to be loeaded from the system.
levelThe mipmap level that the texture should be loaded into.

Definition at line 62 of file Texture.cpp.

void loadTexture ( const char *  texture,
unsigned int  level,
unsigned int  width,
unsigned int  height 
)

Loads a desired texture into memory at an appropriate mipmap level.

Parameters
textureThe name of the texture file to be loaded from the system.
levelThe mipmap level that the texture should be loaded into.
widthThe width of the texture to be loaded
heightThe height of the texture to be loaded.

Definition at line 35 of file Texture.cpp.