I come from a RenderMan shader background and learning VEX now.
I wrote a simple checker shader in VEX, it works on a NURBS Grid SOP.
I added a Texture SOP between the Grid SOP and Shader SOP in the hope to get a denser checker pattern. It did not work as expected.
Following that, I created another scene with a Grid SOP, followed by a Texture SOP finally followed by a Shader SOP. This time round, I use the provided VEX Decal shader. I was able to scale/repeat the decal successfully.
Is there some hint I have to pass on to shader compiler to get the texture coordinate from the SOP? Am I solving the problem along the correct path.
I notice there is UV and there is ST, is it the case that s,t are the parameter for the geometry whereas I should be using the uv information and that I should hide the uv parameter via #hint
A sample shader would be helpful.
Hope I have explain my problem well.
Cheers
–
Nicholas Yue
VEX s,t parameter scaling
5448 5 1- nicholas_yue
- Member
- 301 posts
- Joined: July 2005
- Offline
- edward
- Member
- 7868 posts
- Joined: July 2005
- Offline
The source code for all the standard VEX shops are available. Right-click on an instance of the VEX Decal SHOP, choose “Operator Type Manager…”. This should pop up a new dialog with the entry on Shop/v_decal. Right-click on this name and choose “Edit Contents…”. Select “Vfl Code”. Now you can copy out the source code and examine at your leisure.
- mtucker
- Staff
- 4517 posts
- Joined: July 2005
- Offline
- nicholas_yue
- Member
- 301 posts
- Joined: July 2005
- Offline
mtucker
You can also see the code for any SHOP by choosing “Type Properties…” from the RMB menu, and going to the VEX Code page. The advantage of this dialog is that you can actually edit the code and your changes will be applied automatically, so you can easily experiment with the existing code.
Mark
I tried the above, it displayed
“No VEX Code associated with this operator”
I am using 6.1.175 Houdini Master Apprentice on WindowsXP
Anyone can shed more light on this?
Nicholas Yue
- tallkien
- Member
- 225 posts
- Joined: July 2005
- Offline
- nicholas_yue
- Member
- 301 posts
- Joined: July 2005
- Offline
-
- Quick Links