refactor some things...
This commit is contained in:
parent
3550fad638
commit
1744e689b5
25 changed files with 2396 additions and 1307 deletions
|
|
@ -178,7 +178,7 @@ static pxl8_result parse_cel_chunk(const u8* data, u32 chunk_size, pxl8_ase_cel*
|
|||
}
|
||||
|
||||
mz_ulong dest_len = pixel_data_size;
|
||||
int result = mz_uncompress(cel->pixel_data, &dest_len, data + 20, compressed_data_size);
|
||||
i32 result = mz_uncompress(cel->pixel_data, &dest_len, data + 20, compressed_data_size);
|
||||
if (result != MZ_OK) {
|
||||
pxl8_error("Failed to decompress cel data: miniz error %d", result);
|
||||
SDL_free(cel->pixel_data);
|
||||
|
|
@ -358,13 +358,13 @@ pxl8_result pxl8_ase_load(const char* filepath, pxl8_ase_file* ase_file) {
|
|||
pxl8_io_free_binary_data(file_data);
|
||||
|
||||
if (result != PXL8_OK) {
|
||||
pxl8_ase_free(ase_file);
|
||||
pxl8_ase_destroy(ase_file);
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
void pxl8_ase_free(pxl8_ase_file* ase_file) {
|
||||
void pxl8_ase_destroy(pxl8_ase_file* ase_file) {
|
||||
if (!ase_file) return;
|
||||
|
||||
if (ase_file->frames) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue