[vlc-devel] [PATCH 4/5] macosx: Use avaudiocapture module instead of qtsound

david.fuhrmann at gmail.com david.fuhrmann at gmail.com
Mon Feb 10 19:41:54 CET 2020


From: David Fuhrmann <dfuhrmann at videolan.org>

And remove some references of the old QTKit code.

(cherry picked from commit acef852aac51044b6663d9f86083529e8dfb88e4)
Signed-off-by: David Fuhrmann <dfuhrmann at videolan.org>
---
 .../package/macosx/vlc.xcodeproj/project.pbxproj   |  2 --
 modules/gui/macosx/VLCOpenWindowController.m       | 14 +++++++-------
 2 files changed, 7 insertions(+), 9 deletions(-)

diff --git a/extras/package/macosx/vlc.xcodeproj/project.pbxproj b/extras/package/macosx/vlc.xcodeproj/project.pbxproj
index 9abcdcab23..de6ad05c76 100644
--- a/extras/package/macosx/vlc.xcodeproj/project.pbxproj
+++ b/extras/package/macosx/vlc.xcodeproj/project.pbxproj
@@ -751,7 +751,6 @@
 		CCDDF1AD172FF4C4007729A1 /* dirs.c */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.c; name = dirs.c; path = ../../../src/darwin/dirs.c; sourceTree = "<group>"; };
 		CCF0777B13659A8000AF19FD /* SPMediaKeyTap.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = SPMediaKeyTap.h; sourceTree = "<group>"; };
 		CCF0777C13659A8000AF19FD /* SPMediaKeyTap.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SPMediaKeyTap.m; sourceTree = "<group>"; };
-		DC1A176914E2778A001477C6 /* qtsound.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = qtsound.m; path = ../../../modules/access/qtsound.m; sourceTree = "<group>"; };
 		DCC8017816FCA036007FE736 /* avcapture.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = avcapture.m; path = ../../../modules/access/avcapture.m; sourceTree = "<group>"; };
 		DCC8017916FCA0DA007FE736 /* AVFoundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AVFoundation.framework; path = System/Library/Frameworks/AVFoundation.framework; sourceTree = SDKROOT; };
 		DCE7BD0608A5724D007B10AE /* VLCBookmarksWindowController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = VLCBookmarksWindowController.m; sourceTree = "<group>"; };
@@ -1644,7 +1643,6 @@
 			isa = PBXGroup;
 			children = (
 				DCC8017816FCA036007FE736 /* avcapture.m */,
-				DC1A176914E2778A001477C6 /* qtsound.m */,
 			);
 			name = access;
 			sourceTree = "<group>";
diff --git a/modules/gui/macosx/VLCOpenWindowController.m b/modules/gui/macosx/VLCOpenWindowController.m
index 1555f90a82..994953a8b0 100644
--- a/modules/gui/macosx/VLCOpenWindowController.m
+++ b/modules/gui/macosx/VLCOpenWindowController.m
@@ -221,7 +221,7 @@ - (void)windowDidLoad
     // Auto collapse MRL field
     self.mrlViewHeightConstraint.constant = 0;
 
-    [self updateQTKVideoDevices];
+    [self updateVideoDevices];
     [_qtkVideoDevicePopup removeAllItems];
     msg_Dbg(getIntf(), "Found %lu video capture devices", _avvideoDevices.count);
 
@@ -246,7 +246,7 @@ - (void)windowDidLoad
     [_qtkAudioDevicePopup removeAllItems];
     [_screenqtkAudioPopup removeAllItems];
 
-    [self updateQTKAudioDevices];
+    [self updateAudioDevices];
     msg_Dbg(getIntf(), "Found %lu audio capture devices", _avaudioDevices.count);
 
     if (_avaudioDevices.count >= 1) {
@@ -498,12 +498,12 @@ - (void)openTarget:(NSString *)identifier
             else
                 [options addObject: @"no-screen-follow-mouse"];
             if ([_screenqtkAudioCheckbox state] && _avCurrentAudioDeviceUID)
-                [options addObject: [NSString stringWithFormat: @"input-slave=qtsound://%@", _avCurrentAudioDeviceUID]];
+                [options addObject: [NSString stringWithFormat: @"input-slave=avaudiocapture://%@", _avCurrentAudioDeviceUID]];
         }
         else if ([[[_captureModePopup selectedItem] title] isEqualToString: _NS("Input Devices")]) {
             if ([_qtkVideoCheckbox state]) {
                 if ([_qtkAudioCheckbox state] && _avCurrentAudioDeviceUID)
-                    [options addObject: [NSString stringWithFormat: @"input-slave=qtsound://%@", _avCurrentAudioDeviceUID]];
+                    [options addObject: [NSString stringWithFormat: @"input-slave=avaudiocapture://%@", _avCurrentAudioDeviceUID]];
             }
         }
     }
@@ -1161,7 +1161,7 @@ - (IBAction)openCaptureModeChanged:(id)sender
         if ([_qtkVideoCheckbox state] && _avCurrentDeviceUID)
             [self setMRL:[NSString stringWithFormat:@"avcapture://%@", _avCurrentDeviceUID]];
         else if ([_qtkAudioCheckbox state] && _avCurrentAudioDeviceUID)
-            [self setMRL:[NSString stringWithFormat:@"qtsound://%@", _avCurrentAudioDeviceUID]];
+            [self setMRL:[NSString stringWithFormat:@"avaudiocapture://%@", _avCurrentAudioDeviceUID]];
     }
 }
 
@@ -1306,13 +1306,13 @@ - (IBAction)panelOk:(id)sender
         NSBeep();
 }
 
-- (void)updateQTKVideoDevices
+- (void)updateVideoDevices
 {
     _avvideoDevices = [[AVCaptureDevice devicesWithMediaType:AVMediaTypeVideo]
                          arrayByAddingObjectsFromArray:[AVCaptureDevice devicesWithMediaType:AVMediaTypeMuxed]];
 }
 
-- (void)updateQTKAudioDevices
+- (void)updateAudioDevices
 {
     _avaudioDevices = [[AVCaptureDevice devicesWithMediaType:AVMediaTypeAudio]
                         arrayByAddingObjectsFromArray:[AVCaptureDevice devicesWithMediaType:AVMediaTypeMuxed]];
-- 
2.21.1 (Apple Git-122.3)



More information about the vlc-devel mailing list