API CHANGE: Rename decoding APIs to "pcm_frames" convention.

Renamed APIs:
 * mal_decoder_read()          -> mal_decoder_read_pcm_frames()
 * mal_decoder_seek_to_frame() -> mal_decoder_seek_to_pcm_frame()
This commit is contained in:
David Reid
2018-12-30 09:16:17 +10:00
parent 2aa05be5c6
commit 76e3267c78
2 changed files with 119 additions and 119 deletions
+3 -3
View File
@@ -82,7 +82,7 @@ mal_uint32 on_send_frames_to_device(mal_device* pDevice, mal_uint32 frameCount,
return 0;
}
return (mal_uint32)mal_decoder_read(pDecoder, frameCount, pSamples);
return (mal_uint32)mal_decoder_read_pcm_frames(pDecoder, frameCount, pSamples);
}
int main(int argc, char** argv)
@@ -186,13 +186,13 @@ decoding backend.
Data is read from the decoder as PCM frames:
```
mal_uint64 framesRead = mal_decoder_read(pDecoder, framesToRead, pFrames);
mal_uint64 framesRead = mal_decoder_read_pcm_frames(pDecoder, framesToRead, pFrames);
```
You can also seek to a specific frame like so:
```
mal_result result = mal_decoder_seek(pDecoder, targetFrame);
mal_result result = mal_decoder_seek_to_pcm_frame(pDecoder, targetFrame);
if (result != MAL_SUCCESS) {
return false; // An error occurred.
}