mirror of
https://github.com/overte-org/overte.git
synced 2025-04-20 04:44:11 +02:00
call into correct thread to getJointNames on entity
This commit is contained in:
parent
f265656e74
commit
a515d6debe
1 changed files with 5 additions and 0 deletions
|
@ -774,6 +774,11 @@ int RenderableModelEntityItem::getJointIndex(const QString& name) const {
|
|||
|
||||
QStringList RenderableModelEntityItem::getJointNames() const {
|
||||
QStringList result;
|
||||
if (QThread::currentThread() != thread()) {
|
||||
QMetaObject::invokeMethod(const_cast<RenderableModelEntityItem*>(this), "getJointNames", Qt::BlockingQueuedConnection,
|
||||
Q_RETURN_ARG(QStringList, result));
|
||||
return result;
|
||||
}
|
||||
if (_model && _model->isActive()) {
|
||||
RigPointer rig = _model->getRig();
|
||||
int jointCount = rig->getJointStateCount();
|
||||
|
|
Loading…
Reference in a new issue