home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
gondwana.ecr.mu.oz.au/pub/
/
Graphics.tar
/
Graphics
/
VOGLE.ZIP
/
EXAMPLES
/
MSWIN
/
GETSTR.C
< prev
next >
Wrap
C/C++ Source or Header
|
1994-04-27
|
620b
|
49 lines
#include "vogle.h"
#include <stdio.h>
/*
* Test the getting of strings in graphics mode.
*/
main(argc, argv)
int argc;
char **argv;
{
char *p;
float cw, ch;
int i, n;
char buf[10][128];
vinit("mswin");
if (argc > 1)
font(argv[1]);
clipping(0);
window(-1.0, 1.0, -1.0, 1.0, 1.0, -1.0);
lookat(0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0);
textsize(0.1, 0.25);
rotate(30.0, 'x');
rotate(30.0, 'z');
rotate(60.0, 'y');
color(BLACK);
clear();
color(YELLOW);
rect(-0.5, -0.5, 0.5, 0.5);
move2(-0.5, 0.0);
color(GREEN);
n = 0;
while ((i = getstring(BLACK, buf[n]) && n < 10))
n++;
vexit();
}