summaryrefslogtreecommitdiff
path: root/Userland
diff options
context:
space:
mode:
authorJelle Raaijmakers <jelle@gmta.nl>2022-01-13 02:55:54 +0100
committerAndreas Kling <kling@serenityos.org>2022-01-13 12:13:58 +0100
commitdb1509c0decd93f8d3c79070c681b56207a94f3f (patch)
treecf134ee689ba81162ec95a2a9175749ad9f82525 /Userland
parent1fc611877f0bf2ce2b78593b4960c00164b12de2 (diff)
downloadserenity-db1509c0decd93f8d3c79070c681b56207a94f3f.zip
LibGL: Use C++ casts in `glColor`
Diffstat (limited to 'Userland')
-rw-r--r--Userland/Libraries/LibGL/SoftwareGLContext.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/Userland/Libraries/LibGL/SoftwareGLContext.cpp b/Userland/Libraries/LibGL/SoftwareGLContext.cpp
index 34ab226d7d..b2bac5cbd2 100644
--- a/Userland/Libraries/LibGL/SoftwareGLContext.cpp
+++ b/Userland/Libraries/LibGL/SoftwareGLContext.cpp
@@ -270,7 +270,12 @@ void SoftwareGLContext::gl_color(GLdouble r, GLdouble g, GLdouble b, GLdouble a)
{
APPEND_TO_CALL_LIST_AND_RETURN_IF_NEEDED(gl_color, r, g, b, a);
- m_current_vertex_color = { (float)r, (float)g, (float)b, (float)a };
+ m_current_vertex_color = {
+ static_cast<float>(r),
+ static_cast<float>(g),
+ static_cast<float>(b),
+ static_cast<float>(a),
+ };
}
void SoftwareGLContext::gl_end()