I'm having trouble locating the up vector in UDK I want to use it to mask two materials. Is it named something weird, was it removed, and does it output something I can feed a linear interpolate node?
@Sprunghunt: I think you mean cross product. DOT would give a scalar.
@Jocose: I don't recall there being an UP Vector node either, but what sprunghunt suggests at first can work for getting a world up.
if you hook up a vector (0,0,1) to a transform node set with its input to world space and its output to tangent space you can use the dot product of your surface normal and that world up output as the alpha for your lerp.
thinking he someone gets the up vector from the WorldPosition, but also in the 2nd expmle in the vid he does the the WindDirectionAndSpeed so he can control the angle.
nice, thanks, that gives me enough ideas to work with I would say.
ya im pretty sure the last link is exactly what you wanted, but using that in conjunction with the winddirectionandspeed is the most versatile way to use it.
kinda a weird name for what it does, i just figured it out by skimming over the material nodes page @ UDN
Object Orientation is SORT of what your looking for. its the object's Z axis, not the worlds. So it will always be in respect to the object's local up.
Which has its uses, but if you're looking to make some sort of deposition shader it might not do what you want.
IE if you turn your rock upside down the snow will stay on the original "top" of when the model was imported to UDK.
Replies
or you could use the dot product of the Z and X (or Y) worldposition coordinates
I can't remember there being a specific world up vector.
@Jocose: I don't recall there being an UP Vector node either, but what sprunghunt suggests at first can work for getting a world up.
if you hook up a vector (0,0,1) to a transform node set with its input to world space and its output to tangent space you can use the dot product of your surface normal and that world up output as the alpha for your lerp.
[ame]http://www.youtube.com/watch?v=otedqKHET1w[/ame]
http://udn.epicgames.com/Three/MaterialsCompendium.html#WindDirectionAndSpeed
thinking he someone gets the up vector from the WorldPosition, but also in the 2nd expmle in the vid he does the the WindDirectionAndSpeed so he can control the angle.
Virtuosic talks about it a bit in this thread
http://www.polycount.com/forum/showthread.php?p=1193841
edit:
this could be it http://udn.epicgames.com/Three/MaterialsCompendium.html#ObjectOrientation
ya im pretty sure the last link is exactly what you wanted, but using that in conjunction with the winddirectionandspeed is the most versatile way to use it.
kinda a weird name for what it does, i just figured it out by skimming over the material nodes page @ UDN
Which has its uses, but if you're looking to make some sort of deposition shader it might not do what you want.
IE if you turn your rock upside down the snow will stay on the original "top" of when the model was imported to UDK.
also here: Have a package of some random shader fun I put together a while back. for this particular idea look under the materials group at the "ruster" material.