A downloadable Tool for Windows

Download NowName your own price

A prototype of a tool that I'm intending to eventually use for some retro-style projects.
The idea behind it is to use each pixel to represent an index rather than a color, this is inspired by the way consoles such as the NES work.

This index can then be used in a shader to offset the UV coordinates such that the corresponding color in a palette image is located.

This means that by swapping the palette image read by the shader, you can swap all of the sprite's colors without the need for alternate sets of sprites. You can also easily add the ability to cycle through colors with a simple offset value in the shader.



Current features:

  • Draw a sprite using one of 8 colors in the active palette
  • Change each palette color, automatically updating the sprite
  • Swap to an alternate palette
  • Save and load the sprite in a custom binary format

Upcoming features:

  • Support for multiple sprites, with animation previewing
  • Add and remove palettes
  • Save and load palettes
  • Save and load sprites as png images
  • Disable the bottom two, or right two grids to create 16x8 or 8x16 sprites

More info:
Currently, sprites are stored in a custom .sfr binary format.

Each of the four 8x8 grids stores its contents as a buffer of bytes. This is then compressed using a form of Run Length Encoding designed to work with bytes.

The RLE implementation uses a single byte to represent both the start of a run and the run's length. This is done by using the uppermost bit as a flag as it isn't possible for a run to be greater than 127, thus the uppermost bit would never normally be set.

When saving, the buffers for each grid are stored in a continuous stream with an additional bit representing the length prepended to each. This length bit allows for separating the single stream into its 4 buffers when it comes time to load.


Credits:

at01 Pixel Font: https://grafxkid.itch.io/at01

Download

Download NowName your own price

Click download now to get access to the following files:

windows.zip 35 MB

Leave a comment

Log in with itch.io to leave a comment.