Index: gpu/command_buffer/client/gles2_implementation.cc |
diff --git a/gpu/command_buffer/client/gles2_implementation.cc b/gpu/command_buffer/client/gles2_implementation.cc |
index f60d7772a36e2801ac12d51dd3eab312cc48485e..e0e5fc3b88198ebe3605343816ebf586ad3c97cd 100644 |
--- a/gpu/command_buffer/client/gles2_implementation.cc |
+++ b/gpu/command_buffer/client/gles2_implementation.cc |
@@ -5005,10 +5005,12 @@ void GLES2Implementation::ScheduleDCLayerCHROMIUM( |
GLuint background_color, |
GLuint edge_aa_mask, |
const GLfloat* bounds_rect, |
- GLuint filter) { |
+ GLuint filter, |
+ GLsizei color_space_size, |
+ const GLvoid* color_space) { |
const size_t kRectsSize = 8 * sizeof(GLfloat); |
size_t textures_size = num_textures * sizeof(GLuint); |
- size_t shm_size = kRectsSize + textures_size; |
+ size_t shm_size = kRectsSize + textures_size + color_space_size; |
ScopedTransferBufferPtr buffer(shm_size, helper_, transfer_buffer_); |
if (!buffer.valid() || buffer.size() < shm_size) { |
SetGLError(GL_OUT_OF_MEMORY, "GLES2::ScheduleDCLayerCHROMIUM", |
@@ -5020,8 +5022,12 @@ void GLES2Implementation::ScheduleDCLayerCHROMIUM( |
memcpy(mem + 4, bounds_rect, 4 * sizeof(GLfloat)); |
memcpy(static_cast<char*>(buffer.address()) + kRectsSize, |
contents_texture_ids, textures_size); |
+ if (color_space_size) |
+ memcpy(static_cast<char*>(buffer.address()) + kRectsSize + textures_size, |
+ color_space, color_space_size); |
helper_->ScheduleDCLayerCHROMIUM(num_textures, background_color, edge_aa_mask, |
- filter, buffer.shm_id(), buffer.offset()); |
+ filter, color_space_size, buffer.shm_id(), |
+ buffer.offset()); |
} |
void GLES2Implementation::CommitOverlayPlanesCHROMIUM() { |