Layer#
(Layer)
- Abstract Class
- Default object name:
layer
- Inherits from: ProjectItem
- Inherited by: LayerColor, LayerFile, LayerImage, LayerImageNode, LayerReference, LayerScene
No corresponding User page.
Description#
An abstract image layer found in a layered image.
Public Attributes#
Type | Name | Visual Hint | Description |
---|---|---|---|
long |
blending |
VISUAL_HINT_DEFAULT |
Set the blending mode of current layer. Depending on the mode the layer will blend differently over the bottom layer. Blending mode has no effect if there's only one layer in the image. |
double |
opacity |
VISUAL_HINT_PERCENTAGE |
Set the opacity of the layer. An opacity value of 50% will make the layer 50% transparent. |
long[2] |
pre_filter_offset |
VISUAL_HINT_PIXEL |
Pre-filtered position of the layer in the canvas. This position the one before filtering. Each time the layer is translated, filters are reapplied. |
long |
limited_region_mode |
VISUAL_HINT_DEFAULT |
Uses the limited region set by the parent image or the region set below. |
double[4] |
limited_region |
VISUAL_HINT_PERCENTAGE |
Region of interest to be rendered: x, y, width, height in percentages of the image visible window size. |
long |
comp_mode |
VISUAL_HINT_DEFAULT |
Defines how the layer will be used during the compositing of the image: it will be either resized to match the image size, or used with its original size. |
bool |
use_image_margin |
VISUAL_HINT_DEFAULT |
|
long |
margin_mode |
VISUAL_HINT_DEFAULT |
Set the mode to use to determine the size of the overscan. |
long[4] |
margin_pixel |
VISUAL_HINT_PIXEL |
Set the overscan for the current layer: Left, Top, Right, Bottom |
double[4] |
margin_ratio |
VISUAL_HINT_PERCENTAGE |
Set the overscan for the current layer: Left, Top, Right, Bottom |
object[] (ImageFilter ) |
filters |
VISUAL_HINT_DEFAULT |
List of image filters that are applied to the layer. This filters are applied procedurally. Each time the layer is modified, all the filters in list are reapplied to the layer. |
string |
output_layer |
VISUAL_HINT_TAG |
Select the aov channel to use RGBA. Other channels are discarded. Selecting 'all' disable the filter. |
long |
alpha_channel |
VISUAL_HINT_DEFAULT |
Use default: the 4th channel of the output layer is used as alpha. Use custom channel: the channel specified below is used as alpha. |
string |
custom_channel_name |
VISUAL_HINT_ENUM |
The specified channel will be written in the alpha channel |
bool |
render_to_disk |
VISUAL_HINT_DEFAULT |
If checked, the image is flagged to be rendered and saved to disk at the specified output path. Note the image supports rendering sequences. If you wish to export a still, make sure first frame and last frame have the same value. |
string |
save_as |
VISUAL_HINT_FILENAME_SAVE |
Set the image output filename, without file extension. Please note that the frame number is automatically appended to the filename. |
long |
first_frame |
VISUAL_HINT_FRAME |
Set the first output render frame range. If set to 10, the rendering of the image will start at frame 10. |
long |
last_frame |
VISUAL_HINT_FRAME |
Set the last output render frame range. If set to 20, the rendering of the image will stop at frame 20. |
long |
frame_step |
VISUAL_HINT_FRAME |
Set the output render frame step. The frame step is simply the frame increment between two renders in the frame range defined by first and last frame. |
long |
format |
VISUAL_HINT_DEFAULT |
Image output fileformat. |
string |
LUT |
VISUAL_HINT_ENUM |
Select the color correction to apply to the output image. |
long |
open_exr_output_compression_mode |
VISUAL_HINT_DEFAULT |
Set the OpenEXR output compression mode. |
string |
metadata |
VISUAL_HINT_SCRIPT |
Declare custom metadata to write in the EXR header. |
CID#
class "Layer" "ProjectItem" {
abstract yes
embedded_only yes
#version 0.92
icon "../icons/object_icons/layer.iconrc"
doc "An abstract image layer found in a layered image."
attribute_group "blending" {
collapsed yes
long "blending" {
doc "Set the blending mode of current layer. Depending on the mode the layer will blend differently over the bottom layer. Blending mode has no effect if there\'s only one layer in the image."
preset "Normal" "0"
preset "Alpha Replace" "1"
preset "Alpha Add" "2"
preset "Alpha Subtract" "3"
preset "Alpha Multiply" "4"
preset "Alpha Divide" "5"
preset "Add" "6"
preset "Multiply" "7"
preset "Screen" "8"
preset "Linear Dodge" "9"
preset "Overlay" "10"
preset "Difference" "11"
preset "Hue" "12"
preset "Saturation" "13"
preset "Color" "14"
preset "Brightness" "15"
preset "Keymix" "16"
value 0
}
percentage "opacity" {
doc "Set the opacity of the layer. An opacity value of 50% will make the layer 50% transparent."
animatable yes
slider yes
numeric_range yes 0.0 1
ui_range yes 0.0 1
value 1
}
}
attribute_group "transformation" {
collapsed yes
pixel[2] "pre_filter_offset" {
doc "Pre-filtered position of the layer in the canvas. This position the one before filtering. Each time the layer is translated, filters are reapplied."
output "image"
numeric_range yes -16384 16384
value 0 0
}
pixel[2] "post_filter_offset" {
doc "Post-filtered position of the layer in the canvas. This position the one after filtering. Each time the layer is translated, filters won\'t be reapplied."
output "image"
private yes
numeric_range yes -16384 16384
value 0 0
}
}
attribute_group "region" {
collapsed yes
long "limited_region_mode" {
doc "Uses the limited region set by the parent image or the region set below."
preset "Use image limited region" "0"
preset "Custom" "1"
value 0
}
percentage[4] "limited_region" {
doc "Region of interest to be rendered: x, y, width, height in percentages of the image visible window size."
animatable yes
read_only yes
value 0.0 0.0 1 1
}
long "comp_mode" {
doc "Defines how the layer will be used during the compositing of the image: it will be either resized to match the image size, or used with its original size."
preset "Resize" "0"
preset "No Resize" "1"
value 0
}
}
attribute_group "overscan" {
collapsed yes
bool "use_image_margin" {
animatable yes
value yes
}
long "margin_mode" {
doc "Set the mode to use to determine the size of the overscan."
preset "Pixel" "0"
preset "Ratio" "1"
value 0
}
pixel[4] "margin_pixel" {
doc "Set the overscan for the current layer: Left, Top, Right, Bottom"
numeric_range yes 0.0 10000
ui_range yes 0.0 10000
value 0 0 0 0
}
percentage[4] "margin_ratio" {
doc "Set the overscan for the current layer: Left, Top, Right, Bottom"
numeric_range yes 0.0 10
ui_range yes 0.0 10
value 0.0 0.0 0.0 0.0
}
}
attribute_group "filtering" {
collapsed yes
object[] "filters" {
doc "List of image filters that are applied to the layer. This filters are applied procedurally. Each time the layer is modified, all the filters in list are reapplied to the layer."
filter "ImageFilter"
output "image"
value <empty>
}
}
attribute_group "output" {
collapsed yes
tag "output_layer" {
doc "Select the aov channel to use RGBA. Other channels are discarded. Selecting \'all\' disable the filter."
filter "channel_groups"
preset "all" "-1"
preset "rgba" "0"
preset "coordinates" "1"
preset "diagnostics_pbr_diffuse_sample-count" "2"
preset "diagnostics_pbr_diffuse_sample-count_transmission" "3"
preset "diagnostics_pbr_diffuse_sample-count_reflection" "4"
preset "diagnostics_pbr_glossy_sample-count" "5"
preset "diagnostics_pbr_glossy_sample-count_transmission" "6"
preset "diagnostics_pbr_glossy_sample-count_reflection" "7"
preset "diagnostics_pbr_specular_sample-count" "8"
preset "diagnostics_pbr_specular_sample-count_transmission" "9"
preset "diagnostics_pbr_specular_sample-count_reflection" "10"
preset "diagnostics_pbr_spec-gloss_sample-count" "11"
preset "diagnostics_pbr_spec-gloss_sample-count_transmission" "12"
preset "diagnostics_pbr_spec-gloss_sample-count_reflection" "13"
preset "diagnostics_pbr_subsurface_sample-count" "14"
preset "diagnostics_pbr_volume_sample-count" "15"
preset "diagnostics_pbr_light_sample-count" "16"
preset "motion_vector" "17"
preset "camera_normal" "18"
preset "camera_position" "19"
preset "world_normal" "20"
preset "albedo" "21"
preset "depth" "22"
preset "pbr_diffuse" "23"
preset "pbr_diffuse_transmission" "24"
preset "pbr_diffuse_transmission_k" "25"
preset "pbr_diffuse_transmission_i" "26"
preset "pbr_diffuse_transmission_i_direct" "27"
preset "pbr_diffuse_transmission_i_indirect" "28"
preset "pbr_diffuse_reflection" "29"
preset "pbr_diffuse_reflection_k" "30"
preset "pbr_diffuse_reflection_i" "31"
preset "pbr_diffuse_reflection_i_direct" "32"
preset "pbr_diffuse_reflection_i_indirect" "33"
preset "pbr_glossy" "34"
preset "pbr_glossy_transmission" "35"
preset "pbr_glossy_transmission_k" "36"
preset "pbr_glossy_transmission_i" "37"
preset "pbr_glossy_transmission_i_direct" "38"
preset "pbr_glossy_transmission_i_indirect" "39"
preset "pbr_glossy_reflection" "40"
preset "pbr_glossy_reflection_k" "41"
preset "pbr_glossy_reflection_i" "42"
preset "pbr_glossy_reflection_i_direct" "43"
preset "pbr_glossy_reflection_i_indirect" "44"
preset "pbr_specular" "45"
preset "pbr_specular_transmission" "46"
preset "pbr_specular_transmission_k" "47"
preset "pbr_specular_transmission_i" "48"
preset "pbr_specular_reflection" "49"
preset "pbr_specular_reflection_k" "50"
preset "pbr_specular_reflection_i" "51"
preset "pbr_spec-gloss" "52"
preset "pbr_spec-gloss_transmission" "53"
preset "pbr_spec-gloss_reflection" "54"
preset "pbr_subsurface" "55"
preset "pbr_subsurface_k" "56"
preset "pbr_subsurface_i" "57"
preset "pbr_subsurface_i_direct" "58"
preset "pbr_subsurface_i_indirect" "59"
preset "pbr_volume" "60"
preset "pbr_volume_k" "61"
preset "pbr_volume_i" "62"
preset "pbr_volume_i_direct" "63"
preset "pbr_volume_i_indirect" "64"
preset "pbr_emission" "65"
preset "pbr_light_direction" "66"
preset "pbr_light_radiance" "67"
preset "luminosity" "68"
preset "opacity" "69"
preset "pbr_volume_density" "70"
preset "pbr_volume_attenuation" "71"
preset "pbr_catcher_opacity" "72"
preset "pbr_catcher_diffuse" "73"
preset "pbr_catcher_diffuse_transmission" "74"
preset "pbr_catcher_diffuse_reflection" "75"
preset "pbr_catcher_glossy" "76"
preset "pbr_catcher_glossy_transmission" "77"
preset "pbr_catcher_glossy_reflection" "78"
preset "pbr_catcher_specular" "79"
preset "pbr_catcher_specular_transmission" "80"
preset "pbr_catcher_specular_reflection" "81"
preset "pbr_catcher_spec-gloss" "82"
preset "pbr_catcher_spec-gloss_transmission" "83"
preset "pbr_catcher_spec-gloss_reflection" "84"
preset "pbr_catcher_subsurface" "85"
preset "pbr_catcher_volume" "86"
preset "diagnostics_ray-count" "87"
preset "diagnostics_camera_sample-count" "88"
preset "diagnostics_camera_heat-map" "89"
preset "cryptomatte_material" "90"
preset "cryptomatte_material00" "91"
preset "cryptomatte_material01" "92"
preset "cryptomatte_material02" "93"
preset "cryptomatte_object" "94"
preset "cryptomatte_object00" "95"
preset "cryptomatte_object01" "96"
preset "cryptomatte_object02" "97"
preset "cryptomatte_asset" "98"
preset "cryptomatte_asset00" "99"
preset "cryptomatte_asset01" "100"
preset "cryptomatte_asset02" "101"
preset "lpe_diffuse_reflection_albedo" "102"
preset "lpe_diffuse_reflection_direct" "103"
preset "lpe_diffuse_reflection_indirect" "104"
preset "lpe_diffuse_transmission_albedo" "105"
preset "lpe_diffuse_transmission_direct" "106"
preset "lpe_diffuse_transmission_indirect" "107"
preset "lpe_direct" "108"
preset "lpe_glossy_reflection_albedo" "109"
preset "lpe_glossy_reflection_direct" "110"
preset "lpe_glossy_reflection_indirect" "111"
preset "lpe_glossy_transmission_albedo" "112"
preset "lpe_glossy_transmission_direct" "113"
preset "lpe_glossy_transmission_indirect" "114"
preset "lpe_indirect" "115"
preset "lpe_spec-gloss_reflection_albedo" "116"
preset "lpe_spec-gloss_reflection_direct" "117"
preset "lpe_spec-gloss_reflection_indirect" "118"
preset "lpe_spec-gloss_transmission_albedo" "119"
preset "lpe_spec-gloss_transmission_direct" "120"
preset "lpe_spec-gloss_transmission_indirect" "121"
preset "lpe_specular_reflection_albedo" "122"
preset "lpe_specular_reflection_direct" "123"
preset "lpe_specular_reflection_indirect" "124"
preset "lpe_specular_transmission_albedo" "125"
preset "lpe_specular_transmission_direct" "126"
preset "lpe_specular_transmission_indirect" "127"
preset "lpe_subsurface_albedo" "128"
preset "lpe_subsurface_direct" "129"
preset "lpe_subsurface_indirect" "130"
preset "lpe_volume_albedo" "131"
preset "lpe_volume_direct" "132"
preset "lpe_volume_indirect" "133"
value "all"
}
long "alpha_channel" {
doc "Use default: the 4th channel of the output layer is used as alpha. Use custom channel: the channel specified below is used as alpha."
preset "Use default" "0"
preset "Use custom channel" "1"
value 0
}
enum "custom_channel_name" {
doc "The specified channel will be written in the alpha channel"
filter "custom_channels"
value "__invalid_enum_label__"
}
bool "render_to_disk" {
doc "If checked, the image is flagged to be rendered and saved to disk at the specified output path. Note the image supports rendering sequences. If you wish to export a still, make sure first frame and last frame have the same value."
output "none"
dg_active no
value no
}
filename_save "save_as" {
doc "Set the image output filename, without file extension. Please note that the frame number is automatically appended to the filename."
output "none"
dg_active no
read_only yes
value ""
}
frame "first_frame" {
doc "Set the first output render frame range. If set to 10, the rendering of the image will start at frame 10."
output "none"
dg_active no
value 1
}
frame "last_frame" {
doc "Set the last output render frame range. If set to 20, the rendering of the image will stop at frame 20."
output "none"
dg_active no
value 1
}
frame "frame_step" {
doc "Set the output render frame step. The frame step is simply the frame increment between two renders in the frame range defined by first and last frame."
output "none"
dg_active no
value 1
}
}
attribute_group "output>format" {
collapsed yes
long "format" {
doc "Image output fileformat."
output "none"
dg_active no
read_only yes
preset "Open EXR (16bit)" "0"
preset "Open EXR (32bit)" "1"
preset "Jpeg" "2"
preset "Bitmap" "3"
preset "Targa" "4"
preset "Png (8bit)" "5"
preset "Png (16bit)" "6"
preset "Tiff (8bit)" "7"
preset "Tiff (16bit)" "8"
preset "Tiff (32bit)" "9"
value 0
}
enum "LUT" {
doc "Select the color correction to apply to the output image."
filter "color_space"
output "none"
dg_active no
read_only yes
value "__invalid_enum_label__"
}
long "open_exr_output_compression_mode" {
doc "Set the OpenEXR output compression mode."
output "none"
dg_active no
read_only yes
preset "Use project preferences" "0"
preset "No Compression" "1"
preset "RLE Compression" "2"
preset "ZIPS Compression" "3"
preset "ZIP Compression" "4"
preset "PIZ Compression" "5"
preset "PXR24 Compression" "6"
preset "B44 Compression" "7"
preset "B44A Compression" "8"
preset "DWAA Compression" "9"
preset "DWAB Compression" "10"
value 0
}
script "metadata" {
doc "Declare custom metadata to write in the EXR header."
filter ""
output "none"
dg_active no
value ""
}
}
}