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

Unified Diff: ui/gl/gl_image_io_surface.h

Issue 1830453002: WebGL: GL_RGB emulation for IOSurface backed textures. [For reference only] (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Compile error. Created 4 years, 9 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
« no previous file with comments | « ui/gl/gl_image_glx.cc ('k') | ui/gl/gl_image_io_surface.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/gl/gl_image_io_surface.h
diff --git a/ui/gl/gl_image_io_surface.h b/ui/gl/gl_image_io_surface.h
index d8b731828f26d674176401f38b89489857fed367..cb949a45c047f8b7d499587e75b7574aa1b814d9 100644
--- a/ui/gl/gl_image_io_surface.h
+++ b/ui/gl/gl_image_io_surface.h
@@ -49,6 +49,7 @@ class GL_EXPORT GLImageIOSurface : public GLImage {
void OnMemoryDump(base::trace_event::ProcessMemoryDump* pmd,
uint64_t process_tracing_id,
const std::string& dump_name) override;
+ bool EmulatingRGB() const override;
gfx::GenericSharedMemoryId io_surface_id() const { return io_surface_id_; }
base::ScopedCFTypeRef<IOSurfaceRef> io_surface();
@@ -62,7 +63,13 @@ class GL_EXPORT GLImageIOSurface : public GLImage {
private:
const gfx::Size size_;
- const unsigned internalformat_;
+ unsigned internalformat_;
+
+ // This class is capable of emulating RGB internal format with RGBA
+ // internal format. The member |internalformat_| holds the format
+ // exposed to the command buffer. |desired_internalformat_| holds the format
+ // desired by the caller of the constructor of this object.
+ const unsigned desired_internalformat_;
gfx::BufferFormat format_;
base::ScopedCFTypeRef<IOSurfaceRef> io_surface_;
gfx::GenericSharedMemoryId io_surface_id_;
« no previous file with comments | « ui/gl/gl_image_glx.cc ('k') | ui/gl/gl_image_io_surface.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698