WM_Invalidate during WM_Paint processing

This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

  • WM_Invalidate during WM_Paint processing

    Hi. I am getting screen flicker even though I have double-buffering enabled and otherwise working. I've traced it to occurring when a Window is invalidated whilst it is being painted. This occurs in these circumstances:
    1. GUI_TIMER set up to WM_Invalidate a window (timer is 150ms)
    2. WM_Paint used to paint the screen (screen is taking >150ms to paint)
    3. RTX OS (around 20 tasks running, most on same priority as the WM system)


    Whilst an overrun of the paint time is ny root problem I am not sure the screen should flicker. In saying this, the flicker is a useful debug tool to tell me "overrunning paint"! Maybe there is a define switch somewhere where this is a feature enabled/disabled?

    As an aside, the reason for the paint being so long was my use of RLE compressed bitmaps. I changed to non-compressed and gained an improvement. Am now moving to MEMDEV objects with the hope of improving more.

    Regards
  • Hi,

    Multibuffering works only with the GUIDRV_Lin driver. To enable automatic use of multibuffering with the Window Manager you have to WM_MULTIBUF_Enable(1) after GUI_Init().

    If you are not using GUIDRV_Lin ouy have to use a cached version of the driver. For more information refer to the manual in the appropriate chapter.

    Maybe there is a define switch somewhere where this is a feature enabled/disabled?
    I'm not sure about which feature you are talking...

    As an aside, the reason for the paint being so long was my use of RLE compressed bitmaps.
    The fastest image format is that which fits to the LCD-configuration. For example, if you set up the LCD configuration to use a 16bpp color conversion like GUICC_565 the fastest image format is 565 (for GUICC_M8888I it would be 32bit). You can create images with the BitmapConverter and choose the proper format when saving the image as c-file.

    Regards,
    Sven
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.