[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc
kbr at google.com
kbr at google.com
Wed Dec 22 13:29:28 UTC 2010
The following commit has been merged in the debian/experimental branch:
commit fc43fddcddde0b1288834b43a1276bea36da5721
Author: kbr at google.com <kbr at google.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Thu Sep 16 23:03:51 2010 +0000
2010-09-16 Kenneth Russell <kbr at google.com>
Reviewed by James Robinson.
[chromium] Add needed entry points to WebGraphicsContext3D for compositor
https://bugs.webkit.org/show_bug.cgi?id=45921
* public/WebGraphicsContext3D.h:
* src/WebGraphicsContext3DDefaultImpl.cpp:
(WebKit::WebGraphicsContext3DDefaultImpl::initialize):
(WebKit::WebGraphicsContext3DDefaultImpl::supportsMapSubCHROMIUM):
(WebKit::WebGraphicsContext3DDefaultImpl::mapBufferSubDataCHROMIUM):
(WebKit::WebGraphicsContext3DDefaultImpl::unmapBufferSubDataCHROMIUM):
(WebKit::WebGraphicsContext3DDefaultImpl::mapTexSubImage2DCHROMIUM):
(WebKit::WebGraphicsContext3DDefaultImpl::unmapTexSubImage2DCHROMIUM):
(WebKit::WebGraphicsContext3DDefaultImpl::supportsCopyTextureToParentTextureCHROMIUM):
(WebKit::WebGraphicsContext3DDefaultImpl::copyTextureToParentTextureCHROMIUM):
* src/WebGraphicsContext3DDefaultImpl.h:
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@67677 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebKit/chromium/ChangeLog b/WebKit/chromium/ChangeLog
index 9ef6fe3..afb45c1 100644
--- a/WebKit/chromium/ChangeLog
+++ b/WebKit/chromium/ChangeLog
@@ -1,3 +1,22 @@
+2010-09-16 Kenneth Russell <kbr at google.com>
+
+ Reviewed by James Robinson.
+
+ [chromium] Add needed entry points to WebGraphicsContext3D for compositor
+ https://bugs.webkit.org/show_bug.cgi?id=45921
+
+ * public/WebGraphicsContext3D.h:
+ * src/WebGraphicsContext3DDefaultImpl.cpp:
+ (WebKit::WebGraphicsContext3DDefaultImpl::initialize):
+ (WebKit::WebGraphicsContext3DDefaultImpl::supportsMapSubCHROMIUM):
+ (WebKit::WebGraphicsContext3DDefaultImpl::mapBufferSubDataCHROMIUM):
+ (WebKit::WebGraphicsContext3DDefaultImpl::unmapBufferSubDataCHROMIUM):
+ (WebKit::WebGraphicsContext3DDefaultImpl::mapTexSubImage2DCHROMIUM):
+ (WebKit::WebGraphicsContext3DDefaultImpl::unmapTexSubImage2DCHROMIUM):
+ (WebKit::WebGraphicsContext3DDefaultImpl::supportsCopyTextureToParentTextureCHROMIUM):
+ (WebKit::WebGraphicsContext3DDefaultImpl::copyTextureToParentTextureCHROMIUM):
+ * src/WebGraphicsContext3DDefaultImpl.h:
+
2010-09-15 Tony Chang <tony at chromium.org>
Reviewed by Kent Tamura.
diff --git a/WebKit/chromium/public/WebGraphicsContext3D.h b/WebKit/chromium/public/WebGraphicsContext3D.h
index 44a0498..9857174 100644
--- a/WebKit/chromium/public/WebGraphicsContext3D.h
+++ b/WebKit/chromium/public/WebGraphicsContext3D.h
@@ -83,6 +83,11 @@ public:
// Initializes the graphics context; should be the first operation performed
// on newly-constructed instances. Returns true on success.
+ virtual bool initialize(Attributes, WebView*, bool renderDirectlyToWebView) = 0;
+
+ // Initializes the graphics context; should be the first operation performed
+ // on newly-constructed instances. Returns true on success.
+ // FIXME: remove this entry point once the compositor is switched to use GraphicsContext3D.
virtual bool initialize(Attributes, WebView*) = 0;
// Makes the OpenGL context current on the current thread. Returns true on
@@ -134,8 +139,20 @@ public:
// getError in the order they were added.
virtual void synthesizeGLError(unsigned long error) = 0;
+ // EXT_texture_format_BGRA8888
virtual bool supportsBGRA() = 0;
+ // GL_CHROMIUM_map_sub
+ virtual bool supportsMapSubCHROMIUM() = 0;
+ virtual void* mapBufferSubDataCHROMIUM(unsigned target, int offset, int size, unsigned access) = 0;
+ virtual void unmapBufferSubDataCHROMIUM(const void*) = 0;
+ virtual void* mapTexSubImage2DCHROMIUM(unsigned target, int level, int xoffset, int yoffset, int width, int height, unsigned format, unsigned type, unsigned access) = 0;
+ virtual void unmapTexSubImage2DCHROMIUM(const void*) = 0;
+
+ // GL_CHROMIUM_copy_texture_to_parent_texture
+ virtual bool supportsCopyTextureToParentTextureCHROMIUM() = 0;
+ virtual void copyTextureToParentTextureCHROMIUM(unsigned texture, unsigned parentTexture) = 0;
+
// The entry points below map directly to the OpenGL ES 2.0 API.
// See: http://www.khronos.org/registry/gles/
// and: http://www.khronos.org/opengles/sdk/docs/man/
diff --git a/WebKit/chromium/src/WebGraphicsContext3DDefaultImpl.cpp b/WebKit/chromium/src/WebGraphicsContext3DDefaultImpl.cpp
index 6e1adca..24dcf9a 100644
--- a/WebKit/chromium/src/WebGraphicsContext3DDefaultImpl.cpp
+++ b/WebKit/chromium/src/WebGraphicsContext3DDefaultImpl.cpp
@@ -97,11 +97,16 @@ WebGraphicsContext3DDefaultImpl::~WebGraphicsContext3DDefaultImpl()
}
}
-bool WebGraphicsContext3DDefaultImpl::initialize(WebGraphicsContext3D::Attributes attributes, WebView* webView)
+bool WebGraphicsContext3DDefaultImpl::initialize(WebGraphicsContext3D::Attributes attributes, WebView* webView, bool renderDirectlyToWebView)
{
+ if (renderDirectlyToWebView) {
+ // This mode isn't supported with the in-process implementation yet. (FIXME)
+ return false;
+ }
+
if (!gfx::GLContext::InitializeOneOff())
return false;
-
+
m_glContext = WTF::adoptPtr(gfx::GLContext::CreateOffscreenGLContext(0));
if (!m_glContext)
return false;
@@ -114,6 +119,11 @@ bool WebGraphicsContext3DDefaultImpl::initialize(WebGraphicsContext3D::Attribute
return true;
}
+bool WebGraphicsContext3DDefaultImpl::initialize(WebGraphicsContext3D::Attributes attributes, WebView* webView)
+{
+ return initialize(attributes, webView, false);
+}
+
void WebGraphicsContext3DDefaultImpl::validateAttributes()
{
const char* extensions = reinterpret_cast<const char*>(glGetString(GL_EXTENSIONS));
@@ -463,6 +473,40 @@ bool WebGraphicsContext3DDefaultImpl::supportsBGRA()
return false;
}
+bool WebGraphicsContext3DDefaultImpl::supportsMapSubCHROMIUM()
+{
+ // We don't claim support for this extension at this time
+ return false;
+}
+
+void* WebGraphicsContext3DDefaultImpl::mapBufferSubDataCHROMIUM(unsigned target, int offset, int size, unsigned access)
+{
+ return 0;
+}
+
+void WebGraphicsContext3DDefaultImpl::unmapBufferSubDataCHROMIUM(const void* mem)
+{
+}
+
+void* WebGraphicsContext3DDefaultImpl::mapTexSubImage2DCHROMIUM(unsigned target, int level, int xoffset, int yoffset, int width, int height, unsigned format, unsigned type, unsigned access)
+{
+ return 0;
+}
+
+void WebGraphicsContext3DDefaultImpl::unmapTexSubImage2DCHROMIUM(const void* mem)
+{
+}
+
+bool WebGraphicsContext3DDefaultImpl::supportsCopyTextureToParentTextureCHROMIUM()
+{
+ // We don't claim support for this extension at this time
+ return false;
+}
+
+void WebGraphicsContext3DDefaultImpl::copyTextureToParentTextureCHROMIUM(unsigned id, unsigned id2)
+{
+}
+
// Helper macros to reduce the amount of code.
#define DELEGATE_TO_GL(name, glname) \
diff --git a/WebKit/chromium/src/WebGraphicsContext3DDefaultImpl.h b/WebKit/chromium/src/WebGraphicsContext3DDefaultImpl.h
index a4c5b4b..5bf439a 100644
--- a/WebKit/chromium/src/WebGraphicsContext3DDefaultImpl.h
+++ b/WebKit/chromium/src/WebGraphicsContext3DDefaultImpl.h
@@ -59,6 +59,8 @@ public:
//----------------------------------------------------------------------
// WebGraphicsContext3D methods
+ virtual bool initialize(WebGraphicsContext3D::Attributes attributes, WebView*, bool);
+ // FIXME: remove once compositor is switched over to GraphicsContext3D.
virtual bool initialize(WebGraphicsContext3D::Attributes attributes, WebView*);
virtual bool makeContextCurrent();
@@ -80,6 +82,13 @@ public:
virtual void synthesizeGLError(unsigned long error);
virtual bool supportsBGRA();
+ virtual bool supportsMapSubCHROMIUM();
+ virtual void* mapBufferSubDataCHROMIUM(unsigned target, int offset, int size, unsigned access);
+ virtual void unmapBufferSubDataCHROMIUM(const void*);
+ virtual void* mapTexSubImage2DCHROMIUM(unsigned target, int level, int xoffset, int yoffset, int width, int height, unsigned format, unsigned type, unsigned access);
+ virtual void unmapTexSubImage2DCHROMIUM(const void*);
+ virtual bool supportsCopyTextureToParentTextureCHROMIUM();
+ virtual void copyTextureToParentTextureCHROMIUM(unsigned texture, unsigned parentTexture);
virtual void activeTexture(unsigned long texture);
virtual void attachShader(WebGLId program, WebGLId shader);
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list