QQuickPaintedItem calling both updatePaintNode and paint
-
Hi.
I am trying to use the best of both worlds: using updatePaintNode to draw all but text onto my QuickPaintItem, and call its paint method to place text on the screen. (I am doing this as I do not know how to draw text with the opengl inside updatePaintNode, examples welcomed)
If I comment out updatePaintNode method. The painter gets called and everything okay. To get paint() method called I call at the end of my updatePaintNode
QQuickPaintedItem::updatePaintNode(oldNode,data);
This results in painter getting called but nothing shows up on the screen. Also, if I resize the screen it core dumps.
Is this considered bad practise to paint with opengl and use a Painter inside paint.
Any advise on how to get what is drawn with painter(inside paint() method) to show up with updatePaintNode is much appreciated. As are suggestions for best practises.
Thanks in advance for any help you can provide.
-David
-
Did you check out the Nano painter Library? It uses the best of both approaches...