Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(draw): Enable TSC Compression scheme for frame buffer in Nema acceleration #7509

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

MarkIoanAmat
Copy link
Contributor

TSC Compression for FB

While using NemaGFX to accelerate LVGL, we have the option to use ThinkSilicon's proprietary TSC compression algorithms to encode/decode the frame buffer in favor of memory consumption.

Steps to Enable

  • Enable TSC Frame buffer type. e.g lv_display_set_color_format(display, LV_COLOR_FORMAT_NEMA_TSC12A);
  • Bypass lv_draw_sw_blend function with the use of the define below inside in lv_conf.h
    #define LV_DRAW_BLEND_CUSTOM LV_DRAW_BLEND_CUSTOM_NEMA_GFX

Features not supported while using TSC compression for frame buffer

  • LV_COLOR_FORMAT_ARGB8565
  • LV_COLOR_FORMAT_RGB565A8
  • Blending mode LV_BLEND_MODE_SUBTRACTIVE

@MarkIoanAmat
Copy link
Contributor Author

@kisvegabor @liamHowatt

Copy link
Collaborator

@uLipe uLipe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

First pass, I have a small comment.


lv_area_t blend_area;
if(!lv_area_intersect(&blend_area, blend_dsc->blend_area, draw_unit->clip_area)) return;

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like this initial checking, but I'd like to see an extra information to aid people to track when the things go wrong here, simply putting log-err or log-warning would be helpful here.

@kisvegabor
Copy link
Member

Let's consider #7531 too, as it aims to solve the same issue.

@MarkIoanAmat
Copy link
Contributor Author

@kisvegabor
I had a quick look at #7531 to my understanding these 2 solutions are complementary as they solve different problems. PR #7509 aims to by pass the whole lv_draw_sw_blend function and use a custom one. On the other one PR #7531 allow registering different blending handlers inside lv_draw_sw_blend. Also PR #7509 is adding a special feature which requires the presence of NemaGPU Plus the TSC Compression scheme for FB and it is working under specific constrictions. I can not think of a way merging those two solutions without polluting the common code, which is not preferred of course.
Waiting for your feedback. Thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants