0
0

Is it possible to record the final mixed sound output?

Robin

  • You must to post comments
0
0

Hi,

Yes, you can use FMOD_OUTPUTTYPE_WAVWRITER as the output type, this will write the final output to disk as a wav file.

Or, if you want to be able to hear your final sound output as well as record it, you can create a DSP unit that writes its input to disk and add it to the start of the DSP network using System::addDSP().

  • You must to post comments
0
0

[quote="chenpo":3u4cxbne]Hi,

Yes, you can use FMOD_OUTPUTTYPE_WAVWRITER as the output type, this will write the final output to disk as a wav file.

Or, if you want to be able to hear your final sound output as well as record it, you can create a DSP unit that writes its input to disk and add it to the start of the DSP network using System::addDSP().[/quote:3u4cxbne]

Just to be sure. Please can you confirm that 3D sound mixing is available with this output type?

Thanks

Robin

  • You must to post comments
0
0

yes, it will write out a multichannel wav file

  • You must to post comments
0
0

don’t want to annoy for resurrecting this thread, but how do you write the data in the dsp callback to file? i can write just fine in my app based on the recording example, on a sound object, but i am unclear how to extract the data from inbuffer or outbuffer and write that to the file. essentially i need to translate this bit from the record example
[code:2xp79i8i]

/*
Lock the sound to get access to the raw data.
/
sound->lock(lastrecordpos * exinfo.numchannels * 2, blocklength * exinfo.numchannels * 2, &ptr1, &ptr2, &len1, &len2); /
* exinfo.numchannels * 2 = stereo 16bit. 1 sample = 4 bytes. */

/*
Write it to disk.
*/
if (ptr1 && len1)
{
datalength += fwrite(ptr1, 1, len1, fp);
}
if (ptr2 && len2)
{
datalength += fwrite(ptr2, 1, len2, fp);
}

[/code:2xp79i8i]

into the equivalent usage with the buffers, but i really have no clue how. i messed around with some stuff, and got noise in my file, it maybe had some relationship to the source audio, but not really, just noise really.

thanks!

  • You must to post comments
0
0

There is already some advice in this thread http://52.88.2.202/forum/viewtopic.php?t=9533

  • You must to post comments
0
0

thanks for your quick reply!

i had looked at that post, but i don’t get it.

first off, i am using an encapsulation for file writing that wants a const char * as a pointer to the data. in the recordtodisk sample, i simply cast the void * ptr1 to const char * and all is well and good. but in the dsp unit i have a pointer to an array of floats. how can i cast that pointer to const char *, and do i have to iterate and copy into a separate buffer the values actually pointed to?

in other words, how can i take what i get in the dsp callback, and make it essentially equivalent to this:

sound->lock(lastrecordpos * exinfo.numchannels * 2, blocklength * exinfo.numchannels * 2, &ptr1, &ptr2, &len1, &len2);

  • You must to post comments
0
0

hey here is some of my code to help with wav writing, dsp, and spectrum stuff –

[url:30pyb5e2]http://www.fmod.org/forum/viewtopic.php?p=34609[/url:30pyb5e2]

  • You must to post comments
0
0

[quote="chenpo":30pyly3q]Hi,

Yes, you can use FMOD_OUTPUTTYPE_WAVWRITER as the output type, this will write the final output to disk as a wav file.

Or, if you want to be able to hear your final sound output as well as record it, you can create a DSP unit that writes its input to disk and add it to the start of the DSP network using System::addDSP().[/quote:30pyly3q]

Hi Chenpo can you post some line of code to do it? I just have to do this.
Regards,
Franco

  • You must to post comments
0
0

Franco, John already linked to a post with code in it above your post.

  • You must to post comments
Showing 9 results
Your Answer

Please first to submit.