06/06/2005 at 5:33 AM #67rickardGuest
I want to listen to my music on different computers (e.g. at the university) and I can’t install programs on them (most of them run Linux or Solaris so iTunes isn’t even available). The solution I came up with was AppleRecords by Chris Davies. It’s written in Java and is a great companion to mt-daapd. Anyway, I wanted to be able to stream music without having to download and install anything so I modified the program into an applet instead. It’s a one-night hack, it’s ugly, but it works (if there is interest I can polish the code and publish it). Then I got the idea, what if a DAAP client was hosted by the mt-daapd itself (like the VNC server)?
Anyway, is there interest for a web-based DAAP client?
Feel free to contact me if you have some comments.06/06/2005 at 9:54 AM #3355
That’s a really cool idea.
how much did you have to hack it to make it an applet? And are the changes non-intrusive enough that they would be accepted upstream?
I’d be really interested in that.
— Ron06/06/2005 at 11:01 AM #3356rickardGuest
I had to remove large parts of the code (rendezvous stuff, downloading, …) to make the code “applet-safe” (an applet can only connect to the same host as the web server that hosts the applet, and obviously no file writing etc). Basically, the GUI stuff is more or less rewritten while I kept the basic protocol code untouched (they were nicely separated in different packages). I also started looking into adding Ogg Vorbis to it (I like that format 🙂 ).
Here is an example: http://www.petzall.se/daap-applet.png08/06/2005 at 8:26 AM #3357rickardGuest
I managed to find some spare time I don’t have 😉 and put together some kind of GUI for the applet. I have even made a home page for it
Please, anyone try it out if you want, feedback is valued.
Ogg vorbis works too (it was really easy to do thanks to javazoom)!
Post edited by: rickard, at: 2005/06/08 01:3408/06/2005 at 11:18 AM #3358
Okay.. I’m not very java-ie.
What’s this mean?
java.lang.UnsupportedClassVersionError: org/petzall/daapapplet/DAAPApplet (Unsupported major.minor version 49.0)
at java.lang.ClassLoader.defineClass0(Native Method)
at java.security.AccessController.doPrivileged(Native Method)
08/06/2005 at 11:27 AM #3359
Okay.. nm… looks like Safari insists on using 1.4, not 1.3, despite the hint in the tag. Stupid.
Firefox looks like this, though (at least it comes up in 1.3, anyway…)
java.util.MissingResourceException: Can't find resource for bundle sun.applet.resources.MsgAppletViewer, key appletpanel.badattribute.exception
08/06/2005 at 7:43 PM #3360CCRDudeParticipant
Cool idea B) I want this to work 😀
With version Firefox 1.0.4 (JRE 1.4.2_04) I always get “Unsupported major.minor version 49.0” as well.
(both with your non-valid-html sample code and strict ‘applet’-only html)08/06/2005 at 8:39 PM #3361rickardGuest
Stupid me. I compiled it with JRE 1.5. The tag should read 1.5, not 1.3. I guess my Firefox ignores that tag too.
I will compile it with 1.3 later on if possible.08/06/2005 at 9:10 PM #3362jkpGuest
This sounds like an ace idea … what a string to the bow it would be to have option to connect to a Java applet run by mt-daapd itself.
All your music, anytime, anywhere.
Top stuff.08/06/2005 at 11:49 PM #3363rickardGuest
Now I have recompiled the applet with -version 1.3 so it should run on most browsers (I tested with JRE 1.4.2_01/1.5.0_02-b09, Linux/Solaris/Win32 and the applet loaded on those and played music on atleast the Win32 systems(the others had no speakers)).
I also had the opportunity to write an ant script so its easier to recompile and included a sample with the applet tag in the source.
- The forum ‘Feature Requests’ is closed to new topics and replies.