Question about surface shader.

   2798   2   0
User Avatar
Member
160 posts
Joined:
Offline
It is known that the global variable P is in camera space ,
the global variable Eye should be {0,0,0},
So what is the function of the global variable?
User Avatar
Member
12469 posts
Joined: 7月 2005
Offline
There is nothing really guaranteeing that the shaded object will be in camera space. You should not just assume it is, even though it is. Mantra or PrMan might suddenly decide one day that the default space is going to be world space. :twisted:
Jason Iversen, Technology Supervisor & FX Pipeline/R+D Lead @ Weta FX
also, http://www.odforce.net [www.odforce.net]
User Avatar
Member
606 posts
Joined: 5月 2007
Offline
flyingc
It is known that the global variable P is in camera space ,
the global variable Eye should be {0,0,0},
So what is the function of the global variable?

If the incoming ray to a fragment being shaded originates from e.g. a mirror, then Eye will be the reflection location on the mirror..

eetu.
  • Quick Links