POLYGONS in QML
-
Hello,
It depends on what you want to do. If you want one or a few trapeziums that do not interact with other objects, you can use Image. If you want trapezium that can change its color, width, height and so on you should subclass "QDeclarativeItem":http://doc.qt.nokia.com/4.7-snapshot/qdeclarativeitem.html
Also note that Box2D does not provide visual items.
-
Not by only using QML. As task_struct mentioned above, if you'd like that functionality, you'll have to create a custom QDeclarativeItem in C++ to do it.
There's an example "here":http://www.developer.nokia.com/Community/Wiki/CS001627_-_Creating_a_custom_QML_element_with_Qt which shows how you can create a Line. You can apply the same principles to drawing your own custom object.