3D scatter performance
Unsolved
General and Desktop
-
Hi,
I'm using Q3DScatter to visualize 3D data. In total, I want to display ~100.000 points with a frame rate of ~20Hz.
But I only achieve a frame rate of ~4 hz.
I use the Scatter example of QT creator as a starting point. I inserted a QTimer to create new data:m_selectionTimer = new QTimer(this); m_selectionTimer->setInterval(100); m_selectionTimer->setSingleShot(false); QObject::connect(m_selectionTimer, &QTimer::timeout, this, &ScatterDataModifier::addData); m_selectionTimer->start();
the displaying of data is stripped down to the following:
QScatterDataItem *ptrToDataArray = &m_dataArray->first(); for (int i = 0; i < m_itemCount; i++) { ptrToDataArray->setPosition(randVector()); ptrToDataArray++; } m_proxy->resetArray(m_dataArray);
I guess this is the fastest way to update data, or do you have any hints to improve performance?
Thanks in advance for the help!