From fa7cc825ea7aee9328ecd03b67617847fd128f85 Mon Sep 17 00:00:00 2001 From: Mikko Rasa Date: Sat, 8 Jan 2011 14:26:05 +0000 Subject: [PATCH] Fix overlay text colors --- source/3d/overlay.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/source/3d/overlay.cpp b/source/3d/overlay.cpp index ee9fea7..87c49ba 100644 --- a/source/3d/overlay.cpp +++ b/source/3d/overlay.cpp @@ -8,6 +8,7 @@ Distributed under the GPL #include #include #include +#include #include #include #include @@ -122,7 +123,9 @@ void Overlay3D::render(const GL::Tag &tag) const } GL::translate(0, baseline, 0); - font.draw_string(icon.label); + GL::Immediate imm((GL::TEXCOORD2, GL::COLOR4_UBYTE, GL::VERTEX2)); + imm.color(0.0f, 1.0f, 0.0f); + font.draw_string(icon.label, imm); GL::Texture::unbind(); } @@ -130,6 +133,8 @@ void Overlay3D::render(const GL::Tag &tag) const GL::pop_matrix(); GL::matrix_mode(GL::MODELVIEW); GL::pop_matrix(); + + glColor3f(1.0, 1.0, 1.0); } } -- 2.43.0