[Mesa3d-users] filled circle

Hello,
Can anybody give me an idea as to "how to create a circle &
fill it with 2 colors,the circle should be split into 2 .as the line
translates,the particular color should change(increase/decrease)
accordingly..
kindly give me a clue
regards
lalitha

Thread view

Hello,
Can anybody give me an idea as to "how to create a circle &
fill it with 2 colors,the circle should be split into 2 .as the line
translates,the particular color should change(increase/decrease)
accordingly..
kindly give me a clue
regards
lalitha

On Fri, 20 Sep 2002, Lalithamba Guntupalli wrote:
> Can anybody give me an idea as to "how to create a circle &
> fill it with 2 colors,the circle should be split into 2 .as the line
> translates,the particular color should change(increase/decrease)
> accordingly..
This isn't really a Mesa question - but:
1) Just calculate the geometry you need and draw two sets of
coloured polygons. I'm not going to figure it out for you -
it's just high school stuff.
...or...
2) Draw a simple circle (I'd use a triangle fan with the
first vertex at the center of the circle)...use a two
colour texture to render it in two colours and translate
the texture (either by computing the texture coordinates
appropriately - or by using the OpenGL Texture Matrix).
----
Steve Baker (817)619-2657 (Vox/Vox-Mail)
L3Com/Link Simulation & Training (817)619-2466 (Fax)
Work: sjbaker@... http://www.link.com
Home: sjbaker1@... http://www.sjbaker.org