Discussion Board

Results 1 to 2 of 2
  1. #1
    Registered User
    Join Date
    Mar 2003

    Sound and the Nokia UI

    Eventhough there are examples of how to play sound with the java UI API, there are absolutely no examples of how to create the sound. The sound in blockgame has either been made by a sound tool or a very patient programmer following the cryptic sound format.

    Could we please get some link/directions to some tools which can create Nokia UI sounds (not for use with a single beep, but explosions, music and so on)?

  2. #2
    Regular Contributor
    Join Date
    Mar 2003

    RE: Sound and the Nokia UI

    The com.nokia.mid.ui.Sound class is pretty simple to use really. I presume your problem is that you don't know how to create data in the OTA ringtone format. This data goes in the byte [] data parameter to the constructor, along with FORMAT_TONE as the type.

    FORMAT_WAV doesn't seem to be supported on any devices yet, even the 7650 prototype I have doesn't support it, although it reports that it does. Hopefully the production version will.

    Anyway, back to ringtone format. You need to get the "Smart Messaging Specification" from the "Messaging->Smart Messaging->Documents" section of the Forum Nokia web site here http://www.forum.nokia.com/smsforum/main/1,35452,1_2_5_3,00.html
    Then you need to create a block of data in this format to construct a Sound object with. If you have a 9210 Communicator, you can receive ringtones and save the files to the file system. Then simply take one of these files and paste the bytes into an array in your Java code. Or into a resource file and read the bytes into the array from that.

    Help this helps,

Posting Permissions

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