Skip to content

Commit

Permalink
vgm: fix data block offset with secondary chip
Browse files Browse the repository at this point in the history
  • Loading branch information
jpcima committed Aug 31, 2019
1 parent e7e18ff commit a0126bc
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/FileFormats/format_vgm_import.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -220,6 +220,10 @@ FfmtErrCode VGM_Importer::load(QIODevice &file, FmBank &bank)
file.seek(file.pos() + 2);
file.read(char_p(numb), 4);
pcm_offset = toUint32LE(numb);

// from ValleyBell's vgmtest.c: offset MSB is chip ID
pcm_offset &= 0x7fffffff;

file.seek(file.pos() + pcm_offset);
break;

Expand Down

0 comments on commit a0126bc

Please sign in to comment.