RampDisplayFilter

Overview

The RampDisplayFilter takes in a series of colors, positions, and interpolations to generate a ramp of the specified ramp_type.


Attribute Reference

Advanced attributes

invert_mask

Bool
default: False

Invert the value of the mask

mix

Float
default: 1.0

Blend [0,1] between input and output

Ramp Knot attributes

colors

RgbVector
default: [[ 0, 0, 0 ], [ 0.25, 0.25, 0.25 ], [ 0.75, 0.75, 0.75 ], [ 1, 1, 1 ]]

List of ramp colors

interpolations

IntVector
default: {}

List of ramp interpolations.

positions

FloatVector
default: {}

List of ramp positions

Ramp properties attributes

input

RenderOutput
default: None

RenderOutput fed into the ramp

ramp_type

Int enum
  0 = “v_ramp” (default)
  1 = “u_ramp”
  2 = “diagonal_ramp”
  3 = “radial_ramp”
  4 = “circular_ramp”
  5 = “box_ramp”
  6 = “uxv_ramp”
  7 = “four_corner_ramp”
  8 = “input_ramp”

Type of ramp

General attributes

mask

RenderOutput
default: None

RenderOutput used to mask the output, revealing input1


Examples

local beauty = RenderOutput("/output/beauty") {
    ["file_name"] = "result_tmp.exr",
    ["result"] = "beauty",
}

local input_ramp = RampDisplayFilter("/display/input_ramp") {
    ["positions"] = {0.0, 0.15, 0.3, 0.5, 1.0},
    ["colors"] = {Rgb(0.0, 0.8, 0.8), Rgb(0.0, 1.0, 0.0), Rgb(0.2, 0.2, 0.0), Rgb(0.0, 0.0, 1.0), Rgb(0.2, 0.0, 1.0)},
    ["ramp_type"] = "input_ramp",
    ["interpolations"] = {4, 4, 4, 4, 4},
    ["input"] = beauty
}

RenderOutput("/output/input_ramp") {
    ["file_name"] = "result0.exr",
    ["result"] = "display filter",
    ["display_filter"] = input_ramp,
    ["channel_name"] = "input_ramp"
}