- Add separate `CFGFLAG_COLLIGHT7` for 0.7 color config variables, which use `61/255` as darkest lighting value. In comparison, `CFGFLAG_COLLIGHT` uses `0.5` darkest lighting, so the color values being shown for 0.7 color variables were incorrect. Closes#8775.
- Pass darkest lighting as parameter directly instead of using `bool`s to avoid duplicating the logic.
- Add `ColorHSLA::DARKEST_LGT7` constant to replace existing `CTeeInfo::ms_DarkestLGT7` and `CSkins7::DARKEST_COLOR_LGT` constants.
- Round color components before printing them in config variable command handler, as color components are generally also rounded before being packed and before rendering.
- Remove default value of `ColorHSLA::UnclampLighting` function, to avoid incorrect usage.
Move `CImageInfo` from `engine/graphics.h` to own file `engine/image.h`. Also add 2-component image format to `CImageInfo::EImageFormat` for completeness, to replace the separate `EImageFormat` in `image_loader.h` with `CImageInfo::EImageFormat`.
Move `SetPixelColor`/`GetPixelColor` functions from editor to `CImageInfo` as member functions.
Replace `IGraphics::CopyTextureBufferSub` and `IGraphics::CopyTextureFromTextureBufferSub` functions with more versatile `CImageInfo::CopyRectFrom` function.
Make `IGraphics::LoadSpriteTexture` function more efficient by avoiding a copy of the image data by using the `LoadTextureRawMove` function. Remove unnecessary delegate function `CGraphics_Threaded::LoadSpriteTextureImpl` and temporary buffer `m_vSpriteHelper`.
Move `CEditorImage::DataEquals` function to `CImageInfo::DataEquals`. Use `mem_comp` to compare image data for more efficiency, instead of comparing each pixel individually.
Add another `IGraphics::LoadPng` function that loads image directly from memory and also handles the pnglite incompatibility warnings. This function will be used for more efficient loading of downloaded skin in the future.
Add convenience functions to load/save PNGs from/to `IOHANDLE` to reduce duplicate code when loading and saving images especially in the tools. These functions explicitly only allow loading images in RGBA and RGB format. Move general purpose image loading and saving functions to class `CImageLoader`.
Add more convenient `CByteBufferReader` and `CByteBufferWriter` classes for reading from and writing to a byte buffer while keeping track of the read/write position to replace existing `SImageByteBuffer`.
Extract `ConvertToGrayscale` utility function to reduce duplicate code when creating grayscale versions of skins, start menu images and community icons.
Move and rename `ConvertToRGBA` static function from graphics to `ConvertToRgba` in `image_manipulation.h/cpp`. Add `ConvertToRgbaAlloc` convenience function which allocates the target buffer. Add ``
Add `DilateImage`, `ResizeImage` and `ConvertToRgba` convenience functions that directly accept a `CImageInfo` argument that will be modified.
Remove unnecessary image size limitation in `map_replace_image` tool, which would only be relevant for 0.7 compatible maps. Adjust the maximum allowed image width/height in `map_convert_07` tool to be consistent with the actual limit that the 0.7 client has when loading images (`1 << 13 == 8192`).
Add doxygen comments for `CImageInfo`.
Pass `CImageInfo` by reference consistently, instead of sometimes passing a pointer.
Cleanup image loading and saving code. Improve error handling.
Events with flag `FLAG_RELEASE` must always be forwarded to all components so keys being released can be handled in all components also after some components have been disabled.
Closes#8901.