×

Discussion Board

Results 1 to 3 of 3

Thread: Can't play MP3

  1. #1
    Registered User
    Join Date
    Aug 2008
    Location
    Berlin
    Posts
    18

    Can't play MP3

    Hi,

    I'm trying to play an .mp3 sound on my Nokia N78. I use the following Code:
    PHP Code:
    try
        {
            
    InputStream soundStream getClass().getResourceAsStream("/audio/bell.mp3");
            
    player Manager.createPlayer(soundStream"audio/mpeg");
            
    player.realize();
            
    player.prefetch();
            
    player.start();    
        } catch(
    Exception e)
        {
            
    e.printStackTrace();
        } 
    With Sun WTK 2.5.2 I get an error, probably because it can't play mp3.
    With Sun WTK 3.0 it works
    Nokia S60 3rd Emulator throws an error "Prefetch error: -1"
    My N78 Phone doesn't throw an error but plays no sound.

    Can anyone gibe me a hint?

  2. #2
    Nokia Developer Expert
    Join Date
    May 2007
    Location
    Mexico D.F
    Posts
    351

    Re: Can't play MP3

    Hello,

    1. have you tried audio/mp3 as locator?
    2. Make sure resource is being actually found
    :Ruben

  3. #3
    Registered User
    Join Date
    Aug 2008
    Location
    Berlin
    Posts
    18

    Re: Can't play MP3

    The resource is found because with Sun WTK 3 it works.

    I could get it to work on my phone, too - had to activate "warning sounds"

    Just the Nokia S60 3rd Emulator keeps throwing an error

Similar Threads

  1. Recording in Amr Format
    By losym in forum Symbian Media (Closed)
    Replies: 12
    Last Post: 2009-03-26, 06:41
  2. how to play mp3 file and play long wav file
    By changsshuai in forum Symbian
    Replies: 6
    Last Post: 2008-09-02, 09:50
  3. Replies: 1
    Last Post: 2008-06-17, 10:40
  4. Out of Memory Error (play mp3 on S40)
    By luowaitting in forum Mobile Java Media (Graphics & Sounds)
    Replies: 2
    Last Post: 2007-12-11, 08:25
  5. Cannot play MP3 with chinese filename in MMAPI
    By domicch in forum Mobile Java Media (Graphics & Sounds)
    Replies: 6
    Last Post: 2006-05-17, 07:36

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×