Update assert API to latest bx.

This commit is contained in:
Branimir Karadžić
2025-08-23 09:21:18 -07:00
parent fab28297e0
commit f268ce5c96
2 changed files with 8 additions and 8 deletions

View File

@@ -92,13 +92,13 @@ namespace bgfx
} \
BX_MACRO_BLOCK_END
#define _BGFX_ASSERT(_condition, _format, ...) \
BX_MACRO_BLOCK_BEGIN \
if (!BX_IGNORE_C4127(_condition) \
&& bx::assertFunction(bx::Location::current(), "ASSERT " #_condition " -> " _format, ##__VA_ARGS__) ) \
{ \
bgfx::fatal(__FILE__, uint16_t(__LINE__), bgfx::Fatal::DebugCheck, _format, ##__VA_ARGS__); \
} \
#define _BGFX_ASSERT(_condition, _format, ...) \
BX_MACRO_BLOCK_BEGIN \
if (!BX_IGNORE_C4127(_condition) \
&& bx::assertFunction(bx::Location::current(), 0, "ASSERT " #_condition " -> " _format, ##__VA_ARGS__) ) \
{ \
bgfx::fatal(__FILE__, uint16_t(__LINE__), bgfx::Fatal::DebugCheck, _format, ##__VA_ARGS__); \
} \
BX_MACRO_BLOCK_END
#define BGFX_FATAL(_condition, _err, _format, ...) \

View File

@@ -5313,7 +5313,7 @@ namespace bgfx { namespace gl
}
UniformType::Enum type = convertGlType(gltype);
m_constantBuffer->writeUniformHandle(type, 0, info->m_handle, uint16_t(num) );
m_constantBuffer->writeUniformHandle(bx::narrowCast<uint8_t>(type), 0, info->m_handle, uint16_t(num) );
m_constantBuffer->write(loc);
BX_TRACE("store %s %d", name, info->m_handle);
}