summaryrefslogtreecommitdiffstats
path: root/media
diff options
context:
space:
mode:
Diffstat (limited to 'media')
-rw-r--r--media/media.gyp12
-rw-r--r--media/video/capture/screen/screen_capturer_null.cc29
-rw-r--r--media/video/capture/screen/screen_capturer_x11.cc (renamed from media/video/capture/screen/screen_capturer_linux.cc)6
-rw-r--r--media/video/capture/screen/x11/x_server_pixel_buffer.cc (renamed from media/video/capture/screen/linux/x_server_pixel_buffer.cc)2
-rw-r--r--media/video/capture/screen/x11/x_server_pixel_buffer.h (renamed from media/video/capture/screen/linux/x_server_pixel_buffer.h)6
5 files changed, 45 insertions, 10 deletions
diff --git a/media/media.gyp b/media/media.gyp
index 0b369ea..7bfee3d 100644
--- a/media/media.gyp
+++ b/media/media.gyp
@@ -346,8 +346,8 @@
'video/capture/screen/differ.h',
'video/capture/screen/differ_block.cc',
'video/capture/screen/differ_block.h',
- 'video/capture/screen/linux/x_server_pixel_buffer.cc',
- 'video/capture/screen/linux/x_server_pixel_buffer.h',
+ 'video/capture/screen/x11/x_server_pixel_buffer.cc',
+ 'video/capture/screen/x11/x_server_pixel_buffer.h',
'video/capture/screen/mac/desktop_configuration.mm',
'video/capture/screen/mac/desktop_configuration.h',
'video/capture/screen/mac/scoped_pixel_buffer_object.cc',
@@ -367,8 +367,9 @@
'video/capture/screen/screen_capturer_fake.h',
'video/capture/screen/screen_capturer_helper.cc',
'video/capture/screen/screen_capturer_helper.h',
- 'video/capture/screen/screen_capturer_linux.cc',
+ 'video/capture/screen/screen_capturer_x11.cc',
'video/capture/screen/screen_capturer_mac.mm',
+ 'video/capture/screen/screen_capturer_null.cc',
'video/capture/screen/screen_capturer_win.cc',
'video/capture/screen/shared_buffer.cc',
'video/capture/screen/shared_buffer.h',
@@ -429,6 +430,11 @@
'USE_NEON'
],
}],
+ ['OS != "linux" or use_x11 == 1', {
+ 'sources!': [
+ 'video/capture/screen/screen_capturer_null.cc',
+ ]
+ }],
['OS != "ios"', {
'dependencies': [
'../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
diff --git a/media/video/capture/screen/screen_capturer_null.cc b/media/video/capture/screen/screen_capturer_null.cc
new file mode 100644
index 0000000..19c9fca
--- /dev/null
+++ b/media/video/capture/screen/screen_capturer_null.cc
@@ -0,0 +1,29 @@
+// Copyright (c) 2013 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "media/video/capture/screen/screen_capturer.h"
+
+namespace media {
+
+scoped_refptr<SharedBuffer> ScreenCapturer::Delegate::CreateSharedBuffer(
+ uint32 size) {
+ return scoped_refptr<SharedBuffer>();
+}
+
+void ScreenCapturer::Delegate::ReleaseSharedBuffer(
+ scoped_refptr<SharedBuffer> buffer) {
+}
+
+// static
+scoped_ptr<ScreenCapturer> ScreenCapturer::Create() {
+ return scoped_ptr<ScreenCapturer>();
+}
+
+// static
+scoped_ptr<ScreenCapturer> ScreenCapturer::CreateWithXDamage(
+ bool use_x_damage) {
+ return scoped_ptr<ScreenCapturer>();
+}
+
+} // namespace media
diff --git a/media/video/capture/screen/screen_capturer_linux.cc b/media/video/capture/screen/screen_capturer_x11.cc
index 2f4559b..76778c3 100644
--- a/media/video/capture/screen/screen_capturer_linux.cc
+++ b/media/video/capture/screen/screen_capturer_x11.cc
@@ -4,10 +4,10 @@
#include "media/video/capture/screen/screen_capturer.h"
-#include <X11/Xlib.h>
-#include <X11/Xutil.h>
#include <X11/extensions/Xdamage.h>
#include <X11/extensions/Xfixes.h>
+#include <X11/Xlib.h>
+#include <X11/Xutil.h>
#include <set>
@@ -17,12 +17,12 @@
#include "base/stl_util.h"
#include "base/time.h"
#include "media/video/capture/screen/differ.h"
-#include "media/video/capture/screen/linux/x_server_pixel_buffer.h"
#include "media/video/capture/screen/mouse_cursor_shape.h"
#include "media/video/capture/screen/screen_capture_data.h"
#include "media/video/capture/screen/screen_capture_frame.h"
#include "media/video/capture/screen/screen_capture_frame_queue.h"
#include "media/video/capture/screen/screen_capturer_helper.h"
+#include "media/video/capture/screen/x11/x_server_pixel_buffer.h"
namespace media {
diff --git a/media/video/capture/screen/linux/x_server_pixel_buffer.cc b/media/video/capture/screen/x11/x_server_pixel_buffer.cc
index 11d6220..980f1ca 100644
--- a/media/video/capture/screen/linux/x_server_pixel_buffer.cc
+++ b/media/video/capture/screen/x11/x_server_pixel_buffer.cc
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "media/video/capture/screen/linux/x_server_pixel_buffer.h"
+#include "media/video/capture/screen/x11/x_server_pixel_buffer.h"
#include <sys/shm.h>
diff --git a/media/video/capture/screen/linux/x_server_pixel_buffer.h b/media/video/capture/screen/x11/x_server_pixel_buffer.h
index a565a73..139fbbf 100644
--- a/media/video/capture/screen/linux/x_server_pixel_buffer.h
+++ b/media/video/capture/screen/x11/x_server_pixel_buffer.h
@@ -4,8 +4,8 @@
// Don't include this file in any .h files because it pulls in some X headers.
-#ifndef MEDIA_VIDEO_CAPTURE_SCREEN_LINUX_X_SERVER_PIXEL_BUFFER_H_
-#define MEDIA_VIDEO_CAPTURE_SCREEN_LINUX_X_SERVER_PIXEL_BUFFER_H_
+#ifndef MEDIA_VIDEO_CAPTURE_SCREEN_X11_X_SERVER_PIXEL_BUFFER_H_
+#define MEDIA_VIDEO_CAPTURE_SCREEN_X11_X_SERVER_PIXEL_BUFFER_H_
#include "base/basictypes.h"
#include "third_party/skia/include/core/SkRect.h"
@@ -75,4 +75,4 @@ class XServerPixelBuffer {
} // namespace media
-#endif // MEDIA_VIDEO_CAPTURE_SCREEN_LINUX_X_SERVER_PIXEL_BUFFER_H_
+#endif // MEDIA_VIDEO_CAPTURE_SCREEN_X11_X_SERVER_PIXEL_BUFFER_H_