UnderwareDESIGN

PlayBASIC => Resources => Source Codes => Topic started by: kevin on December 07, 2010, 10:19:39 AM

Title: Palette Mapped Image Functions
Post by: kevin on December 07, 2010, 10:19:39 AM

  Palette Mapped Image Functions

   The attached code contains some functions to convert an image in memory into a palette mapped bank and back again.  The version of the image stored in the bank is palette mapped, so the image is broken down into a colour index table and palette table (table of unique colours).

     The functions are set up to support images of up to 65536 unique colours, if the image has less than 256 colours then the colour index table is a byte per pixel, otherwise it's a word..