Skip to content

fix: NemaGFX requires word-aligned buffers - #3

Merged
AndreCostaaa merged 1 commit into
lvgl:masterfrom
fusetim:fix-nema-alignment
Apr 23, 2026
Merged

fix: NemaGFX requires word-aligned buffers#3
AndreCostaaa merged 1 commit into
lvgl:masterfrom
fusetim:fix-nema-alignment

Conversation

@fusetim

@fusetim fusetim commented Apr 22, 2026

Copy link
Copy Markdown

NemaGFX buffers (src and dst) must be word-aligned.

This commit introduces a two-line change, to ensure all LVGL memory buffers (including (static) image buffers) are word-aligned.
Otherwise, you might get funny colors if your images do not start on word-boundary.

Ref: lvgl/lvgl#9975


Summary by cubic

Align all LVGL buffers to 4 bytes to satisfy NemaGFX and prevent color glitches with misaligned images. Sets LV_ATTRIBUTE_MEM_ALIGN_SIZE to 4 and defines LV_ATTRIBUTE_MEM_ALIGN as __attribute__((aligned(LV_ATTRIBUTE_MEM_ALIGN_SIZE))) so image and display buffers are word-aligned.

Written for commit 59d37c2. Summary will update on new commits.

NemaGFX buffers (src and dst) must be word-aligned.

This commit introduces a two-line change, to ensure all LVGL memory buffers (including
(static) image buffers) are word-aligned.
Otherwise, you might get funny colors if your images do not start on word-boundary.

Ref: lvgl/lvgl#9975

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

No issues found across 1 file

@AndreCostaaa
AndreCostaaa merged commit 2de97d7 into lvgl:master Apr 23, 2026
2 checks passed
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.

2 participants