[Interest] [Qt3D][Threads] A right way to do calculations for qt 3d entities in separate thread

Oleg Evseev ev.mipt at gmail.com
Sat Apr 15 12:45:15 CEST 2017


Hi,

I have a Scene3D with different QEntities.

One of the entity have a slot with calculations which involves updating
QGeometry of one of its child (QEntity) and sometimes creating new child
entity.
I'm looking for a way to move those calculations into separate thread.

But according to http://doc.qt.io/qt-5/threads-qobject.html the first
constraint to be aware of is "The child of a QObject must always be created
in the thread where the parent was created".

So the only thing that comes to mind is to use signals from separate thread
to main one where is parent entity as the request to create new child
entity and another signal from main thread to separate with pointer of new
created child.
Is this a right way to do it?

Thanks in advance for help.

---
With regards, Oleg
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20170415/40a2afae/attachment.html>


More information about the Interest mailing list