From d193abb0ad0827d5ecc0915d65b67faf68a87097 Mon Sep 17 00:00:00 2001 From: Miodrag Milanovic Date: Sat, 3 Sep 2016 13:30:42 +0200 Subject: Update BGFX and BX packages and update MAME code to support new API (nw) Generated missing shaders (nw) --- 3rdparty/bgfx/examples/common/bgfx_utils.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to '3rdparty/bgfx/examples/common/bgfx_utils.cpp') diff --git a/3rdparty/bgfx/examples/common/bgfx_utils.cpp b/3rdparty/bgfx/examples/common/bgfx_utils.cpp index 18db066f468..6f2d29f0fef 100644 --- a/3rdparty/bgfx/examples/common/bgfx_utils.cpp +++ b/3rdparty/bgfx/examples/common/bgfx_utils.cpp @@ -240,6 +240,8 @@ bgfx::TextureHandle loadTexture(bx::FileReaderI* _reader, const char* _filePath, break; case LCT_PALETTE: + format = bgfx::TextureFormat::R8; + bpp = 8; break; } break; @@ -304,7 +306,7 @@ bgfx::TextureHandle loadTexture(bx::FileReaderI* _reader, const char* _filePath, if (NULL != out) { - handle = bgfx::createTexture2D(uint16_t(width), uint16_t(height), 1 + handle = bgfx::createTexture2D(uint16_t(width), uint16_t(height), false, 1 , format , _flags , bgfx::copy(out, width*height*bpp/8) @@ -318,6 +320,7 @@ bgfx::TextureHandle loadTexture(bx::FileReaderI* _reader, const char* _filePath, , uint16_t(height) , 0 , false + , false , 1 , format ); -- cgit v1.2.3-70-g09d2