mirror of
https://github.com/minetest/irrlicht.git
synced 2024-12-27 08:27:30 +01:00
Support GLES2
This commit is contained in:
parent
620f4869a1
commit
d6716ec31b
@ -10,6 +10,14 @@
|
|||||||
|
|
||||||
#include "IRenderTarget.h"
|
#include "IRenderTarget.h"
|
||||||
|
|
||||||
|
#ifndef GL_FRAMEBUFFER_INCOMPLETE_FORMATS
|
||||||
|
#define GL_FRAMEBUFFER_INCOMPLETE_FORMATS GL_FRAMEBUFFER_INCOMPLETE_FORMATS_EXT
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS
|
||||||
|
#define GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS_EXT
|
||||||
|
#endif
|
||||||
|
|
||||||
namespace irr
|
namespace irr
|
||||||
{
|
{
|
||||||
namespace video
|
namespace video
|
||||||
@ -351,10 +359,10 @@ protected:
|
|||||||
case GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT:
|
case GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT:
|
||||||
os::Printer::log("FBO has one or several incomplete image attachments", ELL_ERROR);
|
os::Printer::log("FBO has one or several incomplete image attachments", ELL_ERROR);
|
||||||
break;
|
break;
|
||||||
case GL_FRAMEBUFFER_INCOMPLETE_FORMATS_EXT:
|
case GL_FRAMEBUFFER_INCOMPLETE_FORMATS:
|
||||||
os::Printer::log("FBO has one or several image attachments with different internal formats", ELL_ERROR);
|
os::Printer::log("FBO has one or several image attachments with different internal formats", ELL_ERROR);
|
||||||
break;
|
break;
|
||||||
case GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS_EXT:
|
case GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS:
|
||||||
os::Printer::log("FBO has one or several image attachments with different dimensions", ELL_ERROR);
|
os::Printer::log("FBO has one or several image attachments with different dimensions", ELL_ERROR);
|
||||||
break;
|
break;
|
||||||
case GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT:
|
case GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT:
|
||||||
|
@ -433,9 +433,6 @@ public:
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
#ifdef IRR_OPENGL_HAS_glGenerateMipmap
|
#ifdef IRR_OPENGL_HAS_glGenerateMipmap
|
||||||
#if !defined(IRR_COMPILE_GLES2_COMMON)
|
|
||||||
glEnable(GL_TEXTURE_2D); // Hack some ATI cards need this glEnable according to https://www.khronos.org/opengl/wiki/Common_Mistakes
|
|
||||||
#endif
|
|
||||||
Driver->irrGlGenerateMipmap(TextureType);
|
Driver->irrGlGenerateMipmap(TextureType);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user