PDA

View Full Version : Drawing a cylinder in opengl



02-20-2000, 04:58 AM
How can i draw a simple cylinder using opengl, with the 3D corodinates of the two ends given?

tcs
02-20-2000, 07:45 AM
that's pretty easy math. You could do it yourself, with little knowledge about trigonometry, or you could use gluCylinder(), which is pretty easy. Even with that you still have to do some math, cause you can't just pass a start and a end coordinate....

02-20-2000, 04:15 PM
is there a way i can make the ends of two cylinders join together?



Originally posted by tcs:
that's pretty easy math. You could do it yourself, with little knowledge about trigonometry, or you could use gluCylinder(), which is pretty easy. Even with that you still have to do some math, cause you can't just pass a start and a end coordinate....

Eric
02-21-2000, 12:31 AM
I am sorry but it seems to me that, if you join two ends of a cylinder, it is not a cylinder !

Are you looking for some kind of torus ?

Eric