File tree Expand file tree Collapse file tree 3 files changed +7
-16
lines changed
Expand file tree Collapse file tree 3 files changed +7
-16
lines changed Original file line number Diff line number Diff line change @@ -64,7 +64,7 @@ if(NOT VCPKG_MANIFEST_MODE)
6464 list (APPEND PACKAGES_ALL ${PACKAGES_TEST} )
6565
6666 ezvcpkg_fetch (
67- COMMIT 2024.07.12
67+ COMMIT 2024.11.16
6868 PACKAGES ${PACKAGES_ALL}
6969 # Clean the build trees after building, so that we don't use a ton a disk space on the CI cache
7070 CLEAN_BUILDTREES
Original file line number Diff line number Diff line change 33
44#include < cstring>
55
6- namespace Cesium {
7- // Use STB resize in our own namespace to avoid conflicts from other libs
86#define STBIRDEF
9- #include < stb_image_resize .h>
7+ #include < stb_image_resize2 .h>
108#undef STBIRDEF
11- } // namespace Cesium
12-
13- using namespace Cesium ;
149
1510#define STB_IMAGE_WRITE_STATIC
1611#define STB_IMAGE_WRITE_IMPLEMENTATION
@@ -108,7 +103,7 @@ bool ImageManipulation::blitImage(
108103 }
109104
110105 // Use STB to do the copy / scale
111- stbir_resize_uint8 (
106+ stbir_resize_uint8_linear (
112107 reinterpret_cast <const unsigned char *>(pSource),
113108 sourcePixels.width ,
114109 sourcePixels.height ,
@@ -117,7 +112,7 @@ bool ImageManipulation::blitImage(
117112 targetPixels.width ,
118113 targetPixels.height ,
119114 int (bytesPerTargetRow),
120- target.channels );
115+ static_cast <stbir_pixel_layout>( target.channels ) );
121116 }
122117
123118 return true ;
Original file line number Diff line number Diff line change 3131
3232#define STBI_FAILURE_USERMSG
3333
34- namespace Cesium {
35- // Use STB resize in our own namespace to avoid conflicts from other libs
3634#define STBIRDEF
3735#define STB_IMAGE_RESIZE_IMPLEMENTATION
38- #include < stb_image_resize .h>
36+ #include < stb_image_resize2 .h>
3937#undef STBIRDEF
40- } // namespace Cesium
4138
4239#define STB_IMAGE_STATIC
4340#define STB_IMAGE_IMPLEMENTATION
@@ -49,7 +46,6 @@ using namespace CesiumGltf;
4946using namespace CesiumGltfReader ;
5047using namespace CesiumJsonReader ;
5148using namespace CesiumUtility ;
52- using namespace Cesium ;
5349
5450namespace {
5551#pragma pack(push, 1)
@@ -970,7 +966,7 @@ std::optional<std::string> GltfReader::generateMipMaps(ImageCesium& image) {
970966 image.mipPositions [mipIndex].byteOffset = byteOffset;
971967 image.mipPositions [mipIndex].byteSize = byteSize;
972968
973- if (!stbir_resize_uint8 (
969+ if (!stbir_resize_uint8_linear (
974970 reinterpret_cast <const unsigned char *>(
975971 &image.pixelData [lastByteOffset]),
976972 lastWidth,
@@ -980,7 +976,7 @@ std::optional<std::string> GltfReader::generateMipMaps(ImageCesium& image) {
980976 mipWidth,
981977 mipHeight,
982978 0 ,
983- image.channels )) {
979+ static_cast <stbir_pixel_layout>( image.channels ) )) {
984980 // Remove any added mipmaps.
985981 image.mipPositions .clear ();
986982 image.pixelData .resize (imageByteSize);
You can’t perform that action at this time.
0 commit comments