| Index: device/capture/content/android/screen_capture_machine_android.cc
|
| diff --git a/media/capture/content/android/screen_capture_machine_android.cc b/device/capture/content/android/screen_capture_machine_android.cc
|
| similarity index 92%
|
| rename from media/capture/content/android/screen_capture_machine_android.cc
|
| rename to device/capture/content/android/screen_capture_machine_android.cc
|
| index 204cb55a66263f348a46360d179d95366e0f7ee2..1b36f87f376042ad23afa8df13ec310ac3093ab3 100644
|
| --- a/media/capture/content/android/screen_capture_machine_android.cc
|
| +++ b/device/capture/content/android/screen_capture_machine_android.cc
|
| @@ -2,18 +2,18 @@
|
| // Use of this source code is governed by a BSD-style license that can be
|
| // found in the LICENSE file.
|
|
|
| -#include "media/capture/content/android/screen_capture_machine_android.h"
|
| +#include "device/capture/content/android/screen_capture_machine_android.h"
|
|
|
| #include "base/android/context_utils.h"
|
| #include "base/android/jni_android.h"
|
| #include "base/android/scoped_java_ref.h"
|
| +#include "device/capture/content/video_capture_oracle.h"
|
| #include "jni/ScreenCapture_jni.h"
|
| -#include "media/capture/content/video_capture_oracle.h"
|
| #include "third_party/libyuv/include/libyuv.h"
|
|
|
| using base::android::AttachCurrentThread;
|
|
|
| -namespace media {
|
| +namespace device {
|
|
|
| // static
|
| bool ScreenCaptureMachineAndroid::RegisterScreenCaptureMachine(JNIEnv* env) {
|
| @@ -55,15 +55,15 @@ void ScreenCaptureMachineAndroid::OnRGBAFrameAvailable(JNIEnv* env,
|
| return;
|
| }
|
|
|
| - DCHECK(frame->format() == PIXEL_FORMAT_I420 ||
|
| - frame->format() == PIXEL_FORMAT_YV12);
|
| + DCHECK(frame->format() == media::PIXEL_FORMAT_I420 ||
|
| + frame->format() == media::PIXEL_FORMAT_YV12);
|
|
|
| scoped_refptr<VideoFrame> temp_frame = frame;
|
| if (frame->visible_rect().width() != width ||
|
| frame->visible_rect().height() != height) {
|
| temp_frame = VideoFrame::CreateFrame(
|
| - PIXEL_FORMAT_I420, gfx::Size(width, height), gfx::Rect(width, height),
|
| - gfx::Size(width, height), base::TimeDelta());
|
| + media::PIXEL_FORMAT_I420, gfx::Size(width, height),
|
| + gfx::Rect(width, height), gfx::Size(width, height), base::TimeDelta());
|
| }
|
|
|
| uint8_t* const src =
|
| @@ -130,15 +130,15 @@ void ScreenCaptureMachineAndroid::OnI420FrameAvailable(JNIEnv* env,
|
| return;
|
| }
|
|
|
| - DCHECK(frame->format() == PIXEL_FORMAT_I420 ||
|
| - frame->format() == PIXEL_FORMAT_YV12);
|
| + DCHECK(frame->format() == media::PIXEL_FORMAT_I420 ||
|
| + frame->format() == media::PIXEL_FORMAT_YV12);
|
|
|
| scoped_refptr<VideoFrame> temp_frame = frame;
|
| if (frame->visible_rect().width() != width ||
|
| frame->visible_rect().height() != height) {
|
| temp_frame = VideoFrame::CreateFrame(
|
| - PIXEL_FORMAT_I420, gfx::Size(width, height), gfx::Rect(width, height),
|
| - gfx::Size(width, height), base::TimeDelta());
|
| + media::PIXEL_FORMAT_I420, gfx::Size(width, height),
|
| + gfx::Rect(width, height), gfx::Size(width, height), base::TimeDelta());
|
| }
|
|
|
| uint8_t* const y_src =
|
| @@ -250,8 +250,8 @@ void ScreenCaptureMachineAndroid::MaybeCaptureForRefresh() {
|
| return;
|
| }
|
|
|
| - DCHECK(frame->format() == PIXEL_FORMAT_I420 ||
|
| - frame->format() == PIXEL_FORMAT_YV12);
|
| + DCHECK(frame->format() == media::PIXEL_FORMAT_I420 ||
|
| + frame->format() == media::PIXEL_FORMAT_YV12);
|
|
|
| libyuv::I420Scale(
|
| lastFrame_->visible_data(VideoFrame::kYPlane),
|
| @@ -272,4 +272,4 @@ void ScreenCaptureMachineAndroid::MaybeCaptureForRefresh() {
|
| capture_frame_cb.Run(frame, start_time, true);
|
| }
|
|
|
| -} // namespace media
|
| +} // namespace device
|
|
|