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

Unified Diff: media/gpu/ipc/service/gpu_jpeg_decode_accelerator.cc

Issue 1882373004: Migrate content/common/gpu/media code to media/gpu (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix several more bot-identified build issues Created 4 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: media/gpu/ipc/service/gpu_jpeg_decode_accelerator.cc
diff --git a/content/common/gpu/media/gpu_jpeg_decode_accelerator.cc b/media/gpu/ipc/service/gpu_jpeg_decode_accelerator.cc
similarity index 96%
rename from content/common/gpu/media/gpu_jpeg_decode_accelerator.cc
rename to media/gpu/ipc/service/gpu_jpeg_decode_accelerator.cc
index 6bf6ae4fba7d8c9ea451af3334740a0647f4a69f..bc04101b696832fd3c233a97a00faed5fc3ec33c 100644
--- a/content/common/gpu/media/gpu_jpeg_decode_accelerator.cc
+++ b/media/gpu/ipc/service/gpu_jpeg_decode_accelerator.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 "content/common/gpu/media/gpu_jpeg_decode_accelerator.h"
+#include "media/gpu/ipc/service/gpu_jpeg_decode_accelerator.h"
#include <stdint.h>
#include <utility>
@@ -25,11 +25,11 @@
#if defined(OS_CHROMEOS)
#if defined(ARCH_CPU_X86_FAMILY)
-#include "content/common/gpu/media/vaapi_jpeg_decode_accelerator.h"
+#include "media/gpu/vaapi_jpeg_decode_accelerator.h"
#endif
#if defined(USE_V4L2_CODEC)
-#include "content/common/gpu/media/v4l2_device.h"
-#include "content/common/gpu/media/v4l2_jpeg_decode_accelerator.h"
+#include "media/gpu/v4l2_device.h"
+#include "media/gpu/v4l2_jpeg_decode_accelerator.h"
#endif
#endif
@@ -68,13 +68,13 @@ bool VerifyDecodeParams(const AcceleratedJpegDecoderMsg_Decode_Params& params) {
} // namespace
-namespace content {
+namespace media {
class GpuJpegDecodeAccelerator::Client
: public media::JpegDecodeAccelerator::Client,
public base::NonThreadSafe {
public:
- Client(content::GpuJpegDecodeAccelerator* owner, int32_t route_id)
+ Client(media::GpuJpegDecodeAccelerator* owner, int32_t route_id)
: owner_(owner->AsWeakPtr()), route_id_(route_id) {}
~Client() override { DCHECK(CalledOnValidThread()); }
@@ -108,7 +108,7 @@ class GpuJpegDecodeAccelerator::Client
}
private:
- base::WeakPtr<content::GpuJpegDecodeAccelerator> owner_;
+ base::WeakPtr<media::GpuJpegDecodeAccelerator> owner_;
int32_t route_id_;
std::unique_ptr<media::JpegDecodeAccelerator> accelerator_;
};
@@ -299,8 +299,7 @@ GpuJpegDecodeAccelerator::GpuJpegDecodeAccelerator(
: channel_(channel),
child_task_runner_(base::ThreadTaskRunnerHandle::Get()),
io_task_runner_(io_task_runner),
- client_number_(0) {
-}
+ client_number_(0) {}
GpuJpegDecodeAccelerator::~GpuJpegDecodeAccelerator() {
DCHECK(CalledOnValidThread());
@@ -388,8 +387,8 @@ GpuJpegDecodeAccelerator::CreateV4L2JDA(
const scoped_refptr<base::SingleThreadTaskRunner>& io_task_runner) {
std::unique_ptr<media::JpegDecodeAccelerator> decoder;
#if defined(OS_CHROMEOS) && defined(USE_V4L2_CODEC)
- scoped_refptr<V4L2Device> device = V4L2Device::Create(
- V4L2Device::kJpegDecoder);
+ scoped_refptr<V4L2Device> device =
+ V4L2Device::Create(V4L2Device::kJpegDecoder);
if (device)
decoder.reset(new V4L2JpegDecodeAccelerator(device, io_task_runner));
#endif
@@ -422,4 +421,4 @@ bool GpuJpegDecodeAccelerator::IsSupported() {
return false;
}
-} // namespace content
+} // namespace media

Powered by Google App Engine
This is Rietveld 408576698