2
// interface for game engine
4
// called by GLUT or iPhone app wrapper
7
void initFrameDrawer( int inWidth, int inHeight );
10
// called at application termination
11
// good time to save state for next launch
12
void freeFrameDrawer();
15
// draw scene into frame using GL function calls
19
// start of pointer press
20
void pointerDown( float inX, float inY );
22
// movement with pointer pressed
23
void pointerMove( float inX, float inY );
25
// end of pointer press
26
void pointerUp( float inX, float inY );
31
typedef int16_t Sint16;
32
typedef uint8_t Uint8;
34
// sample rate shared by game engine and sound rendering platform
35
//#define gameSoundSampleRate 22050
36
//#define gameSoundSampleRate 44100
37
#define gameSoundSampleRate 11025
39
// gets the next buffer-full of sound samples from the game engine
40
// inBuffer should be filled with stereo Sint16 samples, little endian,
41
// left-right left-right ....
42
// NOTE: may not be called by the same thread that calls drawFrame,
43
// depending on platform implementation
44
void getSoundSamples( Uint8 *inBuffer, int inLengthToFillInBytes );
48
// called BY game engine (implemented by supporting platform)
50
// true to start or resume playing
52
void setSoundPlaying( char inPlaying );