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

Side by Side Diff: cc/tiles/gpu_image_decode_controller.h

Issue 1866043006: cc: Remove ScheduleOnOriginThread() and CompleteOnOriginThread(). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: nits Created 4 years, 7 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 unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CC_TILES_GPU_IMAGE_DECODE_CONTROLLER_H_ 5 #ifndef CC_TILES_GPU_IMAGE_DECODE_CONTROLLER_H_
6 #define CC_TILES_GPU_IMAGE_DECODE_CONTROLLER_H_ 6 #define CC_TILES_GPU_IMAGE_DECODE_CONTROLLER_H_
7 7
8 #include <memory> 8 #include <memory>
9 #include <unordered_map> 9 #include <unordered_map>
10 #include <vector> 10 #include <vector>
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
64 bool GetTaskForImageAndRef(const DrawImage& image, 64 bool GetTaskForImageAndRef(const DrawImage& image,
65 const TracingInfo& tracing_info, 65 const TracingInfo& tracing_info,
66 scoped_refptr<TileTask>* task) override; 66 scoped_refptr<TileTask>* task) override;
67 void UnrefImage(const DrawImage& image) override; 67 void UnrefImage(const DrawImage& image) override;
68 DecodedDrawImage GetDecodedImageForDraw(const DrawImage& draw_image) override; 68 DecodedDrawImage GetDecodedImageForDraw(const DrawImage& draw_image) override;
69 void DrawWithImageFinished(const DrawImage& image, 69 void DrawWithImageFinished(const DrawImage& image,
70 const DecodedDrawImage& decoded_image) override; 70 const DecodedDrawImage& decoded_image) override;
71 void ReduceCacheUsage() override; 71 void ReduceCacheUsage() override;
72 void SetShouldAggressivelyFreeResources( 72 void SetShouldAggressivelyFreeResources(
73 bool aggressively_free_resources) override; 73 bool aggressively_free_resources) override;
74 void OnImageDecodeTaskCompleted(TileTask* task) override;
75 void OnImageUploadTaskCompleted(TileTask* task) override;
74 76
75 // MemoryDumpProvider overrides. 77 // MemoryDumpProvider overrides.
76 bool OnMemoryDump(const base::trace_event::MemoryDumpArgs& args, 78 bool OnMemoryDump(const base::trace_event::MemoryDumpArgs& args,
77 base::trace_event::ProcessMemoryDump* pmd) override; 79 base::trace_event::ProcessMemoryDump* pmd) override;
78 80
79 // Called by Decode / Upload tasks. 81 // Called by Decode / Upload tasks.
80 void DecodeImage(const DrawImage& image); 82 void DecodeImage(const DrawImage& image);
81 void UploadImage(const DrawImage& image); 83 void UploadImage(const DrawImage& image);
82 void DecodeTaskCompleted(const DrawImage& image); 84 void DecodeTaskCompleted(const DrawImage& image);
83 void UploadTaskCompleted(const DrawImage& image); 85 void UploadTaskCompleted(const DrawImage& image);
(...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after
190 192
191 // We can't release GPU backed SkImages without holding the context lock, 193 // We can't release GPU backed SkImages without holding the context lock,
192 // so we add them to this list and defer deletion until the next time the lock 194 // so we add them to this list and defer deletion until the next time the lock
193 // is held. 195 // is held.
194 std::vector<sk_sp<SkImage>> images_pending_deletion_; 196 std::vector<sk_sp<SkImage>> images_pending_deletion_;
195 }; 197 };
196 198
197 } // namespace cc 199 } // namespace cc
198 200
199 #endif // CC_TILES_GPU_IMAGE_DECODE_CONTROLLER_H_ 201 #endif // CC_TILES_GPU_IMAGE_DECODE_CONTROLLER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698