• 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: AudioUnitGetProperty with Swift 3
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: AudioUnitGetProperty with Swift 3


  • Subject: Re: AudioUnitGetProperty with Swift 3
  • From: Benjamin Federer <email@hidden>
  • Date: Wed, 19 Oct 2016 15:47:21 +0200

Thanks, Matt

Unfortunately this does not work. Since the line creates an explicitly unwrapped optional containing nil, AudioUnitGetProperty fails at runtime, just as passing in nil directly would (if the compiler would allow it):

fatal error: unexpectedly found nil while unwrapping an Optional value

For what it’s worth I am currently querying the maximum property size using AudioUnitGetPropertyInfo, then getting the property data using AudioUnitGetProperty and finally slicing off the portion of relevant data reported by the ioDataSize out value.

Benjamin


Am 19.10.2016 um 15:21 schrieb Matt Grippaldi <email@hidden>:

Try this…

        let nullPtr:UnsafeMutableRawPointer! = nil

Matt Grippaldi
email@hidden









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
  • Follow-Ups:
    • Re: AudioUnitGetProperty with Swift 3
      • From: "Vieira Damiani, Luis F" <email@hidden>
    • Re: AudioUnitGetProperty with Swift 3
      • From: Matt Grippaldi <email@hidden>
References: 
 >AudioUnitGetProperty with Swift 3 (From: Benjamin Federer <email@hidden>)
 >Re: AudioUnitGetProperty with Swift 3 (From: Matt Grippaldi <email@hidden>)

  • Prev by Date: Re: AudioUnitGetProperty with Swift 3
  • Next by Date: Re: AudioUnitGetProperty with Swift 3
  • Previous by thread: Re: AudioUnitGetProperty with Swift 3
  • Next by thread: Re: AudioUnitGetProperty with Swift 3
  • Index(es):
    • Date
    • Thread