2 /* Copyright (c) Mark J. Kilgard, 1994. */
4 /* This program is freely distributable without licensing fees
5 and is provided without guarantee or warrantee expressed or
6 implied. This program is -not- in the public domain. */
10 #else /* for xscreensaver */
13 # define APIENTRY /**/
16 #include "glutstroke.h"
19 glutStrokeCharacter(GLUTstrokeFont font, int c)
21 const StrokeCharRec *ch;
22 const StrokeRec *stroke;
23 const CoordRec *coord;
24 StrokeFontPtr fontinfo;
29 fontinfo = (StrokeFontPtr) __glutFont(font);
31 fontinfo = (StrokeFontPtr) font;
34 if (c < 0 || c >= fontinfo->num_chars)
36 ch = &(fontinfo->ch[c]);
38 for (i = ch->num_strokes, stroke = ch->stroke;
39 i > 0; i--, stroke++) {
40 glBegin(GL_LINE_STRIP);
41 for (j = stroke->num_coords, coord = stroke->coord;
42 j > 0; j--, coord++) {
43 glVertex2f(coord->x, coord->y);
47 glTranslatef(ch->right, 0.0, 0.0);