Unsolved Mouser cursor move around when calling qopenglwidget::update.
-
platform: imx6q cortex-a9 arm based board
rootfs: fsl-yocto-L4.1.15_2.0.0-ga; fsl-img-qt5
qt version: 5.6.2The code is very simple, a mainwindow containing a custom widget inherits
qopenglwidget
, and call theqopenglwidget::update
30 times per second, the strange thing is the cursor will move around randomly, if I don't call the update then everything works right.Qopenglwidget::update
will call the overridepaintgl
and I have commented it so it will do nothing. But if I run the code on my pc there is no such issue. So I think the problem might come from the rootfs on the arm board writed by qt.
I have came up with one solution, write a render function callingpaintgl
, but there will be some work withqopenglcontext
andqopenglframebufferobject
, how to write====update====
Or, is there any low level example about how to use qwidget and opengl instead of using qopenglwidget?