daily update on 20240315 by nitload youmu

This commit is contained in:
YoumuLiu
2024-03-16 03:09:00 +08:00
parent a770bbe685
commit 15bf989285
84 changed files with 1064 additions and 1981 deletions
-25
View File
@@ -15,31 +15,6 @@ SSCAPI void SSCDECL initGL(int majorVersion, int minorVersion)
glfwWindowHint(GLFW_OPENGL_PROFILE, GLFW_OPENGL_CORE_PROFILE);
}
SSCAPI unsigned int SSCDECL loadShaderCode(GladGLContext* context, char* const shaderCode, GLint shadertype)
{
unsigned int shader = context->CreateShader(GL_VERTEX_SHADER);
if (!shader)
{
return 0xffffffff;
}
printf("%s\n", shaderCode);
context->ShaderSource(shader, 1, shaderCode, NULL);
printf("%s\n", shaderCode);
context->CompileShader(shader);
int success;
context->GetShaderiv(shader, GL_COMPILE_STATUS, &success);
if (!success)
{
context->GetShaderInfoLog(shader, 512, NULL, infolog);
infolog[511] = '\0';
return 0;
}
else
{
return shader;
}
}
SSCAPI GLFWglproc SSCDECL loadGlfuncDefault(char* procName)
{
void* ret = glfwGetProcAddress(procName);