Rank: Advanced Member
Groups: Registered
Joined: 1/6/2014(UTC) Posts: 38 Location: Seattle, WA
Was thanked: 1 time(s) in 1 post(s)
|
On Windows boot/restart, I want to:
1. Run vMix 2. Auto load a preset file
I can accomplish both by putting the preset file in the Windows Start Menu.
3. Auto start streaming
I know that External Output can be auto started from vMix Settings, but is there any way to auto start Streaming? I'd rather not switch my config over to External Output if I can avoid it.
Thanks.
|
|
|
|
Rank: Advanced Member
Groups: Registered
Joined: 10/30/2013(UTC) Posts: 290 Location: The Netherlands
Thanks: 6 times Was thanked: 21 time(s) in 15 post(s)
|
you can put a shortcut to FMLEcmd.exe in the startmenu. Streaming then will start immediately.
|
1 user thanked wwdv for this useful post.
|
|
|
Rank: Advanced Member
Groups: Registered
Joined: 1/6/2014(UTC) Posts: 38 Location: Seattle, WA
Was thanked: 1 time(s) in 1 post(s)
|
wwdv wrote:you can put a shortcut to FMLEcmd.exe in the startmenu. Streaming then will start immediately. I assume that only works if I'm using External Output, not simplified Streaming. I'm looking for a way to start Streaming without using External Output.
|
|
|
|
Rank: Advanced Member
Groups: Registered
Joined: 12/29/2013(UTC) Posts: 54 Location: Mississauga, Canada
Thanks: 10 times Was thanked: 3 time(s) in 3 post(s)
|
In case wwdv's suggestion doesn't work: This is a Windows shell script (start-streaming.vbs) that I use to automate FMLE (the full program, not the FMLEcmd command-line executable used by vMix): Code:Set WshShell = WScript.CreateObject("WScript.Shell")
WshShell.Exec("C:\Program Files (x86)\Adobe\Flash Media Live Encoder 3.2\FlashMediaLiveEncoder.exe")
'Give FME time to load
WScript.Sleep 8000 'milliseconds to wait
WshShell.AppActivate "Adobe Flash Media Live Encoder"
WshShell.SendKeys "{ENTER}" 'Start encoding
Set WshShell = nothing
...but using the FMLE program requires the External output, so you probably don't want that. But you can do something similar with vMix... Create a new keyboard shortcut in the vMix settings to perform the "StartStreaming" function, and create a Windows Shell script with the SendKeys command to 'press' that key to start streaming. A wait of a few seconds to let vMix load first would also be a good idea. You can put a shortcut to that script file in your Startup folder.
|
|
|
|
Rank: Advanced Member
Groups: Registered
Joined: 1/6/2014(UTC) Posts: 38 Location: Seattle, WA
Was thanked: 1 time(s) in 1 post(s)
|
Rehan wrote:In case wwdv's suggestion doesn't work... Thanks! The shell script worked perfectly. In vMix, I assigned F5 to StartStreaming, then created a *.vbs file: Code:'Windows shell script to start vMix streaming after a reboot
'F5 is assigned to StartStreaming in vMix settings
Set WshShell = WScript.CreateObject("WScript.Shell")
'Wait for vMix to load (milliseconds)
WScript.Sleep 20000
'Bring up vMix window
WshShell.AppActivate "vMix HD - 14.0.0.106 x64"
'Start streaming
WshShell.SendKeys "{F5}"
The only limitation is that I'll have to update the window title in the AppActivate command every time that the vMix version number changes.
|
|
|
|
Rank: Advanced Member
Groups: Registered
Joined: 1/6/2014(UTC) Posts: 38 Location: Seattle, WA
Was thanked: 1 time(s) in 1 post(s)
|
I should also mention that I'm restarting Windows nightly at midnight using the Task Scheduler with a *.bat file as detailed in this thread: https://social.technet.m...dows-7?forum=w7itproperfAfter restart, vMix loads and then the *.vbs script runs, starting streaming.
|
|
|
|
Rank: Advanced Member
Groups: Registered
Joined: 1/6/2014(UTC) Posts: 38 Location: Seattle, WA
Was thanked: 1 time(s) in 1 post(s)
|
Following up on this in case anyone else tries the same solution...
Occasionally, I would get errors when the script tries to start streaming. Martin looked at the error log and determined that I needed to wait longer after vMix loads, since the video card had not yet fully loaded. So I increased the Wscript.Sleep value from 20000 (20 sec) to 180000 (180 sec = 3 minutes) and am no longer having errors.
|
|
|
|
Rank: Advanced Member
Groups: Registered
Joined: 10/30/2013(UTC) Posts: 290 Location: The Netherlands
Thanks: 6 times Was thanked: 21 time(s) in 15 post(s)
|
Is there in the meantime a more simple way to auto start streaming without (name sensitive) scripts?
|
|
|
|
Rank: Advanced Member
Groups: Registered
Joined: 9/2/2014(UTC) Posts: 91 Location: Washington
Thanks: 18 times Was thanked: 2 time(s) in 2 post(s)
|
Rehan wrote:In case wwdv's suggestion doesn't work: This is a Windows shell script (start-streaming.vbs) that I use to automate FMLE (the full program, not the FMLEcmd command-line executable used by vMix): Code:Set WshShell = WScript.CreateObject("WScript.Shell")
WshShell.Exec("C:\Program Files (x86)\Adobe\Flash Media Live Encoder 3.2\FlashMediaLiveEncoder.exe")
'Give FME time to load
WScript.Sleep 8000 'milliseconds to wait
WshShell.AppActivate "Adobe Flash Media Live Encoder"
WshShell.SendKeys "{ENTER}" 'Start encoding
Set WshShell = nothing
...but using the FMLE program requires the External output, so you probably don't want that. But you can do something similar with vMix... Create a new keyboard shortcut in the vMix settings to perform the "StartStreaming" function, and create a Windows Shell script with the SendKeys command to 'press' that key to start streaming. A wait of a few seconds to let vMix load first would also be a good idea. You can put a shortcut to that script file in your Startup folder. thank you for this
|
|
|
|
Rank: Advanced Member
Groups: Registered
Joined: 10/30/2013(UTC) Posts: 290 Location: The Netherlands
Thanks: 6 times Was thanked: 21 time(s) in 15 post(s)
|
The problem with the external FMLEcmd.exe is that is doesn't stop when vMix is closed. Using a StartStreaming shortcut and a script to autostart streaming is not always working: When vmix is started is is on top, but it is not always the active window, then the shortcut script doesn't work. Start http://127.0.0.1:8088/api/?Function=StartStreaming from a batchfile does work when vMix is not on top , but always opens the browser. Can someone write a script for me that checks or vMix is ready and then sends the StartStreaming url without opening the browser?
|
|
|
|
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