| Index: ui/gl/gl_image_x11.cc
|
| diff --git a/ui/gl/gl_image_x11.cc b/ui/gl/gl_image_x11.cc
|
| index fe945eccbe938aead4af2caaf64966844c5ea65a..a6c09a1513710aa8634b4bfa41a0814d4a02f6bf 100644
|
| --- a/ui/gl/gl_image_x11.cc
|
| +++ b/ui/gl/gl_image_x11.cc
|
| @@ -6,6 +6,7 @@
|
|
|
| #include "base/debug/trace_event.h"
|
| #include "ui/gl/gl_image_glx.h"
|
| +#include "ui/gl/gl_image_shm.h"
|
| #include "ui/gl/gl_image_stub.h"
|
| #include "ui/gl/gl_implementation.h"
|
|
|
| @@ -40,7 +41,18 @@ scoped_refptr<GLImage> GLImage::CreateGLImageForGpuMemoryBuffer(
|
| case kGLImplementationOSMesaGL:
|
| case kGLImplementationDesktopGL:
|
| case kGLImplementationEGLGLES2:
|
| - return NULL;
|
| + switch (buffer.type) {
|
| + case SHARED_MEMORY_BUFFER: {
|
| + scoped_refptr<GLImageShm> image(new GLImageShm(size));
|
| + if (!image->Initialize(buffer))
|
| + return NULL;
|
| +
|
| + return image;
|
| + }
|
| + default:
|
| + NOTREACHED();
|
| + return NULL;
|
| + }
|
| case kGLImplementationMockGL:
|
| return new GLImageStub;
|
| default:
|
|
|