Archive

Archive for the ‘Red5’ Category

File-system mp3 Organisation – Is It Really That Hard?

June 10th, 2008 Chris No comments

Like most people I know I have a lot of mp3's and every person likes to sort theirs differently.

My preferred method of sorting my mp3's is to do it on the file system going artist -> album -> track, but I know some who do crazy stuff like genre -> sub-genre -> artist -> album -> track and worse!

The reason I like to have it sorted on the file system is that I can quickly copy a specific artist's album when I need it, and I don't like bloated mp3 managers like itunes or winamp for managing my collection.

Also like many other people I know, though I did my best to keep things organised I still had an unsorted folder of about 1000 tracks of all kinds of stuff, which I just didn't have time to sort out properly.

So I went looking for a tool to do this organisation for me. I found a couple tools that would do the job but I had to pay for them and as this is a relatively simple job I thought I'd hunt out a free one.

As it turns out there's not many tools that I could find easily to do this in the way I wanted until I came across MediaSort (http://mediasort.sourceforge.net/). This did exactly what I wanted examining the id3 tags of the mp3s in the unsorted folder and moving them into a series of folders arranged in the way I wanted.

The only problem with this tool is that it runs of Apache ant (http://ant.apache.org/) the setup of which on windows can be a right pain to work, and hence the reason for this post - a quick and easy guide to getting MediaSort running on Windows so you too can bring order to your mp3 collection. Incidentally media sort also arranges other file types too such as avi's and images in a similar way, and as such can be really useful for those of you with massive unsorted photo collections.
So what do you do to get it going?

  1. First install the latest java development kit (jdk) for windows from Sun Microsystems (literally just download it and run the installer - version at the time of writing is 6 update 6): http://java.sun.com/javase/downloads/index.jsp
  2. Once this is installed go and grab this really, really handy Apache ant installer for windows from Google code, and, again just run the installer: http://code.google.com/p/winant/
  3. Download the MediaSort code from sourceforge: http://sourceforge.net/project/showfiles.php?group_id=169714&package_id=193585&release_id=510898
  4. Extract the media sort archive and copy the contents of everything in the sub folders of the lib folder to your Apache ant lib folder (being careful to overwrite any files that already exist) on my machine the location of the Apache ant folder is: C:\Program Files\WinAnt\lib due to using the winant installer.
  5. run the run.cmd file in the mediasort folder you just extracted and you should find that it fires up the interface
  6. Set the source folder you want to arrange - in my case C:\MP3\Unsorted and mediasort will analyse the files for meta information (id3 tags from mp3s, filesystem data on the files, etc.)
  7. Set the target folder you want the arranged mp3's to be copied or moved to - in my case C:\music\target
  8. Click on items in the list of meta-data attributes that you want to use to define where you're copying or moving files to - in my case I chose the following pattern: [MP3 - author]/[MP3 - album]/[MP3 - title].mp3
  9. Click copy or move and it will do that sorting the files to the pattern you specified - job done!

This worked great first time for me but there was room for a little improvement. Where some of the mp3's didn't have a full set of id3 tags MediaSort didn't know where to put the files and as such bundled then into folders called "unknown".

So I went hunting for another free tool to analyze the mp3s and populate all the id3 tags before running the sort again and second time round it worked flawlessly. For this part of the process I used Zortam Mp3 Media Studio 8.10 (http://www.zortam.com/) which did the job a treat.

So that's it.

One last thing to mention is if you followed my Red5 posts (http://www.coderchris.com/tag/red5/) then
you should be able to use winant to get that installed on windows too - I've not tried it yet, but it should work.

JW Media Player – A Godsend For Flash Streaming

November 18th, 2007 Chris 13 comments

So, you want or need to stream multimedia content from your website; you don't have time or money to figure out or pay someone to figure out how to do what you need; and you need it to look reasonably pro.

Where do you go?

Well I'll tell you: You go here: http://www.jeroenwijering.com and download JW Media Player

 It's a fantastic, versatile free piece of software you can just plug into any website and use to start streaming content right away!

The best thing however, is that it works really well alongside the Red 5 streaming flash server via the oflaDemo app, and as such completes the package of a free streaming flash solution that looks good and performs well.

Just remember, when following the examples of how to get it to work with at least true streams (i.e. not progressive downloads) give the mediaplayer.swf an absolute url ;)

If anybody needs help getting this to work with Red 5 feel free to drop me an email or leave a comment and I'll help you out :)

Installing Red5 Open Source Flash Media Server On CentOS 4.2

September 19th, 2007 Chris 4 comments

After having no end of issues with the proprietary flash media server 2 from Adobe I decided to give installing the Red5 open source version a go instead.

I have to say I was fairly impressed with just how easy it was to get running without having to do any of the faffing around that was required to get FMS2 running.

Here is the process in a nutshell:

  1. Download and install the Java Development Kit (jdk) from here (I used the rpm version of JDK 6 Update 2): http://java.sun.com/javase/downloads/index.jsp
  2. Download and extract Apache ant from here: http://archive.apache.org/dist/ant/binaries/apache-ant-1.6.5-bin.tar.gz
  3. Copy the extracted apache-ant-1.6.5 folder to /usr/local/ant
  4. Setup the environment variables to include the path for java and ant by typing the following at the shell prompt:PATH=$PATH:$HOME/bin:/usr/local/ant/bin
    export PATHThen also remember to add this to  /etc/profile so the settings don't get lost the next time you login
  5. Download and extract the Red5 server from here: http://osflash.org/red5
     
  6. cd to the Red5 directory you just extracted and type the following at the shell prompt to allow java to retrieve the files it needs from the net and compile and run the server as a background process (the module retrieval is automatic and only has to be done once):ant server & 
  7. Then that's it it's running. In my case I needed to kill the ant/java processes running the server after the java modules were initially retrieved and the server built for the first time, but the second time it was fine even though it did take about 30 seconds to fully startup - this may just be a glitch on my system as I have a lot of other stuff also going on.
  8. The final step is to test it. This can be done by moving the contents of the webapps/root/demos/ folder from the extracted Red5 directory to a webserver somewhere (I don't think it hast to be the same machine) and then viewing the list of demos in the index.html file.I started off by using the port tester to make sure the demo apps could actually connect to the server on the ports they were meant to (basically rtmp port 1935) and then moved onto testing the video streaming app and then tried a proper live broadcast through the server using the simpleBroadcaster app to two friends who were logged on using the simple subscriber app. All worked well especially as far as the video was concerned though the audio was a little crackly on my live broadcast - this could just be the quality of home connections however.The only last not is just a simple reminder that when running the test apps you'll need to specify the server they need to connect to - the apps are setup to access rtmp://localhost/[APP_NAME] but if you're not running these apps as a local user you will need to change localhost to the name or ip of the server Red5 is installed on :)

So far I'm quite happy with Red5 as a free (very important) alternative to FMS2, but should you be looking for a commercial product as this is not quite up your street (that is a cheaper than FMS2) then take a look at this instead: http://www.wowzamedia.com/index.html

Wowza only requires java to run and is like a very polished commercial version of the Red5 server (it was actually through installing Wowza that I worked out what to do with the web apps for Red5 - having had no previous experience in flash streaming other than literally installing FMS2) which has a very reasonable price tag in comparison to the cost of FMS2

Just before I go I just need to mention the map below - Red5 ask you to add yourself to their user map if you're using the software so I have - you can find me in Brighton, England :)

gyo Installing Red5 Open Source Flash Media Server On CentOS 4.2s Installing Red5 Open Source Flash Media Server On CentOS 4.2p Installing Red5 Open Source Flash Media Server On CentOS 4.2h Installing Red5 Open Source Flash Media Server On CentOS 4.2