-
Notifications
You must be signed in to change notification settings - Fork 135
Description
The attached .png has a horribly bright RGB value (index 0 of palette) on its fully transparent pixels.
Rendering it filtered results in a bright outline, see also https://github.com/DragonMinded/libdragon/wiki/Mksprite#avoiding-outline-artifacts-with-bilinear-filtering
Suggestion for a new feature: implement a command line option for mksprite to auto-bleed edge pixels outwards, so that it looks good when filtered without the user having to fix the alpha channel manually.
Perhaps amount of iterations for bleeding algorithm can be manually set (but I think usally 2 is a good value?)
Attention: the algorithm used for bleeding could depend on the 2D art style, e.g. if outlines are used then the exact index color should bleed outwards, while on styles without an outline it might be preferable to mix 4-or-8 neighbour-pixel colors.
Need to also decide if extended colors are always part of the palette or if new values can be mixed for RGB textures.