Drawable Renderer (#1570), Move generic shader lookup to context virtual

This commit is contained in:
Tim Sylvester
2023-05-01 07:51:07 -07:00
committed by Bart Louwers
parent 7cf910129b
commit c7299eaf20
4 changed files with 14 additions and 12 deletions

View File

@@ -1,4 +1,6 @@
#include <mbgl/gl/context.hpp>
#include <mbgl/gfx/shader_registry.hpp>
#include <mbgl/gl/command_encoder.hpp>
#include <mbgl/gl/defines.hpp>
#include <mbgl/gl/drawable_gl.hpp>
@@ -487,6 +489,10 @@ gfx::DrawableTweakerPtr Context::createDrawableTweaker() {
return std::make_shared<gl::DrawableGLTweaker>();
}
gfx::ShaderProgramBasePtr Context::getGenericShader(gfx::ShaderRegistry& shaders, const std::string& name) {
return shaders.get<gl::ShaderProgramGL>(name);
}
void Context::clear(std::optional<mbgl::Color> color,
std::optional<float> depth,
std::optional<int32_t> stencil) {