Getting started with OCIO in RV

I’ve got my OCIO env variable set, pointing to my config.ocio, but I’m still getting errors in RV where it doesn’t seem to pick up the context I set in

1 Like

After many days of toiling away at this I discovered a workaround that works for me.

My issue was the current show I’m working for has their ccc and cdl luts for each vfx shot stored alongside the EXR files, but I couldn’t find in any of the documentation how to list relative filepaths in the ocio.config file to places other than where the ocio.config file is located.

The simple solution (at least for me) use symbolic linked folders to have the EXR media folder “stored” inside the aces folder in the RV configs.

Here is the snippet of my

elif (nodeType == "RVLookPipelineGroup"):
    # Get shot name and lut path from current loaded media in RV
    shotName = os.path.basename(media)
    shotPath = os.path.dirname(media)
    shotPathSplit = shotPath.split(os.sep)
    shot = shotPathSplit[-1]
    package = shotPathSplit[-2]
    vendor = shotPathSplit[-3]
    cdlLocation = shotPath+"/cdl"
    CDLLocation = shotPath+"/CDL"
    cccLocation = shotPath+"/ccc"
    CCCLocation = shotPath+"/CCC"

    # See if the vendor has supplied a ccc or cdl.
    def set_lut_type():
        cdl_exists = os.path.isdir(cdlLocation) or os.path.isdir(CDLLocation)
        ccc_exists = os.path.isdir(cccLocation) or os.path.isdir(CCCLocation)
        if cdl_exists and ccc_exists:
            return "cdl"
        elif ccc_exists:
            return "ccc"
        elif cdl_exists:
            return "cdl"
            raise ValueError("Error: Neither 'cdl' nor 'ccc' folders found.")
    # Set LUT to ccc or cdl depending on what's avilable.
        lutType = set_lut_type()
        print(f"lutType: {lutType}")
    except ValueError as e:

    # Set ennvironment variables
    os.environ["SHOT"] = shot
    os.environ["PACKAGE"] = package
    os.environ["VENDOR"] = vendor
    os.environ["LUT"] = lutType

    result = [
         {"nodeType"   : "OCIOLook",
          "context" : {"SHOT" : os.environ.get("SHOT"), "PACKAGE" : os.environ.get("PACKAGE"), "VENDOR" : os.environ.get("VENDOR"), "LUT" : os.environ.get("LUT"),},
          "properties" : {
              "ocio.function"     : "look",
              "ocio.inColorSpace" : OCIO.Constants.ROLE_SCENE_LINEAR,
              "ocio_look.look"    : "Shot_LUT"}}]

return result

And here is the code from my ocio.config file:

ocio_profile_version: 1

strictparsing: true


  • !
    name: Shot_LUT
    process_space: scene_linear
    transform: ! {src: ‘${SHOT}.${LUT}’, interpolation: linear, cccid: ‘0’}

  • !
    name: neutral
    process_space: scene_linear
    transform: ! {src: ‘neutral.cdl’, interpolation: linear, cccid: ‘0’}
    inverse_transform: ! {src: ‘neutral.cdl’, interpolation: linear}