summaryrefslogtreecommitdiffstats
path: root/cc/output/gl_renderer_draw_cache.h
diff options
context:
space:
mode:
authoralokp@chromium.org <alokp@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-06-29 00:35:12 +0000
committeralokp@chromium.org <alokp@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-06-29 00:35:12 +0000
commitb54beedcc27bea274dba8bdaa55948d4a0447a63 (patch)
tree99ae61ad320b30b66eec65de7544e9301bf828da /cc/output/gl_renderer_draw_cache.h
parent44a4becb395b09648a40f261a9a91343fe322cad (diff)
downloadchromium_src-b54beedcc27bea274dba8bdaa55948d4a0447a63.zip
chromium_src-b54beedcc27bea274dba8bdaa55948d4a0447a63.tar.gz
chromium_src-b54beedcc27bea274dba8bdaa55948d4a0447a63.tar.bz2
Premultiply alpha in shader for non-premultiplied textures.
Instead of using different blending equations we can perform the pre-multiplication in the shader itself. I am working on improving the performance of compositing canvas elements with opaque background. This requires blending the canvas texture with the background color in the shader. The implementation of this blending equation becomes much easier if we can assume that textures are always premultiplied. BUG=236982 TEST=compositing/webgl/webgl-nonpremultiplied-blend.html Review URL: https://chromiumcodereview.appspot.com/16943021 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@209246 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'cc/output/gl_renderer_draw_cache.h')
-rw-r--r--cc/output/gl_renderer_draw_cache.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/cc/output/gl_renderer_draw_cache.h b/cc/output/gl_renderer_draw_cache.h
index e99cc27..85369ef 100644
--- a/cc/output/gl_renderer_draw_cache.h
+++ b/cc/output/gl_renderer_draw_cache.h
@@ -31,7 +31,6 @@ struct TexturedQuadDrawCache {
// Values tracked to determine if textured quads may be coalesced.
int program_id;
int resource_id;
- bool use_premultiplied_alpha;
bool needs_blending;
// Information about the program binding that is required to draw.
@@ -45,6 +44,7 @@ struct TexturedQuadDrawCache {
std::vector<float> vertex_opacity_data;
std::vector<Float16> matrix_data;
+ private:
DISALLOW_COPY_AND_ASSIGN(TexturedQuadDrawCache);
};