mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-10 23:01:50 +00:00
Update DUMB to revision f5f34570905e87f1933a0220d71d0d48c05b9b49
- Added a workaround for bad sample offsets in STM files - Disabled inserting note cut commands in STM files, as there is no such command in the format SVN r4084 (trunk)
This commit is contained in:
parent
277c233f5d
commit
e66f50fb76
1 changed files with 9 additions and 6 deletions
|
@ -134,10 +134,6 @@ static int it_stm_read_pattern( IT_PATTERN *pattern, DUMBFILE *f, unsigned char
|
|||
entry->effectvalue = buffer[ pos + 3 ];
|
||||
if ( entry->instrument && entry->instrument < 32 )
|
||||
entry->mask |= IT_ENTRY_INSTRUMENT;
|
||||
if ( note == 0xFC || note == 0xFE ) {
|
||||
entry->mask |= IT_ENTRY_NOTE;
|
||||
entry->note = IT_NOTE_CUT;
|
||||
}
|
||||
if ( note < 251 ) {
|
||||
entry->mask |= IT_ENTRY_NOTE;
|
||||
entry->note = ( note >> 4 ) * 12 + ( note & 0x0F );
|
||||
|
@ -362,8 +358,15 @@ static DUMB_IT_SIGDATA *it_stm_load_sigdata(DUMBFILE *f, int * version)
|
|||
}
|
||||
}
|
||||
|
||||
dumbfile_skip( f, o - dumbfile_pos( f ) );
|
||||
if ( dumbfile_getnc( (char*)data_block, p - o, f ) != p - o ) {
|
||||
q = o - dumbfile_pos( f );
|
||||
p -= o;
|
||||
o = 0;
|
||||
if ( q >= 0 ) dumbfile_skip( f, q );
|
||||
else {
|
||||
o = -q;
|
||||
memset ( data_block, 0, o );
|
||||
}
|
||||
if ( dumbfile_getnc( (char*)data_block + o, p - o, f ) != p - o ) {
|
||||
free( data_block );
|
||||
_dumb_it_unload_sigdata( sigdata );
|
||||
return NULL;
|
||||
|
|
Loading…
Reference in a new issue