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

Unified Diff: components/view_manager/gles2/command_buffer_impl.cc

Issue 1181013010: Support impl-side painting in Mandoline. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix presubmit warning Created 5 years, 6 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: components/view_manager/gles2/command_buffer_impl.cc
diff --git a/components/view_manager/gles2/command_buffer_impl.cc b/components/view_manager/gles2/command_buffer_impl.cc
index 7725158ffe855d95016fcc29abed35a1c36d085e..1ae846435fc0a409f98e0926772cefcf3302e217 100644
--- a/components/view_manager/gles2/command_buffer_impl.cc
+++ b/components/view_manager/gles2/command_buffer_impl.cc
@@ -137,6 +137,25 @@ void CommandBufferImpl::Echo(const mojo::Callback<void()>& callback) {
base::Bind(&RunCallback, callback));
}
+void CommandBufferImpl::CreateImage(int32_t id,
+ mojo::ScopedHandle memory_handle,
+ int32 type,
+ mojo::SizePtr size,
+ int32_t format,
+ int32_t internal_format) {
+ driver_task_runner_->PostTask(
+ FROM_HERE, base::Bind(&CommandBufferDriver::CreateImage,
+ base::Unretained(driver_.get()), id,
+ base::Passed(&memory_handle), type,
+ base::Passed(&size), format, internal_format));
+}
+
+void CommandBufferImpl::DestroyImage(int32_t id) {
+ driver_task_runner_->PostTask(
+ FROM_HERE, base::Bind(&CommandBufferDriver::DestroyImage,
+ base::Unretained(driver_.get()), id));
+}
+
CommandBufferImpl::~CommandBufferImpl() {
if (observer_)
observer_->OnCommandBufferImplDestroyed();

Powered by Google App Engine
This is Rietveld 408576698