axmol/cocos/renderer/backend/opengl/RenderTargetGL.h

30 lines
685 B
C
Raw Normal View History

#pragma once
#include "../RenderTarget.h"
#include "platform/CCGL.h"
CC_BACKEND_BEGIN
2020-10-27 16:58:37 +08:00
class DeviceGL;
class RenderTargetGL : public RenderTarget
{
public:
/*
2021-12-25 10:04:45 +08:00
* generateFBO, false, use for screen framebuffer
*/
2020-10-27 16:58:37 +08:00
RenderTargetGL(bool defaultRenderTarget, DeviceGL* deviceGL);
~RenderTargetGL();
void bindFrameBuffer() const override;
void unbindFrameBuffer() const override;
void setColorAttachment(ColorAttachment attachment) override;
void setDepthAttachment(TextureBackend* attachment, int level = 0) override;
void setStencilAttachment(TextureBackend* attachment, int level = 0) override;
2021-12-25 10:04:45 +08:00
public:
GLuint _FBO = 0;
};
CC_BACKEND_END