1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 23:07:35 +00:00

LibGL: Implement glColor4b

This commit is contained in:
Jelle Raaijmakers 2022-01-17 18:10:50 +01:00 committed by Andreas Kling
parent 29dc17b7b9
commit 991cbc56a2
2 changed files with 8 additions and 2 deletions

View file

@ -37,7 +37,12 @@ void glColor3ub(GLubyte r, GLubyte g, GLubyte b)
void glColor3ubv(GLubyte const* v)
{
g_gl_context->gl_color(v[0] / 255.0f, v[1] / 255.0f, v[2] / 255.0f, 1.0);
g_gl_context->gl_color(v[0] / 255.0, v[1] / 255.0, v[2] / 255.0, 1.0);
}
void glColor4b(GLbyte r, GLbyte g, GLbyte b, GLbyte a)
{
g_gl_context->gl_color(r / 255.0, g / 255.0, b / 255.0, a / 255.0);
}
void glColor4dv(GLdouble const* v)
@ -62,5 +67,5 @@ void glColor4ub(GLubyte r, GLubyte g, GLubyte b, GLubyte a)
void glColor4ubv(const GLubyte* v)
{
g_gl_context->gl_color(v[0] / 255.0f, v[1] / 255.0f, v[2] / 255.0f, v[3] / 255.0f);
g_gl_context->gl_color(v[0] / 255.0, v[1] / 255.0, v[2] / 255.0, v[3] / 255.0);
}