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

Unified Diff: cc/resources/resource_provider.h

Issue 935333002: Update from https://crrev.com/316786 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 10 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
« no previous file with comments | « cc/resources/recording_source.h ('k') | cc/resources/resource_provider.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/resources/resource_provider.h
diff --git a/cc/resources/resource_provider.h b/cc/resources/resource_provider.h
index 1fb5b60a23596c5b42f6169698871756b96a96ac..167ef201fcfd9c9fbff2eb748d3835c53df5de39 100644
--- a/cc/resources/resource_provider.h
+++ b/cc/resources/resource_provider.h
@@ -332,13 +332,17 @@ class CC_EXPORT ResourceProvider {
class CC_EXPORT ScopedWriteLockGr {
public:
ScopedWriteLockGr(ResourceProvider* resource_provider,
- ResourceProvider::ResourceId resource_id,
- bool use_distance_field_text,
- bool can_use_lcd_text,
- int msaa_sample_count);
+ ResourceProvider::ResourceId resource_id);
~ScopedWriteLockGr();
- SkSurface* get_sk_surface() { return sk_surface_.get(); }
+ void InitSkSurface(bool use_worker_context,
+ bool use_distance_field_text,
+ bool can_use_lcd_text,
+ int msaa_sample_count);
+ void ReleaseSkSurface();
+
+ SkSurface* sk_surface() { return sk_surface_.get(); }
+ ResourceProvider::Resource* resource() { return resource_; }
private:
ResourceProvider* resource_provider_;
@@ -426,6 +430,8 @@ class CC_EXPORT ResourceProvider {
static GLint GetActiveTextureUnit(gpu::gles2::GLES2Interface* gl);
+ OutputSurface* output_surface() { return output_surface_; }
+
private:
struct Resource {
enum Origin { Internal, External, Delegated };
@@ -560,7 +566,7 @@ class CC_EXPORT ResourceProvider {
// Returns NULL if the output_surface_ does not have a ContextProvider.
gpu::gles2::GLES2Interface* ContextGL() const;
- class GrContext* GrContext() const;
+ class GrContext* GrContext(bool worker_context) const;
OutputSurface* output_surface_;
SharedBitmapManager* shared_bitmap_manager_;
« no previous file with comments | « cc/resources/recording_source.h ('k') | cc/resources/resource_provider.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698