Select Git revision
Renderer.hpp
-
BATON Theau authoredBATON Theau authored
Code owners
Assign users and groups as approvers for specific file changes. Learn more.
Renderer.hpp 932 B
#pragma once
#include <optional>
#include <engine/graphics/utility/reference_sorter.hpp>
#include <engine/graphics/back/buffers/FrameBuffer.hpp>
#include <engine/graphics/back/cameras/View.hpp>
#include <engine/graphics/front/module/ImageModule.hpp>
namespace megu {
class Renderer {
public:
Renderer() = delete;
Renderer(float, float);
~Renderer() = default;
void render(const Window & w, Renderable & r, const TextureArray & a) {
this->clear();
r.accept(w, this->_view, this->_module, a);
}
const glm::vec2 dimension() const {return this->_view.dimension();}
void clear() const;
void setClearColor(float, float, float, float = 1.f) const;
View & view() {return this->_view;}
private:
View _view;
Image_Module _module;
};
}