mirror of
https://github.com/vgmstream/vgmstream.git
synced 2025-02-11 16:43:11 +01:00
Updated HCA decoder.
This commit is contained in:
parent
5200ed4a91
commit
4c75e6a5bc
@ -20,6 +20,7 @@ typedef struct clHCA clHCA;
|
|||||||
/* In case you wish to allocate the structure on your own. */
|
/* In case you wish to allocate the structure on your own. */
|
||||||
int clHCA_sizeof();
|
int clHCA_sizeof();
|
||||||
void clHCA_clear(clHCA *, unsigned int ciphKey1, unsigned int ciphKey2);
|
void clHCA_clear(clHCA *, unsigned int ciphKey1, unsigned int ciphKey2);
|
||||||
|
void clHCA_done(clHCA *);
|
||||||
|
|
||||||
/* Or you could let the library allocate it. */
|
/* Or you could let the library allocate it. */
|
||||||
clHCA * clHCA_new(unsigned int ciphKey1, unsigned int ciphKey2);
|
clHCA * clHCA_new(unsigned int ciphKey1, unsigned int ciphKey2);
|
||||||
@ -47,9 +48,10 @@ typedef struct clHCA_stInfo {
|
|||||||
unsigned int channelCount;
|
unsigned int channelCount;
|
||||||
unsigned int blockSize;
|
unsigned int blockSize;
|
||||||
unsigned int blockCount;
|
unsigned int blockCount;
|
||||||
unsigned int loopEnabled;
|
unsigned int loopEnabled;
|
||||||
unsigned int loopStart;
|
unsigned int loopStart;
|
||||||
unsigned int loopEnd;
|
unsigned int loopEnd;
|
||||||
|
const char *comment;
|
||||||
} clHCA_stInfo;
|
} clHCA_stInfo;
|
||||||
|
|
||||||
/* Retrieve information relevant for decoding and playback with this function.
|
/* Retrieve information relevant for decoding and playback with this function.
|
||||||
@ -63,4 +65,3 @@ int clHCA_getInfo(clHCA *, clHCA_stInfo *out);
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
1052
ext_libs/clHCA.c
1052
ext_libs/clHCA.c
File diff suppressed because it is too large
Load Diff
@ -635,6 +635,8 @@ void close_vgmstream(VGMSTREAM * vgmstream) {
|
|||||||
if (vgmstream->coding_type==coding_CRI_HCA) {
|
if (vgmstream->coding_type==coding_CRI_HCA) {
|
||||||
hca_codec_data *data = (hca_codec_data *) vgmstream->codec_data;
|
hca_codec_data *data = (hca_codec_data *) vgmstream->codec_data;
|
||||||
if (vgmstream->codec_data) {
|
if (vgmstream->codec_data) {
|
||||||
|
clHCA *hca = (clHCA *)(data + 1);
|
||||||
|
clHCA_done(hca);
|
||||||
if (data->streamfile) close_streamfile(data->streamfile);
|
if (data->streamfile) close_streamfile(data->streamfile);
|
||||||
free(vgmstream->codec_data);
|
free(vgmstream->codec_data);
|
||||||
vgmstream->codec_data = NULL;
|
vgmstream->codec_data = NULL;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user