View Full Version : AAC to Ogg Vorbis Question (complicated possibly)
Ram
11th February 2005, 21:38
I am reencoding some MKV files into OGM files (trivia but a little background might help). The person seems to have done a single pass encoding so I wanted to reencode them to get the size consistant. The other problem I've run into with these files is they used AAC to encode them. I've fetched the decoder's and registered them on my machine but the audio format is not recognized. I've fetched foobar2000 and it complains "Missing ACM codec". :rolleyes:
Using virtual dub as the demuxer It states the streams are A_AAC/MPEG4/LC/SBR. I saved them as WAV files foor foobar2000 then droped the files into the gui. Next I right clicked on the file selected convert->Run Conversion then used WAV (PCM, fixed point) clicked OK and selected another destination directory and clicked OK then I recieved the notification I was missing a codec. So.. suggestions are welcome I just want to convert these to something BeSweet can process and make them Ogg so I can play them back on XINE on my Linux box. I downloaded FAAC compiled etc., but it appears to be only an encoder.
I've :readfaq: above :search: etc. I've attempted to use FAAD to decode the raw files to wav. These AAC streams will not play on my machine either. Other's have not had the expressed trouble I have. VirtualDubMod registers it as an 'unknown wave format' with the ID I mentioned above. So.. What can I do here? I can't play the files obviously I don't seem to be able to decode them no matter what codec I fetch or what tool I use. Demuxing the files out does no good either. Clues maybe?
Ram
stephanV
11th February 2005, 21:50
I'm not sure you why would want to convert a MKV to OGM... but if you want to extract aac from MKV use MKVToolnix or AVIMux GUI, not VDM.
bond
12th February 2005, 04:38
ogm can store aac, no need to reencode
1) mux the raw .aac into .mp4 with mp4box by using the -sbr switch!
2) install 3ivx, tobias ogm filters (oggds) and graphedit
3) open the .mp4 in graphedit and connect the 3ivx splitter to the ogg muxer and push play
4) that should have muxed the aac into ogm
Ram
14th February 2005, 18:25
Originally posted by stephanV
I'm not sure you why would want to convert a MKV to OGM... but if you want to extract aac from MKV use MKVToolnix or AVIMux GUI, not VDM. Hmmm Ok I finished redoing the audio files. I demuxed the MKV using mkvtoolnix and then reencoded the AAC files to Vorbis. (Using foobar2000 to make them WAV and then BeSweet to make them Ogg) I am not thrilled with AAC files to be brutally honest. It's great to have nice compression etc. however they seem to create complicated problems if you don't download 6 different packages just to play something with them in it as a stream. (that's not a joke) at least Vorbis plays nice with only 2 things to configure. Sigh. Anyhow I've successfully reencoded and repackaged the files in OGM format (cleaned the tags up).
What would be nice is if someone produced a tool to convert OGM files to Theora or if the people messing with Theora and there new video container format allowed for OGM compatibility. Of course converting 100 disks worth of data and rewritting those disks would be a real pain and that's the problem with abandoning OGM is going to create. A lot of people have OGM files. Well I do. MKV seems to be a bit difficult and I have had nothing but trouble with the container format, even though it's been around for about a year.
Additiona by Bond
1) mux the raw .aac into .mp4 with mp4box by using the -sbr switch!
2) install 3ivx, tobias ogm filters (oggds) and graphedit
3) open the .mp4 in graphedit and connect the 3ivx splitter to the ogg muxer and push play
4) that should have muxed the aac into ogm
I've not been able to use AAC files properly (or play them I should say) on my Linux box. I would also rather not use a proprietary patented format. The windows box doesn't like AAC either but I finally got it to play them.
My only problem is the music has the sound of a slight variation in pitch speed. It sounds like a record going to slow then too fast. Considering I professionally run sound I suppose most wouldn't notice the variation in speed. This likely a result of reencoding or was it there to begin with? The speech sounds correct the interesting thing is.
Ram
stephanV
14th February 2005, 19:06
Originally posted by Ram
What would be nice is if someone produced a tool to convert OGM files to Theora or if the people messing with Theora and there new video container format allowed for OGM compatibility. Of course converting 100 disks worth of data and rewritting those disks would be a real pain and that's the problem with abandoning OGM is going to create. A lot of people have OGM files. Well I do.
OGM is a fork of Ogg, not the other way around. :p
But I don't see how abondoning OGM will create problems, the filters are still there and most prgrams just keep on supporting it. Radlight even works on a new splitter for it. People who keep on insisting on using OGM might be a problem though. :p
MKV seems to be a bit difficult and I have had nothing but trouble with the container format, even though it's been around for about a year.
So you're re-encoding because you have playback troubles??? That's about the worst thing you could do. Solve your playback problems... if you dont know how, ask. MKV with AAC on linux? Use VLC player. :)
Ram
14th February 2005, 21:25
Originally posted by stephanV
OGM is a fork of Ogg, not the other way around. :p
Yes I am aware of that, I've been working on GUI tools to work with OGM tools. I don't see why it should be abandoned yet though. I noticed that the mkvextract tool is confusing. It displays a help message if you don't explicitly specify the tracks to demux from the MKV, instead of choosing default names. Looks like I need to extract the stream information from the MKV file and make a little tool to name to streams or use some default stream names 'automagically' passed to the extract program. I have YET to get OGMmerge to work right (LOL).
Originally posted by stephanV
But I don't see how abondoning OGM will create problems, the filters are still there and most prgrams just keep on supporting it. Radlight even works on a new splitter for it. People who keep on insisting on using OGM might be a problem though. :pAs matter of fact I kind of like how it works. :) I understand the reasoning behind MKV but for some reason the format is difficult at best to deal with. I do like the fact you don't have to scan the whole bleeding file to find the information in the file (LOL).
Originally posted by stephanV
So you're re-encoding because you have playback troubles??? That's about the worst thing you could do. Solve your playback problems... if you dont know how, ask. MKV with AAC on linux? Use VLC player. :) More than just playback troubles, MKV seems to destablize the system for windows and is NOW unsupported by Xine. It plays but unhappily under windows, if the files in it were Ogg or normal MP3 low bit rate files, it probably wouldn't be a problem. I've not had too much trouble with MKV since I started testing them and if they start acting odd I just repackage them. As for AAC it's anoying and pattented. I'm not one to use patented technology that's software. I don't agree with that thus I won't use it so I reencoded them. Other than it being a bit of a pain, I spent a bit of time looking through how to deal with AAC data and learned a few things about MKV and OGM so it's all good. hehehe
In order to use many other Linux/Unix based players I have to rebuild GTK on my machine. That will take a few days probably. I think I am going to switch to another distribution than 'la pathetique' Mandrake. I won't get into why :) lets just say they made some very poor choices in my opinion. I think Slackware (which is what I use to run since 1995) is actually easier to deal with than Mandrake (sigh).
Ram
stephanV
14th February 2005, 21:55
Originally posted by Ram
As matter of fact I kind of like how it works. :) I understand the reasoning behind MKV but for some reason the format is difficult at best to deal with. (..)
More than just playback troubles, MKV seems to destablize the system for windows and is NOW unsupported by Xine. It plays but unhappily under windows,
I dont see that happening, besides sometimes a issue with WMP (your not using that though i think)
As for AAC it's anoying and pattented. I'm not one to use patented technology that's software. I don't agree with that thus I won't use it so I reencoded them.
You still used patented technology to decode the files, so youre screwed eiter way :p
Do you use MPEG4 video BTW? :p
(it also makes me wonder where you get the files from... but nevermind :p)
Ram
14th February 2005, 23:00
Originally posted by stephanV
I dont see that happening, besides sometimes a issue with WMP (your not using that though i think)
I don't use Windows Media player, although I attempted as well, however it was fruitless even when I had things set up correctly. BSplayer works OK for OGM and MKV files as long as you don't use AAC. Windows media player simply won't recognize the ID tags in an AVI or MKV file. I get the evil "We can't find something to decode this tough luck" message from it. Hehehehe.
Originally posted by stephanV
You still used patented technology to decode the files, so youre screwed eiter way :p
Do you use MPEG4 video BTW? :p
(it also makes me wonder where you get the files from... but nevermind :p) Yeah life's tough that way isn't it? H263 video ;) hehehehe. I'm aware of the various things that are out there. I think more will be encoded into theora's codec when codecs are available for it. DivX is OK but it again it is patented and requires licensing.
Onto the AAC streams, one thing that bothers me is it says the sample is 22.050Khz however it is scaled to 44.1khz. What's the point of that? Is it a sales gimick? Scaling it won't do any good unless you use a FIR on it and fill with 0's or an IIR filter that doubles the data. The only thing I can think of is to make the audio stream compatible with CD audio. It doesn't gain anything other than loosing even more of the brightness of the audio from 11khz and above. I think I can get the same compression with OGG Vorbis at 44.1khz and the audio sound better.
I also noticed the video has a scaling factor associated with it as well. What's with that? It seems a bit silly. These I believe or related to MKV and the streams that are in the format. Hmmm.
I've not seen what they are using in doing AAC compression but it still is psycho acoustical compression no? All that means is it throws out things you aren't likely to hear because there magnitude is too small and or out of the spectral responsiveness of human hearing. Obviously they aren't using the FFT to do that (that would be really slow and a nightmare to manage IE Amplitude over time to Amplitude over frequency space transform, then there is the real and imaginary data to deal with UGH), hmmm something to examine the FAAC encoder stuff about. I doubt they are doing anything too much more than MP2 audio steam does. I guess I'm now curious, I'll have to look at Vorbis too it seems to get better compression with loosing less of the original audio signal. I can get a 30 minute 44khz file to be around 15M with 0.1 Quality (81kbps) in vorbis. AAC gives me 12.5M file at 22khz and 90kbps. There is a definate descrepency there, and the Ogg just plain sounds better. Hmmm.
Either way they are very asymetric in encoding speed. I wonder if there is a way to get high speed Vorbis with low loss? Say 192ksps with 32bit samples encodes fast, high compression in my case is not the biggest thing but real time compression is. 2 to 4:1 would be adequate for 32bit Digital audio signals being compressed. Off to Theora's site I go!
Ram
stephanV
14th February 2005, 23:41
Originally posted by Ram
I also noticed the video has a scaling factor associated with it as well. What's with that? It seems a bit silly. These I believe or related to MKV and the streams that are in the format. Hmmm.
If you are talking about AR signalling, this makes perfect sense... unless you like people to look like the coneheads.
I've not seen what they are using in doing AAC compression but it still is psycho acoustical compression no? All that means is it throws out things you aren't likely to hear because there magnitude is too small and or out of the spectral responsiveness of human hearing. Obviously they aren't using the FFT to do that (that would be really slow and a nightmare to manage IE Amplitude over time to Amplitude over frequency space transform, then there is the real and imaginary data to deal with UGH), hmmm something to examine the FAAC encoder stuff about. I doubt they are doing anything too much more than MP2 audio steam does.
You're a little bit biased and uninformed about AAC. While in listening tests Vorbis is still better than AAC, AAC is certainly a better standard then MPEG1 layer II.
KpeX
15th February 2005, 16:15
Originally posted by Ram
Onto the AAC streams, one thing that bothers me is it says the sample is 22.050Khz however it is scaled to 44.1khz. What's the point of that? Is it a sales gimick? Scaling it won't do any good unless you use a FIR on it and fill with 0's or an IIR filter that doubles the data. The only thing I can think of is to make the audio stream compatible with CD audio. It doesn't gain anything other than loosing even more of the brightness of the audio from 11khz and above. I think I can get the same compression with OGG Vorbis at 44.1khz and the audio sound better. What you're observing is an HE-AAC stream, one of the most interesting technologies of AAC for low bitrates. HE-AAC uses SBR (spectral band replication) technology to replicate the high frequency range that the base 22.05 khz signal can't sample. See the AAC FAQ in my sig for some more information.
Ram
17th February 2005, 21:09
Originally posted by KpeX
What you're observing is an HE-AAC stream, one of the most interesting technologies of AAC for low bitrates. HE-AAC uses SBR (spectral band replication) technology to replicate the high frequency range that the base 22.05 khz signal can't sample. See the AAC FAQ in my sig for some more information.
Thanks I read that and I hadn't really paid much attention. So essentially they are taking harmonic information from the original signal and recreating the wave shape of the lower frequency wave information via fourier analysis. That's what it looks like. It would also explain why HE is considered 'high complexity', since transforming it that way is VERY time consuming and slow, encoding would take a while as a result (probably 2 or more times longer). The resampling set the data rate necessary to prevent the loss of the added wave shaping, from the Nynqist frequency (at 44.1khz 22.050khz is the maximum possible frequency reproduceable thus parts of the signal would litterally disappear) when reproducing a signal.
SBR is nothing new. Actually it's pretty old, I find it humorous as it looks like they are calling it something new (marketing I guess). They were discusing this sort of thing in the late 80's in relation to signal processing. At that time they simply didn't have the computing power to use it, well they did but it was not cost affective and as another problem they didn't have any of the specific applications that are prevalent now. In otherwords the idea and concept already existed long ago there was just no compelling appplication, let alone cost merit, and therefore no reason for it. It took 15 years to find one, hehehe. The idea of streaming information was just starting to emerge then as well. It makes sense as things take time to 'grow' into a useable idea in reality.
Cyb
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.