[Feat] (GL_Drawing): Add DrawElementsSHITTILY. Add SPIRV->GLSL ES conversion.

This commit is contained in:
BZLZHH
2025-05-05 10:04:35 +08:00
parent 31d2d62a59
commit 3fa6aa660c
14 changed files with 903 additions and 38 deletions
+1
View File
@@ -107,6 +107,7 @@ GLenum CommonState::Clear(GLbitfield mask) {
if ((mask & ~validBits) != 0) {
return GL_INVALID_VALUE;
}
clearMask = mask;
return GL_NO_ERROR;
}
+11 -10
View File
@@ -9,7 +9,13 @@
#include "../../../Includes.h"
class CommonState {
private:
public:
// Viewport
GLint viewport[4] = {0, 0, 0, 0};
// Color mask
GLboolean colorMask[4] = {GL_TRUE, GL_TRUE, GL_TRUE, GL_TRUE};
// Pixel storage parameters
std::unordered_map<GLenum, GLint> pixelStoreParams;
@@ -22,21 +28,15 @@ private:
// Clear state
GLfloat clearColor[4] = {0.0f, 0.0f, 0.0f, 0.0f};
GLfloat clearDepth = 1.0f;
// Color mask
GLboolean colorMask[4] = {GL_TRUE, GL_TRUE, GL_TRUE, GL_TRUE};
GLenum clearMask;
// Depth state
GLenum depthFunc = GL_LESS;
GLboolean depthMask = GL_TRUE;
// Viewport
GLint viewport[4] = {0, 0, 0, 0};
// Capability enables
std::unordered_map<GLenum, bool> capabilities;
public:
CommonState();
// Return: the validity of the operation, according to OpenGL 3 standard
@@ -57,6 +57,7 @@ public:
GLenum Viewport(GLint x, GLint y, GLsizei width, GLsizei height);
GLint QueryPixelStoreInt(GLenum pname);
};
#endif //MOBILEGL_COMMONSTATE_H