Skip to content

Add gd_copy_frame_data()#32

Open
villesundell wants to merge 1 commit intolecram:masterfrom
villesundell:copy-frame-data
Open

Add gd_copy_frame_data()#32
villesundell wants to merge 1 commit intolecram:masterfrom
villesundell:copy-frame-data

Conversation

@villesundell
Copy link
Copy Markdown

@villesundell villesundell commented Jan 23, 2026

The gd_render_frame() copies the pixel-ready picture to the destination buffer, by converting the palette entries into three-byte colored pixels.

However, this is not always desired. For example in applications which need to preserve the pixel - palette relationship for further processing.

Hence the new gd_copy_frame_data() function, which copies only the raw data (pixels represent palette indexes, not colors per se).

Thank you for this amazing and simple library 🙏

The gd_render_frame() copies the pixel-ready picture to the
destination buffer, by converting the palette entries into three-byte
colored pixels.

However, this is not always desired. For example in applications which
need to preserve the pixel - palette relationship for further
processing.

Hence the new gd_copy_frame_data() function, which copies only the
raw data (pixels represent palette indexes, not colors per se).
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.

1 participant