From 4cccc0183cef3dc959500d708256d18a98a62c46 Mon Sep 17 00:00:00 2001 From: MooglyGuy Date: Sun, 24 Nov 2019 15:40:14 +0100 Subject: -bgfx: Fixed Github issues #5830 and #5956. [Ryan Holtz] --- src/osd/modules/render/bgfx/inputpair.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/osd/modules/render/bgfx/inputpair.cpp') diff --git a/src/osd/modules/render/bgfx/inputpair.cpp b/src/osd/modules/render/bgfx/inputpair.cpp index f6e695a9992..9fd2b0e6855 100644 --- a/src/osd/modules/render/bgfx/inputpair.cpp +++ b/src/osd/modules/render/bgfx/inputpair.cpp @@ -46,7 +46,9 @@ bgfx_input_pair::~bgfx_input_pair() void bgfx_input_pair::bind(bgfx_effect *effect, const int32_t screen) const { - assert(effect->uniform(m_sampler) != nullptr); + if (effect->uniform(m_sampler) == nullptr) + return; + std::string name = m_texture + std::to_string(screen); bgfx_texture_handle_provider* provider = chains().textures().provider(name); -- cgit v1.2.3-70-g09d2