×

Discussion Board

Results 1 to 2 of 2
  1. #1
    Registered User
    Join Date
    Jun 2005
    Posts
    4

    j2me recordControl and player record sound "continuesly"...

    i tried testing on record sound continuesly but fail . can this be done with player and recordcontrol?


    capturePlayer.start();

    int buf = 0;

    while (!quit) {

    recordControl.startRecord();



    Thread.sleep(1000);

    synchronized (bos[buf]) {
    recordControl.stopRecord();
    recordControl.commit();


    System.out.println("recording " + buf + " size=" + bos[buf].size());

    bos[buf].notify();


    buf = (buf * -1) + 1;
    recordControl.setRecordStream(bos[buf]);

    }






    }

  2. #2
    Nokia Developer Expert
    Join Date
    Aug 2007
    Posts
    1,595

    Re: j2me recordControl and player record sound "continuesly"...

    Hello jimmyteoh,

    if the problem is that you run out of memory with byte array, try storing audio to a file by using setRecordLocation(java.lang.String locator) method.

    More about setRecordLocation(java.lang.String locator):

    http://java.sun.com/javame/reference...rdControl.html

    http://www.forum.nokia.com/ME_Develo...D8F1EE772.html

    Example source code piece (under headline Scenario 10: Capture and Recording):

    http://www.forum.nokia.com/document/...w-summary.html

    Regards,
    r2j7

Similar Threads

  1. j2me and video recording
    By cloud139 in forum Mobile Java General
    Replies: 10
    Last Post: 2007-08-16, 19:55
  2. Can i record audio in .amr
    By manaljuwdat in forum Mobile Java Media (Graphics & Sounds)
    Replies: 1
    Last Post: 2007-04-23, 08:21
  3. How to cut a unwelcome form interactive in the record sound?
    By zehdopulo in forum Mobile Java Media (Graphics & Sounds)
    Replies: 1
    Last Post: 2007-02-08, 06:16

Posting Permissions

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