External latin font (from font converter) shows discoloration

  • I am seeing some discoloration of externally generated latin fonts in a horizontal band through the middle of the screen. The black text appears red-ish in the band. See the attached images.

    The latin fonts were converted with 4bpp anti-aliasing while the Japanese font was not.

    These red bands do not appear when using the default emWin latin fonts.

    Any thoughts as to what may be causing this?

  • I never debugged the entire issue. I disabled antialiasing on the font conversion and the red bands have disappeared. I assume it had something to do with the blending which was occurring.

  • Hi,

    Drawing AA-fonts requires the ability to read the content of the frame buffer to be able to mix the current content with the text color. How that reading operation works depends on the kind of the used display driver. Drivers with a direct interface like GUIDRV_Lin access the RAM by data- and address bus. Drivers with indirect interface like GUIDRV_FlexColor require reading functions passed by the structure GUI_PORT_API when calling GUIDRV_FlexColor_SetFunc().

    Our assumption is that reading the frame buffer does not work right. Here is a small test which checks if reading basically works:

    It should produce the attached screen.

    It would be helpful to know if that works.

    Regards, Jörg

    Images

    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: https://www.segger.com/ticket/

    Or you can contact us via e-mail.

  • Jörg,

    I have run the test pattern. It appears as expected.

    I suspect it had to do with anti-aliasing or the memory-mapped lcd driver. In any case, using non anti-aliased fonts seems to be working.

    Cheers,
    Joe

  • please do the next test:


    int i = 0;
    while i<0xffffff
    {
    GUI_SetBkColor(i);
    i+=0x010101;
    GUI_Clear();
    GUI_Delay(10);
    }


    that should draw black screen fade into white screen.


    share the results please

  • Hi,

    The test works (of course) without problems and fades from black to white.

    Regards, Jörg

    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: https://www.segger.com/ticket/

    Or you can contact us via e-mail.

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!