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

Side by Side Diff: ui/gl/gl_image.h

Issue 331723003: gpu: Remove Create/DeleteImage IPC by adding an X11_PIXMAP_BUFFER GpuMemoryBuffer type. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef UI_GL_GL_IMAGE_H_ 5 #ifndef UI_GL_GL_IMAGE_H_
6 #define UI_GL_GL_IMAGE_H_ 6 #define UI_GL_GL_IMAGE_H_
7 7
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "ui/gfx/gpu_memory_buffer.h" 9 #include "ui/gfx/gpu_memory_buffer.h"
10 #include "ui/gfx/native_widget_types.h" 10 #include "ui/gfx/native_widget_types.h"
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 // Called before the texture image data will be modified. 42 // Called before the texture image data will be modified.
43 virtual void WillModifyTexImage() = 0; 43 virtual void WillModifyTexImage() = 0;
44 44
45 // Called after the texture image data has been modified. 45 // Called after the texture image data has been modified.
46 virtual void DidModifyTexImage() = 0; 46 virtual void DidModifyTexImage() = 0;
47 47
48 // Indicate that image should be released after use. 48 // Indicate that image should be released after use.
49 // (For an Android work-around only). 49 // (For an Android work-around only).
50 virtual void SetReleaseAfterUse(); 50 virtual void SetReleaseAfterUse();
51 51
52 // Create a GL image for a window.
53 static scoped_refptr<GLImage> CreateGLImage(gfx::PluginWindowHandle window);
54
55 // Create a GL image for a GPU Memory buffer. 52 // Create a GL image for a GPU Memory buffer.
56 static scoped_refptr<GLImage> CreateGLImageForGpuMemoryBuffer( 53 static scoped_refptr<GLImage> CreateGLImageForGpuMemoryBuffer(
57 gfx::GpuMemoryBufferHandle buffer, 54 gfx::GpuMemoryBufferHandle buffer,
58 gfx::Size size, 55 gfx::Size size,
59 unsigned internalformat); 56 unsigned internalformat);
60 57
61 protected: 58 protected:
62 virtual ~GLImage(); 59 virtual ~GLImage();
63 60
64 private: 61 private:
65 friend class base::RefCounted<GLImage>; 62 friend class base::RefCounted<GLImage>;
66 63
67 DISALLOW_COPY_AND_ASSIGN(GLImage); 64 DISALLOW_COPY_AND_ASSIGN(GLImage);
68 }; 65 };
69 66
70 } // namespace gfx 67 } // namespace gfx
71 68
72 #endif // UI_GL_GL_IMAGE_H_ 69 #endif // UI_GL_GL_IMAGE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698