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

Unified Diff: cc/resource_provider.cc

Issue 12212007: cc: Route offscreen context creation for compositor to the browser. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: add cc::GaneshResourceProvider Created 7 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
Index: cc/resource_provider.cc
diff --git a/cc/resource_provider.cc b/cc/resource_provider.cc
index 67d3adfb05d339b547b6ab831703494ee3326446..fde4783b8edb53be44ee60955bfe50c01cecc2da 100644
--- a/cc/resource_provider.cc
+++ b/cc/resource_provider.cc
@@ -11,6 +11,7 @@
#include "base/stl_util.h"
#include "base/string_split.h"
#include "base/string_util.h"
+#include "cc/ganesh_resource_provider.h"
#include "cc/gl_renderer.h" // For the GLC() macro.
#include "cc/platform_color.h"
#include "cc/texture_uploader.h"
@@ -552,6 +553,7 @@ ResourceProvider::ResourceProvider(OutputSurface* context)
, m_useShallowFlush(false)
, m_maxTextureSize(0)
, m_bestTextureFormat(0)
+ , m_ganeshResourceProvider(GaneshResourceProvider::Create())
{
}
@@ -1051,5 +1053,8 @@ void ResourceProvider::lazyAllocate(Resource* resource) {
GLC(context3d, context3d->texImage2D(GL_TEXTURE_2D, 0, format, size.width(), size.height(), 0, format, GL_UNSIGNED_BYTE, 0));
}
+void ResourceProvider::setGaneshContexts(WebKit::WebGraphicsContext3D* context3d, GrContext* grContext) {
+ m_ganeshResourceProvider->set_contexts(context3d, grContext);
+}
} // namespace cc
« cc/gl_renderer.cc ('K') | « cc/resource_provider.h ('k') | cc/resource_update_controller.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698