Renderer/Framebuffer: Add GetType (and rework backend internals)
This commit is contained in:
@@ -144,7 +144,7 @@ namespace Nz
|
||||
|
||||
StackVector<GLenum> invalidateAttachments = NazaraStackVector(GLenum, colorBufferCount + 1);
|
||||
|
||||
if (command.framebuffer->GetType() == OpenGLFramebuffer::Type::FBO)
|
||||
if (command.framebuffer->GetType() == FramebufferType::Texture)
|
||||
{
|
||||
context->glDrawBuffers(GLsizei(colorBufferCount), fboDrawBuffers.data());
|
||||
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
namespace Nz
|
||||
{
|
||||
OpenGLFboFramebuffer::OpenGLFboFramebuffer(OpenGLDevice& device, const std::vector<std::shared_ptr<Texture>>& attachments) :
|
||||
OpenGLFramebuffer(OpenGLFramebuffer::Type::FBO)
|
||||
OpenGLFramebuffer(FramebufferType::Texture)
|
||||
{
|
||||
if (!m_framebuffer.Create(device))
|
||||
throw std::runtime_error("failed to create framebuffer object");
|
||||
|
||||
Reference in New Issue
Block a user