BlissLib: Shader authoring tool

Have you ever found yourself executing repetitive actions like creating a shader, plugging-in texture nodes, connecting attributes, setting parameters and then doing it over again for another object? When I was creating the ‘Creepy still life’ artwork I felt the need to have a tool which would automate the look development process by storing my shader network setups as a library of materials which would be accessible and build interactively during a render session.

After I realized that I was spending too much time on trivial tasks, I decided to write a framework which would take care of the routine part . This is how BlissLib was born.  It took me around two weeks to write the tool and it came out pretty robust.  The framework allows a user to build a library of shader networks and presets for interactive reuse and storage. And because the framework came out to be pretty cool, I couldn’t  just keep it for myself, so I share it with you guys absolutely for free. In addition, the tool comes with a simple UI to browse the shader library. I included several RenderMan and Mental Ray material examples which demonstrate the functionality of the tool. Here is the video which demonstrates BlissLib functionality.

BlissLib has already found its home at LollipopShaders team, who helped to make the tool as production friendly as possible. LollipopShaders used BlissLib to author their RenderMan RIS100 library. Check it out, they have a free library sample with 20 nice presets on

In order to install BlissLib, we need to make 5 simple steps:
Step 1. Download the package. Unpack its content inside Maya scripts folder.

Windows: C:\Users\UserName\Documents\maya\2016\scripts
OSX: /Users/UserName/Library/Preferences/Autodesk/maya/2016/scripts

Step 2. Open Maya ScriptEditor, create a Python tab and copy paste this code

import BlissLib
blissUI = BlissLib.buildUI()

Step 3. Run the code. And you’ll see the BlissLib browser.
Step 4. Create a new PxrDisney material or mia_material_x assign it to an object. Select the object and click on a swatch with corresponding render logo on it. The selected material will be adjusted according to the swatch clicked.
Step 5. Drag and drop the code into Maya Shelf to create a button so we don’t have to run the code from Script Editor each time we want to launch BlissLib. These are simple installation steps to load and use the shader network examples.

script editor

BlissLin screenshot

To author your very own custom shader library:

First of all, we need to create a Maya scene. Create a set of configured shader networks or simple materials of your preferred renderer. Give shaders meaningful names. And run the following lines in a Maya Script Editor.

from BlissLib import shadingNetworkIO

preparing shaders BlissLib

This command will create a database of all materials. So if we open BlissLib with our shelf button we will see a new set of buttons with the names of the created materials. However, the buttons do not have swatches! No worries, we haven’t created any swatches yet. It is a fairly easy process. All we need to do is to create a 150×150 pixel image for every material we just created. Each picture should have exactly the same name as the material it represents. So if we have a material named CarPaint the image should be named CarPaint.jpg Once the thumbnails are ready, copy them into the swatch directory.

Windows: C:\Users\User_1\Documents\maya\2016\scripts\BlissLib\swatch
OSX: /Users/UserName/Library/Preferences/Autodesk/maya/2016/scripts/BlissLib/swatch
folder structure blisslib

All authored materials and thumbnails are found here. User can delete or append the materials just by copy pasting json files.

Next time we launch BlissLib the buttons will have swatches we just created.

That is it! BlissLib can support complex and heavy networks and has been tested with Renderman RIS, Mental Ray and Maya Software. In theory it should work with any renderer which plays nicely with Maya Hypershade.

mental ray BlissLib

BlissLib supports Maya 2014, 2015, 2016 and on. Follow @renderstory to get new updates on tech and storytelling.

31 thoughts on “BlissLib: Shader authoring tool

  1. very nice.thanks !

    i wish the swatch image proccessing would be automatic ,
    and it could be super cool if u would connect the script to an online material library and people could swap materials in an easy way,.
    (and u could earn money from it 🙂

  2. Maya need a shader maneger, a scripts mananger, a scene/assets/objects manager.

    AssetMan + ShaderMonger: free (for now), promising, but after a few years, still not mature, and The UI looks too old. i think the author spend too many time to website.

    SLiB: free + paid version. i don’t have paid version. free version like a “product prototype”, pretty, but almost useless.

    BlissLib: i’m glad to see a new competitor emerged, for now, it’s looks like SLiB free version, but more “usable”.

    my ideal shader/scripts/assets manage software:

    1. can custom library location.
    2. tags:
    mentalray? iray? anorld? v-ray? …
    wood? metal? water?
    shader version?
    any custom tags collection.
    3. simple comments.
    4. easy assign/extract shader.

    1. Hello g2m,
      Thanks for your feedback, I’m glad you find BlissLib useful. Please consider, that this particular BlissLib distribution is not a commercial product and is not a commercial entity either. This website is a purely personal blog. No competition to other similar commercial products was intended 🙂

  3. A little big icons for my small monitor. It can be useful to have an option for custom icon size. It is strange – why *json? why not *ma? But it is very good script, easy to install and use. Thank you very much!

  4. Why can’t I select I select a Material along with all connections saved as a Material in BlissLib ?

  5. I have a material selected, and all it’s connections. I want to take that material as well as all it’s connections and save that material in BlissLib if I should so want to remove the material from the object or replace it with for example a blinn material; but apply the material to which I saved with all it’s connections is this not possible with BlissLib ?

    1. Hi Christopher,
      You don’t need to select anything, just prepare the scene with all the material networks you want to export and run this python command:

      from BlissLib import shadingNetworkIO

      So far, BlissLib doesn’t do a complete replace of the materials. Instead, it works with the already existing material which is attached to the object. For example, if you have a Blinn material attached to the object, you can freely apply Blinn presets from your library. However, if you want to change your Blinn to MIA material, first you need to assign MIA material to the object and then apply various MIA presets from your library. Hope this makes more sense now.

  6. When I select a material for an object, then select all input connections for that particular material run the command;

    from BlissLib import shadingNetworkIO

    I get five materials created in BlissLib, strictly not one material containing everything related to that objects material, it would be more efficient if BlissLib saved the one material and all connections as one material, not numerous materials as it has done with a mILA material I have applied to an object.

    1. Thanks for the feedback. I think we will put it in the next version! So far BlissLib is ment for massive material exports. if someone wants to export 100 materials it would take only one command to do it. so if you want to make a maintainable library of materials you create a scene with all the material networks and than run the command for export.
      Thanks for your feedback Christopher! I’ll definitely consider it.

  7. Thank you for sharing this tool !
    I was wondering if there is a proper way to save materials with displacement maps into the Bliss library ?
    Because as far as I have tried, displacement shader shows up as a seperate material and can’t be loaded correctly.
    Maybe I’m just doing something wrong.
    Or maybe it has something to do with what Christopher mentionned previously on May 2 ?
    But still cheers for sharing this with the community !

    1. Hi Elric
      Thanks for your interest. I actually never tried Blisslib with displacement materials. I’ll take a look at displacement stuff once I have time. thanks for pointing this out!

  8. Do you have a scene for render thumbnails? Post a link please. i Really want to leave it clean.

    Thank you

  9. Hey Einar,
    Great job on BlissLib, loving it!
    Is there any way to take a look at your code? Would be great to see how you’ve approached things.

  10. I’m getting the current error
    # Error: ImportError: file C:\Python Projects\GitHub\Maya\BlissLib\ line 1: No module named PySide
    when running the following code:
    import BlissLib
    blissUI = BlissLib.buildUI()

  11. Hi Einar,

    I really love your script, but wanna to share some things.
    Probably you know that since Maya 2017 PySide was replaced with PySide2? This way BlissLib won’t run on newest version.
    Besides I would recommend you to use QMainWindow rather that QDialog for main window, that let you add menubar with “write to network” button instead of using mel commands.
    Anyway I have already done it by me and ready to share. just write “”

    1. Hello Andrey,
      Thanks for your kind words and thefeedback! Looks like we need to open source the tool so others could contribute the improvements! I’ll keep you posted!

  12. Was BlissLB ever updated to work on Maya 2017? This is something I could really use with trying to streamline materials I make and want to reuse. To have finally found something only to find out it won’t work with what I have is a little disheartening. Is there something else out there that might work like this on 2017? Thank you for even creating something like this and putting it out there for others to use, just wish I could be one of them.

    1. Hi Christy,
      Unfortunately, Autodesk made a lot of changes to their Python GUI API and that requires some serious updating for BlissLib. Hopefully I have time in December to add the support for Maya 2017.

      1. I will be watching and waiting for it. From the videos I’ve seen it’s exactly what I’m looking for to use materials from different renderers and keep a library of them. Seeing the material manager from RenderMan is what made me look for something like this so if it’s even close to that when it comes out, I’ll be happy. Again, thank you for what you have put out, even though I can’t test it. 🙂

Leave a Reply

The reply will be processed within a day