Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(81)

Side by Side Diff: webrtc/modules/video_capture/mac/video_capture_mac.mm

Issue 1644843003: Compile rtc_base_objc and rtc_api_objc for Mac (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 26 matching lines...) Expand all
37 { 37 {
38 38
39 // static 39 // static
40 bool CheckOSVersion() 40 bool CheckOSVersion()
41 { 41 {
42 // Check OSX version 42 // Check OSX version
43 OSErr err = noErr; 43 OSErr err = noErr;
44 44
45 SInt32 version; 45 SInt32 version;
46 46
47 #pragma clang diagnostic push
48 #pragma clang diagnostic ignored "-Wdeprecated"
47 err = Gestalt(gestaltSystemVersion, &version); 49 err = Gestalt(gestaltSystemVersion, &version);
50 #pragma clang diagnostic pop
48 if (err != noErr) 51 if (err != noErr)
49 { 52 {
50 WEBRTC_TRACE(webrtc::kTraceError, webrtc::kTraceVideoCapture, 0, 53 WEBRTC_TRACE(webrtc::kTraceError, webrtc::kTraceVideoCapture, 0,
51 "Could not get OS version"); 54 "Could not get OS version");
52 return false; 55 return false;
53 } 56 }
54 57
55 if (version < 0x00001040) // Older version than Mac OSX 10.4 58 if (version < 0x00001040) // Older version than Mac OSX 10.4
56 { 59 {
57 WEBRTC_TRACE(webrtc::kTraceError, webrtc::kTraceVideoCapture, 0, 60 WEBRTC_TRACE(webrtc::kTraceError, webrtc::kTraceVideoCapture, 0,
58 "OS version too old: 0x%x", version); 61 "OS version too old: 0x%x", version);
59 return false; 62 return false;
60 } 63 }
61 64
62 WEBRTC_TRACE(webrtc::kTraceDebug, webrtc::kTraceVideoCapture, 0, 65 WEBRTC_TRACE(webrtc::kTraceDebug, webrtc::kTraceVideoCapture, 0,
63 "OS version compatible: 0x%x", version); 66 "OS version compatible: 0x%x", version);
64 67
65 return true; 68 return true;
66 } 69 }
67 70
68 // static 71 // static
69 bool CheckQTVersion() 72 bool CheckQTVersion()
70 { 73 {
71 // Check OSX version 74 // Check OSX version
72 OSErr err = noErr; 75 OSErr err = noErr;
73 76
74 SInt32 version; 77 SInt32 version;
75 78
79 #pragma clang diagnostic push
80 #pragma clang diagnostic ignored "-Wdeprecated"
76 err = Gestalt(gestaltQuickTime, &version); 81 err = Gestalt(gestaltQuickTime, &version);
82 #pragma clang diagnostic pop
77 if (err != noErr) 83 if (err != noErr)
78 { 84 {
79 WEBRTC_TRACE(webrtc::kTraceError, webrtc::kTraceVideoCapture, 0, 85 WEBRTC_TRACE(webrtc::kTraceError, webrtc::kTraceVideoCapture, 0,
80 "Could not get QuickTime version"); 86 "Could not get QuickTime version");
81 return false; 87 return false;
82 } 88 }
83 89
84 if (version < 0x07000000) // QT v. 7.x or newer (QT 5.0.2 0x05020000) 90 if (version < 0x07000000) // QT v. 7.x or newer (QT 5.0.2 0x05020000)
85 { 91 {
86 WEBRTC_TRACE(webrtc::kTraceError, webrtc::kTraceVideoCapture, 0, 92 WEBRTC_TRACE(webrtc::kTraceError, webrtc::kTraceVideoCapture, 0,
(...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after
262 268
263 } 269 }
264 270
265 /************************************************************************** 271 /**************************************************************************
266 * 272 *
267 * End Create/Destroy VideoCaptureModule 273 * End Create/Destroy VideoCaptureModule
268 * 274 *
269 ***************************************************************************/ 275 ***************************************************************************/
270 } // namespace videocapturemodule 276 } // namespace videocapturemodule
271 } // namespace webrtc 277 } // namespace webrtc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698