Qt3d Input in c++
Is it possible to do handle mouse input in qt3d in c++? I am able to do so using qml using a sample in the qt3d repo
There isnt a c++ equivalent for this however.
I am not able to do capture mouse events in c++ at all despite numerous attempts (even trying to capture input using event filters attached to various widgets) . Is the c++ mouse input api for qt3d complete for this version of qt (5.6) or should i wait for version 5.7?
I experimented with that a few months ago, but the API has (probably) changed from then. I'm not completely sure at what state it is currently, but here's my exchange with Sean I hope it's of help. This might also be helpful.
For capturing mouse event on any Entity in just add one component Qt3DRender::QObjectPicker() and connect this component with your slot where you want to handle mouse event .
I hope this is what you want.
The new qt3d update fixed the input api for c++.
Thanks for the help guys.