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

Unified Diff: cc/tiles/gpu_image_decode_controller.h

Issue 2286583002: Make cc::SoftwareImageDecodeController, cc::ResourcePool, and cc::StagingBufferPoo… (Closed)
Patch Set: Fixed DEPS. Created 4 years, 4 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: cc/tiles/gpu_image_decode_controller.h
diff --git a/cc/tiles/gpu_image_decode_controller.h b/cc/tiles/gpu_image_decode_controller.h
index 345de1143573507e09cb430a4a89f854a039099c..9b5af7058ea14e7ee1c2ddee006910665d734917 100644
--- a/cc/tiles/gpu_image_decode_controller.h
+++ b/cc/tiles/gpu_image_decode_controller.h
@@ -16,6 +16,7 @@
#include "cc/base/cc_export.h"
#include "cc/resources/resource_format.h"
#include "cc/tiles/image_decode_controller.h"
+#include "components/memory_coordinator/common/memory_coordinator_client.h"
#include "third_party/skia/include/core/SkRefCnt.h"
class SkImageTextureData;
@@ -97,7 +98,8 @@ class ContextProvider;
//
class CC_EXPORT GpuImageDecodeController
: public ImageDecodeController,
- public base::trace_event::MemoryDumpProvider {
+ public base::trace_event::MemoryDumpProvider,
+ public memory_coordinator::MemoryCoordinatorClient {
public:
explicit GpuImageDecodeController(ContextProvider* context,
ResourceFormat decode_format,
@@ -301,6 +303,10 @@ class CC_EXPORT GpuImageDecodeController
ImageData* image_data);
void DeletePendingImages();
+ // Overriden from memory_coordinator::MemoryCoordinatorClient.
+ void OnMemoryStateChange(
+ memory_coordinator::mojom::MemoryState state) override;
+
const ResourceFormat format_;
ContextProvider* context_;
sk_sp<GrContextThreadSafeProxy> context_threadsafe_proxy_;

Powered by Google App Engine
This is Rietveld 408576698