fixed mod property names and added unit test for xm

This commit is contained in:
Mathias Panzenböck
2011-06-18 03:31:49 +02:00
parent fe356c31b4
commit 5ad69f6f2a
18 changed files with 257 additions and 146 deletions

View File

@ -101,7 +101,7 @@ void S3M::File::read(bool)
READ_U16L_AS(length);
READ_U16L_AS(sampleCount);
d->properties.setSampleLength(length);
d->properties.setTableLength(length);
d->properties.setSampleCount(sampleCount);
READ_U16L(d->properties.setPatternCount);

View File

@ -28,7 +28,7 @@ class S3M::Properties::PropertiesPrivate
{
public:
PropertiesPrivate() :
sampleLength(0),
tableLength(0),
channels(0),
stereo(0),
sampleCount(0),
@ -42,7 +42,7 @@ public:
ultraClick(0),
usePanningValues(false) {}
ushort sampleLength;
ushort tableLength;
int channels;
bool stereo;
ushort sampleCount;
@ -88,9 +88,9 @@ int S3M::Properties::channels() const
return d->channels;
}
ushort S3M::Properties::sampleLength() const
ushort S3M::Properties::tableLength() const
{
return d->sampleLength;
return d->tableLength;
}
bool S3M::Properties::stereo() const
@ -148,9 +148,9 @@ bool S3M::Properties::usePanningValues() const
return d->usePanningValues;
}
void S3M::Properties::setSampleLength(ushort sampleLength)
void S3M::Properties::setTableLength(ushort tableLength)
{
d->sampleLength = sampleLength;
d->tableLength = tableLength;
}
void S3M::Properties::setChannels(int channels)

View File

@ -38,7 +38,7 @@ namespace TagLib {
int sampleRate() const;
int channels() const;
ushort sampleLength() const;
ushort tableLength() const;
bool stereo() const;
ushort sampleCount() const;
ushort patternCount() const;
@ -52,7 +52,7 @@ namespace TagLib {
bool usePanningValues() const;
protected:
void setSampleLength(ushort sampleLength);
void setTableLength(ushort tableLength);
void setChannels(int channels);
void setStereo (bool stereo);