OpenGL ES SDK for Android ARM Developer Center
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
tessellation.h File Reference
#include <stdio.h>
#include "matrix.h"

Go to the source code of this file.

Classes

struct  Scene
 
struct  App
 

Macros

#define NUM_SCENES   5
 
#define get_attrib_location(prog, name)
 
#define get_uniform_location(prog, name)
 
#define attribfv(prog, name, n, offset)
 
#define uniform1f(prog, name, value)   glUniform1f(app->u_##prog##_##name, value);
 
#define uniform2f(prog, name, x, y)   glUniform2f(app->u_##prog##_##name, x, y);
 
#define uniform3fv(prog, name, value)   glUniform3fv(app->u_##prog##_##name, 1, &value[0]);
 
#define uniform1i(prog, name, value)   glUniform1i(app->u_##prog##_##name, value);
 
#define uniformm4(prog, name, value)   glUniformMatrix4fv(app->u_##prog##_##name, 1, GL_FALSE, value.value_ptr());
 

Functions

void app_initialize (App *app)
 
void app_update_and_render (App *app)
 

Macro Definition Documentation

#define attribfv (   prog,
  name,
  n,
  offset 
)
Value:
glEnableVertexAttribArray(app->a_##prog##_##name); \
glVertexAttribPointer(app->a_##prog##_##name, n, GL_FLOAT, GL_FALSE, \
n * sizeof(float), (void*)offset);
GLenum GLuint GLintptr offset
Definition: gl2ext.h:629
ClipmapApplication * app
Definition: main.cpp:47
GLuint name
Definition: gl2ext.h:139
GLfloat n
Definition: gl2ext.h:2707

Definition at line 94 of file tessellation.h.

#define get_attrib_location (   prog,
  name 
)
Value:
app->a_##prog##_##name = glGetAttribLocation(app->program_##prog, #name); \
if (app->a_##prog##_##name < 0) { \
printf("Invalid or unused attribute %s\n", #name); \
}
ClipmapApplication * app
Definition: main.cpp:47
GLuint name
Definition: gl2ext.h:139

Definition at line 82 of file tessellation.h.

#define get_uniform_location (   prog,
  name 
)
Value:
app->u_##prog##_##name = glGetUniformLocation(app->program_##prog, #name); \
if (app->u_##prog##_##name < 0) { \
printf("Invalid or unused uniform %s\n", #name); \
}
ClipmapApplication * app
Definition: main.cpp:47
GLuint name
Definition: gl2ext.h:139

Definition at line 88 of file tessellation.h.

#define NUM_SCENES   5

Definition at line 26 of file tessellation.h.

#define uniform1f (   prog,
  name,
  value 
)    glUniform1f(app->u_##prog##_##name, value);

Definition at line 99 of file tessellation.h.

#define uniform1i (   prog,
  name,
  value 
)    glUniform1i(app->u_##prog##_##name, value);

Definition at line 102 of file tessellation.h.

#define uniform2f (   prog,
  name,
  x,
  y 
)    glUniform2f(app->u_##prog##_##name, x, y);

Definition at line 100 of file tessellation.h.

#define uniform3fv (   prog,
  name,
  value 
)    glUniform3fv(app->u_##prog##_##name, 1, &value[0]);

Definition at line 101 of file tessellation.h.

#define uniformm4 (   prog,
  name,
  value 
)    glUniformMatrix4fv(app->u_##prog##_##name, 1, GL_FALSE, value.value_ptr());

Definition at line 103 of file tessellation.h.

Function Documentation

void app_initialize ( App app)

Definition at line 248 of file geometry.cpp.

void app_update_and_render ( App app)

Definition at line 297 of file geometry.cpp.