Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: NeroAacEnc for livestreams (Read 13666 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

NeroAacEnc for livestreams

Hi, I'm running a webradio and I was using aacplusenc as an external encoder to crreate AAC streams.
Since NeroAacEnc is supposed to be superior in quality, and supports ABR streams, I'd like to use that.
Problem is, NeroAacEnc encapsulates the AAC+ data into an MP4 container, which is unsuitable for streaming.

Since I'd use it as external encoder, that reads and writes into pipes, I make NeroAacEnc write to /dev/stdout. I'm struggling to find a solution, how to get the data out of the MP4 container, while streaming live, maybe even encapsulating it in a MPEG2 container, so I can feed a streaming server with that data.

Does anybody know a trick how to do this?
I stumbled upon mpeg4ip which is so old (1997) that the code won't compile, I'm debugging it, so maybe I could use it to extract the AAC stream from the MP4 container on the fly.

Anyway, it would be nice to have an option in NeroAacEnc to inhibit it from putting the AAC stream into the MP4 container and write to STDOUT.

External encoders/decoders work with pipes when used in my radio software.

I f you happen to know anything that might be helpful, please answer!

NeroAacEnc for livestreams

Reply #1
I think mp4box can export raw aac streams out of MP4.
Just out of curiosity. Can you give more details about your setup?
Is it on windows? How are you feeding files to encode etc?

NeroAacEnc for livestreams

Reply #2
I think mp4box can export raw aac streams out of MP4.
Just out of curiosity. Can you give more details about your setup?
Is it on windows? How are you feeding files to encode etc?


No, it is a Linux system running Ubuntu Server 8.10. I'm using Liquidsoap as radio software, of which i do some programming here and there.
If you like to take a look at my configuration: http://pastie.org/pastes/373729
This configuration is a the older setup, where I'm using aacplusenc as encoder.

My stream server is the latest SVN-built Icecast2.

As you can see in my Liquidsoap config, I use external encoders to genereate AAC+ streams, which are then fed into Icecast2.
Moreover, the external encder uses pipes to read the PCM stream and output the AAC+ stream.

NeroAacEnc doesn't support this out of the box, I tried to trick it by writing to /dev/stdout, but since the MP4 container isn't streamable anyway, only garbage comes out.

Also, since libshout doesn't support audio/aacp, I had to patch it. Patches are available on the savonet site, where Liquidsoap is being developed.

NeroAacEnc for livestreams

Reply #3
Indeed, this is not possible with the current version. We'll have to think about a solution for this, one would be to output ADTS streams, optionally.

NeroAacEnc for livestreams

Reply #4
I would appreciate an option where I could choose the container format. MP2 / MP4 would be nice. Raw AAC data would be OK as well.

NeroAacEnc for livestreams

Reply #5
I am amazed. This seems to be a briliant setup. Perhaps I'm going to listen to your stream if it's publicly available before trying to set something up for my-self.
Thanks for the pointers.

BTW I'd appreciate generation of raw aac streams as well.

NeroAacEnc for livestreams

Reply #6
I'd like to add my support and request for generation of raw AAC streams out of this encoder. 

I've found the neroAacEnc encoder to work best for me on a Linux platform running Ampache to stream audio to both iPhone and Android phones using HE-AAC v2 at bitrates around 24kbps and as low as 16kbps.  This works astoundingly well where I live, an area served only by GPRS (no EDGE or 3G)!

Problem is that Ampache wants to stream raw AAC.  The Nero encoder insists on encapsulating in an MP4 container, no exceptions.

My ugly hack has been to encapsulate the encoder in a bash shell script, and inside, allow neroAacEnc to fully transcode into a temporary MP4 file, then "cat" out this file (containing the encapsulated AAC data, with the MP4 headers stripped) to stdout.  This results in a streaming delay that lasts as long as it takes neroAacEnc to complete the transcode process, usually around 15-30 seconds.

It'd be MUCH appreciated...

NeroAacEnc for livestreams

Reply #7
for windows systems you can use qaac...
_

NeroAacEnc for livestreams

Reply #8
for windows systems you can use qaac...


Are you the author of this? What is the benefit over the original qtaacenc? Why was it necessary to fork instead of providing upstream patches?

PS I don't want to start an off-topic discussion. I'm just interested in a brief statement.

 

NeroAacEnc for livestreams

Reply #9
Quote
Are you the author of this?


nope...

Quote
What is the benefit over the original qtaacenc?


related to this topic:
Quote
As for AAC, ADTS output is also supported
and to stdout too!!!

unrelated:
Quote
Encodes as AAC-LC / AAC-HE / ALAC into standard ISO MP4 container.
and
Quote
Can process multiple input files, wild card can be used.

_

NeroAacEnc for livestreams

Reply #10
I just registered to ask if the ADTS output format has been implemented, in order to use neroAacEnc to encode live audio streams?

NeroAacEnc for livestreams

Reply #11
I just registered to ask if the ADTS output format has been implemented, in order to use neroAacEnc to encode live audio streams?

No, not to my knowledge.

In fact, there haven't been any updates to NeroAacEnc lately. I'm not even sure, if the project is still maintained.

As for offline encoding of AAC streams, I gave up on NeroAAC and switched to using qtaacenc.exe in a virtualized Windows. Online (on-the-fly) encoding isn't done anymore. Since there is no practical way of encoding into streaming AAC, it makes no sense providing one. Except, I switched to other means of high quality audio encoding.

NeroAacEnc for livestreams

Reply #12
Since there is no practical way of encoding into streaming AAC, it makes no sense providing one. Except, I switched to other means of high quality audio encoding.


What do you mean by this? Are you saying its not possible to stream live audio with AAC (using for example flv container with global headers) or I missunderstood something?