Skip to content

Setting custom color palette #280

Description

@loxai

Hi (to tobozo, lovyan or any other welcomed expert :)

I'm using the lib on an m5stack. I've been working on a large project and bumping into memory problems.
Up until now, I have been using a framebuffer at 320x240x16bits to do fast graphics. But that's a good chunk of mem.
I tried using begin/end transactions, but I always get flicker. maybe I'm not doing it right (I might open a separate issue, after closing this one).

if I do a 320x240x4bit buffer, I'm saving a lot of mem and still have enough colors, but I don't see a way to set the palette (ie. a custom palette for 2 or 4 bit buffer). is there a way to set an rgb array as palette for a sprite or the LGFX_Device (currently I have the latter at 16bit, while testing sprite/buffer at 2 or 4 (only get color at 8)?

Kind regards

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions