API for scene-items

Hierarchy

Implements

Index

Constructors

constructor

  • new SceneItem(sceneId: string, nodeId: string, sourceId: string): SceneItem

Properties

id

id: string

locked

locked: boolean

name

name: string

nodeId

nodeId: string

parentId

parentId: string

recordingVisible

recordingVisible: boolean

sceneId

sceneId: string

sceneItemId

sceneItemId: string

sceneNodeType

sceneNodeType: TSceneNodeType

sourceId

sourceId: string

streamVisible

streamVisible: boolean

transform

transform: ITransform

visible

visible: boolean

Methods

addToSelection

  • addToSelection(): void

centerOnScreen

  • centerOnScreen(): void

deselect

  • deselect(): void

detachParent

  • detachParent(): void

fitToScreen

  • fitToScreen(): void

flipX

  • flipX(): void

flipY

  • flipY(): void

getItemIndex

  • getItemIndex(): number
  • Returns the item index in the list of all nodes. itemIndex defines the draw order of the node itemIndex for a SceneFolder is the itemIndex of the previous SceneItem

    To change itemIndex use placeBefore and placeAfter methods

    nodeInd | itemInd | nodes tree
     0      |    0    | Folder1
     1      |    0    |   |_Folder2
     2      |    0    |   |_ Item1
     3      |    1    |   \_ Item2
     4      |    2    | Item3
     5      |    2    | Folder3
     6      |    3    |   |_Item4
     7      |    4    |   \_Item5
     

    Returns number

getModel

getNextItem

getNextNode

getNodeIndex

  • getNodeIndex(): number

getParent

getPath

  • getPath(): string[]

getPrevItem

getPrevNode

getScene

getSource

hasParent

  • hasParent(): boolean

isFolder

  • isFolder(): this

isItem

  • isItem(): this

isSelected

  • isSelected(): boolean

placeAfter

  • placeAfter(nodeId: string): void

placeBefore

  • placeBefore(nodeId: string): void

remove

  • remove(): void

resetTransform

  • resetTransform(): void

rotate

  • rotate(deg: number): void

select

  • select(): void

setContentCrop

  • setContentCrop(): void

setParent

  • setParent(parentId: string): void

setScale

  • setScale(newScaleModel: IVec2, origin?: IVec2): void
  • set scale and adjust the item position according to the origin parameter

    Parameters

    • newScaleModel: IVec2
    • Optional origin: IVec2

    Returns void

setSettings

setTransform

setVisibility

  • setVisibility(visible: boolean): void

stretchToScreen

  • stretchToScreen(): void