Files
mice-3ds/include/wav.h
Mahyar Koshkouei a09e44a462 all: move headers to include folder
Signed-off-by: Mahyar Koshkouei <mk@deltabeard.com>
2023-07-08 11:49:04 +01:00

45 lines
747 B
C

#include <stdint.h>
#include "playback.h"
/**
* Set decoder parameters for WAV.
*
* \param decoder Structure to store parameters.
*/
void setWav(struct decoder_fn* decoder);
/**
* Initialise WAV playback.
*
* \param file Location of WAV file to play.
* \return 0 on success, else failure.
*/
int initWav(const char* file);
/**
* Get sampling rate of Wav file.
*
* \return Sampling rate.
*/
uint32_t rateWav(void);
/**
* Get number of channels of Wav file.
*
* \return Number of channels for opened file.
*/
uint8_t channelWav(void);
/**
* Read part of open Wav file.
*
* \param buffer Output.
* \return Samples read for each channel.
*/
uint64_t readWav(void* buffer);
/**
* Free Wav file.
*/
void exitWav(void);