From: Patrick Mochel (mochelp@ironarm.com)
Date: Tue 11 Jul 2000 - 18:50:57 IDT
This is another generic graphics programming question, but hopefully someone will know the answer. How do I iteratate through the colors? It seems like it should be simple, but it's not behaving as expected. I'm writing a little something that draws a color wheel on the screen at 800x600x64K. Just for kicks, suppose that it's just drawing vertical lines, so the code looks like this: ... color = 0; for (xnow = 0; xnow < xmax; xnow++) gl_line(xnow,0,xnow,ymax,color++); ... I come up with about 13 identical sections of color fading. the same happens if I do vga_setcolor(color++); vga_drawline(xnow,0,xnow,ymax); Is there a way that I can do what I am trying simply? Regards, -patrick
This archive was generated by hypermail 2.1.4 : Wed 21 Jan 2004 - 22:10:23 IST