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

Issue 788123002: Add sampler related ES3 APIs to command buffer. (Closed)

Created:
6 years ago by Zhenyao Mo
Modified:
5 years, 11 months ago
Reviewers:
bajones, piman
CC:
chromium-reviews, Ken Russell (switch to Gerrit), piman+watch_chromium.org, no sievers, vmiura
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Project:
chromium
Visibility:
Public.

Description

Add sampler related ES3 APIs to command buffer. Including: glGetSamplerParameter*v glSamplerParameter*v glSamplerParameteri/f glBindSampler glDeleteSamplers glGenSamplers glIsSampler One major feature that I add is the client/service ID mapping handling. BUG=429053 TEST=gpu_unittests R=bajones@chromium.org Committed: https://crrev.com/bcb3fdd69b3a04edf3f48e333ea42a8ec6f0177b Cr-Commit-Position: refs/heads/master@{#307810}

Patch Set 1 #

Total comments: 8
Unified diffs Side-by-side diffs Delta from patch set Stats (+2536 lines, -341 lines) Patch
M gpu/GLES2/gl2chromium_autogen.h View 6 chunks +10 lines, -0 lines 0 comments Download
M gpu/command_buffer/build_gles2_cmd_buffer.py View 28 chunks +286 lines, -29 lines 0 comments Download
M gpu/command_buffer/client/gles2_c_lib_autogen.h View 12 chunks +74 lines, -0 lines 0 comments Download
M gpu/command_buffer/client/gles2_cmd_helper_autogen.h View 6 chunks +96 lines, -0 lines 0 comments Download
M gpu/command_buffer/client/gles2_implementation.h View 5 chunks +8 lines, -0 lines 0 comments Download
M gpu/command_buffer/client/gles2_implementation.cc View 3 chunks +32 lines, -0 lines 2 comments Download
M gpu/command_buffer/client/gles2_implementation_autogen.h View 6 chunks +28 lines, -0 lines 0 comments Download
M gpu/command_buffer/client/gles2_implementation_impl_autogen.h View 6 chunks +174 lines, -0 lines 0 comments Download
M gpu/command_buffer/client/gles2_implementation_unittest.cc View 2 chunks +2 lines, -0 lines 0 comments Download
M gpu/command_buffer/client/gles2_implementation_unittest_autogen.h View 6 chunks +150 lines, -0 lines 0 comments Download
M gpu/command_buffer/client/gles2_interface_autogen.h View 6 chunks +18 lines, -0 lines 0 comments Download
M gpu/command_buffer/client/gles2_interface_stub_autogen.h View 6 chunks +18 lines, -0 lines 0 comments Download
M gpu/command_buffer/client/gles2_interface_stub_impl_autogen.h View 6 chunks +34 lines, -0 lines 0 comments Download
M gpu/command_buffer/client/gles2_trace_implementation_autogen.h View 6 chunks +18 lines, -0 lines 0 comments Download
M gpu/command_buffer/client/gles2_trace_implementation_impl_autogen.h View 6 chunks +63 lines, -0 lines 0 comments Download
M gpu/command_buffer/cmd_buffer_functions.txt View 6 chunks +10 lines, -0 lines 0 comments Download
M gpu/command_buffer/common/gles2_cmd_format.h View 1 chunk +1 line, -0 lines 0 comments Download
M gpu/command_buffer/common/gles2_cmd_format_autogen.h View 6 chunks +448 lines, -0 lines 0 comments Download
M gpu/command_buffer/common/gles2_cmd_format_test_autogen.h View 6 chunks +158 lines, -0 lines 0 comments Download
M gpu/command_buffer/common/gles2_cmd_ids_autogen.h View 1 chunk +236 lines, -226 lines 0 comments Download
M gpu/command_buffer/common/gles2_cmd_utils_autogen.h View 1 chunk +1 line, -0 lines 0 comments Download
M gpu/command_buffer/common/gles2_cmd_utils_implementation_autogen.h View 1 chunk +16 lines, -0 lines 0 comments Download
M gpu/command_buffer/service/context_group.h View 3 chunks +22 lines, -0 lines 0 comments Download
M gpu/command_buffer/service/gles2_cmd_decoder.cc View 2 chunks +17 lines, -0 lines 4 comments Download
M gpu/command_buffer/service/gles2_cmd_decoder_autogen.h View 6 chunks +246 lines, -0 lines 2 comments Download
M gpu/command_buffer/service/gles2_cmd_decoder_unittest_1_autogen.h View 5 chunks +120 lines, -70 lines 0 comments Download
M gpu/command_buffer/service/gles2_cmd_decoder_unittest_2_autogen.h View 9 chunks +197 lines, -14 lines 0 comments Download
M gpu/command_buffer/service/gles2_cmd_decoder_unittest_3_autogen.h View 1 chunk +14 lines, -0 lines 0 comments Download
M gpu/command_buffer/service/gles2_cmd_decoder_unittest_base.h View 3 chunks +7 lines, -1 line 0 comments Download
M gpu/command_buffer/service/gles2_cmd_decoder_unittest_base.cc View 3 chunks +17 lines, -1 line 0 comments Download
M gpu/command_buffer/service/gles2_cmd_validation_autogen.h View 1 chunk +1 line, -0 lines 0 comments Download
M gpu/command_buffer/service/gles2_cmd_validation_implementation_autogen.h View 2 chunks +14 lines, -0 lines 0 comments Download

Messages

Total messages: 12 (2 generated)
Zhenyao Mo
bajones: please review. kbr,sievers, vmiura: FYI, but feel free to review.
6 years ago (2014-12-10 01:54:10 UTC) #1
Zhenyao Mo
https://codereview.chromium.org/788123002/diff/1/gpu/command_buffer/service/gles2_cmd_decoder.cc File gpu/command_buffer/service/gles2_cmd_decoder.cc (right): https://codereview.chromium.org/788123002/diff/1/gpu/command_buffer/service/gles2_cmd_decoder.cc#newcode5869 gpu/command_buffer/service/gles2_cmd_decoder.cc:5869: glSamplerParameterf(sampler, pname, params[0]); This is use glSamplerParameterf to implement ...
6 years ago (2014-12-10 01:59:12 UTC) #2
bajones
https://codereview.chromium.org/788123002/diff/1/gpu/command_buffer/client/gles2_implementation.cc File gpu/command_buffer/client/gles2_implementation.cc (right): https://codereview.chromium.org/788123002/diff/1/gpu/command_buffer/client/gles2_implementation.cc#newcode2318 gpu/command_buffer/client/gles2_implementation.cc:2318: GLsizei /* n */, const GLuint* /* samplers */) ...
6 years ago (2014-12-10 23:13:58 UTC) #3
Zhenyao Mo
https://codereview.chromium.org/788123002/diff/1/gpu/command_buffer/client/gles2_implementation.cc File gpu/command_buffer/client/gles2_implementation.cc (right): https://codereview.chromium.org/788123002/diff/1/gpu/command_buffer/client/gles2_implementation.cc#newcode2318 gpu/command_buffer/client/gles2_implementation.cc:2318: GLsizei /* n */, const GLuint* /* samplers */) ...
6 years ago (2014-12-10 23:41:15 UTC) #4
bajones
lgtm
6 years ago (2014-12-10 23:44:00 UTC) #5
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/788123002/1
6 years ago (2014-12-10 23:48:18 UTC) #7
commit-bot: I haz the power
Committed patchset #1 (id:1)
6 years ago (2014-12-11 00:49:28 UTC) #8
commit-bot: I haz the power
Patchset 1 (id:??) landed as https://crrev.com/bcb3fdd69b3a04edf3f48e333ea42a8ec6f0177b Cr-Commit-Position: refs/heads/master@{#307810}
6 years ago (2014-12-11 00:50:14 UTC) #9
piman
https://codereview.chromium.org/788123002/diff/1/gpu/command_buffer/service/gles2_cmd_decoder.cc File gpu/command_buffer/service/gles2_cmd_decoder.cc (right): https://codereview.chromium.org/788123002/diff/1/gpu/command_buffer/service/gles2_cmd_decoder.cc#newcode5867 gpu/command_buffer/service/gles2_cmd_decoder.cc:5867: GLuint sampler, GLenum pname, const GLfloat* params) { These ...
5 years, 11 months ago (2015-01-09 07:10:57 UTC) #11
Zhenyao Mo
5 years, 11 months ago (2015-01-09 17:45:28 UTC) #12
Message was sent while issue was closed.
https://codereview.chromium.org/788123002/diff/1/gpu/command_buffer/service/g...
File gpu/command_buffer/service/gles2_cmd_decoder.cc (right):

https://codereview.chromium.org/788123002/diff/1/gpu/command_buffer/service/g...
gpu/command_buffer/service/gles2_cmd_decoder.cc:5867: GLuint sampler, GLenum
pname, const GLfloat* params) {
On 2015/01/09 07:10:57, piman (Very slow to review) wrote:
> These 2 methods need to be disabled if !unsafe_es3_apis_enabled(), otherwise
> they will call into NULL on an ES2 implementation, and crash the GPU process.

The check happens in Handle* function, which is the only place that calls the
Do* function.

https://codereview.chromium.org/788123002/diff/1/gpu/command_buffer/service/g...
File gpu/command_buffer/service/gles2_cmd_decoder_autogen.h (right):

https://codereview.chromium.org/788123002/diff/1/gpu/command_buffer/service/g...
gpu/command_buffer/service/gles2_cmd_decoder_autogen.h:92:
group_->GetSamplerServiceId(sampler, &sampler);
On 2015/01/09 07:10:57, piman (Very slow to review) wrote:
> This needs to properly handle failure.
> Spec says GL_INVALID_OPERATION needs to be generated if the name was not
created
> by GenSamplers (or 0).
> If that happens, here, you're ignoring the failure, and passing the client id
to
> the driver instead of raising an error.

Will do.

Powered by Google App Engine
This is Rietveld 408576698