- made some small performance updates for rendering and updated beta version number

This commit is contained in:
Mark Vejvoda
2010-06-25 05:41:50 +00:00
parent 848d953bd7
commit 646e8593f4
7 changed files with 13 additions and 11 deletions

View File

@@ -32,14 +32,14 @@ void TextRenderer2DGl::begin(const Font2D *font){
this->font= static_cast<const Font2DGl*>(font);
}
void TextRenderer2DGl::render(const string &text, int x, int y, bool centered, Vec3f color) {
void TextRenderer2DGl::render(const string &text, int x, int y, bool centered, Vec3f *color) {
assert(rendering);
assertGl();
if(color.x >= 0) {
if(color != NULL) {
glPushAttrib(GL_CURRENT_BIT);
glColor3fv(color.ptr());
glColor3fv(color->ptr());
}
int line=0;
@@ -73,7 +73,7 @@ void TextRenderer2DGl::render(const string &text, int x, int y, bool centered, V
}
}
if(color.x >= 0) {
if(color != NULL) {
glPopAttrib();
}
assertGl();