blob: 867e60d79e7e60c0212c80aad9ba247168afbb9b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
#pragma once
#include <mbgl/util/size.hpp>
#include <mbgl/gfx/backend.hpp>
namespace mbgl {
namespace gfx {
class RendererBackend;
} // namespace gfx
} // namespace mbgl
struct GLFWwindow;
class GLFWBackend {
public:
explicit GLFWBackend() = default;
GLFWBackend(const GLFWBackend&) = delete;
GLFWBackend& operator=(const GLFWBackend&) = delete;
virtual ~GLFWBackend() = default;
static std::unique_ptr<GLFWBackend> Create(GLFWwindow* window, bool capFrameRate) {
return mbgl::gfx::Backend::Create<GLFWBackend, GLFWwindow*, bool>(window, capFrameRate);
}
virtual mbgl::gfx::RendererBackend& getRendererBackend() = 0;
virtual mbgl::Size getSize() const = 0;
virtual void setSize(mbgl::Size) = 0;
};
|