If you want to use a GUI program to do this, then I recommend TAudioConverter by ozok (a member of HA forum). It really is turning out to be THE best GUI tool for these tasks.
---
If you want to do it via command-line . . . .
Using FFMPEG.EXE to extract raw audio stream from video file without re-encoding:
First we determine the exact audio type in the video file, so we run this command-line:
==> ffmpeg.exe -i "Talk Talk Live at Montreux 1986.mp4"
FFMPEG reports this to the console:
Metadata:
major_brand : mp42
minor_version : 0
compatible_brands: isommp42
creation_time : 2014-03-07 19:37:29
Duration: 01:26:49.61, start: 0.000000, bitrate: 510 kb/s
Stream #0:0(und): Video: h264 (Constrained Baseline) (avc1 / 0x31637661), yuv420p, 480x360 [SAR 1:1 DAR 4:3], 412 kb/s, 25 fps, 25 tbr, 25 tbn, 50 tbc
Metadata:
handler_name : VideoHandler
Stream #0:1(und): Audio: aac (mp4a / 0x6134706D), 44100 Hz, stereo, fltp, 95kb/s
Metadata:
creation_time : 2014-03-07 19:38:55
handler_name : IsoMedia File Produced by Google, 5-11-2011
At least one output file must be specified
The audio is aac, so now can we run our extraction command:
==> ffmpeg.exe -i "Talk Talk Live at Montreux 1986.mp4" -vn -acodec copy "Talk Talk Live at Montreux 1986.aac"
---
I'm not 100% sure about this, but I have a feeling you can set up foobar2000 converter to run that FFMPEG command-line.
You could forget about determining the file-type and just have all output renamed to "some filename.xxx".
Unfortunately, it seems foobar2000 has some missing playback functionality whereby it will not guess if a file is a playable audio file no matter what the file extension.
If I drag a AAC file renamed as "Talk Talk Live at Montreux 1986.xxx" into VLC Media Player, it WILL start playing.
If I drag a AAC file renamed as "Talk Talk Live at Montreux 1986.xxx" into foobar2000, it WILL NOT start playing and foobar2000 error window pops up.
I am wondering if there is a way to configure foobar2000 to guess and play a file if it has unknown file extension and is a playable audio file.
Does anyone here have more info on this?