Setting up for Real Audio

Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #1994
    Anonymous
    Inactive

    I’m trying to figure out how to set FireFly up to transcode rtsp streams with mplayer so that I can listen to the BBC.

    This looks possible but I’m getting a little confused.

    It looks like url files contain (a single) radio link and that these get put into the database as a file with a null codec.

    There does not seem to be a distinction between files that represent playlists and files that are actually content in the plug in structure for FireFly.

    It would be nice to be able to handle playlists via the plug in structure so that a RAM file could just return the URL of the stream it is pointing to.

    Also there seems not to be a distinction between a file and a stream. A stream having a transport and a codec whereas a file is just read from a filesystem (a sort of transport) and just has a codec. It would be good to split handling URIs into transport and then filetype. And filetype further into content and playlist. A plugin could then register for one or some combination of these. One would be better but a combination would allow plugging holes in support for certain streams. e.g. pass rtsp/ra to mplayer.

    At present it seems that I need a transcoder that will preload the ram file.

    I’m just trying to understand this so take any of the above as coming from a complete neophyte!

    Thanks

    #14940
    Anonymous
    Inactive

    OK. I have modified mt-daapd-sc.sh to call mplayer. I was initially stumped by the lack of /dev/fd devices but then found a modified version of mplayer in SSODS which writes to stdout. And …… it doesn’t work. This is the snippet out of my mt-daapd-sc.sh.


    MP_GENOPT="-really-quiet -vc null -vo null -bandwidth 10000000 -cache 128"
    MP_FLTROPT="-af volume=0,resample=44100:0:1,channels=2"
    MP_DEVOPT="-ao pcm:waveheader:file=-"

    ram_file() {
    rtspurl=$($CURL $(cat "$FILE")) 2> /tmp/test1.txt
    echo "url=${rtspurl} offset=${2} len=${3}" > /tmp/test.txt
    echo "$MPLAYER $MP_GENOPT $MP_FLTROPT $MP_DEVOPT" > /tmp/test3.txt
    ${MPLAYER} ${MP_GENOPT} ${MP_FLTROPT} ${MP_DEVOPT} "$rtspurl" 2> /tmp/test2.txt | $WAVSTREAMER -o 0 -l 10000
    }

    mplayer launches and starts to download the stream but exits quite quickly. I guess the forward pipe must get closed. I’ve tried with and without wavstreamer and with and with wav headers but what is above was what I expected to work.

    I’m getting a bad header error from wavstreamer and a hung process.

    Any ideas? I think I’m pretty close.

    I’m playing on a Roku M1000.

    Thanks[/code]

    #14941
    Anonymous
    Inactive

    I can use the same mplayer command and redirect stdout to a wav file, scan and then play it via FireFly!

    #14942
    rpedde
    Participant

    @sousoux wrote:

    I can use the same mplayer command and redirect stdout to a wav file, scan and then play it via FireFly!

    I think the (imho) righter way to do that is to make a dummy .url file and point it to a web service that transcodes the file.

    Like, make a cgi on a webserver that does the transcoding, and then point the url file to that.

    It’s probably possible to abuse firefly to do it, but it’s really fundamentally not set up for streaming. Just to serve files.

    #14943
    Anonymous
    Inactive

    @rpedde wrote:

    I think the (imho) righter way to do that is to make a dummy .url file and point it to a web service that transcodes the file.

    Like, make a cgi on a webserver that does the transcoding, and then point the url file to that.

    It’s probably possible to abuse firefly to do it, but it’s really fundamentally not set up for streaming. Just to serve files.

    That’s like putting a red cape in front of a bull. 🙂 Thanks for the feedback!

    #14944
    Gday21
    Participant

    Hi I would be interested in knowing how far you have got with this development?
    As I have just bought a Roku only to find it doesn’t support the BBC Radio 4 outside the UK. So the only way I can see it working is to do as you are suggesting. As it’s available quite readily as a Real Player feed.
    Unfortunately I am completely a novice w.r.t. Firefly and Roku and still haven’t found out how to even create a Radio file on the Firefly never mind transcode it.
    So I would be interested in any feedback in your project.

    Rgds

    Gday

    NSLU2/MacBook Pro/ Roku

    #14945
    Anonymous
    Inactive

    I have it working -ish!

    Not really ready for prime time. It’s got delayed due to work and xmas. I’ll try to post something in January.

Viewing 7 posts - 1 through 7 (of 7 total)
  • The forum ‘Feature Requests’ is closed to new topics and replies.