summaryrefslogtreecommitdiffstats
path: root/progs/trivial/line.c
diff options
context:
space:
mode:
authorKeith Whitwell <[email protected]>2007-11-25 15:06:54 +0000
committerJosé Fonseca <[email protected]>2007-12-09 14:06:00 +0000
commitb1399a5dd20fad801ee10383143439f8cf4615db (patch)
tree7a8bc67ae96af42f5831e51ed5c29d7402fc2482 /progs/trivial/line.c
parentb47836225185c8d2e2ccf3e191230304709d0a57 (diff)
gallium: more trivial tests
Diffstat (limited to 'progs/trivial/line.c')
-rw-r--r--progs/trivial/line.c13
1 files changed, 9 insertions, 4 deletions
diff --git a/progs/trivial/line.c b/progs/trivial/line.c
index b435a2689a0..de5f9274e41 100644
--- a/progs/trivial/line.c
+++ b/progs/trivial/line.c
@@ -40,7 +40,7 @@ static void Init(void)
fprintf(stderr, "GL_VERSION = %s\n", (char *) glGetString(GL_VERSION));
fprintf(stderr, "GL_VENDOR = %s\n", (char *) glGetString(GL_VENDOR));
- glClearColor(0.3, 0.3, 0.3, 0.0);
+ glClearColor(0.0, 0.0, 1.0, 0.0);
}
static void Reshape(int width, int height)
@@ -71,15 +71,20 @@ static void Draw(void)
{
glClear(GL_COLOR_BUFFER_BIT);
- glBegin(GL_LINE_STRIP);
+ glBegin(GL_LINES);
glColor3f(0,0,.7);
glVertex3f( 0.9, -0.9, -30.0);
glColor3f(.8,0,0);
glVertex3f( 0.9, 0.9, -30.0);
+
+ glColor3f(.8,0,0);
+ glVertex3f( 0.9, 0.9, -30.0);
+ glColor3f(0,.9,0);
+ glVertex3f(-0.9, 0.0, -30.0);
+
+
glColor3f(0,.9,0);
glVertex3f(-0.9, 0.0, -30.0);
- /* Repeat the first vertex - don't have lineloop support in GS yet
- */
glColor3f(0,0,.7);
glVertex3f( 0.9, -0.9, -30.0);
glEnd();