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
v_user  
#1 Posted : Friday, April 14, 2017 7:31:10 AM(UTC)
v_user

Rank: Newbie

Groups: Registered
Joined: 4/11/2017(UTC)
Posts: 4

Thanks: 1 times
Hello everyone,
I'm trying to use custom ffmpeg commands through ffmpegformats.xml in recording from a Magewell capture card. It works properly when recording through vmix interface, thus invoking the ffmpeg.exe in vmix installation folder. What about if I wanted to pass the input source (as seen by vMix) to an independent build of ffmpeg in my PC? In particular I would like to exploit the .asf streams created by vMix/ffmpeg i.e. input type

Code:
"C:\\Program Files (x86)\\vMix\\streaming\\ffmpeg.exe" -report -y -f asf -i "\\\\.\\pipe\\--long key here--" etc...


and put the pipe as a source in an independent ffmpeg CLI. What I really want is to avoid the dshow call in my ffmpeg command, due to an issue in recognizing full audio features of my Magewell card as DirectShow audio device.

As you can expect, the input pipe as it is reported in vMix/ffmpeg log file cannot be used after ending the record.
Is there any (hopefully simple...) way to grab the key produced by vMix in the pipe and use it real time in a totally separate ffmpeg command?

Thank you!

DWAM  
#2 Posted : Friday, April 14, 2017 7:40:02 AM(UTC)
DWAM

Rank: Advanced Member

Groups: Registered
Joined: 3/20/2014(UTC)
Posts: 2,721
Man
France
Location: Bordeaux, France

Thanks: 243 times
Was thanked: 794 time(s) in 589 post(s)
Hi and welcome to the vMix forum

I do it easily using the EXTERNAL feature.
Simply activate external (or EXT2 set to any specific input) and use vMixVideo and vMixAudio virtual devices as capture inputs in FFMPEG

Hpe this helps
Guillaume
DWAM  
#3 Posted : Friday, April 14, 2017 7:44:32 AM(UTC)
DWAM

Rank: Advanced Member

Groups: Registered
Joined: 3/20/2014(UTC)
Posts: 2,721
Man
France
Location: Bordeaux, France

Thanks: 243 times
Was thanked: 794 time(s) in 589 post(s)
I have already explained this with many details in this thread:
https://forums.vmix.com/....aspx?g=posts&t=8659

PS : Remember GTX cards only accepts 2 simultaneous encodes. Might need to adapt your script in order to use CPU encoding instead of GPU.
v_user  
#4 Posted : Friday, April 14, 2017 10:15:41 AM(UTC)
v_user

Rank: Newbie

Groups: Registered
Joined: 4/11/2017(UTC)
Posts: 4

Thanks: 1 times
DWAM wrote:
I have already explained this with many details in this thread:
https://forums.vmix.com/....aspx?g=posts&t=8659


Thank you, Guillaume. I've already scrutinized your posts. If I'm not wrong, they help in adapting vMix commands reported in log files, after a recording has been done, that it's what I've just done by myself with success. Moreover the procedure you are kindly recalling involves dshow management of the virtual devices. This can be trivially be done in ffmpeg, directly in CLI and without any intermediate software layer, vMix or whatever. As I wrote, though straightforward, dshow calls are undesiderable for my purposes.
The EXTERNAL feature appears in the User Guide as a way to pilot 3rd party applications such as Adobe Flash Media Live Encoder and Skype: FFmpeg is a medium in that case, not the final application to be piloted. I possibly need this particular use of FFmpeg.

So:
1. How can I intercept the key connected to pipe while recording in vMix (not after)?
2. Can be EXTERNAL used to pass 'something' to an independent (= completely user controlled) FFmpeg CLI?

Thanks again



DWAM  
#5 Posted : Friday, April 14, 2017 10:37:50 AM(UTC)
DWAM

Rank: Advanced Member

Groups: Registered
Joined: 3/20/2014(UTC)
Posts: 2,721
Man
France
Location: Bordeaux, France

Thanks: 243 times
Was thanked: 794 time(s) in 589 post(s)
Maybe I wasn't clear enough...

You can do what I wrote AT THE SAME TIME as vMix records or streams... I use this method to simultaneously stream or record to other destinations or codecs.
I only mentionned the log file as an easy way to get a working sample for commandlines which most people are not familiar with. I suggested to do a small record or stream in order to create a log file with appropriate settings/presets.

Quote:
The EXTERNAL feature appears in the User Guide as a way to pilot 3rd party applications such as Adobe Flash Media Live Encoder and Skype

Or FFMPEG, or VLC or OBS or any other application which accepts audio and video capture (virtual) devices...

Quote:
dshow calls are undesiderable for my purposes

I'd be curious to know why

Quote:
How can I intercept the key connected to pipe while recording in vMix (not after)?

The way I indicated which is not to try to intercept the pipe but rather use EXT or EXT2 virtual devices

Quote:
Can be EXTERNAL used to pass 'something' to an independent (= completely user controlled) FFmpeg CLI?

Yes, this is exactly what I explained

Believe me, just try...

Activate EXTERNAL, configure FFMPEG with vMixAudio and vMixVideo virtual devices as inputs and define your options and destinations.
You can also test with VLC for easier/quicker setting, it works the same way.
vMix virtual devices are seen as any regular capture device.

Guillaume



thanks 1 user thanked DWAM for this useful post.
v_user on 4/14/2017(UTC)
DWAM  
#6 Posted : Friday, April 14, 2017 11:46:03 AM(UTC)
DWAM

Rank: Advanced Member

Groups: Registered
Joined: 3/20/2014(UTC)
Posts: 2,721
Man
France
Location: Bordeaux, France

Thanks: 243 times
Was thanked: 794 time(s) in 589 post(s)
Quote:
What I really want is to avoid the dshow call in my ffmpeg command, due to an issue in recognizing full audio features of my Magewell card as DirectShow audio device.


You won't get this issue with my solution as dshow recognizes perfectly well vMix outs.
v_user  
#7 Posted : Friday, April 14, 2017 11:52:03 AM(UTC)
v_user

Rank: Newbie

Groups: Registered
Joined: 4/11/2017(UTC)
Posts: 4

Thanks: 1 times
Thank you Guillaume, I did manage. I was completely misunderstanding the ability of vMix to create virtual devices for any capturing software, including a process running in ffmpeg CLI at the same time EXTERNAL output is being activated. Your last reply was definitly clarifyng, sorry for my poor insight.
I use it as a workaround for capturing in ffmpeg the audio channel of my Magewell card which is wrongly "seen" by dshow as a 44.1 KHz device (even though with sources at higher sampling rate). So I cannot produce quality capture without resampling audio streams (as an alternative audio capture could be done with Magewell SDK tools, for example, and then remuxed with video, which is a time expensive method).

Hopefully the stream produced by vMix (through EXTERNAL) is not processed at all and so I can simply copy the PCM stream in final output.
Are we sure there is no background processing (i.e. audio resampling) by vMix in launching EXTERNAL feature? (I see in ffmpeg log the correct sample rate but it is the vMix output, while it's the stream entering vMix that I wish investigate...)

Thank you so much
DWAM  
#8 Posted : Friday, April 14, 2017 12:39:38 PM(UTC)
DWAM

Rank: Advanced Member

Groups: Registered
Joined: 3/20/2014(UTC)
Posts: 2,721
Man
France
Location: Bordeaux, France

Thanks: 243 times
Was thanked: 794 time(s) in 589 post(s)
Good! ;o)

Quote:
Are we sure there is no background processing by vMix in launching EXTERNAL feature?

What do you mean here? Sorry it's my turn not to understand! Remember I'm French, english is not my mother tongue.

Background processing? regarding the signal, the image/audio treatment? I think not, it's uncompressed signal, not altered...
But there is background processing in terms of CPU/GPU...
DWAM  
#9 Posted : Friday, April 14, 2017 1:01:05 PM(UTC)
DWAM

Rank: Advanced Member

Groups: Registered
Joined: 3/20/2014(UTC)
Posts: 2,721
Man
France
Location: Bordeaux, France

Thanks: 243 times
Was thanked: 794 time(s) in 589 post(s)
Quote:
Are we sure there is no background processing (i.e. audio resampling) by vMix in launching EXTERNAL feature? (I see in ffmpeg log the correct sample rate but it is the vMix output, while it's the stream entering vMix that I wish investigate...)


Oh I just saw your edit.
I will not answer this point, I prefer Magewell specialists like Martin Kay (Zenvideo) or Tom Sinclair or (obviously) Martin to do it if they see this thread.

My opinion is : it depends on your Magewell card settings and your input and project settings in vMix.

Guillaume
v_user  
#10 Posted : Saturday, April 15, 2017 5:25:32 AM(UTC)
v_user

Rank: Newbie

Groups: Registered
Joined: 4/11/2017(UTC)
Posts: 4

Thanks: 1 times
DWAM wrote:
Quote:
Are we sure there is no background processing (i.e. audio resampling) by vMix in launching EXTERNAL feature? (I see in ffmpeg log the correct sample rate but it is the vMix output, while it's the stream entering vMix that I wish investigate...)


Oh I just saw your edit.
I will not answer this point, I prefer Magewell specialists like Martin Kay (Zenvideo) or Tom Sinclair or (obviously) Martin to do it if they see this thread.

My opinion is : it depends on your Magewell card settings and your input and project settings in vMix.

Guillaume


If vMix developers could tell us how they manage the original MagewellPlugin.dll e LibMWCapture.dll in the installation folder of the application (both are part of Magewell SDK), it would be greatly appreciated!
I have only limited developing skills, but these .dll's would let me assume that Magewell card's audio/video properties are correctly parsed when entering the input layer of vMix. IMHO that is a prerequisite to operate with project settings in vMix.
The question arising is again how is produced the .asf stream (with pipe string reported in post#1).
Thank you for your time and support :-)

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.