Contents

init(contentsOf:byReference:)

Initializes the receiver with the audio data located at a given URL.

Declaration

init?(contentsOf url: URL, byReference byRef: Bool)

Parameters

  • url:

    URL to the sound file with which the receiver is to be initialized.

  • byRef:

    When True only the name of the sound is stored with the NSSound instance when archived using Encode(with:); otherwise the audio data is archived along with the instance.

Return Value

Initialized NSSound instance.

See Also

Creating Sounds