Icecast Streaming Media Server Forum Index Icecast Streaming Media Server
Icecast is a Xiph Foundation Project
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

transcoding questions

 
Post new topic   Reply to topic    Icecast Streaming Media Server Forum Index -> Icecast Server
View previous topic :: View next topic  
Author Message
cookiesunshinex



Joined: 27 Dec 2008
Posts: 18

PostPosted: Sun Jan 04, 2009 7:58 pm    Post subject: transcoding questions Reply with quote

My desired result:

1 source client streaming 128k MP3 to a mount called stream

Have the ability to allow listeners to listen to 128k MP3 stream or 64k MP3 stream.

After alot of reading on this and other forums, I realize that I need to transcode the original 128k MP3 stream to 64k MP3 stream.

First I realize that icecast does not handle transcoding.
Secondly, I realize that I must define a second mount (let's call it stream64).

I want to run the transcoder on my CentOS 4.7 server.
After reading the Icecast manual, I see that I can use the two commands to initiate a transcode script
<on-connect>/home/icecast/bin/source-start</on-connect>
<on-disconnect>/home/icecast/bin/source-end</on-disconnect>

It looks like I have two options for the actual transcoding:

Option 1: user Stream Transcoder V3 - http://www.oddsock.org/tools/streamtranscoderv3/

Question 1: I could not find any install instructions for Stream Transcoder. Can anyone point me in the right direction?

Option 2: user ffmpeg binary.

Question 2: If I use ffmpeg I know by reading the man pages that I can use this command to convert a normal mp3 file to 64k
ffmpeg -i filename.mp3 -ab 64 filename64.mp3

How can I handle capturing the stream and then transcoding that back to the mountpoint?

Question 3: As far as server resources, which would require less overhead to do the transcoding? ffmpeg or streamtranscoder3?

Question 4: Is it possible to transcode my fallback mount? If so, can I assume that the process to transcode would be the same as the primary mount?
Back to top
View user's profile Send private message
karlH
Code Warrior
Code Warrior


Joined: 13 Jun 2005
Posts: 5476
Location: UK

PostPosted: Sun Jan 04, 2009 8:22 pm    Post subject: Reply with quote

You can use the on-connect or the auth url mount add option to start off a transcoder process.

1. Streamtranscoder is not provided by us, check the oddsock site.

2. you may be able to chain the commands together, look at wget/curl and ezstream.

3. I doubt there is any difference. The main resource usage would be in the encoding and both will be the same I guess.

4. icecast does not care how the content was created as long as it comes in at a steady rate. As long as it is valid then it can be a fallback mount. obviously if the main feed goes down then the fallback will as well.

karl.
Back to top
View user's profile Send private message Send e-mail Visit poster's website
cookiesunshinex



Joined: 27 Dec 2008
Posts: 18

PostPosted: Mon Jan 05, 2009 6:18 am    Post subject: Reply with quote

I just realized that my original post may not have been clear.

My source client exists on a Mac PC using Nicecast (for example). There is no way to transcode with Nicecast.

So I wanted to figure out a way to transcode on the server.

Since my original post I have found a couple other options which are linux binaries:
vlc
transcode (though may only work for video)

I'm wondering what other people out there are using for server side transcoding.

Any examples would be great.

If understand your answer in number 2 correctly, that means that I need to take the http stream with some like wget/curl and input that into another command, ezstream, or possibly alternatively ffmpeg, vlc, transcode, and the output would be a transcoded http stream to the stream64 mount.

Am I on the right path?
Back to top
View user's profile Send private message
EvilOverlord
Forum Admin
Forum Admin


Joined: 12 Jun 2005
Posts: 173
Location: Isle of Man

PostPosted: Tue Jan 13, 2009 5:26 pm    Post subject: Reply with quote



As you can see in the above image, icecast just distributes the stream, hence transcoding is not a feature it gets involved with.

However as karl has said, you can use streamTranscoder, which you can run on the same machine as icecast. (there is a commandline version) The stream flow is then thus:

source client -> icecast(stream) -> streamTranscoder -> icecast(stream64) -> listener client

http://www.oddsock.org/tools/streamTranscoder/
Back to top
View user's profile Send private message Visit poster's website
cookiesunshinex



Joined: 27 Dec 2008
Posts: 18

PostPosted: Tue Jan 13, 2009 10:30 pm    Post subject: Reply with quote

I fully understood that diagram before posting.

In the end, the best way to achieve my goal seems to be streamtranscoder running on the linux box where my icecast2 server is running.

there doesn't seem to be any install instructions for streamtranscoder, but that's not really of anyone's matter here.
Back to top
View user's profile Send private message
iunderwood



Joined: 23 Aug 2008
Posts: 114
Location: Leicester, MA

PostPosted: Fri Jan 16, 2009 5:29 pm    Post subject: Reply with quote

StreamTranscoder has been nothing short of awesome for me.

Granted, I'm running it on Win2k3, but it's churning out 6 different bitrates from a 128k Ogg stream. Smile It does need a restart sometimes, but I haven't fleshed it out too much.
_________________
++I;
Back to top
View user's profile Send private message
newb0rn



Joined: 04 Feb 2009
Posts: 6

PostPosted: Wed Feb 04, 2009 1:04 am    Post subject: Reply with quote

i've been playing around with vlc this evening trying to get it to connect/not overrun/error... Not happening for me so far, but then these things always take a bit of time..

I have been prompted into looking into vlc though because of the experience ive had with streamtranscoder.. I've found that it appears to use a large amount of cpu, often spiking quite wildly.

I was running 2 x mp3 64k and 2 x -1 ogg (around 48kbps). My VPS host ended up limiting my cpu share until i got rid of a pair of them.

I noticed my website was running rather slow of late and have correlated it to the streamtranscoder ripping into the CPU. I'm not sure if its just my centos box, but streamtranscoder does not seem to work efficiently for me.
Back to top
View user's profile Send private message
karlH
Code Warrior
Code Warrior


Joined: 13 Jun 2005
Posts: 5476
Location: UK

PostPosted: Wed Feb 04, 2009 1:13 am    Post subject: Reply with quote

you are better off reporting issues with stream transcoder to the forums at oddsock.org

karl
Back to top
View user's profile Send private message Send e-mail Visit poster's website
newb0rn



Joined: 04 Feb 2009
Posts: 6

PostPosted: Wed Feb 04, 2009 1:46 am    Post subject: Reply with quote

Last time I looked in that forum posts were not getting much attention and given its no longer in development I wouldnt expect much support. Not really having a moan about it, just passing my experience of it onto the OP.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Icecast Streaming Media Server Forum Index -> Icecast Server All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2002 phpBB Group
subRebel style by ktauber