Jump to content

compiling shaders


haggi

Recommended Posts

I'm writing some shaders in vex code like I have done before with renderman shaders. With the shader compiler in renderman I get a compiled opcode file. With vcc I get an .vex textfile out of a .vfl file.

So I'm a bit confused how the whole thing works. Are these text vex files read by the renderer and compliled again to use them?

My goal is to create a shader and use it in my ifd file to render it in mantra with the option mantra -f myifdfile.ifd.

My idea was to create a shader library with

vcc -M shaders.otl myshader.vfl

.

Then I load this otl in my ifd file with

ray_loadotl ..../shaders.otl

From my understanding the otl file should contain the compiled shader definitions in a way that I can use them in my ifd file with:

ray_property object name "cubeNode"
ray_property object surface lambert_surface

where lambert_surface is my shader.

Well, this doesent work at all. The shaders cannot be found, errormessages say the path cannot be found.

If I navigate to the directory where the vex files are located, the shaders are found and used, even if I completly remove the ray_loadotl from my ifd file.

My goal is to create a shader library which can be included into the ifd file (or linked) so that I can use the shaders without the .vex files. Is this possible?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...