added rest of the openGL implementation theoreticaly the engine can render now
This commit is contained in:
29
TSE_GlfwOpenGlImpl/src/RenderTexture.hpp
Normal file
29
TSE_GlfwOpenGlImpl/src/RenderTexture.hpp
Normal file
@@ -0,0 +1,29 @@
|
||||
#pragma once
|
||||
|
||||
#include "buffer/FrameBuffer.hpp"
|
||||
#include "interfaces/IRenderTarget.hpp"
|
||||
#include "interfaces/ITexture.hpp"
|
||||
#include "interfaces/IResizeNotifiable.hpp"
|
||||
|
||||
namespace TSE::GLFW
|
||||
{
|
||||
class RenderTexture : public IRenderTarget, public ITexture, public IResizeNotifiable
|
||||
{
|
||||
public:
|
||||
FrameBuffer buffer;
|
||||
|
||||
RenderTexture(Vector2 v);
|
||||
|
||||
Vector2 size() const override;
|
||||
void SetSize(Vector2 v);
|
||||
float width() const override;
|
||||
float height() const override;
|
||||
uint GetTextureId() const override;
|
||||
|
||||
void Update() override;
|
||||
void Bind() override;
|
||||
void Unbind() override;
|
||||
|
||||
void OnResize(float width, float height, IResizable* wnd) override;
|
||||
};
|
||||
} // namespace TSE::GLFW
|
||||
Reference in New Issue
Block a user