From 2f3c37d850d7fa53e64e1883c7db78190a218773 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Branimir=20Karad=C5=BEi=C4=87?= Date: Thu, 27 Mar 2014 22:36:53 -0700 Subject: [PATCH] Cleanup. --- src/bgfx.cpp | 2 +- src/bgfx_p.h | 2 +- src/renderer_d3d11.cpp | 2 +- src/renderer_gl.cpp | 4 +++- src/renderer_null.cpp | 2 +- 5 files changed, 7 insertions(+), 5 deletions(-) diff --git a/src/bgfx.cpp b/src/bgfx.cpp index 37bc46b1..499064a3 100644 --- a/src/bgfx.cpp +++ b/src/bgfx.cpp @@ -1496,7 +1496,7 @@ namespace bgfx case CommandBuffer::DestroyProgram: { - FragmentShaderHandle handle; + ProgramHandle handle; _cmdbuf.read(handle); rendererDestroyProgram(handle); diff --git a/src/bgfx_p.h b/src/bgfx_p.h index 0cb5750a..6527a446 100644 --- a/src/bgfx_p.h +++ b/src/bgfx_p.h @@ -2637,7 +2637,7 @@ namespace bgfx void rendererCreateFragmentShader(FragmentShaderHandle _handle, Memory* _mem); void rendererDestroyFragmentShader(FragmentShaderHandle _handle); void rendererCreateProgram(ProgramHandle _handle, VertexShaderHandle _vsh, FragmentShaderHandle _fsh); - void rendererDestroyProgram(FragmentShaderHandle _handle); + void rendererDestroyProgram(ProgramHandle _handle); void rendererCreateTexture(TextureHandle _handle, Memory* _mem, uint32_t _flags, uint8_t _skip); void rendererUpdateTextureBegin(TextureHandle _handle, uint8_t _side, uint8_t _mip); void rendererUpdateTexture(TextureHandle _handle, uint8_t _side, uint8_t _mip, const Rect& _rect, uint16_t _z, uint16_t _depth, uint16_t _pitch, const Memory* _mem); diff --git a/src/renderer_d3d11.cpp b/src/renderer_d3d11.cpp index b2e0fd27..b6e65ccc 100644 --- a/src/renderer_d3d11.cpp +++ b/src/renderer_d3d11.cpp @@ -2248,7 +2248,7 @@ namespace bgfx s_renderCtx->m_program[_handle.idx].create(s_renderCtx->m_vertexShaders[_vsh.idx], s_renderCtx->m_fragmentShaders[_fsh.idx]); } - void Context::rendererDestroyProgram(FragmentShaderHandle _handle) + void Context::rendererDestroyProgram(ProgramHandle _handle) { s_renderCtx->m_program[_handle.idx].destroy(); } diff --git a/src/renderer_gl.cpp b/src/renderer_gl.cpp index ac077f44..c232fc67 100644 --- a/src/renderer_gl.cpp +++ b/src/renderer_gl.cpp @@ -293,6 +293,7 @@ namespace bgfx MOZ_WEBGL_compressed_texture_s3tc, MOZ_WEBGL_depth_texture, + NV_draw_buffers, NVX_gpu_memory_info, OES_compressed_ETC1_RGB8_texture, @@ -423,6 +424,7 @@ namespace bgfx { "MOZ_WEBGL_compressed_texture_s3tc", false, true }, { "MOZ_WEBGL_depth_texture", false, true }, + { "NV_draw_buffers", false, true }, // GLES2 extension. { "NVX_gpu_memory_info", false, true }, { "OES_compressed_ETC1_RGB8_texture", false, true }, @@ -3225,7 +3227,7 @@ namespace bgfx s_renderCtx->m_program[_handle.idx].create(s_renderCtx->m_vertexShaders[_vsh.idx], isValid(_fsh) ? s_renderCtx->m_fragmentShaders[_fsh.idx] : dummyFragmentShader); } - void Context::rendererDestroyProgram(FragmentShaderHandle _handle) + void Context::rendererDestroyProgram(ProgramHandle _handle) { s_renderCtx->m_program[_handle.idx].destroy(); } diff --git a/src/renderer_null.cpp b/src/renderer_null.cpp index 43e99122..d2b65647 100644 --- a/src/renderer_null.cpp +++ b/src/renderer_null.cpp @@ -101,7 +101,7 @@ namespace bgfx { } - void Context::rendererDestroyProgram(FragmentShaderHandle /*_handle*/) + void Context::rendererDestroyProgram(ProgramHandle /*_handle*/) { }