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 */
14 # define APIENTRY /**/
17 #include "glutstroke.h"
20 glutStrokeCharacter(GLUTstrokeFont font, int c)
22 const StrokeCharRec *ch;
23 const StrokeRec *stroke;
24 const CoordRec *coord;
25 StrokeFontPtr fontinfo;
30 fontinfo = (StrokeFontPtr) __glutFont(font);
32 fontinfo = (StrokeFontPtr) font;
35 if (c < 0 || c >= fontinfo->num_chars)
37 ch = &(fontinfo->ch[c]);
39 for (i = ch->num_strokes, stroke = ch->stroke;
40 i > 0; i--, stroke++) {
41 glBegin(GL_LINE_STRIP);
42 for (j = stroke->num_coords, coord = stroke->coord;
43 j > 0; j--, coord++) {
44 glVertex2f(coord->x, coord->y);
48 glTranslatef(ch->right, 0.0, 0.0);