Civ2-clone
Civ2-clone copied to clipboard
Some issues with BitmapStorage
-
The
Raylib.LoadImageFromMemoryfunction for _imageCache https://github.com/axx0/Civ2-clone/blob/1cb5c53eb77adcd8a3c72f7d1602ba7a9bd9911b/RaylibUI/Bitmaps/Images.ImportBitmaps.cs#L101 works well only for gifs but not for bmps so we probably have to use our custom implementation here (I'm referring toLoadPropertiesFromPicfunction in RaylibUtils). -
We probably don't need to define transparent colours in BitmapStorage and then do this: https://github.com/axx0/Civ2-clone/blob/1cb5c53eb77adcd8a3c72f7d1602ba7a9bd9911b/RaylibUI/Bitmaps/Images.ImportBitmaps.cs#L111 since transparent colours are already defined in the colour palette of the file (pngs work different but we already deal with that). If 1) is solved then the cached image will have transparent colours fixed.
-
Extraction of images and textures in
CityLoader,TerrainLoader, etc. differs from the implementation mentioned in 1) with _imageCache. This needs to be cleaned up so that the bitmap & texture loading logic is consistent throughout the project.
I can try to deal with this.