Chromium Code Reviews| 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 8f2d3f09c3d2b641cae5c739b5221c9519ecc66c..1160a183bc669feba29a111c4c64fdd8369182af 100644 |
| --- a/gpu/command_buffer/client/gles2_implementation.cc |
| +++ b/gpu/command_buffer/client/gles2_implementation.cc |
| @@ -3600,6 +3600,19 @@ void GLES2Implementation::ProduceTextureCHROMIUM(GLenum target, |
| CheckGLError(); |
| } |
| +void GLES2Implementation::ProduceTextureDirectCHROMIUM( |
| + GLuint texture, GLenum target, const GLbyte* data) { |
| + GPU_CLIENT_SINGLE_THREAD_CHECK(); |
| + GPU_CLIENT_LOG("[" << GetLogPrefix() << "] glProduceTextureDirectCHROMIUM(" |
| + << static_cast<const void*>(data) << ")"); |
| + const Mailbox& mailbox = *reinterpret_cast<const Mailbox*>(data); |
| + DCHECK(mailbox.Verify()) << "ProduceTextureDirectCHROMIUM was passed a " |
| + "mailbox that was not generated by " |
| + "GenMailboxCHROMIUM."; |
| + helper_->ProduceTextureDirectCHROMIUMImmediate(texture, target, data); |
| + CheckGLError(); |
| +} |
| + |
| void GLES2Implementation::ConsumeTextureCHROMIUM(GLenum target, |
| const GLbyte* data) { |
| GPU_CLIENT_SINGLE_THREAD_CHECK(); |
| @@ -3613,6 +3626,23 @@ void GLES2Implementation::ConsumeTextureCHROMIUM(GLenum target, |
| CheckGLError(); |
| } |
| +GLuint GLES2Implementation::CreateAndConsumeTextureCHROMIUM( |
| + GLenum target, const GLbyte* data) { |
| + GPU_CLIENT_SINGLE_THREAD_CHECK(); |
| + GPU_CLIENT_LOG("[" << GetLogPrefix() << "] glCreateAndConsumeTextureCHROMIUM(" |
| + << static_cast<const void*>(data) << ")"); |
| + const Mailbox& mailbox = *reinterpret_cast<const Mailbox*>(data); |
| + DCHECK(mailbox.Verify()) << "CreateAndConsumeTextureCHROMIUM was passed a " |
| + "mailbox that was not generated by " |
| + "GenMailboxCHROMIUM."; |
| + GLuint client_id; |
| + GetIdHandler(id_namespaces::kTextures)->MakeIds(this, 0, 1, &client_id); |
| + helper_->CreateAndConsumeTextureCHROMIUMImmediate(target, |
| + client_id, data); |
|
vmiura
2014/06/03 00:00:50
I think we need the following Flush() here to ensu
|
| + CheckGLError(); |
| + return client_id; |
| +} |
| + |
| void GLES2Implementation::PushGroupMarkerEXT( |
| GLsizei length, const GLchar* marker) { |
| GPU_CLIENT_SINGLE_THREAD_CHECK(); |