Sprite Production Field Notes

sprite sheet maker

Reset pixels and opacity before recycling a HUD buffer

A Solarus toast can inherit yesterday’s icon and the previous notification’s fading opacity. For a reused surface, pixels and drawable opacity have separate lifetimes. In the tested runtime, filling with zero alpha did not erase the old pixels. The clear operation did erase them and retained the surface’s opacity.

Make your buffer pool prove it can change roles

Render a red badge near the left side of a test notification and leave it at a partially faded opacity. Return its surface to the pool. Take the same allocation back, reset it for a fully opaque notification, and draw a small yellow badge near the right side. Check the old badge location for transparency and the new one for the expected opacity after compositing.

Run the test with the two notifications reversed too, so an accidentally correct default does not conceal a one-way reset. Assign the initial opacity at the point where the new role acquires the surface. Keep an allocator assertion for dimensions in case a future role borrows a differently sized buffer. FrameSprite’s technical guide and test fixture shows why a transparent fill and an actual clear give different outcomes.

Prepared by the FrameSprite Workflow Team with AI assistance. Examples are illustrative unless attributed to a linked fixture.