change attribute which is behind the back
4556 6 1- luoqiulin
- Member
- 303 posts
- Joined: May 2007
- Offline
i need the grid's point feed back different value,when it's front or back from the line by vop!
for example, the line's normal is forward, and if the grid's points is ahead from the line,the grid point's normal is forward too, and if the points is at the back of the line, the point's normal is reversed!
the picture shows my mean, wish you tell me how can i do it in vop!
for example, the line's normal is forward, and if the grid's points is ahead from the line,the grid point's normal is forward too, and if the points is at the back of the line, the point's normal is reversed!
the picture shows my mean, wish you tell me how can i do it in vop!
- circusmonkey
- Member
- 2624 posts
- Joined: Aug. 2006
- Offline
- tamte
- Member
- 8749 posts
- Joined: July 2007
- Offline
lets assume that you are taking that green vector as a direction from nearest point on the line
then you should be able to have access to that point's normal (yellow vector) from any of the green points as well
so just calculate dot product between green and it's corresponding yellow vector and if it is less than 0 just reverse green vector
then you should be able to have access to that point's normal (yellow vector) from any of the green points as well
so just calculate dot product between green and it's corresponding yellow vector and if it is less than 0 just reverse green vector
Tomas Slancik
FX Supervisor
Method Studios, NY
FX Supervisor
Method Studios, NY
- peliosis
- Member
- 175 posts
- Joined: July 2005
- Offline
- luoqiulin
- Member
- 303 posts
- Joined: May 2007
- Offline
- graham
- Member
- 1921 posts
- Joined: Nov. 2006
- Offline
- luoqiulin
- Member
- 303 posts
- Joined: May 2007
- Offline
-
- Quick Links