mirror of
https://github.com/thestk/stk
synced 2026-01-14 13:31:53 +00:00
Another update to FileRead for Aiff sowt uncompressed format.
This commit is contained in:
@@ -447,12 +447,6 @@ bool FileRead :: getAifInfo( const char *fileName )
|
||||
byteswap_ = true;
|
||||
#endif
|
||||
|
||||
if ( fread(&id, 4, 1, fd_) != 1 ) goto error;
|
||||
if ( !strncmp(id, "sowt", 4) ) { // uncompressed little-endian
|
||||
if ( byteswap_ == false ) byteswap_ = true;
|
||||
else byteswap_ = false;
|
||||
}
|
||||
|
||||
// Determine the data format.
|
||||
dataType_ = 0;
|
||||
if ( aifc == false ) {
|
||||
@@ -462,6 +456,11 @@ bool FileRead :: getAifInfo( const char *fileName )
|
||||
else if ( temp <= 32 ) dataType_ = STK_SINT32;
|
||||
}
|
||||
else {
|
||||
if ( fread(&id, 4, 1, fd_) != 1 ) goto error;
|
||||
if ( !strncmp(id, "sowt", 4) ) { // uncompressed little-endian
|
||||
if ( byteswap_ == false ) byteswap_ = true;
|
||||
else byteswap_ = false;
|
||||
}
|
||||
if ( !strncmp(id, "NONE", 4) || !strncmp(id, "sowt", 4) ) {
|
||||
if ( temp <= 8 ) dataType_ = STK_SINT8;
|
||||
else if ( temp <= 16 ) dataType_ = STK_SINT16;
|
||||
|
||||
Reference in New Issue
Block a user