mirror of
https://github.com/thorvg/thorvg.git
synced 2025-06-08 13:43:43 +00:00
loaders/png: fixed data conversion warnings on Windows
../src/loaders/external_png/tvgPngLoader.cpp(110): warning C4244: '=': conversion from 'float' to 'uint32_t', possible loss of data ../src/loaders/external_png/tvgPngLoader.cpp(111): warning C4244: '=': conversion from 'float' to 'uint32_t', possible loss of data ../src/loaders/external_png/tvgPngLoader.cpp(112): warning C4244: '=': conversion from 'float' to 'uint32_t', possible loss of data
This commit is contained in:
parent
226c468f72
commit
a08b7f0c38
1 changed files with 3 additions and 3 deletions
|
@ -107,9 +107,9 @@ unique_ptr<Surface> PngLoader::bitmap()
|
||||||
//TODO: It's better to keep this surface instance in the loader side
|
//TODO: It's better to keep this surface instance in the loader side
|
||||||
auto surface = new Surface;
|
auto surface = new Surface;
|
||||||
surface->buf32 = content;
|
surface->buf32 = content;
|
||||||
surface->stride = w;
|
surface->stride = (uint32_t)w;
|
||||||
surface->w = w;
|
surface->w = (uint32_t)w;
|
||||||
surface->h = h;
|
surface->h = (uint32_t)h;
|
||||||
surface->cs = cs;
|
surface->cs = cs;
|
||||||
surface->channelSize = sizeof(uint32_t);
|
surface->channelSize = sizeof(uint32_t);
|
||||||
surface->owner = true;
|
surface->owner = true;
|
||||||
|
|
Loading…
Add table
Reference in a new issue