2021-05-28 04:40 AM
Question is if TouchGFX framework supports 256 colors? How to tie together hardware CLUT settings and framework?
Due to internal RAM size limitations, I want to halve the framebuffer size by reducing the color depth from 16 bpp to 8 bpp . I cannot use the partial buffer strategy because my display has an RGB interface and no internal GRAM.
Firstly without TouchGFX enabled I changed LTDC setting PixelFormat to L8 and enable CLUT with some random colors to see if hardware settings are ok. That setting works, I can see my colors.
Now I make TouchGFX Designer application with 8 bit color depth option. After creating UI in simulator and see it in 256 colors style as expected. But on my target board everything is drawn in 256 grey scale.
There are references in the documentation about 8 bpp bitmaps for images to reduce flash occupied by them. But my goal is to reduce RAM for framebuffer, is it even possible.
Solved! Go to Solution.
2021-05-29 09:20 AM
In Cube project folder /touchgfx/target delete this full before in cube generate code, here is bug that when you change from one to other config this files isnt correct regenerated always.
And generating process generate for you CLUT ARGB2222 , you dont need hand work here. Too touchgfx convert all images with selected dither to this CLUT table. You after generate see it in file target/TouchGFXHAL.cpp
2021-05-28 07:10 AM
I setup it in Cube:
2021-05-29 02:53 AM
Hey!
Can you please elaborate. Step 4: what folder should I delete?
Can't see settings for CLUT table in CubeMX nor in TouchGFX Designer, I thought CLUT is generated by hand
2021-05-29 09:20 AM
In Cube project folder /touchgfx/target delete this full before in cube generate code, here is bug that when you change from one to other config this files isnt correct regenerated always.
And generating process generate for you CLUT ARGB2222 , you dont need hand work here. Too touchgfx convert all images with selected dither to this CLUT table. You after generate see it in file target/TouchGFXHAL.cpp
2021-05-30 04:26 AM
Thanks, it worked
2021-11-19 06:09 AM
@MM..1 This literally saved me hours of debugging