added .mod file support

This commit is contained in:
Mathias Panzenböck
2011-06-14 03:47:08 +02:00
parent 812826fe3a
commit f75f5ac9bb
17 changed files with 374 additions and 123 deletions

View File

@ -106,7 +106,7 @@ void S3M::File::read(bool)
READ_ASSERT(readBlock(4) == "SCRM");
READ_BYTE_AS(baseVolume);
d->properties.setBaseVolume(baseVolume << 1);
d->properties.setBaseVolume((int)baseVolume << 1);
READ_BYTE(d->properties.setTempo);
READ_BYTE(d->properties.setBpmSpeed);
@ -133,10 +133,10 @@ void S3M::File::read(bool)
StringList comment;
for(ushort i = 0; i < sampleCount; ++ i)
{
seek(96 + length + (i << 1));
seek(96L + length + ((long)i << 1));
READ_U16L_AS(instrumentOffset);
seek(instrumentOffset << 4);
seek((long)instrumentOffset << 4);
READ_BYTE_AS(sampleType);
READ_STRING_AS(dosFileName, 13);
@ -158,4 +158,5 @@ void S3M::File::read(bool)
}
d->tag.setComment(comment.toString("\n"));
d->tag.setTrackerName("ScreamTracker III");
}

View File

@ -22,8 +22,6 @@
#ifndef TAGLIB_S3MFILE_H
#define TAGLIB_S3MFILE_H
#include <stdint.h>
#include "tfile.h"
#include "audioproperties.h"
#include "taglib_export.h"