vMix Forums
»
General
»
Feature Requests
»
Shortcut for "TransitionActive"
Rank: Advanced Member
Groups: Registered
Joined: 1/9/2019(UTC) Posts: 77 Location: Stockholm Thanks: 20 times Was thanked: 5 time(s) in 4 post(s)
|
Hi,
I often use the merge-function with long transition times like 8000ms. By that I can achieve smooth zooms in and out from a 4K camera input to a virtual input of the same camera with predefined zoom and pan. Works just perfect. But I have done mistakes and selected another input for preview DURING an ongoing transition and the consequence is obvious.
A couple of years ago we had a feature request (https://forums.vmix.com/posts/t26470-Indicator-that-effect-is-processing) to indicate exactly this in the vMix UI - and we got it! Big thx to the vMix-team!
Long story short, I would appreciate if we could get a shortcut for the exact same thing. For example "TransitionActive" that just returns true or false, or a string value of the remaining transition time in ms. I would then use this information and add functionality to my Skaarhoj AirflyPro to prevent human error during live events.
Thx! /Peter
|
|
|
|
Rank: Advanced Member
Groups: Registered
Joined: 12/27/2012(UTC) Posts: 5,237 Location: Belgium Thanks: 293 times Was thanked: 957 time(s) in 792 post(s)
|
Originally Posted by: Peter Berglund Hi,
I often use the merge-function with long transition times like 8000ms. By that I can achieve smooth zooms in and out from a 4K camera input to a virtual input of the same camera with predefined zoom and pan. Works just perfect. But I have done mistakes and selected another input for preview DURING an ongoing transition and the consequence is obvious.
A couple of years ago we had a feature request (https://forums.vmix.com/posts/t26470-Indicator-that-effect-is-processing) to indicate exactly this in the vMix UI - and we got it! Big thx to the vMix-team!
Long story short, I would appreciate if we could get a shortcut for the exact same thing. For example "TransitionActive" that just returns true or false, or a string value of the remaining transition time in ms. I would then use this information and add functionality to my Skaarhoj AirflyPro to prevent human error during live events.
Thx! /Peter Interesting. Until available can you not check the value (script) of the Preview input number ( API XML) as that changes to what was the output the moment a transition finishes ? this could create your shortcut/trigger
|
|
|
|
Rank: Advanced Member
Groups: Registered
Joined: 1/9/2019(UTC) Posts: 77 Location: Stockholm Thanks: 20 times Was thanked: 5 time(s) in 4 post(s)
|
Quote:Interesting.
Until available can you not check the value (script) of the Preview input number ( API XML) as that changes to what was the output the moment a transition finishes ? this could create your shortcut/trigger Thx for your suggestion. Might be possible, but so much easier to act on a vMix DeviceCore parameter inside Skaarhoj (Reactor). I can imagine that other control surfaces can benefit from the suggested shortcut as well, and even inside a script itself to make things simpler. Thx! /Peter
|
|
|
|
Rank: Advanced Member
Groups: Registered
Joined: 2/18/2014(UTC) Posts: 1,838 Location: Stockholm
Thanks: 144 times Was thanked: 297 time(s) in 250 post(s)
|
+1, if As I guess Peter means some information in the API XML that reflects the status, something like: Quote:<transitions> <transition number="1" active="true" effect="Fade" duration="500"/> <transition number="2" active="false" effect="Merge" duration="500"/> <transition number="3" active="false" effect="Wipe" duration="1000"/> <transition number="4" active="false" effect="CubeZoom" duration="1000"/> </transitions> or, perhaps instead of "true" reports time in ms, e.e "200", where the number is how far the transition has executed
|
|
|
|
Rank: Advanced Member
Groups: Registered
Joined: 1/9/2019(UTC) Posts: 77 Location: Stockholm Thanks: 20 times Was thanked: 5 time(s) in 4 post(s)
|
Originally Posted by: richardgatarski +1, if As I guess Peter means some information in the API XML that reflects the status, something like: Quote:<transitions> <transition number="1" active="true" effect="Fade" duration="500"/> <transition number="2" active="false" effect="Merge" duration="500"/> <transition number="3" active="false" effect="Wipe" duration="1000"/> <transition number="4" active="false" effect="CubeZoom" duration="1000"/> </transitions> or, perhaps instead of "true" reports time in ms, e.e "200", where the number is how far the transition has executed Well, for me it's good enough by far if it is an or-query of these transition numbers. In other way, if any of the transitions are active, return "True". Else "False". Or as I mentioned in my original post, remaining time in ms (rather than how far the transition has executed). So if 0(ms) is returned, it equals transition complete. Thx! /P
|
|
|
|
Rank: Advanced Member
Groups: Registered
Joined: 12/27/2012(UTC) Posts: 5,237 Location: Belgium Thanks: 293 times Was thanked: 957 time(s) in 792 post(s)
|
Originally Posted by: richardgatarski +1, if As I guess Peter means some information in the API XML that reflects the status, something like: Quote:<transitions> <transition number="1" active="true" effect="Fade" duration="500"/> <transition number="2" active="false" effect="Merge" duration="500"/> <transition number="3" active="false" effect="Wipe" duration="1000"/> <transition number="4" active="false" effect="CubeZoom" duration="1000"/> </transitions> or, perhaps instead of "true" reports time in ms, e.e "200", where the number is how far the transition has executed WOuld be handy indeed but imo only usefull for long transition times. Both could be done/retrieved with a (VB.net) script though for now . either way it would have to be queried by script and a lot would depend on how you woud call the transition , decide which transition want to look for etc Pron more effective if it would show which transition is actually hapening
|
|
|
|
Rank: Advanced Member
Groups: Registered
Joined: 2/18/2014(UTC) Posts: 1,838 Location: Stockholm
Thanks: 144 times Was thanked: 297 time(s) in 250 post(s)
|
Originally Posted by: doggy imo only usefull for long transition times. agree Originally Posted by: doggy Both could be done/retrieved with a (VB.net) script though for now . either way it would have to be queried by script and a lot would depend on how you woud call the transition , decide which transition want to look for etc This brings, together with an idea for a new related FR I am pondering about, up the question how frequently the XML is updated by vix? I have not seen anything about that in the documentation. (I understand that the XML is generated when the API is called, but is it generated directly from vMix current status, or is it somehow cashed?)
|
|
|
|
Rank: Advanced Member
Groups: Registered
Joined: 12/27/2012(UTC) Posts: 5,237 Location: Belgium Thanks: 293 times Was thanked: 957 time(s) in 792 post(s)
|
Originally Posted by: richardgatarski This brings, together with an idea for a new related FR I am pondering about, up the question how frequently the XML is updated by vix? I have not seen anything about that in the documentation. (I understand that the XML is generated when the API is called, but is it generated directly from vMix current status, or is it somehow cashed?)
AFAIK Presets are updated once a minute, API XML whenever there is a change Checking it with using it as a datasource there it is responding tothe min poling time of 100 miliseconds
|
|
|
|
Rank: Advanced Member
Groups: Registered
Joined: 2/18/2014(UTC) Posts: 1,838 Location: Stockholm
Thanks: 144 times Was thanked: 297 time(s) in 250 post(s)
|
Originally Posted by: doggy Checking it with using it as a datasource there it is responding tothe min poling time of 100 miliseconds No offence, and you had a lower time than 100ms set for the Datasource update interval? In any case, thanks for checking - good to know (100 ms is a lot in my humble opinion).
|
|
|
|
Rank: Advanced Member
Groups: Registered
Joined: 12/27/2012(UTC) Posts: 5,237 Location: Belgium Thanks: 293 times Was thanked: 957 time(s) in 792 post(s)
|
Originally Posted by: richardgatarski Originally Posted by: doggy Checking it with using it as a datasource there it is responding tothe min poling time of 100 miliseconds No offence, and you had a lower time than 100ms set for the Datasource update interval? In any case, thanks for checking - good to know (100 ms is a lot in my humble opinion). One can not set the update interval lower than 100ms in the datasource manager ( can in script)
|
|
|
|
Rank: Advanced Member
Groups: Registered
Joined: 12/27/2012(UTC) Posts: 5,237 Location: Belgium Thanks: 293 times Was thanked: 957 time(s) in 792 post(s)
|
Below is a go at determining time remaining and when a transition is finished Its based on the transitionsettings on the vMix GUI Mind you response time in the script editor console is slower than actual say display info in the title Code:' One of Transitions (1-4) set in the vMix GUI
dim vTransition as string = "CubeZoom"
dim xml as string = API.XML()
dim x as new system.xml.xmldocument
x.loadxml(xml)
'Get the duration of the transition
Dim vDuration as string = x.SelectSingleNode("//transition[@effect='" & Vtransition & "']/@duration").Value
'Input that is currently active
Dim vActive as string = x.SelectSingleNode("//active").InnerText
Dim vElapsed As TimeSpan
Dim watch As Stopwatch = Stopwatch.StartNew()
'Execute the transition
API.Function(vTransition,,duration:=vDuration )
Do While true
xml= API.XML()
x.loadxml(xml)
If x.SelectSingleNode("//preview").InnerText = vActive
' if preview becomes what was active the transition is done
console.writeline("Done")
API.Function("SetText",Input:=1,SelectedName:="Headline.Text" ,Value:="DONE")
Exit do
else
' a bit of countdon based on the transition duration (formula can be improved)
API.Function("SetText",Input:=1,SelectedName:="Headline.Text" ,Value:=(vDuration/1000) - Math.Floor(watch.Elapsed.TotalMilliseconds/1000) )
Console.WriteLine( vDuration/1000 - Math.Floor(watch.Elapsed.TotalMilliseconds/1000))
end if
' sleep(100)
Loop
|
1 user thanked doggy for this useful post.
|
|
|
vMix Forums
»
General
»
Feature Requests
»
Shortcut for "TransitionActive"
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.
Important Information:
The vMix Forums uses cookies. By continuing to browse this site, you are agreeing to our use of cookies.
More Details
Close