(3D) What Are Normalos and how are they used?

Just starting out? Need help? Post your questions and find answers here.
Vallan
User
User
Posts: 24
Joined: Thu Mar 09, 2006 1:25 pm

(3D) What Are Normalos and how are they used?

Post by Vallan »

I'd try a little bit with Ogre and now I want to use Light and Shadow.
I did try it with a sample cube and found out that I have to set the "Normalos". Now is my question:

How can I use normalos,
and how do I calculate them,
and before everything What are normalos?
Google 4ever!
traumatic
PureBasic Expert
PureBasic Expert
Posts: 1661
Joined: Sun Apr 27, 2003 4:41 pm
Location: Germany
Contact:

Re: (3D) What Are Normalos and how are they used?

Post by traumatic »

Good programmers don't comment their code. It was hard to write, should be hard to read.
Vallan
User
User
Posts: 24
Joined: Thu Mar 09, 2006 1:25 pm

Post by Vallan »

Thanks, I hope it helps.
Google 4ever!
Vallan
User
User
Posts: 24
Joined: Thu Mar 09, 2006 1:25 pm

Post by Vallan »

:D This did explain almost all. But how do I calculate the cross product in PB?
Google 4ever!
User avatar
Comtois
Addict
Addict
Posts: 1432
Joined: Tue Aug 19, 2003 11:36 am
Location: Doubs - France

Post by Comtois »

Please correct my english
http://purebasic.developpez.com/
traumatic
PureBasic Expert
PureBasic Expert
Posts: 1661
Joined: Sun Apr 27, 2003 4:41 pm
Location: Germany
Contact:

Post by traumatic »

Vallan wrote::D This did explain almost all. But how do I calculate the cross product in PB?
Just like the article says ;)

For example:

Code: Select all

Structure VECTOR3
  x.f
  y.f
  z.f
EndStructure 

Procedure VectorCross(*out.VECTOR3, *v1.VECTOR3, *v2.VECTOR3)
  *out\x = (*v1\y * *v2\z) - (*v1\z * *v2\y)
  *out\y = (*v1\z * *v2\x) - (*v1\x * *v2\z)
  *out\z = (*v1\x * *v2\y) - (*v1\y * *v2\x)
  ProcedureReturn *out
EndProcedure 
Good programmers don't comment their code. It was hard to write, should be hard to read.
Post Reply