Text render with GLUT
I am unable to render text in my GLUT based openGL program with out weird arrays of bits. There has got to be an easier way to this. Can anyone help?
What do you mean by weird array of bits? I use text rendering from glut and is easy...
void renderBitmapString(
float x,
float y,
float z,
void *font,
char *string) {
char *c;
glRasterPos3f(x, y,z);
for (c=string; *c != '\0'; c++) {
glutBitmapCharacter(font, *c);
}
}
is pretty easy...
void renderBitmapString(
float x,
float y,
float z,
void *font,
char *string) {
char *c;
glRasterPos3f(x, y,z);
for (c=string; *c != '\0'; c++) {
glutBitmapCharacter(font, *c);
}
}
is pretty easy...
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement