From 517e5069c957478bdea4e6d8c6a0437dd4302fbc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Branimir=20Karad=C5=BEi=C4=87?= Date: Thu, 5 Nov 2015 22:10:32 -0800 Subject: [PATCH] Warn on matrix cache overflow. --- src/bgfx_p.h | 2 +- src/config.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/bgfx_p.h b/src/bgfx_p.h index 7cade4fc..c35a13cc 100644 --- a/src/bgfx_p.h +++ b/src/bgfx_p.h @@ -826,7 +826,7 @@ namespace bgfx uint32_t reserve(uint16_t* _num) { uint32_t num = *_num; - BX_CHECK(m_num+num < BGFX_CONFIG_MAX_MATRIX_CACHE, "Matrix cache overflow. %d (max: %d)", m_num+num, BGFX_CONFIG_MAX_MATRIX_CACHE); + BX_WARN(m_num+num < BGFX_CONFIG_MAX_MATRIX_CACHE, "Matrix cache overflow. %d (max: %d)", m_num+num, BGFX_CONFIG_MAX_MATRIX_CACHE); num = bx::uint32_min(num, BGFX_CONFIG_MAX_MATRIX_CACHE-m_num); uint32_t first = m_num; m_num += num; diff --git a/src/config.h b/src/config.h index 32b3662b..f136df9e 100644 --- a/src/config.h +++ b/src/config.h @@ -195,7 +195,7 @@ #endif // BGFX_CONFIG_MAX_DRAW_CALLS #ifndef BGFX_CONFIG_MAX_BLIT_ITEMS -# define BGFX_CONFIG_MAX_BLIT_ITEMS 256 +# define BGFX_CONFIG_MAX_BLIT_ITEMS (1<<10) #endif // BGFX_CONFIG_MAX_BLIT_ITEMS #ifndef BGFX_CONFIG_MAX_MATRIX_CACHE