/// <summary> /// Set the relative crop coordinates of the specified source item /// </summary> /// <param name="fromSceneName">Source of the scene item</param> /// <param name="toSceneName">Destination for the scene item</param> /// <param name="sceneItem">Scene item, requires name or id</param> public void DuplicateSceneItem(string fromSceneName, string toSceneName, SceneItem sceneItem) { var requestFields = new JObject(); requestFields.Add("fromScene", fromSceneName); requestFields.Add("toScene", toSceneName); JObject minReqs = new JObject(); if (sceneItem.SourceName != null) { minReqs.Add("name", sceneItem.SourceName); } minReqs.Add("id", sceneItem.ID); requestFields.Add("item", minReqs); SendRequest("DuplicateSceneItem", requestFields); }
/// <summary> /// Set the relative crop coordinates of the specified source item /// </summary> /// <param name="sceneItem">Scene item object</param> /// <param name="cropInfo">Crop coordinates</param> /// <param name="scene">Parent scene of scene item</param> public void SetSceneItemCrop(SceneItem sceneItem, SceneItemCropInfo cropInfo, OBSScene scene) { SetSceneItemCrop(sceneItem.SourceName, cropInfo, scene.Name); }