appleseed Users Forum

OSL Shader Use

I’ve recently started poking at the world of Appleseed to use in a senior design project and there’s a lot to take in. I’m brand new to everything so I’ve spent the last few weeks going through documentation and exploring options within Appleseed Studio.

My next phase of work revolves around importing and using external OSL shaders but I have almost no idea where to start. The end goal will be to import and apply the shader to geometry via c++ code, but in the meantime I would like to understand the process using the GUI - and will fill in the code API calls later. Are there tutorials / docs which can assist me with this process, or perhaps someone with a similar project who can shed some experience?

Thanks in advance.

Hi @F4alt
Welcome to our forum!

The easiest is to use OSL is with blenderseed via the OSL_Script Base node. You can load OSL source code into this shader node and it will generate the corresponding user interface elements.
See screenshot below.

For general info about OSL in appleseed see https://github.com/appleseedhq/appleseed/wiki/Rules-and-Conventions
For the OSL source code of our own shader see https://github.com/appleseedhq/appleseed/tree/master/src/appleseed.shaders/src/appleseed

OSL Script node used in blenderseed

1 Like