View Full Version : Flash wrapper to allow daemon on Web access

2007-08-11, 16:32
Sorry for the cryptic title line…

Here's the story: I use a Slimbox for my main player, but I also have a server in my office so that I can access my music from anywhere with a Net connection. I've had occasional probs with both Softsqueeze and mp3 players (ie, iTunes) hiccuping and not working flawlessly in coordination with the browser controls.

Today while doing some Web authoring, I noticed some code—evidently it's pretty common—that uses Flash to embed an mp3 player in a Web page. I experimented by generating a Web page with that code, then using it to control my music. Voilà! It worked well, tho' Firefox was working pretty hard.

I'm not a sophisticated coder, but I can't imagine that'd be too hard for someone to build a skin with that sort of code so that a user could essentially turn a player daemon off and on via the browser interface to the server. WTH?—perhaps a bit of javascript could sense whether "Play" is bolded and control the Flash embed automatically. I tried to do the more simple approach by squirting a snippet into the Handheld status.html page, but no luck.

What do you more-expert-than-I ppl think? I realize that the cognoscienti of the Web spurn Flash, but this might be a [rare] useful deployment of it—provided Flash acts merely as a wrapper and doesn't degrade audio quality, of course.

Your thoughts?

2007-08-12, 19:08
I don't think I have successfully parsed your question. "Player daemon"? But I'll mention a little I know about Flash.

Without special server software (Adobe sells it, but there are open source projects as well), Flash doesn't really stream music. It does progressive download. It can do a great job at playing a single mp3 file (or a sequence of them, for that matter), but without server support or some tricky Flash programming (quite tricky, I believe) it probably wouldn't work on SlimServer's stream.mp3 (part of the problem being that stream.mp3 isn't really rate-limited...not sure how well it would work if it were).

It's fairly easy to communicate with a Flash app via javascript, so all sorts of control scenarios are possible.

If I ever manage to update slimfx, I would like to include functionality to play music in the browser, making use of the download link per track and managing the playlists in the client code. (I got started on some of this, but put it aside a while ago and haven't managed to pick it up again).