Closed denjhang closed 3 years ago
hmm ... it gets confused by the lack of EoF command in those files.
How did you manage to create such files?
EDIT: What happens is, that it processes data from [beginning ... EOF offset] - or until the EOF command occours, whatever comes first. In pass 1, the file gets smaller, but it doesn't set its internal EOF offset so the new size. So in pass 2 it processes data beyond the end of the file. This happens only when there is no EOF command, as the EOF command would cause it to correctly stop processing.
I used the wav2psg provided in a post on the sms power! forum more than ten years ago for conversion wav to psg.zip .
Okay, interesting.
Anyway, a675dd892357146d90a8cb6fc27a87d7d28ec6ae fixes the crash. It doesn't really "fix" the files though (i.e. they will still lack the EOF offset) and it seems to eat up the last wait command in the file.
So how do I add EOF to the vgm?
You add a byte 66
with a hex editor to the end of the file.
Then you increase the "EOF offset" in the VGM header (offset 0x04..0x07) by 1.
vgm_cmp.zip These files in the compressed package cannot be compressed using vgm_cmp.