hello,
I am trying to make a simple bump map with the VEX Builder, but I can't figure out where the “computenormal” VOP is.
I am trying to translate into VEX Builder the following vex code snipet:
P_temp = P + ( N * bump_value * bump_amt ); // move P along its normal by intensity
N = computenormal( P_temp );
thanks for your help
bump with vex builder?
4368 4 2- muigoan
- Member
- 19 posts
- Joined: July 2005
- Offline
- muigoan
- Member
- 19 posts
- Joined: July 2005
- Offline
- muigoan
- Member
- 19 posts
- Joined: July 2005
- Offline
- David Gary
- Member
- 74 posts
- Joined: July 2005
- Offline
To do bump mapping, just use the DisplaceAlongNormal VOP in a SurfaceShader context. (the Bump/BumpMap VOPs are based on it)
You'll find the corresponding code with Right-Click on it/TypeProperties/ inner and outer code.
Bump mapping is displacement mapping where you don't use the computed P.
You need to wire the output N of the DisplaceAlongNormal VOP to the nN of a Lightning model VOP.
( i don't see any relation with the shadingnormal VOP but maybe i don't undersatnd the pb you just had).
You'll find the corresponding code with Right-Click on it/TypeProperties/ inner and outer code.
Bump mapping is displacement mapping where you don't use the computed P.
You need to wire the output N of the DisplaceAlongNormal VOP to the nN of a Lightning model VOP.
( i don't see any relation with the shadingnormal VOP but maybe i don't undersatnd the pb you just had).
- Simon
- Member
- 2199 posts
- Joined: July 2005
- Online
It's worth noting as well that not all VEX commands are implimented in VOPs. Computenormal is one of them. For a complete list of VEX functions
go here
$HH\vex\html\quickref.html
Any that aren't made into VOPs yet can easily be added using the inline VOP.
:wink:
go here
$HH\vex\html\quickref.html
Any that aren't made into VOPs yet can easily be added using the inline VOP.
:wink:
The trick is finding just the right hammer for every screw
-
- Quick Links