PDA

View Full Version : Flip normals?



vofka
05-03-2002, 10:28 PM
Hi everyone.
I want to place a camera inside a big skydome. How can I draw this skydome? I suppose I have to draw it (using simple sphere function) and "flipping" normals.
How can I do this flip?

Thanx.

Azdo
05-03-2002, 10:54 PM
Originally posted by vofka:

How can I do this flip?


It's easy: you just negate all the coordinates of your normal vector.

(a,b,c)=>(-a,-b,-c)


HTH

vofka
05-03-2002, 11:20 PM
But what if I use function such as glutSolidSphere() to draw my skydome?

mproso
05-04-2002, 04:36 AM
Why dont you use gluSphere , gluQuadricNormals and gluQuadricOrientation functions.
With gluQuadricOrientation you can change where your normals are pointing.
Hope this helps.