Changed osg::ImageSequence::set/getDuration to set/getLength() to be in keeping with the
osg::ImageStream's getLength().
This commit is contained in:
@@ -35,7 +35,7 @@ void ImageSequence::write(DataOutputStream* out)
|
||||
|
||||
|
||||
out->writeInt(getMode());
|
||||
out->writeDouble(getDuration());
|
||||
out->writeDouble(getLength());
|
||||
|
||||
out->writeUInt(getFileNames().size());
|
||||
for(FileNames::iterator itr = getFileNames().begin();
|
||||
@@ -76,7 +76,7 @@ void ImageSequence::read(DataInputStream* in)
|
||||
|
||||
|
||||
setMode((osg::ImageSequence::Mode)(in->readInt()));
|
||||
setDuration(in->readDouble());
|
||||
setLength(in->readDouble());
|
||||
|
||||
unsigned int numFileNames = in->readUInt();
|
||||
if (numFileNames>0)
|
||||
|
||||
@@ -47,10 +47,10 @@ bool ImageSequence_readLocalData(Object& obj, Input& fr)
|
||||
}
|
||||
}
|
||||
|
||||
double duration;
|
||||
if (fr.read("Duration", duration))
|
||||
double length;
|
||||
if (fr.read("Duration", length) || fr.read("Length", length) )
|
||||
{
|
||||
is.setDuration(duration);
|
||||
is.setLength(length);
|
||||
}
|
||||
|
||||
if (fr.matchSequence("FileNames {"))
|
||||
@@ -108,7 +108,7 @@ bool ImageSequence_writeLocalData(const Object& obj, Output& fw)
|
||||
break;
|
||||
}
|
||||
|
||||
fw.indent()<<"Duration "<<is.getDuration()<<std::endl;
|
||||
fw.indent()<<"Length "<<is.getLength()<<std::endl;
|
||||
|
||||
if (!is.getFileNames().empty())
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user