Hi guys &girls,
I’m writing an application that tracks the head movement from webcam and paint na image over the face. The problem is how to create and bind c++class instance to qml.
Pseudo c++ code:
Class FaceItem{
String imagePath;
float scale;
QVector2D position;
QVector3D rotation;
}
And now how do I create and bind a qml objects like:
Image{
source:imagePath
x:position.x
y:positon.y
scale:scale
Rotation {axis: Qt.vector3d(0, 0, 1); angle: rotation_.x }
}
I have tried ListView example (http://qt-project.org/doc/qt-5/qtquick-modelviewsdata-cppmodels.html), but position of list element doesnt work for me, because listview does not permit to overlay two list elements(in my case images).
Thanks for your help!
↧