Drawing a Spherical Mesh
01-23-2014, 10:11 PM
Post: #7
 patrice Member Posts: 184 Joined: Dec 2013
RE: Drawing a Spherical Mesh
Code:
    LINE(aa(1),aa(2),bb(1),bb(2),rgb(128+aa(1)*128,128+aa(2)*128,128+aa(3)*128)​);     LINE(bb(1),bb(2),cc(1),cc(2),rgb(128+bb(1)*128,128+bb(2)*128,128+bb(3)*128)​);     LINE(cc(1),cc(2),aa(1),aa(2),rgb(128+cc(1)*128,128+cc(2)*128,128+cc(3)*128)​);
Note that the LINE command compute a color depending on coordinates.
I did it because the TRIANCLE make a flat convex thing on screen.
MY changed TRIANGLE
Code:
triangle ({aa(1),aa(2),rgb(128+aa(1)*128,128+aa(2)*128,128+aa(3)*128),aa(3)},{bb(1),​bb(2),rgb(128+bb(1)*128,128+bb(2)*128,128+bb(3)*128),bb(3)},{cc(1),cc(2),rgb(128​+cc(1)*128,128+cc(2)*128,128+cc(3)*128),cc(3)});

Patrice
“Everything should be made as simple as possible, but no simpler.” Albert Einstein
 « Next Oldest | Next Newest »

 Messages In This Thread Drawing a Spherical Mesh - jgreenb2 - 01-20-2014, 08:07 PM RE: Drawing a Spherical Mesh - Han - 01-20-2014, 09:47 PM RE: Drawing a Spherical Mesh - jgreenb2 - 01-20-2014, 09:58 PM RE: Drawing a Spherical Mesh - cyrille de brébisson - 01-20-2014, 10:27 PM RE: Drawing a Spherical Mesh - jgreenb2 - 01-21-2014, 12:15 AM RE: Drawing a Spherical Mesh - patrice - 01-21-2014, 01:08 AM RE: Drawing a Spherical Mesh - patrice - 01-23-2014 10:11 PM

User(s) browsing this thread: 1 Guest(s)