'Splitting two channels of a WAV file into separate stereo files using ffmpeg

When activating RAW audio on a GoPro camera, you will get a WAV file with 4 channels. Channels 1 and two are the left and the right channel of the audio. Actually, I have no idea what channels 3 and 4 are doing. For me they are empty. Now I want to have the channels 1 and 2 as dedicated WAV files even turned into a stereo format. At the moment I achieved this with a two-step process using the ffmpeg command line tool like: Splitting the channels into separate files

ffmpeg -y -i source.wav -c pcm_s32le -filter_complex 'channelsplit=channel_layout=4.0[C1][C2][C3][C4]' -map '[C1]' channel1.wav -c pcm_s32le -map '[C2]' channel2.wav -map '[C3]' channel3.wav -map '[C4]' channel4.wav

and then convert the mono files into stereo

ffmpeg -y -i channel1.wav -c pcm_s32le -ac 2 channel1-stereo.wav

My question is now if I can do this in one step and even just ignore the two channels I don't care about?

Right now I need to create temporary files for all four channels and then do a second step to convert the two channels I'm interested in into stereo.



Solution 1:[1]

Probably You should do This:

@Html.TextBoxFor(model => model.Price, new { type = number } )

If You are using MVC- 1.5 or higher you dont need to use htmlAttributes, but you should change the type of input value for the textBoxFor cause its always a string that you are passing to your int parameter

Solution 2:[2]

There is a bug in the code. The view uses a model

@model PharmaProj.Models.Product

but you submit Product from view to the action where Purchace is an input parameter

[HttpPost]
 public ActionResult PurchaseProd(Purchase po)

you have to decide what to use Product or Purchase

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Leandro Toloza
Solution 2 Serge