Rename internal C++ Color struct to Color32 to help differentiate it from Colorf.

This commit is contained in:
Alex Szpakowski
2019-09-14 23:13:40 -03:00
parent e824a1e26b
commit 9ab2a94037
17 changed files with 65 additions and 65 deletions
+2 -2
View File
@@ -50,7 +50,7 @@ namespace image
namespace magpie
{
static_assert(sizeof(Color) == 4, "sizeof(Color) must equal 4 bytes!");
static_assert(sizeof(Color32) == 4, "sizeof(Color32) must equal 4 bytes!");
bool STBHandler::canDecode(Data *data)
{
@@ -147,7 +147,7 @@ FormatHandler::EncodedImage STBHandler::encode(const DecodedImage &img, EncodedF
memcpy(encimg.data + headerlen, img.data, img.width * img.height * bpp);
// convert the pixels from RGBA to BGRA.
Color *encodedpixels = (Color *) (encimg.data + headerlen);
Color32 *encodedpixels = (Color32 *) (encimg.data + headerlen);
for (int y = 0; y < img.height; y++)
{
for (int x = 0; x < img.width; x++)