Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

Playing MP3s using Java or C#

Options
  • 15-08-2007 11:51am
    #1
    Registered Users Posts: 11,038 ✭✭✭✭


    Hey, so i'll be heading into 4th year of Software Development in October... As part of our course we have to do a big final year project... We are free to choose our own, but to help some lecturers have submitted some proposals of their own...

    One option is for a radio station thing, which plays certain music depending on user or whatever...

    I was just wondering if anybody had a link or something with an overview of how this would be implemented, and how easy (or not) it is...

    We have until middle of september to submit an idea so i have plenty of time, just looking to do a little bit of research...

    Which language would suit better, Java or C#? I've been using C# in work since April, but used Java in college for last 2 years...

    Any pointers or help would be much appreciated...


Comments

  • Moderators, Science, Health & Environment Moderators Posts: 10,079 Mod ✭✭✭✭marco_polo


    I am sure there are similar libraries for C# but there is a good article on doing it in java here: (Scroll down a bit). You will be plesantly surprised by the number of lines of of lines of code ;)

    http://www.javalobby.org/java/forums/t18465.html


  • Registered Users Posts: 11,980 ✭✭✭✭Giblet


    I wrote an mp3 player for my 2nd year project using that library. Beware that you can't skip through songs (in the version I used anyway). If you want some help, just ask. It has quite a small footprint as well, and doesn't crash easily.


  • Registered Users Posts: 151 ✭✭sailorfoley


    I wrote an MP3 / mpeg video player in C# a few years back. I used Direct X 9 at the time. There was a managed version which had very high level objects for audio / video file playing, chaging volume, scanning to a point in the track / video - all the basic things you would expect to be able to do.

    I'd recommend it.


  • Closed Accounts Posts: 161 ✭✭nude_hamster


    DirectSound and other .Net2 /.Net3 technologies I found much wider available for source and tutorials for this kind of thing. Java was not so common for this but I found documentation is much better.

    Also personally I dislike developing in C# but I think for mp3 player , C# is what you might want to use over java.


  • Registered Users Posts: 11,038 ✭✭✭✭dulpit


    Thanks for replies all, i'll have to look into it..

    I wrote an MP3 / mpeg video player in C# a few years back. I used Direct X 9 at the time. There was a managed version which had very high level objects for audio / video file playing, chaging volume, scanning to a point in the track / video - all the basic things you would expect to be able to do.

    I'd recommend it.

    Any links or whatever to where you found help and stuff?


  • Advertisement
  • Registered Users Posts: 11,038 ✭✭✭✭dulpit


    Also, just though of this, would it be possible for this sort of scenario:

    On PC #1 the program runs, has all the mp3s or whatever, chooses the music. Some dude on PC#2 logs onto some website, can listen to this music? By streaming it or something?


  • Closed Accounts Posts: 161 ✭✭nude_hamster


    dulpit wrote:
    Also, just though of this, would it be possible for this sort of scenario:

    On PC #1 the program runs, has all the mp3s or whatever, chooses the music. Some dude on PC#2 logs onto some website, can listen to this music? By streaming it or something?

    em .. that sounds like yahoo launch or some similar web app.

    but if you develope something like this , you must be careful of your copyrights and ownerships of the the songs you provide, I think even if its being used for your 4th year project , but im not sure on that one. I think i have heard people having to check out rights for data and content used in their project for a thesis or proof of concept


  • Closed Accounts Posts: 17,208 ✭✭✭✭aidan_walsh


    you must be careful of your copyrights and ownerships of the the songs you provide
    Educational use is a special exception in copyright law.


  • Registered Users Posts: 1,823 ✭✭✭EvilMonkey


    I used Bass before with C++ to make an mp3 player. I think their is a .net API so it should work with C#.


  • Closed Accounts Posts: 161 ✭✭nude_hamster


    Educational use is a special exception in copyright law.
    are they any rescriptions at all, or looser restrictions?


  • Advertisement
  • Registered Users Posts: 11,038 ✭✭✭✭dulpit


    EvilMonkey wrote:
    I used Bass before with C++ to make an mp3 player. I think their is a .net API so it should work with C#.

    Ok, so i had a quick look at that bass thing, it seems to offer what i'd need... No starter guides or anything available though, doesn't explain how to use the thing at all anywhere...

    Do you know of any guides or anything??? I've never done anything like this before, so i won't be able to just jump straight in...


  • Registered Users Posts: 1,823 ✭✭✭EvilMonkey


    dulpit wrote:
    Ok, so i had a quick look at that bass thing, it seems to offer what i'd need... No starter guides or anything available though, doesn't explain how to use the thing at all anywhere...

    Do you know of any guides or anything??? I've never done anything like this before, so i won't be able to just jump straight in...

    I just used the documentation and samples to get me up and running.


  • Closed Accounts Posts: 4,943 ✭✭✭Mutant_Fruit


    If you're going with C#, would you consider making your project cross platform? I.e. have it able to use DirectX on windows, GStreamer on Linux + whatever on MacOS?

    If you write your application without hardcoding in things which only work for one particular OS, Mono will allow you to run your app on pretty much every OS out there.


  • Registered Users Posts: 151 ✭✭sailorfoley


    dulpit wrote:
    Thanks for replies all, i'll have to look into it..




    Any links or whatever to where you found help and stuff?

    I used the SDK reference and MSDN (which is the online version) to do it all.
    If you want i could dig out the project and answer any questions you might have.


  • Registered Users Posts: 2,299 ✭✭✭PixelTrawler


    Within the last few days on TheCodeProject, somebody posted an article where they developed a little c# program for playing music.

    The idea was it was interface less, so you could hide player. It creates an exe that when double clicked plays the music and then theres nothing visible on screen

    But the should be code in it for playing music

    http://www.codeproject.com/useritems/mp3toexe.asp


Advertisement