mirror of
https://github.com/JulianGro/overte.git
synced 2025-04-29 21:23:05 +02:00
Merge pull request #6376 from ZappoMan/fixModelCrash
fix crash in Model::deleteGeometry when _rig is not initialized
This commit is contained in:
commit
319f9fc30e
1 changed files with 5 additions and 3 deletions
|
@ -1099,10 +1099,12 @@ void Model::setGeometry(const QSharedPointer<NetworkGeometry>& newGeometry) {
|
|||
|
||||
void Model::deleteGeometry() {
|
||||
_blendedVertexBuffers.clear();
|
||||
_rig->clearJointStates();
|
||||
_meshStates.clear();
|
||||
_rig->deleteAnimations();
|
||||
_rig->destroyAnimGraph();
|
||||
if (_rig) {
|
||||
_rig->clearJointStates();
|
||||
_rig->deleteAnimations();
|
||||
_rig->destroyAnimGraph();
|
||||
}
|
||||
_blendedBlendshapeCoefficients.clear();
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue