Results 1 to 2 of 2

Thread: About data size filled in the buffer

  1. #1
    Junior Member
    Join Date
    Nov 2011
    Posts
    1

    About data size filled in the buffer

    I want to write a simple example project to test recording in my platform. My platform supports OpenSL ES v1.0.1, and I have a following question.

    If I set the recorder stop when it is recording, how do I know the exact number of bytes filled in the last buffer if it is not filled up ?

    In version 1.1, the callback function has some parameters about buffer and its filled data, but there is no such parameters in version 1.0.1.

    Is there any way to get this information because I must know the data size in last buffer ?

    Any suggestion would be greatly appreciated !

  2. #2
    Junior Member
    Join Date
    Mar 2012
    Posts
    9

    Re: About data size filled in the buffer

    As you have noted, this information is not available in OpenSL ES 1.0.1. This was one of the reasons for the modification to the buffer queue APIs in OpenSL ES 1.1. As a possible workaround, you might try zeroing out the buffer ahead of time, and then at completion examine the buffer to see which portion is non-zero. This gives an approximation of how much was filled, however it does not handle correctly the case of recording silence.

Similar Threads

  1. Size of data in glCompressedTexImage2D
    By maximus-dev in forum OpenGL ES 1.X - fixed function hardware
    Replies: 3
    Last Post: 04-28-2010, 06:22 PM

Posting Permissions

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