Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6974733
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T17:16:35+00:00 2026-05-27T17:16:35+00:00

I have an audio file in my iPhone app that I convert to an

  • 0

I have an audio file in my iPhone app that I convert to an NSData object. Ideally, I would like to get an array of doubles from the audio file. Is there a way to convert NSData to an array of doubles?

Here is the current output from the line NSLog(@"%@\n", data) where data is an NSData object of the audio file:

<0000001c 66747970 6d703432 00000001 6d703431 6d703432 69736f6d 00000008 77696465 004d956e 6d646174 21000340 681c210c 53ed990c 1f33e94d ab588b95 55a61078 08799c67 f1f706cc 595b4eb6 08cfb807 ea0e3c40 03c13303 e674e05a...
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T17:16:36+00:00Added an answer on May 27, 2026 at 5:16 pm

    The -bytes method return the raw bytes of the NSData. You can then cast it to a pointer to double (assuming correct endianness).

    const double* array_of_doubles = (const double*)[data bytes];
    NSUInteger size_of_array = [data length] / sizeof(double);
    

    Edit: The data is an MP4 file. You cannot convert MP4 to a meaningful double array directly. I don’t know what you want to do, but maybe AVAssetReader would help.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a 30 second audio file and I would like to get callbacks
I am trying to play audio file in my iphone app.I have used this
I have made an iphone app to upload an audio file. I have also
I have one audio file captured from my iphone. I want to upload this
I have a button that plays an audio file on its click listener. If
So I have a script that, when run, plays an audio file which I
So, I have a php script that sends my mp3 file to the audio
Is there anyway to store audio on an iphone app and then grab that
I have an audio file with length of 500 miniseconds for my app. I
If I have a recorded audio file (MP3), is there any way to get

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.