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

Issue 15792007: gpu: Autogenerate glHint state (Closed)

Created:
7 years, 6 months ago by Sami
Modified:
7 years, 6 months ago
Reviewers:
greggman
CC:
chromium-reviews, apatrick_chromium
Visibility:
Public.

Description

gpu: Autogenerate glHint state This patch implements automated code generation for state that is set with the glHint function. Currently this state includes GL_GENERATE_MIPMAP_HINT and GL_FRAGMENT_SHADER_DERIVATIVE_HINT_OES. In order to support functions like glHint that take an enum identifying the state variable whose value is being set, we add a new 'NamedParameter' state type to the command buffer code generator. Functions of this type are expected to take the parameter enum as the first argument and the value as the second one. This same mechanism can also be used with glPixelStorei and other similar functions. BUG=245228 TEST=glHint test in [1] passes repeatedly with --enable-virtual-gl-contexts. [1] https://www.khronos.org/registry/webgl/conformance-suites/1.0.1/conformance/extensions/oes-standard-derivatives.html Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=203463

Patch Set 1 #

Total comments: 4

Patch Set 2 : Initialize extension state conditionally. Exclude extension tokens from static validity tables. #

Total comments: 2

Patch Set 3 : Switch-case instead of if-series. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+125 lines, -27 lines) Patch
M gpu/command_buffer/build_gles2_cmd_buffer.py View 1 2 7 chunks +72 lines, -2 lines 0 comments Download
M gpu/command_buffer/common/gles2_cmd_utils_implementation_autogen.h View 1 1 chunk +1 line, -0 lines 0 comments Download
M gpu/command_buffer/service/context_state.h View 1 chunk +0 lines, -3 lines 0 comments Download
M gpu/command_buffer/service/context_state.cc View 2 chunks +0 lines, -6 lines 0 comments Download
M gpu/command_buffer/service/context_state_autogen.h View 1 chunk +2 lines, -0 lines 0 comments Download
M gpu/command_buffer/service/context_state_impl_autogen.h View 1 4 chunks +30 lines, -0 lines 0 comments Download
M gpu/command_buffer/service/gles2_cmd_decoder.cc View 2 chunks +0 lines, -15 lines 0 comments Download
M gpu/command_buffer/service/gles2_cmd_decoder_autogen.h View 1 2 1 chunk +16 lines, -1 line 0 comments Download
M gpu/command_buffer/service/gles2_cmd_decoder_unittest_0_autogen.h View 1 1 chunk +3 lines, -0 lines 0 comments Download
M gpu/command_buffer/service/gles2_cmd_validation_implementation_autogen.h View 1 1 chunk +1 line, -0 lines 0 comments Download

Messages

Total messages: 10 (0 generated)
Sami
7 years, 6 months ago (2013-05-30 14:55:51 UTC) #1
greggman
A couple of issues. Sorry I don't have any easy suggestions to deal with it. ...
7 years, 6 months ago (2013-05-30 17:15:23 UTC) #2
greggman
Random ideas 1) Maybe add some flags to NamedParameter that say if the state is ...
7 years, 6 months ago (2013-05-30 17:25:09 UTC) #3
Sami
On 2013/05/30 17:25:09, greggman wrote: > Random ideas > > 1) Maybe add some flags ...
7 years, 6 months ago (2013-05-30 17:51:10 UTC) #4
Sami
PTAL https://codereview.chromium.org/15792007/diff/1/gpu/command_buffer/service/context_state_impl_autogen.h File gpu/command_buffer/service/context_state_impl_autogen.h (right): https://codereview.chromium.org/15792007/diff/1/gpu/command_buffer/service/context_state_impl_autogen.h#newcode114 gpu/command_buffer/service/context_state_impl_autogen.h:114: glHint( On 2013/05/30 17:15:24, greggman wrote: > You ...
7 years, 6 months ago (2013-05-30 18:59:45 UTC) #5
greggman
looks good. just one question https://codereview.chromium.org/15792007/diff/7001/gpu/command_buffer/service/gles2_cmd_decoder_autogen.h File gpu/command_buffer/service/gles2_cmd_decoder_autogen.h (right): https://codereview.chromium.org/15792007/diff/7001/gpu/command_buffer/service/gles2_cmd_decoder_autogen.h#newcode1410 gpu/command_buffer/service/gles2_cmd_decoder_autogen.h:1410: if (target == GL_GENERATE_MIPMAP_HINT ...
7 years, 6 months ago (2013-05-30 19:57:16 UTC) #6
Sami
https://codereview.chromium.org/15792007/diff/7001/gpu/command_buffer/service/gles2_cmd_decoder_autogen.h File gpu/command_buffer/service/gles2_cmd_decoder_autogen.h (right): https://codereview.chromium.org/15792007/diff/7001/gpu/command_buffer/service/gles2_cmd_decoder_autogen.h#newcode1410 gpu/command_buffer/service/gles2_cmd_decoder_autogen.h:1410: if (target == GL_GENERATE_MIPMAP_HINT && On 2013/05/30 19:57:16, greggman ...
7 years, 6 months ago (2013-05-31 09:40:20 UTC) #7
greggman
lgtm
7 years, 6 months ago (2013-05-31 17:43:48 UTC) #8
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/skyostil@chromium.org/15792007/11001
7 years, 6 months ago (2013-05-31 17:51:41 UTC) #9
commit-bot: I haz the power
7 years, 6 months ago (2013-05-31 20:10:20 UTC) #10
Message was sent while issue was closed.
Change committed as 203463

Powered by Google App Engine
This is Rietveld 408576698