logo

Live Production Software Forums


Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Options
Go to last post Go to first unread
jeregan  
#1 Posted : Wednesday, October 30, 2024 4:07:15 AM(UTC)
jeregan

Rank: Member

Groups: Registered
Joined: 7/14/2016(UTC)
Posts: 26
Location: Canada

Was thanked: 10 time(s) in 3 post(s)
This would vastly reduce the # of times a camera is moved in error while it is program.

Situation:
- Camera 1 has several PTZ Virtual inputs created from it.
- Camera 1 is in program.
- One of these PTZ Virtual inputs is selected and put into preview.
- The camera is moved to this new virtual position - moving the shot in program in error because the person did not realize the camera was in program.

Solution: Only move the camera IF it is not in program.

For many years I have used scripts that do this checking. But is requires a custom script for each input, and could easily be handled directly by vMix.

Here is the method of how it could be built into vMix.

Have two check boxes on EACH virtual PTZ input to give specific input flexibility:
[ ] Program Lock - if checked, when this virtual PTZ input is selected, the camera will NOT move to this preprogrammed spot if the camera is IN PROGRAM as well.
[ ] Double Click Go - if checked, and the option above is checked, when this virtual PTZ input is clicked/selected twice in 1 second, the camera WILL move even if the camera is IN PROGRAM.

Note in both cases: the Preview Input is switched BACK to the physical Camera input automatically so the person can easily see what Input # is up in preview. (my script does this by executing the PTZ movement when not in program and then waiting 500mS before selecting the base input, otherwise it just switches to the base camera input).

Manual camera adjustments using the Xbox gamepad or other shortcuts will still be possible even when the input is in both preview AND program.





Dan Whitaker  
#2 Posted : Monday, August 4, 2025 3:15:35 PM(UTC)
Dan Whitaker

Rank: Newbie

Groups: Registered
Joined: 10/20/2020(UTC)
Posts: 3
United States
Location: Corvallis

Thanks: 1 times
+1 this would help a lot
jet  
#3 Posted : Monday, August 18, 2025 1:49:24 PM(UTC)
jet

Rank: Advanced Member

Groups: Registered
Joined: 11/14/2012(UTC)
Posts: 361
Man
Location: Finland

Thanks: 232 times
Was thanked: 24 time(s) in 22 post(s)
+1
jeregan  
#4 Posted : Saturday, September 5, 2026 6:59:34 AM(UTC)
jeregan

Rank: Member

Groups: Registered
Joined: 7/14/2016(UTC)
Posts: 26
Location: Canada

Was thanked: 10 time(s) in 3 post(s)
I don't think people realize how much this could help them prevent errors when live.

Here is my script that I currently use in case anyone wants to do it the way I have.


'Call this as a shortcut.

'Ideally the first two items below should be passed via argumnets in the short cut.
'But vMix does not currently support that (ver. 29).

'Specify ptzinput name for the virtual input that matches the button being pressed
Dim ptzcamNAME As String = "PTZ - N - Ambo"

'Ideally you could call the camera via the underlying UUID that vMix assigns, then changing the Name or moving inputs around
'would not matter.

'Specify the input name of the camera itself, that all the PTZshots are built from
Dim realcamNAME As String = "CAM 1 - PTZ North"

' script to prevent human error from moving accidentally moving an active PTZ camera
' Jeff Regan - j--0@outlok.com - Oct 28, 2016

' If the camera the user wants to put up in preview to move is up in the Active Output
' then select the real camera input itself in preview - no auto PTZ movements will occur.
' The user can then adjust PTZ by hand live if they want

' If the camera is not up on the active shot, select the PTZcam the user requested.
' Then wait half a second and select the real camera feed and put it up in preview.
' This allows the user to make fine adjustments to the camera PTZ before sending it
' to the active shot. When the camera does go live, it will stay with the adjusted shot
' and will not recall the saved PTZcam movement the user originally selected.

'Load current xml from vmix
Dim doc As New XmlDocument()

doc.Load("http://127.0.0.1:8088/API")

'Find out which input ID is up on the active output.
Dim activecamNUM As String = doc.SelectSingleNode("/vmix/active").InnerText
'Find name of active input
Dim activecamNAME As String = doc.SelectSingleNode("/vmix/inputs/input[@number='"+activecamNUM +"']").InnerText

Dim nodes As XmlNodeList
Dim node As XmlNode

nodes = doc.SelectNodes("/vmix/inputs/input")

dim num as string
dim title as string
dim errNUM as string
dim realcamNUM as string
dim ptzcamNUM as string
dim inputerrNUM as string

For Each node In nodes
'Console.WriteLine("number: "+node.SelectSingleNode("@number").InnerText+" title: "+node.SelectSingleNode("@title").InnerText)
num=node.SelectSingleNode("@number").InnerText
title=node.SelectSingleNode("@title").InnerText

' find ptz camera input number that matches the name of the ptz
If ptzcamNAME = title Then
ptzcamNUM = num
'Console.WriteLine("ptzcam:"+ptzcamNUM+" "+ptzcamNAME)
End If

' find the real camera input number that matches the name of the camera
If realcamNAME = title Then
realcamNUM = num
'Console.WriteLine("realcam:"+realcamNUM+" "+realcamNAME)
End If

Next

'Console.WriteLine("activecam:"+activecamNUM+" "+activecamNAME)

If activecamNUM = realcamNUM or activecamNUM = ptzcamNUM Then
API.Function("PreviewInput",realcamNUM)
else
API.Function("PTZMoveToVirtualInputPosition",ptzcamNUM)
API.Function("PreviewInput",ptzcamNUM)
Sleep(500)
API.Function("PreviewInput",realcamNUM)
End If



Users browsing this topic
Guest
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.