Method CreateSceneItem
- Namespace
- OBSStudioClient
- Assembly
- OBSClient.dll
CreateSceneItem(SceneRef, SourceRef, bool?, Guid?, CancellationToken)
Creates a new scene item using a source.
public Task<int> CreateSceneItem(SceneRef scene, SourceRef source, bool? sceneItemEnabled = null, Guid? canvasUuid = null, CancellationToken cancellationToken = default)
Parameters
sceneSceneRefThe scene to create the new item in, by name or by UUID.
sourceSourceRefThe source to add to the scene, by name or by UUID.
sceneItemEnabledbool?Enable state to apply to the scene item on creation. If omitted: True.
canvasUuidGuid?UUID of the canvas the scene is in, if the scene is given by name.
cancellationTokenCancellationTokenA token that ends the wait for the response, which makes the method throw an OperationCanceledException. A request that was already sent is not undone: OBS Studio may still carry it out.
Returns
Remarks
Scenes only.