problems with colors

new topic     » topic index » view thread      » older message » newer message

------=_NextPart_000_001E_01BF879C.498A1FA0
        charset="iso-8859-2"
Content-Transfer-Encoding: quoted-printable

problem no 1:
can anyone tell me how can i display many different colors at hte same =
time on the screen in euphoria dos program?

i want to draw many lines with slightly different colors
rgb=3D0,0,0 rgb=3D1,0,0 ....


i used palette() function

when using draw_line(colornum,....) function in loop statement and=20
value of 'colornum' is being changed evry time, also all the lines which =
were drawn with colornum become colored with value that colornum =
currently has
this sux!

here's code:

atom mycolor
atom r,g,b,x,y,cn
r=3D1
g=3D1
b=3D1
x=3D0
y=3D0
cn=3D0

bk_color(BLUE)


while 1 do
--Here the main thing

       mycolor =3D palette(cn, {r,g,b})
      draw_line(cn, {{x, y}, {x, y+200}})

      cn=3Dcn+1

            x=3Dx+1
           r=3Dr+1

           if(x>500)then
                       exit
                     end if

 if get_key() !=3D -1 then
     exit
 end if
     end while

     while 1 do

      if get_key() !=3D -1 then
     exit
 end if
     end while

end procedure

Problem no2:
in win32lib program
i use mcolor=3Drgb(r,g,b) function, and r goes from 0-255 as in C
, these colors should all be slightly different, not two same, but there =
ar ten, or more, same, and then again different
whats wrong

PROBLEM no 3:
Win32Lib
when calling xPostQuitMessage C fucntion it says theres an error
when calling other C functions theres no error


If anyone is working on artificial intelligence program, send code to me

------=_NextPart_000_001E_01BF879C.498A1FA0
        charset="iso-8859-2"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META content=3D"text/html; charset=3Diso-8859-2" =
http-equiv=3DContent-Type>
<META content=3D"MSHTML 5.00.2614.3401" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>problem no 1:</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>can anyone tell me how&nbsp;can i =
display many=20
different colors at hte same time on the screen</FONT><FONT face=3DArial =
size=3D2>=20
in euphoria dos program?</FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>i want to draw many lines with slightly =
different=20
colors</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>rgb=3D0,0,0 <FONT face=3DArial =
size=3D2>rgb=3D1,0,0=20
....</FONT></FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>i used palette() function</FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>when using draw_line(colornum,....) =
function in=20
loop statement and </FONT></DIV>
<DIV><FONT face=3DArial size=3D2>value of 'colornum' is being changed =
evry time,=20
also all the lines which were drawn with colornum become colored with =
value that=20
colornum currently has</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>this sux!</FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>here's code:</FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>atom mycolor<BR>atom=20
></DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>bk_color(BLUE)</FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2><BR>while 1 do<BR>--Here the main=20
thing</FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =
mycolor =3D=20
palette(cn, {r,g,b})<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; draw_line(cn, =
{{x, y},=20
{x, y+200}})</FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =
cn=3Dcn+1</FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=3DArial=20
p;=20
r=3Dr+1</FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=3DArial=20
&nbsp;=20
end if</FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>&nbsp;if get_key() !=3D -1=20
then<BR>&nbsp;&nbsp;&nbsp;&nbsp; exit<BR>&nbsp;end=20
if<BR>&nbsp;&nbsp;&nbsp;&nbsp; end while</FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>&nbsp;&nbsp;&nbsp;&nbsp; while 1 =
do</FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;if =
get_key() !=3D -1=20
then<BR>&nbsp;&nbsp;&nbsp;&nbsp; exit<BR>&nbsp;end=20
if<BR>&nbsp;&nbsp;&nbsp;&nbsp; end while</FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>end procedure</FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Problem no2:</FONT></DIV>
<DIV><FONT face=3DArial size=3D2><FONT face=3DArial size=3D2>in win32lib =

program</FONT></FONT></DIV>
<DIV><FONT face=3DArial size=3D2>i use mcolor=3Drgb(r,g,b) function, and =
r goes from=20
0-255 as in C</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>, these colors should all be slightly =
different,=20
not two same, but there ar ten, or more, same, and then again=20
different</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>whats wrong</FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>PROBLEM no 3:</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>Win32Lib</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>when calling xPostQuitMessage C =
fucntion it says=20
theres an error</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>when calling other C functions theres =
no=20
error</FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2><FONT face=3DArial size=3D2>If anyone =
is working on=20
artificial intelligence program, send code to=20

------=_NextPart_000_001E_01BF879C.498A1FA0--

new topic     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu