KallistiOS git master
Independent SDK for the Sega Dreamcast
Loading...
Searching...
No Matches
sdl_sound.c File Reference
#include <SDL/SDL.h>
#include <dc/fmath.h>

Macros

#define AMPLITUDE   16384
 
#define FRQ_44KHZ   44100
 
#define INCREMENT   1.0f / 100.0f
 

Functions

static void audio_callback (void *userdata, Uint8 *stream, int length)
 
int main (int argc, char *argv[])
 

Variables

static float pos = 0.0f
 

Macro Definition Documentation

◆ AMPLITUDE

#define AMPLITUDE   16384

Referenced by audio_callback().

◆ FRQ_44KHZ

#define FRQ_44KHZ   44100

Referenced by main().

◆ INCREMENT

#define INCREMENT   1.0f / 100.0f

Referenced by audio_callback().

Function Documentation

◆ audio_callback()

static void audio_callback ( void * userdata,
Uint8 * stream,
int length )
static

References AMPLITUDE, F_PI, fsin(), INCREMENT, pos, and stream.

Referenced by main().

◆ main()

int main ( int argc,
char * argv[] )

References audio_callback(), FRQ_44KHZ, and NULL.

Variable Documentation

◆ pos

float pos = 0.0f
static

Referenced by audio_callback(), and kbd_readline().