Add support for getting the max texture size

This commit is contained in:
Luke Benstead 2018-08-07 08:45:24 +01:00
parent 85d4bb5ec3
commit 0b91c20bbd
2 changed files with 4 additions and 0 deletions

View File

@ -9,6 +9,7 @@
#define TRACE_ENABLED 0
#define TRACE() if(TRACE_ENABLED) {fprintf(stderr, "%s\n", __func__);}
#define MAX_TEXTURE_SIZE 1024
typedef struct {
unsigned int cmd[8];

View File

@ -434,6 +434,9 @@ void APIENTRY glGetIntegerv(GLenum pname, GLint *params) {
case GL_BLEND_DST:
*params = BLEND_DFACTOR;
break;
case GL_MAX_TEXTURE_SIZE:
*params = MAX_TEXTURE_SIZE;
break;
default:
_glKosThrowError(GL_INVALID_ENUM, "glGetIntegerv");
_glKosPrintError();