Rolbacked RigGeometry with the hackyfix (I just add the compute boundcallback in the copy consturctor)

Modified headers of RigTransforms to comply with osg metamodel
This commit is contained in:
Julien Valentin
2016-06-27 11:51:32 +01:00
committed by Robert Osfield
parent 4c149bd2e7
commit c8a7ce4e52
4 changed files with 19 additions and 9 deletions

View File

@@ -57,7 +57,8 @@ RigGeometry::RigGeometry()
setDataVariance(osg::Object::DYNAMIC);
_needToComputeMatrix = true;
_matrixFromSkeletonToGeometry = _invMatrixFromSkeletonToGeometry = osg::Matrix::identity();
// disable the computation of boundingbox for the rig mesh
setComputeBoundingBoxCallback(new RigComputeBoundingBoxCallback);
}
@@ -68,9 +69,12 @@ RigGeometry::RigGeometry(const RigGeometry& b, const osg::CopyOp& copyop) :
_vertexInfluenceSet(b._vertexInfluenceSet),
_vertexInfluenceMap(b._vertexInfluenceMap),
_needToComputeMatrix(b._needToComputeMatrix)
{
{
// disable the computation of boundingbox for the rig mesh
setComputeBoundingBoxCallback(new RigComputeBoundingBoxCallback);
// we dont copy the RigImplementation yet. because the RigImplementation need to be initialized in a valid graph, with a skeleton ...
// dont know yet what to do with a clone of a RigGeometry
}
@@ -113,8 +117,6 @@ void RigGeometry::computeMatrixFromRootSkeleton()
_matrixFromSkeletonToGeometry = mtxList[0] * osg::Matrix::inverse(notRoot);
_invMatrixFromSkeletonToGeometry = osg::Matrix::inverse(_matrixFromSkeletonToGeometry);
_needToComputeMatrix = false;
// disable the computation of boundingbox for the rig mesh
setComputeBoundingBoxCallback(new RigComputeBoundingBoxCallback);
}
void RigGeometry::update()