From a4a1237c84db9d4706a1c8a718d0f284e27e8c33 Mon Sep 17 00:00:00 2001 From: Zakk Date: Tue, 24 Feb 2015 22:45:09 -0500 Subject: [PATCH] Remove some debugging output in SourceLayout. Don't use 10.10 specific CMSampleBuffer creation function. Bump version up to 1.9.8 --- .../CSAVFCapturePlugin/AVFCapture.m | 47 ------------------- CocoaSplit/CSAacEncoder.m | 5 +- CocoaSplit/CocoaSplit-Info.plist | 4 +- CocoaSplit/SourceLayout.m | 2 - 4 files changed, 6 insertions(+), 52 deletions(-) diff --git a/CapturePlugins/CSAVFCapturePlugin/CSAVFCapturePlugin/AVFCapture.m b/CapturePlugins/CSAVFCapturePlugin/CSAVFCapturePlugin/AVFCapture.m index d6172e64..f7446df1 100644 --- a/CapturePlugins/CSAVFCapturePlugin/CSAVFCapturePlugin/AVFCapture.m +++ b/CapturePlugins/CSAVFCapturePlugin/CSAVFCapturePlugin/AVFCapture.m @@ -274,7 +274,6 @@ -(void) changeAvailableVideoDevices { [self setDeviceForUniqueID:self.savedUniqueID]; [self restoreFormatAndFrameRate]; - } } @@ -293,52 +292,6 @@ -(void) removeAudioOutput } -/* --(void) setupAudioOutput -{ - - if (!_capture_session) - { - return; - } - - if (!_audio_capture_output) - { - - - - _audio_capture_output = [[AVCaptureAudioDataOutput alloc] init]; - - - _audio_capture_output.audioSettings = @{ - AVFormatIDKey: [NSNumber numberWithInt:kAudioFormatLinearPCM], - AVLinearPCMBitDepthKey: @32, - AVLinearPCMIsFloatKey: @YES, - AVLinearPCMIsNonInterleaved: @YES, - //AVNumberOfChannelsKey: @2, - }; - - - _audio_capture_queue = dispatch_queue_create("AVFCaptureMuxedAudio", NULL); - [_audio_capture_output setSampleBufferDelegate:self queue:_audio_capture_queue]; - } - - - [_capture_session beginConfiguration]; - - if ([_capture_session canAddOutput:_audio_capture_output]) - { - [_capture_session addOutput:_audio_capture_output]; - - } else { - NSLog(@"COULDN'T ADD AUDIO OUTPUT"); - } - - - [_capture_session commitConfiguration]; -} - -*/ diff --git a/CocoaSplit/CSAacEncoder.m b/CocoaSplit/CSAacEncoder.m index f4dd5203..f2fb93f9 100644 --- a/CocoaSplit/CSAacEncoder.m +++ b/CocoaSplit/CSAacEncoder.m @@ -173,7 +173,10 @@ -(void) enqueuePCM:(AudioBufferList *)pcmBuffer atTime:(const AudioTimeStamp *)a CMBlockBufferCreateWithMemoryBlock(NULL, aacBuffer, buffer_size, kCFAllocatorMalloc, NULL, 0, buffer_size, 0, &bufferRef); - CMAudioSampleBufferCreateReadyWithPacketDescriptions(kCFAllocatorDefault, bufferRef, cmFormat, 1, ptsTime, &packetDesc, &newSampleBuf); + CMAudioSampleBufferCreateWithPacketDescriptions(kCFAllocatorDefault, bufferRef, YES, NULL, NULL, cmFormat, 1, ptsTime, &packetDesc, &newSampleBuf); + + + //CMAudioSampleBufferCreateReadyWithPacketDescriptions(kCFAllocatorDefault, bufferRef, cmFormat, 1, ptsTime, &packetDesc, &newSampleBuf); CMSampleBufferCreateCopyWithNewTiming(kCFAllocatorDefault, newSampleBuf, 1, &timeInfo, &timingSampleBuf); CFRelease(newSampleBuf); diff --git a/CocoaSplit/CocoaSplit-Info.plist b/CocoaSplit/CocoaSplit-Info.plist index 833381a0..3e56f3e6 100644 --- a/CocoaSplit/CocoaSplit-Info.plist +++ b/CocoaSplit/CocoaSplit-Info.plist @@ -17,11 +17,11 @@ CFBundlePackageType APPL CFBundleShortVersionString - 1.9.6 + 1.9.8 CFBundleSignature ???? CFBundleVersion - 1.9.6 + 1.9.8 LSApplicationCategoryType public.app-category.video LSMinimumSystemVersion diff --git a/CocoaSplit/SourceLayout.m b/CocoaSplit/SourceLayout.m index d49b4f1d..c92c39d7 100644 --- a/CocoaSplit/SourceLayout.m +++ b/CocoaSplit/SourceLayout.m @@ -330,14 +330,12 @@ -(void)renderToSurface:(IOSurfaceRef)ioSurface if (!_rFbo) { glGenFramebuffers(1, &_rFbo); - NSLog(@"GENERATED FBO %d", _rFbo); } if (!_fboTexture) { glGenTextures(1, &_fboTexture); - NSLog(@"GENERATED TEXTURE %d", _fboTexture); }