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

Unified Diff: gpu/command_buffer/build_gles2_cmd_buffer.py

Issue 169403005: command_buffer: Implement path rendering functions for CHROMIUM_path_rendering (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@nv-pr-02-texgen
Patch Set: rebase and cleanup ids Created 6 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: gpu/command_buffer/build_gles2_cmd_buffer.py
diff --git a/gpu/command_buffer/build_gles2_cmd_buffer.py b/gpu/command_buffer/build_gles2_cmd_buffer.py
index 796e081a509a145df34c7dbe2080017281947197..646373ed063a7b713176377c03fef880d20e3c41 100755
--- a/gpu/command_buffer/build_gles2_cmd_buffer.py
+++ b/gpu/command_buffer/build_gles2_cmd_buffer.py
@@ -536,6 +536,31 @@ _STATES = {
},
],
},
+ 'PathStencilFuncCHROMIUM': {
+ 'type': 'Normal',
+ 'func': 'PathStencilFuncNV',
+ 'extension_flag': 'chromium_path_rendering',
+ 'states': [
+ {
+ 'name': 'stencil_path_func',
+ 'type': 'GLenum',
+ 'enum': 'GL_PATH_STENCIL_FUNC_CHROMIUM',
+ 'default': 'GL_ALWAYS',
+ },
+ {
+ 'name': 'stencil_path_ref',
+ 'type': 'GLint',
+ 'enum': 'GL_PATH_STENCIL_REF_CHROMIUM',
+ 'default': '0',
+ },
+ {
+ 'name': 'stencil_path_mask',
+ 'type': 'GLuint',
+ 'enum': 'GL_PATH_STENCIL_VALUE_MASK_CHROMIUM',
+ 'default': '0xFFFFFFFFU',
+ },
+ ],
+ },
}
# Named type info object represents a named type that is used in OpenGL call
@@ -1099,6 +1124,40 @@ _NAMED_TYPE_INFO = {
'GL_INT',
],
},
+ 'PathFillMode': {
+ 'type': 'GLenum',
+ 'valid': [
+ 'GL_INVERT',
+ 'GL_COUNT_UP_CHROMIUM',
+ 'GL_COUNT_DOWN_CHROMIUM',
+ ],
+ },
+ 'PathParameter': {
+ 'type': 'GLenum',
+ 'valid': [
+ 'GL_PATH_STROKE_WIDTH_CHROMIUM',
+ 'GL_PATH_INITIAL_END_CAP_CHROMIUM',
+ 'GL_PATH_TERMINAL_END_CAP_CHROMIUM',
+ 'GL_PATH_JOIN_STYLE_CHROMIUM',
+ 'GL_PATH_MITER_LIMIT_CHROMIUM',
+ ]
+ },
+ 'PathParameterCapValues': {
+ 'type': 'GLint',
+ 'valid': [
+ 'GL_FLAT',
+ 'GL_SQUARE_CHROMIUM',
+ 'GL_ROUND_CHROMIUM',
+ ]
+ },
+ 'PathParameterJoinValues': {
+ 'type': 'GLint',
+ 'valid': [
+ 'GL_MITER_REVERT_CHROMIUM',
+ 'GL_BEVEL_CHROMIUM',
+ 'GL_ROUND_CHROMIUM',
+ ]
+ },
'ReadPixelType': {
'type': 'GLenum',
'valid': [
@@ -2611,6 +2670,94 @@ _FUNCTION_INFO = {
'extension': True,
'extension_flag': 'chromium_path_rendering',
},
+ 'GenPathsCHROMIUM': {
+ 'type': 'Custom',
+ 'cmd_args': 'GLuint first_client_id, GLsizei range',
+ 'chromium': True,
+ 'extension': True,
+ 'extension_flag': 'chromium_path_rendering',
+ },
+ 'DeletePathsCHROMIUM': {
+ 'type': 'Custom',
+ 'cmd_args': 'GLuint first_client_id, GLsizei range',
+ 'impl_func': False,
+ 'unit_test': False,
+ 'chromium': True,
+ 'extension': True,
+ 'extension_flag': 'chromium_path_rendering',
+ },
+ 'IsPathCHROMIUM': {
+ 'type': 'Is',
+ 'decoder_func': 'DoIsPathCHROMIUM',
+ 'gl_test_func': 'glIsPathNV',
+ 'chromium': True,
+ 'extension': True,
+ 'extension_flag': 'chromium_path_rendering',
+ },
+ 'PathCommandsCHROMIUM': {
+ 'type': 'Manual',
+ 'immediate': False,
+ 'chromium': True,
+ 'extension': True,
+ 'extension_flag': 'chromium_path_rendering',
+ },
+ 'PathParameterfCHROMIUM': {
+ 'type': 'Custom',
+ 'chromium': True,
+ 'extension': True,
+ 'extension_flag': 'chromium_path_rendering',
+ },
+ 'PathParameteriCHROMIUM': {
+ 'type': 'Custom',
+ 'chromium': True,
+ 'extension': True,
+ 'extension_flag': 'chromium_path_rendering',
+ },
+ 'PathStencilFuncCHROMIUM': {
+ 'type': 'StateSet',
+ 'state': 'PathStencilFuncCHROMIUM',
+ 'decoder_func': 'glPathStencilFuncNV',
+ 'chromium': True,
+ 'extension': True,
+ 'extension_flag': 'chromium_path_rendering',
+ },
+ 'StencilFillPathCHROMIUM': {
+ 'type': 'Custom',
+ 'chromium': True,
+ 'extension': True,
+ 'extension_flag': 'chromium_path_rendering',
+ },
+ 'StencilStrokePathCHROMIUM': {
+ 'type': 'Custom',
+ 'chromium': True,
+ 'extension': True,
+ 'extension_flag': 'chromium_path_rendering',
+ },
+ 'CoverFillPathCHROMIUM': {
+ 'type': 'Custom',
+ 'chromium': True,
+ 'extension': True,
+ 'extension_flag': 'chromium_path_rendering',
+ },
+ 'CoverStrokePathCHROMIUM': {
+ 'type': 'Custom',
+ 'chromium': True,
+ 'extension': True,
+ 'extension_flag': 'chromium_path_rendering',
+ },
+ 'StencilThenCoverFillPathCHROMIUM': {
+ 'type': 'Custom',
+ 'chromium': True,
+ 'extension': True,
+ 'extension_flag': 'chromium_path_rendering',
+ },
+ 'StencilThenCoverStrokePathCHROMIUM': {
+ 'type': 'Custom',
+ 'chromium': True,
+ 'extension': True,
+ 'extension_flag': 'chromium_path_rendering',
+ },
+
}
@@ -5797,6 +5944,7 @@ TEST_P(%(test_name)s, %(name)sInvalidArgsBadSharedMemoryId) {
def WriteServiceImplementation(self, func, file):
"""Overrriden from TypeHandler."""
self.WriteServiceHandlerFunctionHeader(func, file)
+ self.WriteHandlerExtensionCheck(func, file)
args = func.GetOriginalArgs()
for arg in args:
arg.WriteGetCode(file)

Powered by Google App Engine
This is Rietveld 408576698