← All ideas

OSL Node Improvement

I would like to suggest improvements to script/osl shader node

Ideas

  1. Add a Separate OSL option in the shader options list which will house all the osl shaders found on the default blender directory or in BLENDER_OSL_PATH variable

  2. The OSL option list would have 2 default options Load OSL Shader and Create OSL shader

    1. Load OSL shader - This will open the directory search window and you can load your osl shader, this will drop it into blender like a regular shader node
    2. Create OSL Shader - Drops a blank node, You can right click, select Edit OSL Shader , do your code, hit compile and the node updates
  3. Add a Environment Variable for batch loading osl shaders like BLENDER_OSL_PATH , any OSL shaders appended to this path will load in Blender, because if a user or studio has a bunch of osl shaders they need to load they would have to add the script node and load it one by one, which is very tedious.

  4. How OSL nodes would be edited

    1. You drop a Blank OSL Node.
    2. You can right click on the node and select Edit OSL Shader , this will add the code to the script editor
    3. You can make your code adjustments
    4. Hit Compile in the script editor and the node will update

Untitled-1.png Screenshot 2025-02-25 225107.png

100%

Development Status: Open

Upvote 6 Downvote 0
shamiel
25 Feb 2025

1 Comment

Lauloque

I wonder if it would also be interesting to also have an implementation of .osl files in the Asset Browser 🤔 Basically treated as nodegroups, except it's contained in .osl files instead of .blend files.

3