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

Unified Diff: services/ui/public/cpp/gpu/mojo_gpu_memory_buffer_manager.h

Issue 2562623005: mus/gpu: Rename the client/server side memory buffer managers. (Closed)
Patch Set: tot merge Created 4 years 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: services/ui/public/cpp/gpu/mojo_gpu_memory_buffer_manager.h
diff --git a/services/ui/public/cpp/gpu/mojo_gpu_memory_buffer_manager.h b/services/ui/public/cpp/gpu/mojo_gpu_memory_buffer_manager.h
deleted file mode 100644
index d1f5e339f376378ca8b45fd612f78978b98f1d92..0000000000000000000000000000000000000000
--- a/services/ui/public/cpp/gpu/mojo_gpu_memory_buffer_manager.h
+++ /dev/null
@@ -1,68 +0,0 @@
-// Copyright 2015 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.
-
-#ifndef SERVICES_UI_PUBLIC_CPP_GPU_MOJO_GPU_MEMORY_BUFFER_MANAGER_H_
-#define SERVICES_UI_PUBLIC_CPP_GPU_MOJO_GPU_MEMORY_BUFFER_MANAGER_H_
-
-#include <memory>
-#include <vector>
-
-#include "base/macros.h"
-#include "base/memory/ref_counted.h"
-#include "base/memory/weak_ptr.h"
-#include "base/threading/thread.h"
-#include "gpu/command_buffer/client/gpu_memory_buffer_manager.h"
-#include "services/ui/public/interfaces/gpu_service.mojom.h"
-
-namespace base {
-class WaitableEvent;
-}
-
-namespace ui {
-
-namespace mojom {
-class GpuService;
-}
-
-class MojoGpuMemoryBufferManager : public gpu::GpuMemoryBufferManager {
- public:
- explicit MojoGpuMemoryBufferManager(mojom::GpuServicePtr gpu_service);
- ~MojoGpuMemoryBufferManager() override;
-
- private:
- void InitThread(mojo::InterfacePtrInfo<mojom::GpuService> gpu_service_info);
- void TearDownThread();
- void AllocateGpuMemoryBufferOnThread(const gfx::Size& size,
- gfx::BufferFormat format,
- gfx::BufferUsage usage,
- gfx::GpuMemoryBufferHandle* handle,
- base::WaitableEvent* wait);
- void DeletedGpuMemoryBuffer(gfx::GpuMemoryBufferId id,
- const gpu::SyncToken& sync_token);
-
- // Overridden from gpu::GpuMemoryBufferManager:
- std::unique_ptr<gfx::GpuMemoryBuffer> CreateGpuMemoryBuffer(
- const gfx::Size& size,
- gfx::BufferFormat format,
- gfx::BufferUsage usage,
- gpu::SurfaceHandle surface_handle) override;
- std::unique_ptr<gfx::GpuMemoryBuffer> CreateGpuMemoryBufferFromHandle(
- const gfx::GpuMemoryBufferHandle& handle,
- const gfx::Size& size,
- gfx::BufferFormat format) override;
- void SetDestructionSyncToken(gfx::GpuMemoryBuffer* buffer,
- const gpu::SyncToken& sync_token) override;
- int counter_ = 0;
- // TODO(sad): Explore the option of doing this from an existing thread.
- base::Thread thread_;
- mojom::GpuServicePtr gpu_service_;
- base::WeakPtr<MojoGpuMemoryBufferManager> weak_ptr_;
- base::WeakPtrFactory<MojoGpuMemoryBufferManager> weak_ptr_factory_;
-
- DISALLOW_COPY_AND_ASSIGN(MojoGpuMemoryBufferManager);
-};
-
-} // namespace ui
-
-#endif // SERVICES_UI_PUBLIC_CPP_GPU_MOJO_GPU_MEMORY_BUFFER_MANAGER_H_
« no previous file with comments | « services/ui/public/cpp/gpu/gpu_service.cc ('k') | services/ui/public/cpp/gpu/mojo_gpu_memory_buffer_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698