Back to index

extremetuxracer  0.5beta
Classes | Defines | Typedefs | Enumerations
pp_types.h File Reference
#include "etracer.h"
#include "ppgltk/alg/color.h"
#include "ppgltk/alg/vec2d.h"
#include "ppgltk/alg/vec3d.h"
#include "ppgltk/alg/matrix.h"
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  triangle_t
struct  ray_t
 Ray (half-line) More...
struct  material_t
 Material. More...
struct  light_t
 Light. More...
struct  key_frame_t
 Key frame for animation sequences. More...
struct  sphere_t
 Data for Sphere node type. More...
struct  scene_node_struct
 Scene graph node. More...
struct  view_t
struct  control_t
 Control data. More...
union  scene_node_struct.param

Defines

#define NUM_TERRAIN_TYPES   64

Typedefs

typedef struct scene_node_struct scene_node_t
 Scene graph node.

Enumerations

enum  geometry_t { Empty, Sphere }
 Scene graph node types. More...
enum  tux_eye_t { TuxLeftEye = 0, TuxRightEye = 1 }
 Tux's eyes. More...
enum  difficulty_level_t {
  DIFFICULTY_LEVEL_EASY, DIFFICULTY_LEVEL_NORMAL, DIFFICULTY_LEVEL_HARD, DIFFICULTY_LEVEL_INSANE,
  DIFFICULTY_NUM_LEVELS
}
 Difficulty levels. More...
enum  race_conditions_t {
  RACE_CONDITIONS_SUNNY, RACE_CONDITIONS_CLOUDY, RACE_CONDITIONS_NIGHT, RACE_CONDITIONS_EVENING,
  RACE_CONDITIONS_NUM_CONDITIONS
}
 Race conditions. More...
enum  view_mode_t { BEHIND, FOLLOW, ABOVE, NUM_VIEW_MODES }
 View mode. More...
enum  control_mode_t { KEYBOARD = 0, MOUSE = 1, JOYSTICK = 2 }
 Control mode. More...

Class Documentation

struct triangle_t

Definition at line 32 of file pp_types.h.

Collaboration diagram for triangle_t:
Class Members
Vec3d p
Vec2d t
struct ray_t

Ray (half-line)

Definition at line 38 of file pp_types.h.

Collaboration diagram for ray_t:
Class Members
Vec3d pt
Vec3d vec
struct material_t

Material.

Definition at line 44 of file pp_types.h.

Collaboration diagram for material_t:
Class Members
Color diffuse
Color specular
float specular_exp
struct light_t

Light.

Definition at line 52 of file pp_types.h.

Class Members
GLfloat ambient
GLfloat constant_attenuation
GLfloat diffuse
bool is_on
GLfloat linear_attenuation
GLfloat position
GLfloat quadratic_attenuation
GLfloat specular
GLfloat spot_cutoff
GLfloat spot_direction
GLfloat spot_exponent
struct key_frame_t

Key frame for animation sequences.

Definition at line 67 of file pp_types.h.

Collaboration diagram for key_frame_t:
Class Members
float l_hip
float l_shldr
float pitch angle of rotation about x axis
Vec3d pos
float r_hip
float r_shldr
float time
float yaw angle of rotation about y axis
struct sphere_t

Data for Sphere node type.

Definition at line 88 of file pp_types.h.

Class Members
int divisions How many divisions do we use to draw a sphere?
float radius
struct scene_node_struct

Scene graph node.

Definition at line 102 of file pp_types.h.

Collaboration diagram for scene_node_struct:
Class Members
struct scene_node_struct * child
bool eye Is this node one of tux's eyes?
geometry_t geom type of node
Matrix invtrans
material_t * mat
char * name name of node (for debugging)
struct scene_node_struct * next
union scene_node_struct param
struct scene_node_struct * parent
bool render_shadow Do we draw the shadow of this node?
Matrix trans The forward and inverse transforms.
tux_eye_t which_eye If so, which one?
struct view_t

Definition at line 164 of file pp_types.h.

Collaboration diagram for view_t:
Class Members
Vec3d dir viewing direction
bool initialized has view been initialized?
Matrix inv_view_mat inverse view matrix
view_mode_t mode View mode.
Vec3d plyr_pos position of player
Vec3d pos position of camera
Vec3d up up direction
struct control_t

Control data.

Definition at line 195 of file pp_types.h.

Class Members
bool back_flip
float barrel_roll_factor
bool barrel_roll_left
bool barrel_roll_right
bool begin_jump
float flip_factor
bool front_flip
bool is_braking is player braking?
bool is_paddling is player paddling?
float jump_amt
bool jump_charging
float jump_start_time
bool jumping
control_mode_t mode control mode
float paddle_time
float turn_animation animation step [-1,1]
float turn_fact turning [-1,1]
union scene_node_struct.param

Definition at line 110 of file pp_types.h.

Class Members
sphere_t sphere

Define Documentation

#define NUM_TERRAIN_TYPES   64

Definition at line 135 of file pp_types.h.


Typedef Documentation

Scene graph node.


Enumeration Type Documentation

Control mode.

Enumerator:
KEYBOARD 
MOUSE 
JOYSTICK 

Definition at line 188 of file pp_types.h.

             {
    KEYBOARD = 0,
    MOUSE = 1,
    JOYSTICK = 2
} control_mode_t;

Difficulty levels.

Enumerator:
DIFFICULTY_LEVEL_EASY 
DIFFICULTY_LEVEL_NORMAL 
DIFFICULTY_LEVEL_HARD 
DIFFICULTY_LEVEL_INSANE 
DIFFICULTY_NUM_LEVELS 

Definition at line 138 of file pp_types.h.

enum geometry_t

Scene graph node types.

Enumerator:
Empty 
Sphere 

Definition at line 83 of file pp_types.h.

Race conditions.

Enumerator:
RACE_CONDITIONS_SUNNY 
RACE_CONDITIONS_CLOUDY 
RACE_CONDITIONS_NIGHT 
RACE_CONDITIONS_EVENING 
RACE_CONDITIONS_NUM_CONDITIONS 

Definition at line 147 of file pp_types.h.

enum tux_eye_t

Tux's eyes.

Enumerator:
TuxLeftEye 
TuxRightEye 

Definition at line 96 of file pp_types.h.

View mode.

Enumerator:
BEHIND 
FOLLOW 
ABOVE 
NUM_VIEW_MODES 

Definition at line 156 of file pp_types.h.