Scene layers
  • 20 Sep 2024
  • 2 Minutes to read
  • Dark
    Light
  • PDF

Scene layers

  • Dark
    Light
  • PDF

Article summary

In a scene, the inputs are stacked/layered on top of each other. For each layer (input), you can set several properties that control the position, scaling, opacity, blend mode, audio active, layer active, etc.

To add, delete, and rearrange layers, see  User interface/Scene layers (6).

For the selected layer, the Preview window will display a yellow outline representing that layer. For the other layers, the preview window will display a slightly dimmed outline.

In the preview window, the selected layer can be moved and scaled using the outline handles.

To select a scene, click on the scene name just above the scene layers.

For each layer, the following functions/properties are available:

  • Eye icon: Enable or disable the video of the layer.
  • Speaker icon: Enable or disable audio of the layer.
  • Lock icon: Lock/unlock layer moving and scaling in the preview window. The locked layer can still be edited using layer properties.
  • Layer/alpha icon: There are four different settings related to how an alpha channel operates in a layer:
    • Default (not checked) - The alpha channel (if it exists in the layer) is used as a mask for the layer itself. 
    • Layer icon - The alpha channel of the layer is used as a mask for the layer below. The RGB content of the layer is ignored.
    • Layer icon (+) - The alpha channel is added to the layer’s alpha channel below.  This is often called additive alpha. The RGB content of the layer is ignored.
    • Layer icon (-) - The alpha channel is subtracted from the layer’s alpha channel below. This is often called subtractive alpha. The RGB content of the layer is ignored.
    • More on masking and alpha channels in a separate chapter.
  • Operator icon: The icon indicates if there are one or more Operator added to the scene layer. By clicking on the icon the Operator tab will open.
  • Layer name: name of the input or scene
  • Blend mode: type of blending mode used when rendering the layer. More information can be found here.
  • Processing time: if detailed processing time is enabled (in Settings), this will display the GPU Kernel Execution time of the layer (ms).
  • Anchor X/Y: center coordinate used in rotation transformation
  • Position X/Y: X/Y position in the scene. The upper left corner is 0,0. Right-click to access the context menu for "Reset Position X,Y."
  • Scale X/Y: Scale in X/Y in %. Right-click to access the context menu for "Reset Scale X,Y" and "Scale to fit". The "Scale to fit" will scale to fit the Scene's width and height. The scaling will be proportional by enabling the icon between Scale X and Scale Y.
  • Rotation: rotation in angles. Rotation is centered around the anchor position (above).
  • Opacity: layer transparency. The opacity will operate on the whole layer if there is no alpha channel in the layer. If an alpha channel exists, the opacity setting will operate as a pre-multiplier.
  • Batch: See documentation further down on this page.

Items in the list are rendered top-to-bottom, meaning that the items at the bottom of the list will be rendered on top of the ones above.

Use the yellow arrows to collapse/expand the scene layers view.

Batches

Batches is a feature in Composer that allows you to label your scene layers. In other words, you can give each layer a name or multiple names separated by a space character. By using the batch API:s in Composer, you can modify all layers (having a specific batch name) using a single API call. For example, show all layers labelled "FrontCam":

http://[YOURIP:PORT]/api/batch/showlayer?batch=FrontCam

Batches can be modified using three API:s:

  • /api/batch/showlayer - enable (show) matching layers.
  • /api/batch/showlayersolo - enable (show) matching layers and hide all other layers.
  • /api/batch/hidelayer - disable (hide) matching layers.

Batch names are case-sensitive.

Batches can also be modified using the Script Engine.



Was this article helpful?