• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: ExtendedAudioFile problems
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: ExtendedAudioFile problems


  • Subject: Re: ExtendedAudioFile problems
  • From: patrick machielse <email@hidden>
  • Date: Mon, 2 Jul 2007 01:08:41 +0200

Op 2-jul-2007, om 00:32 heeft Kevin Avila het volgende geschreven:

On Jul 1, 2007, at 2:24 PM, patrick machielse wrote:
This program exits with status 0, but the created file isn't removed, which is what according to the documentation should happen.

The file is closed and the ExtAudioFile object is disposed, not the file on disk.

Hmm, the docs say: "If no frames were written to an ExtAudioFile allocated by ExtAudioFileCreateNew, the output file is deleted.". I think that means that the file should be gone if my test program runs successfully. You could argue this is a bug in the documentation...


ExtAudioFileWriteAsync(audiofile, 0, NULL);

That is the correct method, insure your 'audiofile' variable is a valid ExtAudioFile object.

When I call ExtAudioFileWriteAsync() audiofile is not NULL and the file it refers to exists.


Some further experiments show that the crash _doesn't_ occur if I do something with the ExtAudioFile first (after creating it and before priming it). For instance:

//  set the client format
error = ExtAudioFileSetProperty(audiofile,
                                kExtAudioFileProperty_ClientDataFormat,
                                sizeof (AudioStreamBasicDescription),
                                &asbd);
if ( error ) {
    NSLog(@"could not set client data format");
    return 1;
}

ExtAudioFileWriteAsync(audiofile, 0, NULL); /* NO CRASH */

patrick
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Coreaudio-api mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >ExtendedAudioFile problems (From: patrick machielse <email@hidden>)
 >Re: ExtendedAudioFile problems (From: Kevin Avila <email@hidden>)

  • Prev by Date: Re: ExtendedAudioFile problems
  • Next by Date: problems using afconvert to do alac to aac
  • Previous by thread: Re: ExtendedAudioFile problems
  • Next by thread: problems using afconvert to do alac to aac
  • Index(es):
    • Date
    • Thread