Added optional indexed color conversion for TMX

Added support for direct conversion of 4bpp/8bpp TMX files into
respective 4bpp/8bpp indexed color images, to preserve the palette and
color ordering; added new "--colorindex" switch to enable indexed color
conversion