mirror of
https://github.com/JulianGro/overte.git
synced 2025-04-29 20:42:56 +02:00
Merge pull request #15251 from SamGondelman/animation82
Case 21888: Revert changes that impacted animation performance
This commit is contained in:
commit
3c42cb34ed
2 changed files with 7 additions and 14 deletions
|
@ -178,7 +178,6 @@ void CauterizedModel::updateClusterMatrices() {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
computeMeshPartLocalBounds();
|
|
||||||
|
|
||||||
// post the blender if we're not currently waiting for one to finish
|
// post the blender if we're not currently waiting for one to finish
|
||||||
auto modelBlender = DependencyManager::get<ModelBlender>();
|
auto modelBlender = DependencyManager::get<ModelBlender>();
|
||||||
|
|
|
@ -1346,19 +1346,14 @@ void Model::updateRig(float deltaTime, glm::mat4 parentTransform) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void Model::computeMeshPartLocalBounds() {
|
void Model::computeMeshPartLocalBounds() {
|
||||||
render::Transaction transaction;
|
for (auto& part : _modelMeshRenderItems) {
|
||||||
auto meshStates = _meshStates;
|
const Model::MeshState& state = _meshStates.at(part->_meshIndex);
|
||||||
for (auto renderItem : _modelMeshRenderItemIDs) {
|
|
||||||
transaction.updateItem<ModelMeshPartPayload>(renderItem, [this, meshStates](ModelMeshPartPayload& data) {
|
|
||||||
const Model::MeshState& state = meshStates.at(data._meshIndex);
|
|
||||||
if (_useDualQuaternionSkinning) {
|
if (_useDualQuaternionSkinning) {
|
||||||
data.computeAdjustedLocalBound(state.clusterDualQuaternions);
|
part->computeAdjustedLocalBound(state.clusterDualQuaternions);
|
||||||
} else {
|
} else {
|
||||||
data.computeAdjustedLocalBound(state.clusterMatrices);
|
part->computeAdjustedLocalBound(state.clusterMatrices);
|
||||||
}
|
}
|
||||||
});
|
|
||||||
}
|
}
|
||||||
AbstractViewStateInterface::instance()->getMain3DScene()->enqueueTransaction(transaction);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// virtual
|
// virtual
|
||||||
|
@ -1391,7 +1386,6 @@ void Model::updateClusterMatrices() {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
computeMeshPartLocalBounds();
|
|
||||||
|
|
||||||
// post the blender if we're not currently waiting for one to finish
|
// post the blender if we're not currently waiting for one to finish
|
||||||
auto modelBlender = DependencyManager::get<ModelBlender>();
|
auto modelBlender = DependencyManager::get<ModelBlender>();
|
||||||
|
|
Loading…
Reference in a new issue