Quantcast
Channel: Qt DevNet forums: Qt Quick 1283365070**
Viewing all articles
Browse latest Browse all 4972

What is the proper things to be done in QQuickItem::updatePaintNode() ?

$
0
0
This is an update of my previous question: http://qt-project.org/forums/viewthread/49653/ Finally I located the issue inside updatePaintNode function. I minimized the related code into several lines: // Profile3DWidget is a subclass of QQuickItem QSGNode* Profile3DWidget::updatePaintNode(QSGNode * old_node, UpdatePaintNodeData * data) {     if (!old_node)     {         old_node = new QSGGeometryNode();     } } The program crashes. But if I change the created node class to QSGNode, the program will not crash: // Profile3DWidget is a subclass of QQuickItem QSGNode* Profile3DWidget::updatePaintNode(QSGNode * old_node, UpdatePaintNodeData * data) {     if (!old_node)     {         old_node = new QSGNode();     } } So what should I do inside this function? Thanks!!

Viewing all articles
Browse latest Browse all 4972

Latest Images

Trending Articles



Latest Images