Moved osg::DOFTransform to osgSim::DOFTransform.

Fixed crash associated with .osg files which contain empty description fields.

From Sondra Inverson, added support to .ive plugin for osgSim::DOFTransform.
This commit is contained in:
Robert Osfield
2003-11-25 14:11:05 +00:00
parent 032909f8c7
commit 31c5528ffb
26 changed files with 246 additions and 203 deletions

View File

@@ -37,6 +37,7 @@
#include "LOD.h"
#include "PagedLOD.h"
#include "PositionAttitudeTransform.h"
#include "DOFTransform.h"
#include "Transform.h"
#include "Switch.h"
#include "OccluderNode.h"
@@ -110,6 +111,12 @@ void DataOutputStream::writeLong(long l){
if (_verboseOutput) std::cout<<"read/writeLong() ["<<l<<"]"<<std::endl;
}
void DataOutputStream::writeULong(unsigned long l){
_ostream->write((char*)&l, LONGSIZE);
if (_verboseOutput) std::cout<<"read/writeULong() ["<<l<<"]"<<std::endl;
}
void DataOutputStream::writeDouble(double d){
_ostream->write((char*)&d, DOUBLESIZE);
@@ -500,6 +507,9 @@ void DataOutputStream::writeNode(const osg::Node* node)
else if(dynamic_cast<const osg::PositionAttitudeTransform*>(node)){
((ive::PositionAttitudeTransform*)(node))->write(this);
}
else if(dynamic_cast<const osgSim::DOFTransform*>(node)){
((ive::DOFTransform*)(node))->write(this);
}
else if(dynamic_cast<const osg::LightSource*>(node)){
((ive::LightSource*)(node))->write(this);
}