Newer
Older
Import / research / ui / TweakableProperties / toolkit / include / Sounds.h
@John John on 29 Dec 2020 576 bytes bulk import from macbookpro checkouts
#ifndef SOUNDS_H
#define SOUNDS_H


#include <stdlib.h>


#include "Namespace.h"
BEGIN_NAMESPACE


enum SoundFormat
{
	SF_WAV,
	SF_MP3
};


// TODO: class wrapper
struct Sound;


Sound* SoundFilePlay(const char* a_filename, SoundFormat a_fmt = SF_WAV, int a_channels = 2, int a_samples = 44100);
Sound* SoundPlayFromMemory(void* a_buffer, size_t a_bufferLength, SoundFormat a_fmt = SF_WAV, int a_channels = 2, int a_samples = 44100);
void SoundWaitToFinish(Sound* a_sound);
void SoundClose(Sound* a_sound);


END_NAMESPACE


#endif // SOUNDS_H