Hi

I've noticed a strange behaviour in my application and I'm not able to understand if this is my implementation problem or not and who I can resolve this problem.

I'm using Kubuntu 12.10 with QT 4.8.2 from repositories packages.

The situation is the follows:

I have a widget which extends QGLWidget. I make some graphics operations and when I done I call the QWidget::update() to force an override paintGL() slot to repaint the widget. At random times, happens that the QWidget::update() DON'T calls the paintGL(), so, there is not 1:1 correspondance between update() and paintGL() slot.

In general this can't be a problem, but in my case I use a semaphore release inside the paintGL(): if the paintGL() is lost, the semaphore release don't comes and my application freezes. I have to use this semaphore because others my application modules have to wait until paintGL() is finished: paintGL() have to work on a graphics shared structure which can't be modified from others component until paintGL() are done, because race-condition (if I don't use the semaphore the application crash because the slot paintGL() can be called when another module works on shared structure).

There is a trick to force 1:1 update() and paintGL(), or there are some advices to engineer this situation in a different and secure way?

Many thanks!

Bye