Added support for ClipPlane, ClipNode, TexGenNode to .ive

This commit is contained in:
Robert Osfield
2004-09-29 19:10:00 +00:00
parent 5be0004d52
commit a8739f952a
17 changed files with 394 additions and 39 deletions

View File

@@ -33,7 +33,13 @@ void TexGen::write(DataOutputStream* out){
// Write mode
out->writeInt(getMode());
// Notice no support for planes yet
if ( out->getVersion() >= VERSION_0005 )
{
out->writePlane(getPlane(osg::TexGen::S));
out->writePlane(getPlane(osg::TexGen::T));
out->writePlane(getPlane(osg::TexGen::R));
out->writePlane(getPlane(osg::TexGen::Q));
}
}
void TexGen::read(DataInputStream* in){
@@ -51,6 +57,14 @@ void TexGen::read(DataInputStream* in){
throw Exception("TexGen::read(): Could not cast this osg::TexGen to an osg::Object.");
// Read TexGen's properties
setMode((osg::TexGen::Mode)in->readInt());
if ( in->getVersion() >= VERSION_0005 )
{
setPlane(osg::TexGen::S, in->readPlane());
setPlane(osg::TexGen::T, in->readPlane());
setPlane(osg::TexGen::R, in->readPlane());
setPlane(osg::TexGen::Q, in->readPlane());
}
}
else{