Skip to content

Commit 44d2f8a

Browse files
committed
Fix MSVC warning
Signed-off-by: Matias N. Goldberg <[email protected]>
1 parent 6aa2ebd commit 44d2f8a

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

test/integration/heightmap.cc

+5-2
Original file line numberDiff line numberDiff line change
@@ -379,7 +379,9 @@ TEST_F(HeightmapTest, GZ_UTILS_TEST_DISABLED_ON_WIN32(Heightmap))
379379
{
380380
// Output reference
381381
base64Encoded.clear();
382-
const uint32_t header[3] = { width, height, normalCamImage.Format() };
382+
const uint32_t header[3] = {
383+
width, height, static_cast<uint32_t>(normalCamImage.Format())
384+
};
383385

384386
Base64Encode(header, sizeof(header), base64Encoded);
385387
Base64Encode(normalData, width * height * normalChannelCount,
@@ -391,7 +393,8 @@ TEST_F(HeightmapTest, GZ_UTILS_TEST_DISABLED_ON_WIN32(Heightmap))
391393
{
392394
// Output value
393395
base64Encoded.clear();
394-
const uint32_t header[3] = { width, height, PF_FLOAT32_RGBA };
396+
const uint32_t header[3] = { width, height,
397+
static_cast<uint32_t>(PF_FLOAT32_RGBA) };
395398

396399
std::cout << "Depth Camera Output:" << std::endl;
397400
Base64Encode(header, sizeof(header), base64Encoded);

0 commit comments

Comments
 (0)