how can I get the name of the object/sop/etc. attached to given SHOP?
for example if i want to have a single shadow shader that takes different shadow maps from channels on lights it attached to.
Also i want to see animated texture on sprites in opengl preview, driven by point attribute?
is it possible? i know how to setup it for rendering but what about opengl?
is there any variable available for SHOP, for example, $ATTACHED_OBJ or something like that to make me know what object is processed?
I haven't found any documentation about variables for SHOPs….
name of object SHOP is attached to
2681 2 1- mlesin
- Member
- 176 posts
- Joined: May 2006
- Offline
- jason_iversen
- Member
- 12523 posts
- Joined: July 2005
- Offline
In SHOPs, you have a $OBJ which is the object to which the shader is bound.
A typical setting for a VEX Shadow SHOP applied to many lights might have this in it's Depth Map field:
`chs(“/obj/$OBJ/depthmap”)`
…in this way you can apply one shadow shader to many lights, applying the relevant depthmaps defined in each Light Object.
Also, in VEX, you might be interested in the renderstate() function, particularly “object:name”. Read here: http://www.sidefx.com/docs/content/vex/functions/renderstate.xml [sidefx.com]
Hope this helps,
Jason
A typical setting for a VEX Shadow SHOP applied to many lights might have this in it's Depth Map field:
`chs(“/obj/$OBJ/depthmap”)`
…in this way you can apply one shadow shader to many lights, applying the relevant depthmaps defined in each Light Object.
Also, in VEX, you might be interested in the renderstate() function, particularly “object:name”. Read here: http://www.sidefx.com/docs/content/vex/functions/renderstate.xml [sidefx.com]
Hope this helps,
Jason
Jason Iversen, Technology Supervisor & FX Pipeline/R+D Lead @ Weta FX
also, http://www.odforce.net [www.odforce.net]
also, http://www.odforce.net [www.odforce.net]
- mlesin
- Member
- 176 posts
- Joined: May 2006
- Offline
-
- Quick Links