Record audio from microphone in a separate file?

Daedro

New Member
Hi, OBS!)

I think, this will be very useful for further video editing for example in sony vegas. For now i have to use another audio recording software(unnecessary costs little CPU %) and sometimes that's can be uncomfortable. Plus, everytime i have to manually sync recorded mic with video, and that costs some time. Ideal realisation in Bandicam, there is all-what-need options for audio record.

sorry if my english bad. And thanks for listening :)
 

Lain

Forum Admin
Lain
Forum Moderator
Developer
Commonly requested feature. We'll try to do this in the rewrite via filters (I think, I haven't decided), but it's doable to some extent. I have to take it in to consideration just because of the frequency that people request it, though I can't guarantee it'll be any time soon.
 
Isn't it possible in this version, with some neat "hack?

I tried implementing it myself, but as i got no programming skills to talk of, it didn't go to well.

But i was looking at the buffers, as i understand in, Desktop and Mic goes into a buffer (byte array or something i guess?), and then you mix them somehow.

Now when mixing, shouldn't it be possible to just tell it to write the Mic buffer into a file, and keep appending to it?

I am not sure how to write the Wave header and such, but if you can just write the actually "Wave data", the audio is there.

Code:
            for (UINT i=0; i<auxAudioSources.Num(); i++) {
                float *auxBuffer;

                if(auxAudioSources[i]->GetBuffer(&auxBuffer, timestamp))
                    MixAudio(mixBuffer.Array(), auxBuffer, audioSampleSize*2, false);
            }


It's pretty much here, if you could just save the auxBuffer and keep appending it.
 
https://www.sendspace.com/file/hy3iso

Here is a version that does what you probably expect.

It saved a PCM 16bit (Left Channel) from your Microphone in the same directory as your Recording, they should also be in sync, haven't done any thorough testing on this though.

(If anyone uses/test this, plz give me feedback).
 

Acecool

New Member
I'd love this as well, but with a twist. In the area of buttons to preview / start, a new button to start recording audio only ( for microphone / speakers with the audio options still valid to turn on / off each channel ) and have it saved in audio format.

The feature to save video and audio into separate files would save a step for many people who compile videos from different angles use one good audio source and skip to other videos without needing to separate the audio manually.

So, with this in mind, I think a downarrow / dropdown button could be added beside the Start Recording ( whereby clicking Start Recording would serve the normal purpose ) and when clicked would open a menu including: With Audio/Video Saved Separately ( if in file-mode ), Audio Only ( if in file-mode, or streaming -- audio streaming sites?? do they exist? )

Something like this ( Quick MSPaint Edit and Arial 7 as font... ):
obs_start_recording_options_dropdown.png


The important thing is the dropdown.. It could work one of two ways... 1) When you click on the option it performs that action and doesn't change the button name / default feature. Or 2) When you select the option, the button updates; clicking the button then performs that action.
 
@eN-t, problem is that my solution isn't perfect. It can go out of sync with the Video. As i record it at quite a bad way:S
Pretty sure it can go out of sync in both the offset (meaning when both starts), and if something happens while recording, as i am pretty sure my way does not use the inbuilt Sync Correction.

It should be fairly easy for a real developer to implement when they have time though. As it's basically just copying data, and instead of sending it to the FLV/MP4 file, send it to a separate WAV file as well (or AAC as you can pretty much just copy any data).
 
Top