1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 // This file is auto-generated from
6 // gpu/command_buffer/build_gles2_cmd_buffer.py
7 // It's formatted by clang-format using chromium coding style:
8 // clang-format -i -style=chromium filename
11 #ifndef GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_VALIDATION_IMPLEMENTATION_AUTOGEN_H_
12 #define GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_VALIDATION_IMPLEMENTATION_AUTOGEN_H_
14 static const GLenum valid_attachment_table
[] = {
17 GL_STENCIL_ATTACHMENT
,
20 static const GLenum valid_attachment_table_es3
[] = {
21 GL_DEPTH_STENCIL_ATTACHMENT
,
24 static const GLenum valid_backbuffer_attachment_table
[] = {
30 static const GLenum valid_blit_filter_table
[] = {
35 static const GLenum valid_buffer_mode_table
[] = {
36 GL_INTERLEAVED_ATTRIBS
,
40 static const GLenum valid_buffer_parameter_table
[] = {
45 static const GLenum valid_buffer_parameter_table_es3
[] = {
46 GL_BUFFER_ACCESS_FLAGS
,
52 static const GLenum valid_buffer_target_table
[] = {
54 GL_ELEMENT_ARRAY_BUFFER
,
57 static const GLenum valid_buffer_target_table_es3
[] = {
61 GL_PIXEL_UNPACK_BUFFER
,
62 GL_TRANSFORM_FEEDBACK_BUFFER
,
66 static const GLenum valid_buffer_usage_table
[] = {
72 static const GLenum valid_buffer_usage_table_es3
[] = {
81 static const GLenum valid_bufferfi_table
[] = {
85 static const GLenum valid_bufferfv_table
[] = {
90 static const GLenum valid_bufferiv_table
[] = {
95 static const GLenum valid_bufferuiv_table
[] = {
99 static const GLenum valid_capability_table
[] = {
104 GL_POLYGON_OFFSET_FILL
,
105 GL_SAMPLE_ALPHA_TO_COVERAGE
,
111 static const GLenum valid_capability_table_es3
[] = {
112 GL_RASTERIZER_DISCARD
,
113 GL_PRIMITIVE_RESTART_FIXED_INDEX
,
116 static const GLenum valid_cmp_function_table
[] = {
127 static const GLenum valid_compressed_texture_format_table_es3
[] = {
128 GL_COMPRESSED_R11_EAC
,
129 GL_COMPRESSED_SIGNED_R11_EAC
,
130 GL_COMPRESSED_RG11_EAC
,
131 GL_COMPRESSED_SIGNED_RG11_EAC
,
132 GL_COMPRESSED_RGB8_ETC2
,
133 GL_COMPRESSED_SRGB8_ETC2
,
134 GL_COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2
,
135 GL_COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2
,
136 GL_COMPRESSED_RGBA8_ETC2_EAC
,
137 GL_COMPRESSED_SRGB8_ALPHA8_ETC2_EAC
,
140 static const GLenum valid_draw_mode_table
[] = {
150 static const GLenum valid_dst_blend_factor_table
[] = {
154 GL_ONE_MINUS_SRC_COLOR
,
156 GL_ONE_MINUS_DST_COLOR
,
158 GL_ONE_MINUS_SRC_ALPHA
,
160 GL_ONE_MINUS_DST_ALPHA
,
162 GL_ONE_MINUS_CONSTANT_COLOR
,
164 GL_ONE_MINUS_CONSTANT_ALPHA
,
167 static const GLenum valid_equation_table
[] = {
170 GL_FUNC_REVERSE_SUBTRACT
,
173 static const GLenum valid_equation_table_es3
[] = {
178 static const GLenum valid_face_mode_table
[] = {
183 static const GLenum valid_face_type_table
[] = {
189 static const GLenum valid_frame_buffer_parameter_table
[] = {
190 GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE
,
191 GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME
,
192 GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL
,
193 GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE
,
196 static const GLenum valid_frame_buffer_parameter_table_es3
[] = {
197 GL_FRAMEBUFFER_ATTACHMENT_RED_SIZE
,
198 GL_FRAMEBUFFER_ATTACHMENT_GREEN_SIZE
,
199 GL_FRAMEBUFFER_ATTACHMENT_BLUE_SIZE
,
200 GL_FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE
,
201 GL_FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE
,
202 GL_FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE
,
203 GL_FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE
,
204 GL_FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING
,
205 GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER
,
208 static const GLenum valid_frame_buffer_target_table
[] = {
212 static const GLenum valid_frame_buffer_target_table_es3
[] = {
217 static const GLenum valid_g_l_state_table
[] = {
219 GL_ALIASED_LINE_WIDTH_RANGE
,
220 GL_ALIASED_POINT_SIZE_RANGE
,
222 GL_ARRAY_BUFFER_BINDING
,
224 GL_COMPRESSED_TEXTURE_FORMATS
,
228 GL_ELEMENT_ARRAY_BUFFER_BINDING
,
229 GL_FRAMEBUFFER_BINDING
,
230 GL_GENERATE_MIPMAP_HINT
,
232 GL_IMPLEMENTATION_COLOR_READ_FORMAT
,
233 GL_IMPLEMENTATION_COLOR_READ_TYPE
,
234 GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS
,
235 GL_MAX_CUBE_MAP_TEXTURE_SIZE
,
236 GL_MAX_FRAGMENT_UNIFORM_VECTORS
,
237 GL_MAX_RENDERBUFFER_SIZE
,
238 GL_MAX_TEXTURE_IMAGE_UNITS
,
240 GL_MAX_VARYING_VECTORS
,
241 GL_MAX_VERTEX_ATTRIBS
,
242 GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS
,
243 GL_MAX_VERTEX_UNIFORM_VECTORS
,
244 GL_MAX_VIEWPORT_DIMS
,
245 GL_NUM_COMPRESSED_TEXTURE_FORMATS
,
246 GL_NUM_SHADER_BINARY_FORMATS
,
249 GL_RENDERBUFFER_BINDING
,
251 GL_SAMPLE_COVERAGE_INVERT
,
252 GL_SAMPLE_COVERAGE_VALUE
,
255 GL_SHADER_BINARY_FORMATS
,
259 GL_TEXTURE_BINDING_2D
,
260 GL_TEXTURE_BINDING_CUBE_MAP
,
262 GL_UNPACK_FLIP_Y_CHROMIUM
,
263 GL_UNPACK_PREMULTIPLY_ALPHA_CHROMIUM
,
264 GL_UNPACK_UNPREMULTIPLY_ALPHA_CHROMIUM
,
265 GL_BIND_GENERATES_RESOURCE_CHROMIUM
,
266 GL_VERTEX_ARRAY_BINDING_OES
,
269 GL_BLEND_EQUATION_RGB
,
270 GL_BLEND_EQUATION_ALPHA
,
275 GL_COLOR_CLEAR_VALUE
,
276 GL_DEPTH_CLEAR_VALUE
,
277 GL_STENCIL_CLEAR_VALUE
,
284 GL_POLYGON_OFFSET_FACTOR
,
285 GL_POLYGON_OFFSET_UNITS
,
288 GL_STENCIL_VALUE_MASK
,
289 GL_STENCIL_BACK_FUNC
,
291 GL_STENCIL_BACK_VALUE_MASK
,
292 GL_STENCIL_WRITEMASK
,
293 GL_STENCIL_BACK_WRITEMASK
,
295 GL_STENCIL_PASS_DEPTH_FAIL
,
296 GL_STENCIL_PASS_DEPTH_PASS
,
297 GL_STENCIL_BACK_FAIL
,
298 GL_STENCIL_BACK_PASS_DEPTH_FAIL
,
299 GL_STENCIL_BACK_PASS_DEPTH_PASS
,
304 GL_POLYGON_OFFSET_FILL
,
305 GL_SAMPLE_ALPHA_TO_COVERAGE
,
309 GL_RASTERIZER_DISCARD
,
310 GL_PRIMITIVE_RESTART_FIXED_INDEX
,
313 static const GLenum valid_g_l_state_table_es3
[] = {
314 GL_COPY_READ_BUFFER_BINDING
,
315 GL_COPY_WRITE_BUFFER_BINDING
,
332 GL_DRAW_FRAMEBUFFER_BINDING
,
333 GL_FRAGMENT_SHADER_DERIVATIVE_HINT
,
335 GL_MAX_3D_TEXTURE_SIZE
,
336 GL_MAX_ARRAY_TEXTURE_LAYERS
,
337 GL_MAX_COLOR_ATTACHMENTS
,
338 GL_MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS
,
339 GL_MAX_COMBINED_UNIFORM_BLOCKS
,
340 GL_MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS
,
342 GL_MAX_ELEMENT_INDEX
,
343 GL_MAX_ELEMENTS_INDICES
,
344 GL_MAX_ELEMENTS_VERTICES
,
345 GL_MAX_FRAGMENT_INPUT_COMPONENTS
,
346 GL_MAX_FRAGMENT_UNIFORM_BLOCKS
,
347 GL_MAX_FRAGMENT_UNIFORM_COMPONENTS
,
348 GL_MAX_PROGRAM_TEXEL_OFFSET
,
350 GL_MAX_SERVER_WAIT_TIMEOUT
,
351 GL_MAX_TEXTURE_LOD_BIAS
,
352 GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS
,
353 GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS
,
354 GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS
,
355 GL_MAX_UNIFORM_BLOCK_SIZE
,
356 GL_MAX_UNIFORM_BUFFER_BINDINGS
,
357 GL_MAX_VARYING_COMPONENTS
,
358 GL_MAX_VERTEX_OUTPUT_COMPONENTS
,
359 GL_MAX_VERTEX_UNIFORM_BLOCKS
,
360 GL_MAX_VERTEX_UNIFORM_COMPONENTS
,
361 GL_MIN_PROGRAM_TEXEL_OFFSET
,
364 GL_NUM_PROGRAM_BINARY_FORMATS
,
368 GL_PIXEL_PACK_BUFFER_BINDING
,
369 GL_PIXEL_UNPACK_BUFFER_BINDING
,
370 GL_PROGRAM_BINARY_FORMATS
,
372 GL_READ_FRAMEBUFFER_BINDING
,
374 GL_TEXTURE_BINDING_2D_ARRAY
,
375 GL_TEXTURE_BINDING_3D
,
376 GL_TRANSFORM_FEEDBACK_BINDING
,
377 GL_TRANSFORM_FEEDBACK_ACTIVE
,
378 GL_TRANSFORM_FEEDBACK_BUFFER_BINDING
,
379 GL_TRANSFORM_FEEDBACK_PAUSED
,
380 GL_TRANSFORM_FEEDBACK_BUFFER_SIZE
,
381 GL_TRANSFORM_FEEDBACK_BUFFER_START
,
382 GL_UNIFORM_BUFFER_BINDING
,
383 GL_UNIFORM_BUFFER_OFFSET_ALIGNMENT
,
384 GL_UNIFORM_BUFFER_SIZE
,
385 GL_UNIFORM_BUFFER_START
,
386 GL_UNPACK_IMAGE_HEIGHT
,
387 GL_UNPACK_ROW_LENGTH
,
388 GL_UNPACK_SKIP_IMAGES
,
389 GL_UNPACK_SKIP_PIXELS
,
393 static const GLenum valid_get_max_index_type_table
[] = {
399 static const GLenum valid_get_tex_param_target_table
[] = {
404 static const GLenum valid_get_tex_param_target_table_es3
[] = {
409 static const GLenum valid_hint_mode_table
[] = {
415 static const GLenum valid_hint_target_table
[] = {
416 GL_GENERATE_MIPMAP_HINT
,
419 static const GLenum valid_hint_target_table_es3
[] = {
420 GL_FRAGMENT_SHADER_DERIVATIVE_HINT
,
423 static const GLenum valid_image_internal_format_table
[] = {
425 GL_RGB_YUV_420_CHROMIUM
,
429 static const GLenum valid_image_usage_table
[] = {
434 static const GLenum valid_index_type_table
[] = {
439 static const GLenum valid_index_type_table_es3
[] = {
443 static const GLenum valid_indexed_buffer_target_table
[] = {
444 GL_TRANSFORM_FEEDBACK_BUFFER
,
448 static const GLenum valid_indexed_g_l_state_table
[] = {
449 GL_TRANSFORM_FEEDBACK_BUFFER_BINDING
,
450 GL_TRANSFORM_FEEDBACK_BUFFER_SIZE
,
451 GL_TRANSFORM_FEEDBACK_BUFFER_START
,
452 GL_UNIFORM_BUFFER_BINDING
,
453 GL_UNIFORM_BUFFER_SIZE
,
454 GL_UNIFORM_BUFFER_START
,
457 static const GLenum valid_internal_format_parameter_table
[] = {
458 GL_NUM_SAMPLE_COUNTS
,
462 static const GLenum valid_invalidate_frame_buffer_target_table
[] = {
466 static const GLenum valid_map_buffer_access_table
[] = {
469 GL_MAP_INVALIDATE_RANGE_BIT
,
470 GL_MAP_INVALIDATE_BUFFER_BIT
,
471 GL_MAP_FLUSH_EXPLICIT_BIT
,
472 GL_MAP_UNSYNCHRONIZED_BIT
,
475 static const GLenum valid_matrix_mode_table
[] = {
476 GL_PATH_PROJECTION_CHROMIUM
,
477 GL_PATH_MODELVIEW_CHROMIUM
,
480 static const GLenum valid_pixel_store_table
[] = {
483 GL_UNPACK_FLIP_Y_CHROMIUM
,
484 GL_UNPACK_PREMULTIPLY_ALPHA_CHROMIUM
,
485 GL_UNPACK_UNPREMULTIPLY_ALPHA_CHROMIUM
,
488 static const GLenum valid_pixel_store_table_es3
[] = {
492 GL_UNPACK_ROW_LENGTH
,
493 GL_UNPACK_IMAGE_HEIGHT
,
494 GL_UNPACK_SKIP_PIXELS
,
496 GL_UNPACK_SKIP_IMAGES
,
499 static const GLint valid_pixel_store_alignment_table
[] = {
506 static const GLenum valid_pixel_type_table
[] = {
508 GL_UNSIGNED_SHORT_5_6_5
,
509 GL_UNSIGNED_SHORT_4_4_4_4
,
510 GL_UNSIGNED_SHORT_5_5_5_1
,
513 static const GLenum valid_pixel_type_table_es3
[] = {
521 GL_UNSIGNED_INT_2_10_10_10_REV
,
522 GL_UNSIGNED_INT_10F_11F_11F_REV
,
523 GL_UNSIGNED_INT_5_9_9_9_REV
,
524 GL_UNSIGNED_INT_24_8
,
525 GL_FLOAT_32_UNSIGNED_INT_24_8_REV
,
528 static const GLenum valid_program_parameter_table
[] = {
534 GL_ACTIVE_ATTRIBUTES
,
535 GL_ACTIVE_ATTRIBUTE_MAX_LENGTH
,
537 GL_ACTIVE_UNIFORM_MAX_LENGTH
,
540 static const GLenum valid_program_parameter_table_es3
[] = {
541 GL_ACTIVE_UNIFORM_BLOCKS
,
542 GL_ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH
,
543 GL_TRANSFORM_FEEDBACK_BUFFER_MODE
,
544 GL_TRANSFORM_FEEDBACK_VARYINGS
,
545 GL_TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH
,
548 static const GLenum valid_query_object_parameter_table
[] = {
550 GL_QUERY_RESULT_AVAILABLE_EXT
,
553 static const GLenum valid_query_parameter_table
[] = {
554 GL_CURRENT_QUERY_EXT
,
557 static const GLenum valid_query_target_table
[] = {
558 GL_ANY_SAMPLES_PASSED_EXT
,
559 GL_ANY_SAMPLES_PASSED_CONSERVATIVE_EXT
,
560 GL_COMMANDS_ISSUED_CHROMIUM
,
561 GL_LATENCY_QUERY_CHROMIUM
,
562 GL_ASYNC_PIXEL_UNPACK_COMPLETED_CHROMIUM
,
563 GL_ASYNC_PIXEL_PACK_COMPLETED_CHROMIUM
,
564 GL_COMMANDS_COMPLETED_CHROMIUM
,
567 static const GLenum valid_read_pixel_format_table
[] = {
573 static const GLenum valid_read_pixel_format_table_es3
[] = {
577 static const GLenum deprecated_read_pixel_format_table_es3
[] = {
582 static const GLenum valid_read_pixel_type_table
[] = {
584 GL_UNSIGNED_SHORT_5_6_5
,
585 GL_UNSIGNED_SHORT_4_4_4_4
,
586 GL_UNSIGNED_SHORT_5_5_5_1
,
589 static const GLenum valid_read_pixel_type_table_es3
[] = {
595 static const GLenum deprecated_read_pixel_type_table_es3
[] = {
596 GL_UNSIGNED_SHORT_5_6_5
,
597 GL_UNSIGNED_SHORT_4_4_4_4
,
598 GL_UNSIGNED_SHORT_5_5_5_1
,
601 static const GLenum valid_render_buffer_format_table
[] = {
605 GL_DEPTH_COMPONENT16
,
609 static const GLenum valid_render_buffer_format_table_es3
[] = {
635 GL_DEPTH_COMPONENT24
,
636 GL_DEPTH_COMPONENT32F
,
638 GL_DEPTH32F_STENCIL8
,
641 static const GLenum valid_render_buffer_parameter_table
[] = {
642 GL_RENDERBUFFER_RED_SIZE
,
643 GL_RENDERBUFFER_GREEN_SIZE
,
644 GL_RENDERBUFFER_BLUE_SIZE
,
645 GL_RENDERBUFFER_ALPHA_SIZE
,
646 GL_RENDERBUFFER_DEPTH_SIZE
,
647 GL_RENDERBUFFER_STENCIL_SIZE
,
648 GL_RENDERBUFFER_WIDTH
,
649 GL_RENDERBUFFER_HEIGHT
,
650 GL_RENDERBUFFER_INTERNAL_FORMAT
,
653 static const GLenum valid_render_buffer_parameter_table_es3
[] = {
654 GL_RENDERBUFFER_SAMPLES
,
657 static const GLenum valid_render_buffer_target_table
[] = {
661 static const GLenum valid_reset_status_table
[] = {
662 GL_GUILTY_CONTEXT_RESET_ARB
,
663 GL_INNOCENT_CONTEXT_RESET_ARB
,
664 GL_UNKNOWN_CONTEXT_RESET_ARB
,
667 static const GLenum valid_sampler_parameter_table
[] = {
668 GL_TEXTURE_MAG_FILTER
,
669 GL_TEXTURE_MIN_FILTER
,
675 GL_TEXTURE_COMPARE_MODE
,
676 GL_TEXTURE_COMPARE_FUNC
,
679 static const GLenum valid_shader_parameter_table
[] = {
684 GL_SHADER_SOURCE_LENGTH
,
685 GL_TRANSLATED_SHADER_SOURCE_LENGTH_ANGLE
,
688 static const GLenum valid_shader_precision_table
[] = {
697 static const GLenum valid_shader_type_table
[] = {
702 static const GLenum valid_src_blend_factor_table
[] = {
706 GL_ONE_MINUS_SRC_COLOR
,
708 GL_ONE_MINUS_DST_COLOR
,
710 GL_ONE_MINUS_SRC_ALPHA
,
712 GL_ONE_MINUS_DST_ALPHA
,
714 GL_ONE_MINUS_CONSTANT_COLOR
,
716 GL_ONE_MINUS_CONSTANT_ALPHA
,
717 GL_SRC_ALPHA_SATURATE
,
720 static const GLenum valid_stencil_op_table
[] = {
731 static const GLenum valid_string_type_table
[] = {
735 GL_SHADING_LANGUAGE_VERSION
,
739 static const GLenum valid_subscription_target_table
[] = {
740 GL_MOUSE_POSITION_CHROMIUM
,
743 static const GLbitfield valid_sync_flush_flags_table
[] = {
744 GL_SYNC_FLUSH_COMMANDS_BIT
,
748 static const GLenum valid_sync_parameter_table
[] = {
755 static const GLenum valid_texture_3_d_target_table
[] = {
760 static const GLenum valid_texture_bind_target_table
[] = {
765 static const GLenum valid_texture_bind_target_table_es3
[] = {
770 static const GLenum valid_texture_compare_func_table
[] = {
781 static const GLenum valid_texture_compare_mode_table
[] = {
783 GL_COMPARE_REF_TO_TEXTURE
,
786 static const GLenum valid_texture_format_table
[] = {
794 static const GLenum valid_texture_format_table_es3
[] = {
805 static const GLenum valid_texture_internal_format_table
[] = {
813 static const GLenum valid_texture_internal_format_table_es3
[] = {
863 GL_DEPTH_COMPONENT16
,
864 GL_DEPTH_COMPONENT24
,
865 GL_DEPTH_COMPONENT32F
,
867 GL_DEPTH32F_STENCIL8
,
870 static const GLenum valid_texture_internal_format_storage_table
[] = {
876 GL_LUMINANCE8_ALPHA8_EXT
,
881 static const GLenum valid_texture_internal_format_storage_table_es3
[] = {
926 GL_DEPTH_COMPONENT16
,
927 GL_DEPTH_COMPONENT24
,
928 GL_DEPTH_COMPONENT32F
,
930 GL_DEPTH32F_STENCIL8
,
931 GL_COMPRESSED_R11_EAC
,
932 GL_COMPRESSED_SIGNED_R11_EAC
,
933 GL_COMPRESSED_RG11_EAC
,
934 GL_COMPRESSED_SIGNED_RG11_EAC
,
935 GL_COMPRESSED_RGB8_ETC2
,
936 GL_COMPRESSED_SRGB8_ETC2
,
937 GL_COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2
,
938 GL_COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2
,
939 GL_COMPRESSED_RGBA8_ETC2_EAC
,
940 GL_COMPRESSED_SRGB8_ALPHA8_ETC2_EAC
,
943 static const GLenum deprecated_texture_internal_format_storage_table_es3
[] = {
946 GL_LUMINANCE8_ALPHA8_EXT
,
949 GL_LUMINANCE_ALPHA16F_EXT
,
952 GL_LUMINANCE_ALPHA32F_EXT
,
955 static const GLenum valid_texture_mag_filter_mode_table
[] = {
960 static const GLenum valid_texture_min_filter_mode_table
[] = {
963 GL_NEAREST_MIPMAP_NEAREST
,
964 GL_LINEAR_MIPMAP_NEAREST
,
965 GL_NEAREST_MIPMAP_LINEAR
,
966 GL_LINEAR_MIPMAP_LINEAR
,
969 static const GLenum valid_texture_parameter_table
[] = {
970 GL_TEXTURE_MAG_FILTER
,
971 GL_TEXTURE_MIN_FILTER
,
972 GL_TEXTURE_POOL_CHROMIUM
,
977 static const GLenum valid_texture_parameter_table_es3
[] = {
978 GL_TEXTURE_BASE_LEVEL
,
979 GL_TEXTURE_COMPARE_FUNC
,
980 GL_TEXTURE_COMPARE_MODE
,
981 GL_TEXTURE_IMMUTABLE_FORMAT
,
982 GL_TEXTURE_IMMUTABLE_LEVELS
,
983 GL_TEXTURE_MAX_LEVEL
,
989 static const GLenum valid_texture_pool_table
[] = {
990 GL_TEXTURE_POOL_MANAGED_CHROMIUM
,
991 GL_TEXTURE_POOL_UNMANAGED_CHROMIUM
,
994 static const GLenum valid_texture_target_table
[] = {
996 GL_TEXTURE_CUBE_MAP_POSITIVE_X
,
997 GL_TEXTURE_CUBE_MAP_NEGATIVE_X
,
998 GL_TEXTURE_CUBE_MAP_POSITIVE_Y
,
999 GL_TEXTURE_CUBE_MAP_NEGATIVE_Y
,
1000 GL_TEXTURE_CUBE_MAP_POSITIVE_Z
,
1001 GL_TEXTURE_CUBE_MAP_NEGATIVE_Z
,
1004 static const GLenum valid_texture_usage_table
[] = {
1006 GL_FRAMEBUFFER_ATTACHMENT_ANGLE
,
1009 static const GLenum valid_texture_wrap_mode_table
[] = {
1015 static const GLenum valid_transform_feedback_bind_target_table
[] = {
1016 GL_TRANSFORM_FEEDBACK
,
1019 static const GLenum valid_transform_feedback_primitive_mode_table
[] = {
1025 static const GLenum valid_uniform_block_parameter_table
[] = {
1026 GL_UNIFORM_BLOCK_BINDING
,
1027 GL_UNIFORM_BLOCK_DATA_SIZE
,
1028 GL_UNIFORM_BLOCK_NAME_LENGTH
,
1029 GL_UNIFORM_BLOCK_ACTIVE_UNIFORMS
,
1030 GL_UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES
,
1031 GL_UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER
,
1032 GL_UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER
,
1035 static const GLenum valid_uniform_parameter_table
[] = {
1038 GL_UNIFORM_NAME_LENGTH
,
1039 GL_UNIFORM_BLOCK_INDEX
,
1041 GL_UNIFORM_ARRAY_STRIDE
,
1042 GL_UNIFORM_MATRIX_STRIDE
,
1043 GL_UNIFORM_IS_ROW_MAJOR
,
1046 static const GLenum valid_value_buffer_target_table
[] = {
1047 GL_SUBSCRIBED_VALUES_BUFFER_CHROMIUM
,
1050 static const GLenum valid_vertex_attrib_i_type_table
[] = {
1059 static const GLint valid_vertex_attrib_size_table
[] = {
1066 static const GLenum valid_vertex_attrib_type_table
[] = {
1074 static const GLenum valid_vertex_attrib_type_table_es3
[] = {
1078 GL_INT_2_10_10_10_REV
,
1079 GL_UNSIGNED_INT_2_10_10_10_REV
,
1082 static const GLenum valid_vertex_attribute_table
[] = {
1083 GL_VERTEX_ATTRIB_ARRAY_NORMALIZED
,
1084 GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
,
1085 GL_VERTEX_ATTRIB_ARRAY_ENABLED
,
1086 GL_VERTEX_ATTRIB_ARRAY_SIZE
,
1087 GL_VERTEX_ATTRIB_ARRAY_STRIDE
,
1088 GL_VERTEX_ATTRIB_ARRAY_TYPE
,
1089 GL_CURRENT_VERTEX_ATTRIB
,
1092 static const GLenum valid_vertex_attribute_table_es3
[] = {
1093 GL_VERTEX_ATTRIB_ARRAY_INTEGER
,
1094 GL_VERTEX_ATTRIB_ARRAY_DIVISOR
,
1097 static const GLenum valid_vertex_pointer_table
[] = {
1098 GL_VERTEX_ATTRIB_ARRAY_POINTER
,
1101 Validators::Validators()
1102 : attachment(valid_attachment_table
, arraysize(valid_attachment_table
)),
1103 backbuffer_attachment(valid_backbuffer_attachment_table
,
1104 arraysize(valid_backbuffer_attachment_table
)),
1105 blit_filter(valid_blit_filter_table
, arraysize(valid_blit_filter_table
)),
1106 buffer_mode(valid_buffer_mode_table
, arraysize(valid_buffer_mode_table
)),
1107 buffer_parameter(valid_buffer_parameter_table
,
1108 arraysize(valid_buffer_parameter_table
)),
1109 buffer_target(valid_buffer_target_table
,
1110 arraysize(valid_buffer_target_table
)),
1111 buffer_usage(valid_buffer_usage_table
,
1112 arraysize(valid_buffer_usage_table
)),
1113 bufferfi(valid_bufferfi_table
, arraysize(valid_bufferfi_table
)),
1114 bufferfv(valid_bufferfv_table
, arraysize(valid_bufferfv_table
)),
1115 bufferiv(valid_bufferiv_table
, arraysize(valid_bufferiv_table
)),
1116 bufferuiv(valid_bufferuiv_table
, arraysize(valid_bufferuiv_table
)),
1117 capability(valid_capability_table
, arraysize(valid_capability_table
)),
1118 cmp_function(valid_cmp_function_table
,
1119 arraysize(valid_cmp_function_table
)),
1120 compressed_texture_format(),
1121 draw_mode(valid_draw_mode_table
, arraysize(valid_draw_mode_table
)),
1122 dst_blend_factor(valid_dst_blend_factor_table
,
1123 arraysize(valid_dst_blend_factor_table
)),
1124 equation(valid_equation_table
, arraysize(valid_equation_table
)),
1125 face_mode(valid_face_mode_table
, arraysize(valid_face_mode_table
)),
1126 face_type(valid_face_type_table
, arraysize(valid_face_type_table
)),
1127 frame_buffer_parameter(valid_frame_buffer_parameter_table
,
1128 arraysize(valid_frame_buffer_parameter_table
)),
1129 frame_buffer_target(valid_frame_buffer_target_table
,
1130 arraysize(valid_frame_buffer_target_table
)),
1131 g_l_state(valid_g_l_state_table
, arraysize(valid_g_l_state_table
)),
1132 get_max_index_type(valid_get_max_index_type_table
,
1133 arraysize(valid_get_max_index_type_table
)),
1134 get_tex_param_target(valid_get_tex_param_target_table
,
1135 arraysize(valid_get_tex_param_target_table
)),
1136 hint_mode(valid_hint_mode_table
, arraysize(valid_hint_mode_table
)),
1137 hint_target(valid_hint_target_table
, arraysize(valid_hint_target_table
)),
1138 image_internal_format(valid_image_internal_format_table
,
1139 arraysize(valid_image_internal_format_table
)),
1140 image_usage(valid_image_usage_table
, arraysize(valid_image_usage_table
)),
1141 index_type(valid_index_type_table
, arraysize(valid_index_type_table
)),
1142 indexed_buffer_target(valid_indexed_buffer_target_table
,
1143 arraysize(valid_indexed_buffer_target_table
)),
1144 indexed_g_l_state(valid_indexed_g_l_state_table
,
1145 arraysize(valid_indexed_g_l_state_table
)),
1146 internal_format_parameter(
1147 valid_internal_format_parameter_table
,
1148 arraysize(valid_internal_format_parameter_table
)),
1149 invalidate_frame_buffer_target(
1150 valid_invalidate_frame_buffer_target_table
,
1151 arraysize(valid_invalidate_frame_buffer_target_table
)),
1152 map_buffer_access(valid_map_buffer_access_table
,
1153 arraysize(valid_map_buffer_access_table
)),
1154 matrix_mode(valid_matrix_mode_table
, arraysize(valid_matrix_mode_table
)),
1155 pixel_store(valid_pixel_store_table
, arraysize(valid_pixel_store_table
)),
1156 pixel_store_alignment(valid_pixel_store_alignment_table
,
1157 arraysize(valid_pixel_store_alignment_table
)),
1158 pixel_type(valid_pixel_type_table
, arraysize(valid_pixel_type_table
)),
1159 program_parameter(valid_program_parameter_table
,
1160 arraysize(valid_program_parameter_table
)),
1161 query_object_parameter(valid_query_object_parameter_table
,
1162 arraysize(valid_query_object_parameter_table
)),
1163 query_parameter(valid_query_parameter_table
,
1164 arraysize(valid_query_parameter_table
)),
1165 query_target(valid_query_target_table
,
1166 arraysize(valid_query_target_table
)),
1167 read_pixel_format(valid_read_pixel_format_table
,
1168 arraysize(valid_read_pixel_format_table
)),
1169 read_pixel_type(valid_read_pixel_type_table
,
1170 arraysize(valid_read_pixel_type_table
)),
1171 render_buffer_format(valid_render_buffer_format_table
,
1172 arraysize(valid_render_buffer_format_table
)),
1173 render_buffer_parameter(valid_render_buffer_parameter_table
,
1174 arraysize(valid_render_buffer_parameter_table
)),
1175 render_buffer_target(valid_render_buffer_target_table
,
1176 arraysize(valid_render_buffer_target_table
)),
1177 reset_status(valid_reset_status_table
,
1178 arraysize(valid_reset_status_table
)),
1179 sampler_parameter(valid_sampler_parameter_table
,
1180 arraysize(valid_sampler_parameter_table
)),
1181 shader_binary_format(),
1182 shader_parameter(valid_shader_parameter_table
,
1183 arraysize(valid_shader_parameter_table
)),
1184 shader_precision(valid_shader_precision_table
,
1185 arraysize(valid_shader_precision_table
)),
1186 shader_type(valid_shader_type_table
, arraysize(valid_shader_type_table
)),
1187 src_blend_factor(valid_src_blend_factor_table
,
1188 arraysize(valid_src_blend_factor_table
)),
1189 stencil_op(valid_stencil_op_table
, arraysize(valid_stencil_op_table
)),
1190 string_type(valid_string_type_table
, arraysize(valid_string_type_table
)),
1191 subscription_target(valid_subscription_target_table
,
1192 arraysize(valid_subscription_target_table
)),
1193 sync_flush_flags(valid_sync_flush_flags_table
,
1194 arraysize(valid_sync_flush_flags_table
)),
1195 sync_parameter(valid_sync_parameter_table
,
1196 arraysize(valid_sync_parameter_table
)),
1197 texture_3_d_target(valid_texture_3_d_target_table
,
1198 arraysize(valid_texture_3_d_target_table
)),
1199 texture_bind_target(valid_texture_bind_target_table
,
1200 arraysize(valid_texture_bind_target_table
)),
1201 texture_compare_func(valid_texture_compare_func_table
,
1202 arraysize(valid_texture_compare_func_table
)),
1203 texture_compare_mode(valid_texture_compare_mode_table
,
1204 arraysize(valid_texture_compare_mode_table
)),
1205 texture_format(valid_texture_format_table
,
1206 arraysize(valid_texture_format_table
)),
1207 texture_internal_format(valid_texture_internal_format_table
,
1208 arraysize(valid_texture_internal_format_table
)),
1209 texture_internal_format_storage(
1210 valid_texture_internal_format_storage_table
,
1211 arraysize(valid_texture_internal_format_storage_table
)),
1212 texture_mag_filter_mode(valid_texture_mag_filter_mode_table
,
1213 arraysize(valid_texture_mag_filter_mode_table
)),
1214 texture_min_filter_mode(valid_texture_min_filter_mode_table
,
1215 arraysize(valid_texture_min_filter_mode_table
)),
1216 texture_parameter(valid_texture_parameter_table
,
1217 arraysize(valid_texture_parameter_table
)),
1218 texture_pool(valid_texture_pool_table
,
1219 arraysize(valid_texture_pool_table
)),
1220 texture_target(valid_texture_target_table
,
1221 arraysize(valid_texture_target_table
)),
1222 texture_usage(valid_texture_usage_table
,
1223 arraysize(valid_texture_usage_table
)),
1224 texture_wrap_mode(valid_texture_wrap_mode_table
,
1225 arraysize(valid_texture_wrap_mode_table
)),
1226 transform_feedback_bind_target(
1227 valid_transform_feedback_bind_target_table
,
1228 arraysize(valid_transform_feedback_bind_target_table
)),
1229 transform_feedback_primitive_mode(
1230 valid_transform_feedback_primitive_mode_table
,
1231 arraysize(valid_transform_feedback_primitive_mode_table
)),
1232 uniform_block_parameter(valid_uniform_block_parameter_table
,
1233 arraysize(valid_uniform_block_parameter_table
)),
1234 uniform_parameter(valid_uniform_parameter_table
,
1235 arraysize(valid_uniform_parameter_table
)),
1236 value_buffer_target(valid_value_buffer_target_table
,
1237 arraysize(valid_value_buffer_target_table
)),
1238 vertex_attrib_i_type(valid_vertex_attrib_i_type_table
,
1239 arraysize(valid_vertex_attrib_i_type_table
)),
1240 vertex_attrib_size(valid_vertex_attrib_size_table
,
1241 arraysize(valid_vertex_attrib_size_table
)),
1242 vertex_attrib_type(valid_vertex_attrib_type_table
,
1243 arraysize(valid_vertex_attrib_type_table
)),
1244 vertex_attribute(valid_vertex_attribute_table
,
1245 arraysize(valid_vertex_attribute_table
)),
1246 vertex_pointer(valid_vertex_pointer_table
,
1247 arraysize(valid_vertex_pointer_table
)) {
1250 void Validators::UpdateValuesES3() {
1251 attachment
.AddValues(valid_attachment_table_es3
,
1252 arraysize(valid_attachment_table_es3
));
1253 buffer_parameter
.AddValues(valid_buffer_parameter_table_es3
,
1254 arraysize(valid_buffer_parameter_table_es3
));
1255 buffer_target
.AddValues(valid_buffer_target_table_es3
,
1256 arraysize(valid_buffer_target_table_es3
));
1257 buffer_usage
.AddValues(valid_buffer_usage_table_es3
,
1258 arraysize(valid_buffer_usage_table_es3
));
1259 capability
.AddValues(valid_capability_table_es3
,
1260 arraysize(valid_capability_table_es3
));
1261 compressed_texture_format
.AddValues(
1262 valid_compressed_texture_format_table_es3
,
1263 arraysize(valid_compressed_texture_format_table_es3
));
1264 equation
.AddValues(valid_equation_table_es3
,
1265 arraysize(valid_equation_table_es3
));
1266 frame_buffer_parameter
.AddValues(
1267 valid_frame_buffer_parameter_table_es3
,
1268 arraysize(valid_frame_buffer_parameter_table_es3
));
1269 frame_buffer_target
.AddValues(valid_frame_buffer_target_table_es3
,
1270 arraysize(valid_frame_buffer_target_table_es3
));
1271 g_l_state
.AddValues(valid_g_l_state_table_es3
,
1272 arraysize(valid_g_l_state_table_es3
));
1273 get_tex_param_target
.AddValues(
1274 valid_get_tex_param_target_table_es3
,
1275 arraysize(valid_get_tex_param_target_table_es3
));
1276 hint_target
.AddValues(valid_hint_target_table_es3
,
1277 arraysize(valid_hint_target_table_es3
));
1278 index_type
.AddValues(valid_index_type_table_es3
,
1279 arraysize(valid_index_type_table_es3
));
1280 pixel_store
.AddValues(valid_pixel_store_table_es3
,
1281 arraysize(valid_pixel_store_table_es3
));
1282 pixel_type
.AddValues(valid_pixel_type_table_es3
,
1283 arraysize(valid_pixel_type_table_es3
));
1284 program_parameter
.AddValues(valid_program_parameter_table_es3
,
1285 arraysize(valid_program_parameter_table_es3
));
1286 read_pixel_format
.RemoveValues(
1287 deprecated_read_pixel_format_table_es3
,
1288 arraysize(deprecated_read_pixel_format_table_es3
));
1289 read_pixel_format
.AddValues(valid_read_pixel_format_table_es3
,
1290 arraysize(valid_read_pixel_format_table_es3
));
1291 read_pixel_type
.RemoveValues(deprecated_read_pixel_type_table_es3
,
1292 arraysize(deprecated_read_pixel_type_table_es3
));
1293 read_pixel_type
.AddValues(valid_read_pixel_type_table_es3
,
1294 arraysize(valid_read_pixel_type_table_es3
));
1295 render_buffer_format
.AddValues(
1296 valid_render_buffer_format_table_es3
,
1297 arraysize(valid_render_buffer_format_table_es3
));
1298 render_buffer_parameter
.AddValues(
1299 valid_render_buffer_parameter_table_es3
,
1300 arraysize(valid_render_buffer_parameter_table_es3
));
1301 texture_bind_target
.AddValues(valid_texture_bind_target_table_es3
,
1302 arraysize(valid_texture_bind_target_table_es3
));
1303 texture_format
.AddValues(valid_texture_format_table_es3
,
1304 arraysize(valid_texture_format_table_es3
));
1305 texture_internal_format
.AddValues(
1306 valid_texture_internal_format_table_es3
,
1307 arraysize(valid_texture_internal_format_table_es3
));
1308 texture_internal_format_storage
.RemoveValues(
1309 deprecated_texture_internal_format_storage_table_es3
,
1310 arraysize(deprecated_texture_internal_format_storage_table_es3
));
1311 texture_internal_format_storage
.AddValues(
1312 valid_texture_internal_format_storage_table_es3
,
1313 arraysize(valid_texture_internal_format_storage_table_es3
));
1314 texture_parameter
.AddValues(valid_texture_parameter_table_es3
,
1315 arraysize(valid_texture_parameter_table_es3
));
1316 vertex_attrib_type
.AddValues(valid_vertex_attrib_type_table_es3
,
1317 arraysize(valid_vertex_attrib_type_table_es3
));
1318 vertex_attribute
.AddValues(valid_vertex_attribute_table_es3
,
1319 arraysize(valid_vertex_attribute_table_es3
));
1322 #endif // GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_VALIDATION_IMPLEMENTATION_AUTOGEN_H_