diff options
author | kkinnunen <kkinnunen@nvidia.com> | 2015-11-23 00:25:25 -0800 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-11-23 08:26:14 +0000 |
commit | 8fbcba14c3ad7a6e27293dce819450e5aa44e4aa (patch) | |
tree | 9a72ee41d786b261f8b276d737132496d9c982b1 /cc/output | |
parent | cf2f7169157ddfa960fb9edebb65f203846dfd08 (diff) | |
download | chromium_src-8fbcba14c3ad7a6e27293dce819450e5aa44e4aa.zip chromium_src-8fbcba14c3ad7a6e27293dce819450e5aa44e4aa.tar.gz chromium_src-8fbcba14c3ad7a6e27293dce819450e5aa44e4aa.tar.bz2 |
command_buffer: Make inactive bound uniforms reserve the location
Specifying uniform values with locations bound with
CHROMIUM_bind_uniform_location should work, regardless whether
the underlying driver optimized the variable away or not.
Fixes the case where updating an inactive uniform would cause
INVALID_OPERATION, because the location was empty.
Fixes the case where updating an uniform would cause wrong
uniform to be updated, if the uniform was inactive and bound
to a location that would be assigned to an unbound uniform.
Makes the Program::uniform_infos_ array linear (non-sparse). The
location bindings are now handled with Program::uniform_locations_
sparse array.
Simplifies the correction of driver-supplied uniform names and
determining whether an uniform is an array or not.
Fixes a cc bug exposed by the implementation (cc_unittests):
VideoGLRendererPixelTest.YUVAEdgeBleed
VideoGLRendererPixelTest.SimpleYUVARect
BUG=542355
CQ_INCLUDE_TRYBOTS=tryserver.blink:linux_blink_rel
Review URL: https://codereview.chromium.org/1419393005
Cr-Commit-Position: refs/heads/master@{#361076}
Diffstat (limited to 'cc/output')
-rw-r--r-- | cc/output/shader.cc | 11 |
1 files changed, 2 insertions, 9 deletions
diff --git a/cc/output/shader.cc b/cc/output/shader.cc index f356c7c..de1ddd4 100644 --- a/cc/output/shader.cc +++ b/cc/output/shader.cc @@ -2105,15 +2105,8 @@ void FragmentShaderYUVAVideo::Init(GLES2Interface* context, unsigned program, int* base_uniform_index) { static const char* uniforms[] = { - "y_texture", - "u_texture", - "v_texture", - "a_texture", - "alpha", - "cc_matrix", - "yuv_adj", - "ya_clamp_rect", - "uv_clamp_rect", + "y_texture", "u_texture", "v_texture", "a_texture", "alpha", + "yuv_matrix", "yuv_adj", "ya_clamp_rect", "uv_clamp_rect", }; int locations[arraysize(uniforms)]; |