Add clang-format (#1086)

Co-authored-by: mwilsnd <mwilsnd@gmail.com>
This commit is contained in:
Bart Louwers
2023-05-01 16:57:37 +02:00
committed by GitHub
parent 403a12bd1b
commit 71f6da2722
1018 changed files with 27876 additions and 25862 deletions

View File

@@ -9,14 +9,12 @@ namespace mbgl {
namespace gl {
RendererBackend::RendererBackend(const gfx::ContextMode contextMode_)
: gfx::RendererBackend(contextMode_) {
}
: gfx::RendererBackend(contextMode_) {}
std::unique_ptr<gfx::Context> RendererBackend::createContext() {
auto result = std::make_unique<gl::Context>(*this);
result->enableDebugging();
result->initializeExtensions(
std::bind(&RendererBackend::getExtensionFunctionPointer, this, std::placeholders::_1));
result->initializeExtensions(std::bind(&RendererBackend::getExtensionFunctionPointer, this, std::placeholders::_1));
return result;
}
@@ -32,7 +30,7 @@ void RendererBackend::assumeFramebufferBinding(const gl::FramebufferID fbo) {
}
void RendererBackend::assumeViewport(int32_t x, int32_t y, const Size& size) {
getContext<gl::Context>().viewport.setCurrentValue({ x, y, size });
getContext<gl::Context>().viewport.setCurrentValue({x, y, size});
assert(gl::value::Viewport::Get() == getContext<gl::Context>().viewport.getCurrentValue());
}
@@ -53,7 +51,7 @@ void RendererBackend::setFramebufferBinding(const gl::FramebufferID fbo) {
}
void RendererBackend::setViewport(int32_t x, int32_t y, const Size& size) {
getContext<gl::Context>().viewport = { x, y, size };
getContext<gl::Context>().viewport = {x, y, size};
assert(gl::value::Viewport::Get() == getContext<gl::Context>().viewport.getCurrentValue());
}