Home > Mobile >  QT refresh timer interface problem
QT refresh timer interface problem

Time:10-11

Implemented using QT version, will every frame image mapped, to draw in a paintevent, comfortable speed through the timer Settings,

Through the timer timeout calls the update method refresh paintevent to refresh interface,
4 ms timer setting time, paintevent refresh again time is about 10 ms, the notable speed is slow, at this time what happened??

Set the timer timeout is 16 ms, paintevent call a time about 10 ms, version can appear cogged, at this time what happened??

Who can help me and explain these two cases is how to return a responsibility

CodePudding user response:

How to improve the interface refresh efficiency

CodePudding user response:

Change a good computer can obviously increase

CodePudding user response:

After this and the update call related qt the means of processing, the update will only remind refresh redrawn, but qt will need to redraw their judgment, will merge into one and then redraw many times, you draw directly outside a try, not pantevent processing in a try,

CodePudding user response:

Connection when the last parameter to specify the connection way, do you use to direct a try, not to put the timer on another thread, try effect, at least some time interval should be more accurate

CodePudding user response:

refer to the original poster smiling qian xi reply opportunely:
implemented using QT version, will every frame image mapped, to draw in a paintevent, comfortable speed through the timer Settings,

Through the timer timeout calls the update method refresh paintevent to refresh interface,
4 ms timer setting time, paintevent refresh again time is about 10 ms, the notable speed is slow, at this time what happened??

Set the timer timeout is 16 ms, paintevent call a time about 10 ms, version can appear cogged, at this time what happened??

Who can help me and explain these two cases is how to return a responsibility


Brush so fast, the human eye treatment?
Movie to 24 picture 1 SEC
  •  Tags:  
  • Qt
  • Related