Re: [cc65] TGI palettes (was: TGI colors revisited)

From: Ullrich von Bassewitz <uz1musoftware.de>
Date: 2011-05-24 18:39:44
On Tue, May 24, 2011 at 07:00:34AM -0400, Greg King wrote:
> But, a program still needs to know _when_ it happens!

Why? If this happens, there's not much a program can do anyway. 

Assume a monochrome driver and a program that allocates black for the
background and white as drawing color. If the driver returns dark blue for the
background and yellow as foreground color, there's really nothing the program
can do about it but just use the colors. It might look strange, but the only
other choice would be to terminate the program.

Or assume Olivers example: There's no red on the Apple, so the driver might
return orange instead. What do you think a program could do if it gets an
error code?

And, please note that the problem does only hit portable programs that run on
new/unknown platforms or with new/unknown drivers. A program written with
knowledge of the platform will of course know that it will get orange instead
of red on an apple and act accordingly - if this is really necessary. The
difference to the scenario above is that the program does not just get an
abstract error code ("what I got is not red but some other, unknown, but
hopefully similar color") which cannot be handled in a reasonable way, but
knows "ahh, this is the apple, so I allocated red, but got orange".

Regards


        Uz


-- 
Ullrich von Bassewitz                                  uz@musoftware.de
----------------------------------------------------------------------
To unsubscribe from the list send mail to majordomo@musoftware.de with
the string "unsubscribe cc65" in the body(!) of the mail.
Received on Tue May 24 18:39:52 2011

This archive was generated by hypermail 2.1.8 : 2011-05-24 18:39:55 CEST