[Ohrrpgce] color problem fixed
Mike Caron
caron.mike at gmail.com
Sat Jun 4 08:33:51 PDT 2005
On 6/4/05, Draknight2 at wmconnect.com <Draknight2 at wmconnect.com> wrote:
> Well I fixed the problem in the ohrgfx, turns out that the user's xp machine
> didn't return the correct ascii character using the chr() statement, which I
> used to save the pixel data of the 4-bit bmp. But now I used arrays instead
> of strings, and it works. it was a very peculiar bug indeed.
Odd. They probably need to have the latest VB Runtimes.
> one more thing, would this formula work for color comparison?
> color=sqr((r^2)+(g^2)+(b^2)) I accidentally stambled on this while
> searching the internet for the dos to window color table.
I don't think so.
color=sqr((63^2)+(63^2)+(63^2))
= sqr(3969 + 3969 + 3969)
= sqr(11907)
~ 109
Use the formula I sent you before:
color = RGB(r * 4 + Int(r / 16), g * 4 + Int(g / 16), b * 4 + Int(b / 16))
> _______________________________________________
> Ohrrpgce-motherhamster.org mailing list
> ohrrpgce at lists.motherhamster.org
> http://lists.motherhamster.org/listinfo.cgi/ohrrpgce-motherhamster.org
>
>
>
--
Mike Caron
Final Fantasy Q
http://finalfantasyq.com
More information about the Ohrrpgce
mailing list