summaryrefslogtreecommitdiffstats
path: root/content/browser/device_monitor_mac.h
diff options
context:
space:
mode:
authormcasas@chromium.org <mcasas@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-10-23 23:36:50 +0000
committermcasas@chromium.org <mcasas@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-10-23 23:36:50 +0000
commit83deae1b6e8d3e6826bc69cd7e6fe93ae2d4c546 (patch)
tree9ece79caf02c5940c9aed324c3db74b03beab52a /content/browser/device_monitor_mac.h
parent6e3f2a404bd89787a4d86a6d00d8cf4aa0612bcf (diff)
downloadchromium_src-83deae1b6e8d3e6826bc69cd7e6fe93ae2d4c546.zip
chromium_src-83deae1b6e8d3e6826bc69cd7e6fe93ae2d4c546.tar.gz
chromium_src-83deae1b6e8d3e6826bc69cd7e6fe93ae2d4c546.tar.bz2
Added AVFoundation Glue and Device Monitoring for Mac.
This CL adds files called avfoundation_glue.{h,mm} to media/video/capture/mac. These files encapsulate dynamic loading of AVFoundation libraries and define+ implement a facade to the used AVFoundation classes. The first usage of those is the DeviceMonitorMac, where the original QTKit event class is transformed into an interface (MacMonitorInterface), implemented by both QTKitMonitorImpl and AVFoundationMonitorImpl. the usage of one or the other is decided on DeviceMonitorMac constructor time. This CL is part of a larger exercise to add support for Video Capture in Mac > 10.6 using AVFoundation. BUG=288562 Review URL: https://codereview.chromium.org/24615005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@230553 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content/browser/device_monitor_mac.h')
-rw-r--r--content/browser/device_monitor_mac.h18
1 files changed, 14 insertions, 4 deletions
diff --git a/content/browser/device_monitor_mac.h b/content/browser/device_monitor_mac.h
index bab522f..6def493 100644
--- a/content/browser/device_monitor_mac.h
+++ b/content/browser/device_monitor_mac.h
@@ -8,19 +8,29 @@
#include "base/basictypes.h"
#include "base/system_monitor/system_monitor.h"
+namespace {
+class DeviceMonitorMacImpl;
+}
+
namespace content {
+// Class to track audio/video devices removal or addition via callback to
+// base::SystemMonitor ProcessDevicesChanged(). A single object of this class
+// is created from the browser main process and lives as long as this one.
class DeviceMonitorMac {
public:
DeviceMonitorMac();
~DeviceMonitorMac();
- private:
- // Forward the notifications to system monitor.
+ // Method called by the internal DeviceMonitorMacImpl object
+ // |device_monitor_impl_| when a device of type |type| has been added to or
+ // removed from the system. This code executes in the notification thread
+ // (QTKit or AVFoundation).
void NotifyDeviceChanged(base::SystemMonitor::DeviceType type);
- class QTMonitorImpl;
- scoped_ptr<DeviceMonitorMac::QTMonitorImpl> qt_monitor_;
+ private:
+ scoped_ptr<DeviceMonitorMacImpl> device_monitor_impl_;
+
DISALLOW_COPY_AND_ASSIGN(DeviceMonitorMac);
};