Re: [cc65] Optimized tgi line functions for horizontal and vertical lines

From: Greg King <>
Date: 2011-11-08 01:14:08
From: "Ullrich von Bassewitz"; on Mon, Nov 07, 2011 04:14 PM -0500
> On Mon, Nov 07, 2011 at 03:34:35PM +0100, "Andreas Rückert" wrote:
> > Problem is, that the tgi_setcolor() calls are not inverted.
> > tgi_setcolor(COLOR_WHITE) draws black now and vice versa.
> Yes, we had a lengthy discussion about that, some time ago. The mixture of
> palettes and colors is not really well-thought. Color constants are -- despite
> their names -- actually indices into the palette. At least for some of the
> drivers that support a palette. A proposed solution does exist already (which
> will require a change to the TGI API); but, is not implemented.

Until then, you can do what CC65's TGI demo source code does.
It defines more useful names:


Then, "tgi_setcolor(COLOR_FORE);" makes more sense in your code.

To unsubscribe from the list send mail to with
the string "unsubscribe cc65" in the body(!) of the mail.
Received on Tue Nov 8 02:14:56 2011

This archive was generated by hypermail 2.1.8 : 2011-11-08 02:14:58 CET