PDA

View Full Version : silly glutsphere question



gunslinger
01-14-2004, 04:57 AM
hi all,
i have a silly glutsphere qustion (as u may have guessed from the topic http://www.opengl.org/discussion_boards/ubb/smile.gif ):
since i am playng with vertex and fragment program, i need to send to my programs a lot of other infos along with the simple vertex coordinates... so when i use a glutsphere,
how can i pass normals, texCoords, color per vertex, and so on instructions? When i say "GLUT SPHERE!!!!" all those info are packed and sended (like if i were using an InterleavedArray) or i am supposed to supply them by hand????
Thanks, sometimes i really got lost with such things http://www.opengl.org/discussion_boards/ubb/wink.gif

nexusone
01-14-2004, 05:06 AM
glutSphere does not generate texcoordinates, not sure you can get the other information from it ether.

You may want to try glusphere, which you can have it generate texcoordinates, normals, etc.

But the best way to make sure you have all the information you are requestiing, is to create your own sphere routine.
Then you can send all the data you want from it to another appication.

mikael_aronsson
01-14-2004, 05:48 AM
glut does not have a glutSphere function, it does have a glutWireSphere function for example, unless you mean the gluSphere function... anyway, as far as I know glut calls gluSphere to generate the sphere, and gluSphere would be happy to give you texture coordinates if you want it to.

Mikael