Permalink
Browse files

Merge pull request #47 from MaddTheSane/patch-1

Fixes #37, updates cocoa audio libraries
  • Loading branch information...
0xe1f committed Apr 20, 2018
2 parents 5795b3a + b4b99c7 commit 3303ee1421f7441b0d828f8f318e2ea662868a9b
Showing with 5 additions and 5 deletions.
  1. +5 −5 Src/Cocoa/CMCocoaSound.m
@@ -81,8 +81,8 @@ - (BOOL)initializeWithSampleRate:(UInt32)sampleRate
bitsPerChannel:(UInt16)bitsPerChannel
{
OSStatus result = noErr;
Component comp;
ComponentDescription desc;
AudioComponent comp;
AudioComponentDescription desc;
struct AURenderCallbackStruct callback;
AudioStreamBasicDescription requestedDesc;
@@ -106,12 +106,12 @@ - (BOOL)initializeWithSampleRate:(UInt32)sampleRate
desc.componentFlags = 0;
desc.componentFlagsMask = 0;
comp = FindNextComponent(NULL, &desc); // FIXME: deprec
comp = AudioComponentFindNext(NULL, &desc);
if (!comp)
return NO;
// Open & initialize the default output audio unit
result = OpenAComponent(comp, &outputAudioUnit); // FIXME: deprec
result = AudioComponentInstanceNew(comp, &outputAudioUnit);
if (result != noErr)
return NO;
@@ -200,7 +200,7 @@ - (BOOL)destroy
if (result != noErr)
success = NO;
result = CloseComponent(outputAudioUnit); // FIXME: deprec
result = AudioComponentInstanceDispose(outputAudioUnit);
if (result != noErr)
success = NO;

0 comments on commit 3303ee1

Please sign in to comment.