зеркало из https://github.com/mozilla/gecko-dev.git
Backed out 2 changesets (bug 1717151) for causing bustage on validationEGL.h. CLOSED TREE
Backed out changeset 06d6ad49726c (bug 1717151) Backed out changeset ee22b6243926 (bug 1717151)
This commit is contained in:
Родитель
0fd845f828
Коммит
1439cf57eb
|
@ -80,6 +80,7 @@ static ShCompileOptions ChooseValidatorCompileOptions(
|
|||
options ^= SH_EXPAND_SELECT_HLSL_INTEGER_POW_EXPRESSIONS;
|
||||
options ^= SH_HLSL_GET_DIMENSIONS_IGNORES_BASE_LEVEL;
|
||||
|
||||
options ^= SH_DONT_REMOVE_INVARIANT_FOR_FRAGMENT_INPUT;
|
||||
options ^= SH_REMOVE_INVARIANT_AND_CENTROID_FOR_ESSL3;
|
||||
}
|
||||
|
||||
|
|
|
@ -1 +1 @@
|
|||
chromium/4515
|
||||
chromium/4324
|
||||
|
|
|
@ -6,15 +6,34 @@ extern "C" {
|
|||
#endif
|
||||
|
||||
/*
|
||||
** Copyright 2013-2020 The Khronos Group Inc.
|
||||
** SPDX-License-Identifier: Apache-2.0
|
||||
** Copyright (c) 2013-2017 The Khronos Group Inc.
|
||||
**
|
||||
** Permission is hereby granted, free of charge, to any person obtaining a
|
||||
** copy of this software and/or associated documentation files (the
|
||||
** "Materials"), to deal in the Materials without restriction, including
|
||||
** without limitation the rights to use, copy, modify, merge, publish,
|
||||
** distribute, sublicense, and/or sell copies of the Materials, and to
|
||||
** permit persons to whom the Materials are furnished to do so, subject to
|
||||
** the following conditions:
|
||||
**
|
||||
** The above copyright notice and this permission notice shall be included
|
||||
** in all copies or substantial portions of the Materials.
|
||||
**
|
||||
** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
||||
** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
||||
** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
||||
** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
|
||||
*/
|
||||
/*
|
||||
** This header is generated from the Khronos EGL XML API Registry.
|
||||
** The current version of the Registry, generator scripts
|
||||
** used to make the header, and the header can be found at
|
||||
** http://www.khronos.org/registry/egl
|
||||
**
|
||||
** Khronos $Git commit SHA1: 5a9a7e3fcb $ on $Git commit date: 2020-08-24 11:05:32 -0700 $
|
||||
** Khronos $Git commit SHA1: cb927ca98d $ on $Git commit date: 2019-08-08 01:05:38 -0700 $
|
||||
*/
|
||||
|
||||
#include <EGL/eglplatform.h>
|
||||
|
@ -23,7 +42,7 @@ extern "C" {
|
|||
#define EGL_EGL_PROTOTYPES 1
|
||||
#endif
|
||||
|
||||
/* Generated on date 20201001 */
|
||||
/* Generated on date 20190808 */
|
||||
|
||||
/* Generated C header for:
|
||||
* API: egl
|
||||
|
|
|
@ -6,20 +6,39 @@ extern "C" {
|
|||
#endif
|
||||
|
||||
/*
|
||||
** Copyright 2013-2020 The Khronos Group Inc.
|
||||
** SPDX-License-Identifier: Apache-2.0
|
||||
** Copyright (c) 2013-2017 The Khronos Group Inc.
|
||||
**
|
||||
** Permission is hereby granted, free of charge, to any person obtaining a
|
||||
** copy of this software and/or associated documentation files (the
|
||||
** "Materials"), to deal in the Materials without restriction, including
|
||||
** without limitation the rights to use, copy, modify, merge, publish,
|
||||
** distribute, sublicense, and/or sell copies of the Materials, and to
|
||||
** permit persons to whom the Materials are furnished to do so, subject to
|
||||
** the following conditions:
|
||||
**
|
||||
** The above copyright notice and this permission notice shall be included
|
||||
** in all copies or substantial portions of the Materials.
|
||||
**
|
||||
** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
||||
** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
||||
** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
||||
** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
|
||||
*/
|
||||
/*
|
||||
** This header is generated from the Khronos EGL XML API Registry.
|
||||
** The current version of the Registry, generator scripts
|
||||
** used to make the header, and the header can be found at
|
||||
** http://www.khronos.org/registry/egl
|
||||
**
|
||||
** Khronos $Git commit SHA1: 5a9a7e3fcb $ on $Git commit date: 2020-08-24 11:05:32 -0700 $
|
||||
** Khronos $Git commit SHA1: cb927ca98d $ on $Git commit date: 2019-08-08 01:05:38 -0700 $
|
||||
*/
|
||||
|
||||
#include <EGL/eglplatform.h>
|
||||
|
||||
#define EGL_EGLEXT_VERSION 20201001
|
||||
#define EGL_EGLEXT_VERSION 20190808
|
||||
|
||||
/* Generated C header for:
|
||||
* API: egl
|
||||
|
@ -424,9 +443,9 @@ EGLAPI EGLSurface EGLAPIENTRY eglCreateStreamProducerSurfaceKHR (EGLDisplay dpy,
|
|||
|
||||
#ifndef EGL_KHR_swap_buffers_with_damage
|
||||
#define EGL_KHR_swap_buffers_with_damage 1
|
||||
typedef EGLBoolean (EGLAPIENTRYP PFNEGLSWAPBUFFERSWITHDAMAGEKHRPROC) (EGLDisplay dpy, EGLSurface surface, const EGLint *rects, EGLint n_rects);
|
||||
typedef EGLBoolean (EGLAPIENTRYP PFNEGLSWAPBUFFERSWITHDAMAGEKHRPROC) (EGLDisplay dpy, EGLSurface surface, EGLint *rects, EGLint n_rects);
|
||||
#ifdef EGL_EGLEXT_PROTOTYPES
|
||||
EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffersWithDamageKHR (EGLDisplay dpy, EGLSurface surface, const EGLint *rects, EGLint n_rects);
|
||||
EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffersWithDamageKHR (EGLDisplay dpy, EGLSurface surface, EGLint *rects, EGLint n_rects);
|
||||
#endif
|
||||
#endif /* EGL_KHR_swap_buffers_with_damage */
|
||||
|
||||
|
@ -579,12 +598,6 @@ EGLAPI EGLBoolean EGLAPIENTRY eglQuerySurfacePointerANGLE (EGLDisplay dpy, EGLSu
|
|||
#define EGL_FIXED_SIZE_ANGLE 0x3201
|
||||
#endif /* EGL_ANGLE_window_fixed_size */
|
||||
|
||||
#ifndef EGL_ARM_image_format
|
||||
#define EGL_ARM_image_format 1
|
||||
#define EGL_COLOR_COMPONENT_TYPE_UNSIGNED_INTEGER_ARM 0x3287
|
||||
#define EGL_COLOR_COMPONENT_TYPE_INTEGER_ARM 0x3288
|
||||
#endif /* EGL_ARM_image_format */
|
||||
|
||||
#ifndef EGL_ARM_implicit_external_sync
|
||||
#define EGL_ARM_implicit_external_sync 1
|
||||
#define EGL_SYNC_PRIOR_COMMANDS_IMPLICIT_EXTERNAL_ARM 0x328A
|
||||
|
@ -688,11 +701,6 @@ EGLAPI EGLBoolean EGLAPIENTRY eglQueryDisplayAttribEXT (EGLDisplay dpy, EGLint a
|
|||
#define EGL_EXT_device_query 1
|
||||
#endif /* EGL_EXT_device_query */
|
||||
|
||||
#ifndef EGL_EXT_device_query_name
|
||||
#define EGL_EXT_device_query_name 1
|
||||
#define EGL_RENDERER_EXT 0x335F
|
||||
#endif /* EGL_EXT_device_query_name */
|
||||
|
||||
#ifndef EGL_EXT_gl_colorspace_bt2020_linear
|
||||
#define EGL_EXT_gl_colorspace_bt2020_linear 1
|
||||
#define EGL_GL_COLORSPACE_BT2020_LINEAR_EXT 0x333F
|
||||
|
@ -869,12 +877,6 @@ EGLAPI EGLSurface EGLAPIENTRY eglCreatePlatformPixmapSurfaceEXT (EGLDisplay dpy,
|
|||
#define EGL_PLATFORM_X11_SCREEN_EXT 0x31D6
|
||||
#endif /* EGL_EXT_platform_x11 */
|
||||
|
||||
#ifndef EGL_EXT_platform_xcb
|
||||
#define EGL_EXT_platform_xcb 1
|
||||
#define EGL_PLATFORM_XCB_EXT 0x31DC
|
||||
#define EGL_PLATFORM_XCB_SCREEN_EXT 0x31DE
|
||||
#endif /* EGL_EXT_platform_xcb */
|
||||
|
||||
#ifndef EGL_EXT_protected_content
|
||||
#define EGL_EXT_protected_content 1
|
||||
#define EGL_PROTECTED_CONTENT_EXT 0x32C0
|
||||
|
@ -915,9 +917,9 @@ EGLAPI EGLBoolean EGLAPIENTRY eglStreamConsumerOutputEXT (EGLDisplay dpy, EGLStr
|
|||
|
||||
#ifndef EGL_EXT_swap_buffers_with_damage
|
||||
#define EGL_EXT_swap_buffers_with_damage 1
|
||||
typedef EGLBoolean (EGLAPIENTRYP PFNEGLSWAPBUFFERSWITHDAMAGEEXTPROC) (EGLDisplay dpy, EGLSurface surface, const EGLint *rects, EGLint n_rects);
|
||||
typedef EGLBoolean (EGLAPIENTRYP PFNEGLSWAPBUFFERSWITHDAMAGEEXTPROC) (EGLDisplay dpy, EGLSurface surface, EGLint *rects, EGLint n_rects);
|
||||
#ifdef EGL_EGLEXT_PROTOTYPES
|
||||
EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffersWithDamageEXT (EGLDisplay dpy, EGLSurface surface, const EGLint *rects, EGLint n_rects);
|
||||
EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffersWithDamageEXT (EGLDisplay dpy, EGLSurface surface, EGLint *rects, EGLint n_rects);
|
||||
#endif
|
||||
#endif /* EGL_EXT_swap_buffers_with_damage */
|
||||
|
||||
|
@ -1141,24 +1143,6 @@ EGLAPI EGLBoolean EGLAPIENTRY eglPostSubBufferNV (EGLDisplay dpy, EGLSurface sur
|
|||
#define EGL_GENERATE_RESET_ON_VIDEO_MEMORY_PURGE_NV 0x334C
|
||||
#endif /* EGL_NV_robustness_video_memory_purge */
|
||||
|
||||
#ifndef EGL_NV_stream_consumer_eglimage
|
||||
#define EGL_NV_stream_consumer_eglimage 1
|
||||
#define EGL_STREAM_CONSUMER_IMAGE_NV 0x3373
|
||||
#define EGL_STREAM_IMAGE_ADD_NV 0x3374
|
||||
#define EGL_STREAM_IMAGE_REMOVE_NV 0x3375
|
||||
#define EGL_STREAM_IMAGE_AVAILABLE_NV 0x3376
|
||||
typedef EGLBoolean (EGLAPIENTRYP PFNEGLSTREAMIMAGECONSUMERCONNECTNVPROC) (EGLDisplay dpy, EGLStreamKHR stream, EGLint num_modifiers, EGLuint64KHR *modifiers, EGLAttrib *attrib_list);
|
||||
typedef EGLint (EGLAPIENTRYP PFNEGLQUERYSTREAMCONSUMEREVENTNVPROC) (EGLDisplay dpy, EGLStreamKHR stream, EGLTime timeout, EGLenum *event, EGLAttrib *aux);
|
||||
typedef EGLBoolean (EGLAPIENTRYP PFNEGLSTREAMACQUIREIMAGENVPROC) (EGLDisplay dpy, EGLStreamKHR stream, EGLImage *pImage, EGLSync sync);
|
||||
typedef EGLBoolean (EGLAPIENTRYP PFNEGLSTREAMRELEASEIMAGENVPROC) (EGLDisplay dpy, EGLStreamKHR stream, EGLImage image, EGLSync sync);
|
||||
#ifdef EGL_EGLEXT_PROTOTYPES
|
||||
EGLAPI EGLBoolean EGLAPIENTRY eglStreamImageConsumerConnectNV (EGLDisplay dpy, EGLStreamKHR stream, EGLint num_modifiers, EGLuint64KHR *modifiers, EGLAttrib *attrib_list);
|
||||
EGLAPI EGLint EGLAPIENTRY eglQueryStreamConsumerEventNV (EGLDisplay dpy, EGLStreamKHR stream, EGLTime timeout, EGLenum *event, EGLAttrib *aux);
|
||||
EGLAPI EGLBoolean EGLAPIENTRY eglStreamAcquireImageNV (EGLDisplay dpy, EGLStreamKHR stream, EGLImage *pImage, EGLSync sync);
|
||||
EGLAPI EGLBoolean EGLAPIENTRY eglStreamReleaseImageNV (EGLDisplay dpy, EGLStreamKHR stream, EGLImage image, EGLSync sync);
|
||||
#endif
|
||||
#endif /* EGL_NV_stream_consumer_eglimage */
|
||||
|
||||
#ifndef EGL_NV_stream_consumer_gltexture_yuv
|
||||
#define EGL_NV_stream_consumer_gltexture_yuv 1
|
||||
#define EGL_YUV_PLANE0_TEXTURE_UNIT_NV 0x332C
|
||||
|
@ -1378,40 +1362,6 @@ EGLAPI EGLuint64NV EGLAPIENTRY eglGetSystemTimeNV (void);
|
|||
#define EGL_NATIVE_SURFACE_TIZEN 0x32A1
|
||||
#endif /* EGL_TIZEN_image_native_surface */
|
||||
|
||||
#ifndef EGL_WL_bind_wayland_display
|
||||
#define EGL_WL_bind_wayland_display 1
|
||||
#define PFNEGLBINDWAYLANDDISPLAYWL PFNEGLBINDWAYLANDDISPLAYWLPROC
|
||||
#define PFNEGLUNBINDWAYLANDDISPLAYWL PFNEGLUNBINDWAYLANDDISPLAYWLPROC
|
||||
#define PFNEGLQUERYWAYLANDBUFFERWL PFNEGLQUERYWAYLANDBUFFERWLPROC
|
||||
struct wl_display;
|
||||
struct wl_resource;
|
||||
#define EGL_WAYLAND_BUFFER_WL 0x31D5
|
||||
#define EGL_WAYLAND_PLANE_WL 0x31D6
|
||||
#define EGL_TEXTURE_Y_U_V_WL 0x31D7
|
||||
#define EGL_TEXTURE_Y_UV_WL 0x31D8
|
||||
#define EGL_TEXTURE_Y_XUXV_WL 0x31D9
|
||||
#define EGL_TEXTURE_EXTERNAL_WL 0x31DA
|
||||
#define EGL_WAYLAND_Y_INVERTED_WL 0x31DB
|
||||
typedef EGLBoolean (EGLAPIENTRYP PFNEGLBINDWAYLANDDISPLAYWLPROC) (EGLDisplay dpy, struct wl_display *display);
|
||||
typedef EGLBoolean (EGLAPIENTRYP PFNEGLUNBINDWAYLANDDISPLAYWLPROC) (EGLDisplay dpy, struct wl_display *display);
|
||||
typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYWAYLANDBUFFERWLPROC) (EGLDisplay dpy, struct wl_resource *buffer, EGLint attribute, EGLint *value);
|
||||
#ifdef EGL_EGLEXT_PROTOTYPES
|
||||
EGLAPI EGLBoolean EGLAPIENTRY eglBindWaylandDisplayWL (EGLDisplay dpy, struct wl_display *display);
|
||||
EGLAPI EGLBoolean EGLAPIENTRY eglUnbindWaylandDisplayWL (EGLDisplay dpy, struct wl_display *display);
|
||||
EGLAPI EGLBoolean EGLAPIENTRY eglQueryWaylandBufferWL (EGLDisplay dpy, struct wl_resource *buffer, EGLint attribute, EGLint *value);
|
||||
#endif
|
||||
#endif /* EGL_WL_bind_wayland_display */
|
||||
|
||||
#ifndef EGL_WL_create_wayland_buffer_from_image
|
||||
#define EGL_WL_create_wayland_buffer_from_image 1
|
||||
#define PFNEGLCREATEWAYLANDBUFFERFROMIMAGEWL PFNEGLCREATEWAYLANDBUFFERFROMIMAGEWLPROC
|
||||
struct wl_buffer;
|
||||
typedef struct wl_buffer *(EGLAPIENTRYP PFNEGLCREATEWAYLANDBUFFERFROMIMAGEWLPROC) (EGLDisplay dpy, EGLImageKHR image);
|
||||
#ifdef EGL_EGLEXT_PROTOTYPES
|
||||
EGLAPI struct wl_buffer *EGLAPIENTRY eglCreateWaylandBufferFromImageWL (EGLDisplay dpy, EGLImageKHR image);
|
||||
#endif
|
||||
#endif /* EGL_WL_create_wayland_buffer_from_image */
|
||||
|
||||
/* ANGLE EGL extensions */
|
||||
#include "eglext_angle.h"
|
||||
|
||||
|
|
|
@ -24,11 +24,9 @@
|
|||
|
||||
#ifndef EGL_ANGLE_d3d_texture_client_buffer
|
||||
#define EGL_ANGLE_d3d_texture_client_buffer 1
|
||||
#define EGL_D3D_TEXTURE_ANGLE 0x33A3
|
||||
#define EGL_TEXTURE_OFFSET_X_ANGLE 0x3490
|
||||
#define EGL_TEXTURE_OFFSET_Y_ANGLE 0x3491
|
||||
#define EGL_D3D11_TEXTURE_PLANE_ANGLE 0x3492
|
||||
#define EGL_D3D11_TEXTURE_ARRAY_SLICE_ANGLE 0x3493
|
||||
#define EGL_D3D_TEXTURE_ANGLE 0x33A3
|
||||
#define EGL_TEXTURE_OFFSET_X_ANGLE 0x3490
|
||||
#define EGL_TEXTURE_OFFSET_Y_ANGLE 0x3491
|
||||
#endif /* EGL_ANGLE_d3d_texture_client_buffer */
|
||||
|
||||
#ifndef EGL_ANGLE_software_display
|
||||
|
@ -206,12 +204,12 @@ EGLAPI EGLBoolean EGLAPIENTRY eglReleaseDeviceANGLE(EGLDeviceEXT device);
|
|||
typedef EGLint (EGLAPIENTRYP PFNEGLPROGRAMCACHEGETATTRIBANGLEPROC) (EGLDisplay dpy, EGLenum attrib);
|
||||
typedef void (EGLAPIENTRYP PFNEGLPROGRAMCACHEQUERYANGLEPROC) (EGLDisplay dpy, EGLint index, void *key, EGLint *keysize, void *binary, EGLint *binarysize);
|
||||
typedef void (EGLAPIENTRYP PFNEGLPROGRAMCACHEPOPULATEANGLEPROC) (EGLDisplay dpy, const void *key, EGLint keysize, const void *binary, EGLint binarysize);
|
||||
typedef EGLint (EGLAPIENTRYP PFNEGLPROGRAMCACHERESIZEANGLEPROC) (EGLDisplay dpy, EGLint limit, EGLint mode);
|
||||
typedef EGLint (EGLAPIENTRYP PFNEGLPROGRAMCACHERESIZEANGLEPROC) (EGLDisplay dpy, EGLint limit, EGLenum mode);
|
||||
#ifdef EGL_EGLEXT_PROTOTYPES
|
||||
EGLAPI EGLint EGLAPIENTRY eglProgramCacheGetAttribANGLE(EGLDisplay dpy, EGLenum attrib);
|
||||
EGLAPI void EGLAPIENTRY eglProgramCacheQueryANGLE(EGLDisplay dpy, EGLint index, void *key, EGLint *keysize, void *binary, EGLint *binarysize);
|
||||
EGLAPI void EGLAPIENTRY eglProgramCachePopulateANGLE(EGLDisplay dpy, const void *key, EGLint keysize, const void *binary, EGLint binarysize);
|
||||
EGLAPI EGLint EGLAPIENTRY eglProgramCacheResizeANGLE(EGLDisplay dpy, EGLint limit, EGLint mode);
|
||||
EGLAPI EGLint EGLAPIENTRY eglProgramCacheResizeANGLE(EGLDisplay dpy, EGLint limit, EGLenum mode);
|
||||
#endif
|
||||
#endif /* EGL_ANGLE_program_cache_control */
|
||||
|
||||
|
@ -228,11 +226,6 @@ EGLAPI EGLint EGLAPIENTRY eglProgramCacheResizeANGLE(EGLDisplay dpy, EGLint limi
|
|||
#define EGL_BIND_TO_TEXTURE_TARGET_ANGLE 0x348D
|
||||
#endif /* EGL_ANGLE_iosurface_client_buffer */
|
||||
|
||||
#ifndef ANGLE_metal_texture_client_buffer
|
||||
#define ANGLE_metal_texture_client_buffer 1
|
||||
#define EGL_METAL_TEXTURE_ANGLE 0x34A7
|
||||
#endif /* ANGLE_metal_texture_client_buffer */
|
||||
|
||||
#ifndef EGL_ANGLE_create_context_extensions_enabled
|
||||
#define EGL_ANGLE_create_context_extensions_enabled 1
|
||||
#define EGL_EXTENSIONS_ENABLED_ANGLE 0x345F
|
||||
|
@ -338,23 +331,11 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffersWithFrameTokenANGLE(EGLDisplay dpy,
|
|||
#define EGL_EAGL_CONTEXT_ANGLE 0x348C
|
||||
#endif
|
||||
|
||||
#ifndef EGL_ANGLE_device_metal
|
||||
#define EGL_ANGLE_device_metal 1
|
||||
#define EGL_METAL_DEVICE_ANGLE 0x34A6
|
||||
#endif /* EGL_ANGLE_device_metal */
|
||||
|
||||
#ifndef EGL_ANGLE_display_semaphore_share_group
|
||||
#define EGL_ANGLE_display_semaphore_share_group 1
|
||||
#define EGL_DISPLAY_SEMAPHORE_SHARE_GROUP_ANGLE 0x348D
|
||||
#endif /* EGL_ANGLE_display_semaphore_share_group */
|
||||
|
||||
#ifndef EGL_ANGLE_external_context_and_surface
|
||||
#define EGL_ANGLE_external_context_and_surface 1
|
||||
#define EGL_EXTERNAL_CONTEXT_ANGLE 0x348E
|
||||
#define EGL_EXTERNAL_SURFACE_ANGLE 0x348F
|
||||
#define EGL_EXTERNAL_CONTEXT_SAVE_STATE_ANGLE 0x3490
|
||||
#endif /* EGL_ANGLE_external_context_and_surface */
|
||||
|
||||
// clang-format on
|
||||
|
||||
#endif // INCLUDE_EGL_EGLEXT_ANGLE_
|
||||
|
|
|
@ -2,17 +2,36 @@
|
|||
#define __eglplatform_h_
|
||||
|
||||
/*
|
||||
** Copyright 2007-2020 The Khronos Group Inc.
|
||||
** SPDX-License-Identifier: Apache-2.0
|
||||
** Copyright (c) 2007-2016 The Khronos Group Inc.
|
||||
**
|
||||
** Permission is hereby granted, free of charge, to any person obtaining a
|
||||
** copy of this software and/or associated documentation files (the
|
||||
** "Materials"), to deal in the Materials without restriction, including
|
||||
** without limitation the rights to use, copy, modify, merge, publish,
|
||||
** distribute, sublicense, and/or sell copies of the Materials, and to
|
||||
** permit persons to whom the Materials are furnished to do so, subject to
|
||||
** the following conditions:
|
||||
**
|
||||
** The above copyright notice and this permission notice shall be included
|
||||
** in all copies or substantial portions of the Materials.
|
||||
**
|
||||
** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
||||
** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
||||
** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
||||
** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
|
||||
*/
|
||||
|
||||
/* Platform-specific types and definitions for egl.h
|
||||
* $Revision: 30994 $ on $Date: 2015-04-30 13:36:48 -0700 (Thu, 30 Apr 2015) $
|
||||
*
|
||||
* Adopters may modify khrplatform.h and this file to suit their platform.
|
||||
* You are encouraged to submit all modifications to the Khronos group so that
|
||||
* they can be included in future versions of this file. Please submit changes
|
||||
* by filing an issue or pull request on the public Khronos EGL Registry, at
|
||||
* https://www.github.com/KhronosGroup/EGL-Registry/
|
||||
* by sending them to the public Khronos Bugzilla (http://khronos.org/bugzilla)
|
||||
* by filing a bug against product "EGL" component "Registry".
|
||||
*/
|
||||
|
||||
#include <KHR/khrplatform.h>
|
||||
|
@ -48,13 +67,7 @@
|
|||
* implementations.
|
||||
*/
|
||||
|
||||
#if defined(EGL_NO_PLATFORM_SPECIFIC_TYPES)
|
||||
|
||||
typedef void *EGLNativeDisplayType;
|
||||
typedef void *EGLNativePixmapType;
|
||||
typedef void *EGLNativeWindowType;
|
||||
|
||||
#elif defined(_WIN32) || defined(__VC32__) && !defined(__CYGWIN__) && !defined(__SCITECH_SNAP__) /* Win32 and WinCE */
|
||||
#if defined(_WIN32) || defined(__VC32__) && !defined(__CYGWIN__) && !defined(__SCITECH_SNAP__) /* Win32 and WinCE */
|
||||
#ifndef WIN32_LEAN_AND_MEAN
|
||||
#define WIN32_LEAN_AND_MEAN 1
|
||||
#endif
|
||||
|
@ -70,12 +83,6 @@ typedef HWND EGLNativeWindowType;
|
|||
typedef IInspectable* EGLNativeWindowType;
|
||||
#endif
|
||||
|
||||
#elif defined(__EMSCRIPTEN__)
|
||||
|
||||
typedef int EGLNativeDisplayType;
|
||||
typedef int EGLNativePixmapType;
|
||||
typedef int EGLNativeWindowType;
|
||||
|
||||
#elif defined(__WINSCW__) || defined(__SYMBIAN32__) /* Symbian */
|
||||
|
||||
typedef int EGLNativeDisplayType;
|
||||
|
@ -103,17 +110,17 @@ typedef void* EGLNativeDisplayType;
|
|||
typedef struct egl_native_pixmap_t* EGLNativePixmapType;
|
||||
typedef struct ANativeWindow* EGLNativeWindowType;
|
||||
|
||||
#elif defined(USE_OZONE)
|
||||
#elif defined(USE_OZONE) || defined(USE_SYSTEM_EGL)
|
||||
|
||||
typedef intptr_t EGLNativeDisplayType;
|
||||
typedef intptr_t EGLNativePixmapType;
|
||||
typedef intptr_t EGLNativeWindowType;
|
||||
|
||||
#elif defined(__unix__) && defined(EGL_NO_X11)
|
||||
#elif defined(__ggp__)
|
||||
|
||||
typedef void *EGLNativeDisplayType;
|
||||
typedef khronos_uintptr_t EGLNativePixmapType;
|
||||
typedef khronos_uintptr_t EGLNativeWindowType;
|
||||
typedef intptr_t EGLNativeDisplayType;
|
||||
typedef intptr_t EGLNativePixmapType;
|
||||
typedef intptr_t EGLNativeWindowType;
|
||||
|
||||
#elif defined(__unix__) || defined(USE_X11)
|
||||
|
||||
|
@ -141,9 +148,9 @@ typedef khronos_uintptr_t EGLNativeWindowType;
|
|||
|
||||
#elif defined(__Fuchsia__)
|
||||
|
||||
typedef void *EGLNativeDisplayType;
|
||||
typedef khronos_uintptr_t EGLNativePixmapType;
|
||||
typedef khronos_uintptr_t EGLNativeWindowType;
|
||||
typedef int EGLNativeDisplayType;
|
||||
typedef void *EGLNativePixmapType;
|
||||
typedef void *EGLNativeWindowType
|
||||
|
||||
#else
|
||||
#error "Platform not recognized"
|
||||
|
|
|
@ -1,14 +1,33 @@
|
|||
#ifndef __gles2_gl2_h_
|
||||
#define __gles2_gl2_h_ 1
|
||||
#ifndef __gl2_h_
|
||||
#define __gl2_h_ 1
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*
|
||||
** Copyright 2013-2020 The Khronos Group Inc.
|
||||
** SPDX-License-Identifier: MIT
|
||||
** Copyright (c) 2013-2017 The Khronos Group Inc.
|
||||
**
|
||||
** Permission is hereby granted, free of charge, to any person obtaining a
|
||||
** copy of this software and/or associated documentation files (the
|
||||
** "Materials"), to deal in the Materials without restriction, including
|
||||
** without limitation the rights to use, copy, modify, merge, publish,
|
||||
** distribute, sublicense, and/or sell copies of the Materials, and to
|
||||
** permit persons to whom the Materials are furnished to do so, subject to
|
||||
** the following conditions:
|
||||
**
|
||||
** The above copyright notice and this permission notice shall be included
|
||||
** in all copies or substantial portions of the Materials.
|
||||
**
|
||||
** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
||||
** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
||||
** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
||||
** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
|
||||
*/
|
||||
/*
|
||||
** This header is generated from the Khronos OpenGL / OpenGL ES XML
|
||||
** API Registry. The current version of the Registry, generator scripts
|
||||
** used to make the header, and the header can be found at
|
||||
|
@ -25,7 +44,7 @@ extern "C" {
|
|||
#define GL_GLES_PROTOTYPES 1
|
||||
#endif
|
||||
|
||||
/* Generated on date 20210107 */
|
||||
/* Generated on date 20170325 */
|
||||
|
||||
/* Generated C header for:
|
||||
* API: gles2
|
||||
|
@ -43,8 +62,8 @@ extern "C" {
|
|||
typedef khronos_int8_t GLbyte;
|
||||
typedef khronos_float_t GLclampf;
|
||||
typedef khronos_int32_t GLfixed;
|
||||
typedef khronos_int16_t GLshort;
|
||||
typedef khronos_uint16_t GLushort;
|
||||
typedef short GLshort;
|
||||
typedef unsigned short GLushort;
|
||||
typedef void GLvoid;
|
||||
typedef struct __GLsync *GLsync;
|
||||
typedef khronos_int64_t GLint64;
|
||||
|
@ -458,7 +477,7 @@ typedef void (GL_APIENTRYP PFNGLRELEASESHADERCOMPILERPROC) (void);
|
|||
typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
|
||||
typedef void (GL_APIENTRYP PFNGLSAMPLECOVERAGEPROC) (GLfloat value, GLboolean invert);
|
||||
typedef void (GL_APIENTRYP PFNGLSCISSORPROC) (GLint x, GLint y, GLsizei width, GLsizei height);
|
||||
typedef void (GL_APIENTRYP PFNGLSHADERBINARYPROC) (GLsizei count, const GLuint *shaders, GLenum binaryFormat, const void *binary, GLsizei length);
|
||||
typedef void (GL_APIENTRYP PFNGLSHADERBINARYPROC) (GLsizei count, const GLuint *shaders, GLenum binaryformat, const void *binary, GLsizei length);
|
||||
typedef void (GL_APIENTRYP PFNGLSHADERSOURCEPROC) (GLuint shader, GLsizei count, const GLchar *const*string, const GLint *length);
|
||||
typedef void (GL_APIENTRYP PFNGLSTENCILFUNCPROC) (GLenum func, GLint ref, GLuint mask);
|
||||
typedef void (GL_APIENTRYP PFNGLSTENCILFUNCSEPARATEPROC) (GLenum face, GLenum func, GLint ref, GLuint mask);
|
||||
|
@ -601,7 +620,7 @@ GL_APICALL void GL_APIENTRY glReleaseShaderCompiler (void);
|
|||
GL_APICALL void GL_APIENTRY glRenderbufferStorage (GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
|
||||
GL_APICALL void GL_APIENTRY glSampleCoverage (GLfloat value, GLboolean invert);
|
||||
GL_APICALL void GL_APIENTRY glScissor (GLint x, GLint y, GLsizei width, GLsizei height);
|
||||
GL_APICALL void GL_APIENTRY glShaderBinary (GLsizei count, const GLuint *shaders, GLenum binaryFormat, const void *binary, GLsizei length);
|
||||
GL_APICALL void GL_APIENTRY glShaderBinary (GLsizei count, const GLuint *shaders, GLenum binaryformat, const void *binary, GLsizei length);
|
||||
GL_APICALL void GL_APIENTRY glShaderSource (GLuint shader, GLsizei count, const GLchar *const*string, const GLint *length);
|
||||
GL_APICALL void GL_APIENTRY glStencilFunc (GLenum func, GLint ref, GLuint mask);
|
||||
GL_APICALL void GL_APIENTRY glStencilFuncSeparate (GLenum face, GLenum func, GLint ref, GLuint mask);
|
||||
|
|
|
@ -6,9 +6,28 @@ extern "C" {
|
|||
#endif
|
||||
|
||||
/*
|
||||
** Copyright 2013-2020 The Khronos Group Inc.
|
||||
** SPDX-License-Identifier: MIT
|
||||
** Copyright (c) 2013-2018 The Khronos Group Inc.
|
||||
**
|
||||
** Permission is hereby granted, free of charge, to any person obtaining a
|
||||
** copy of this software and/or associated documentation files (the
|
||||
** "Materials"), to deal in the Materials without restriction, including
|
||||
** without limitation the rights to use, copy, modify, merge, publish,
|
||||
** distribute, sublicense, and/or sell copies of the Materials, and to
|
||||
** permit persons to whom the Materials are furnished to do so, subject to
|
||||
** the following conditions:
|
||||
**
|
||||
** The above copyright notice and this permission notice shall be included
|
||||
** in all copies or substantial portions of the Materials.
|
||||
**
|
||||
** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
||||
** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
||||
** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
||||
** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
|
||||
*/
|
||||
/*
|
||||
** This header is generated from the Khronos OpenGL / OpenGL ES XML
|
||||
** API Registry. The current version of the Registry, generator scripts
|
||||
** used to make the header, and the header can be found at
|
||||
|
@ -19,7 +38,7 @@ extern "C" {
|
|||
#define GL_APIENTRYP GL_APIENTRY*
|
||||
#endif
|
||||
|
||||
/* Generated on date 20210107 */
|
||||
/* Generated on date 20200221 */
|
||||
|
||||
/* Generated C header for:
|
||||
* API: gles2
|
||||
|
@ -331,12 +350,12 @@ GL_APICALL GLboolean GL_APIENTRY glIsEnablediOES (GLenum target, GLuint index);
|
|||
typedef void (GL_APIENTRYP PFNGLDRAWELEMENTSBASEVERTEXOESPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLint basevertex);
|
||||
typedef void (GL_APIENTRYP PFNGLDRAWRANGEELEMENTSBASEVERTEXOESPROC) (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const void *indices, GLint basevertex);
|
||||
typedef void (GL_APIENTRYP PFNGLDRAWELEMENTSINSTANCEDBASEVERTEXOESPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex);
|
||||
typedef void (GL_APIENTRYP PFNGLMULTIDRAWELEMENTSBASEVERTEXEXTPROC) (GLenum mode, const GLsizei *count, GLenum type, const void *const*indices, GLsizei drawcount, const GLint *basevertex);
|
||||
typedef void (GL_APIENTRYP PFNGLMULTIDRAWELEMENTSBASEVERTEXEXTPROC) (GLenum mode, const GLsizei *count, GLenum type, const void *const*indices, GLsizei primcount, const GLint *basevertex);
|
||||
#ifdef GL_GLEXT_PROTOTYPES
|
||||
GL_APICALL void GL_APIENTRY glDrawElementsBaseVertexOES (GLenum mode, GLsizei count, GLenum type, const void *indices, GLint basevertex);
|
||||
GL_APICALL void GL_APIENTRY glDrawRangeElementsBaseVertexOES (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const void *indices, GLint basevertex);
|
||||
GL_APICALL void GL_APIENTRY glDrawElementsInstancedBaseVertexOES (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex);
|
||||
GL_APICALL void GL_APIENTRY glMultiDrawElementsBaseVertexEXT (GLenum mode, const GLsizei *count, GLenum type, const void *const*indices, GLsizei drawcount, const GLint *basevertex);
|
||||
GL_APICALL void GL_APIENTRY glMultiDrawElementsBaseVertexEXT (GLenum mode, const GLsizei *count, GLenum type, const void *const*indices, GLsizei primcount, const GLint *basevertex);
|
||||
#endif
|
||||
#endif /* GL_OES_draw_elements_base_vertex */
|
||||
|
||||
|
@ -1605,10 +1624,6 @@ GL_APICALL void GL_APIENTRY glFramebufferTexture2DMultisampleEXT (GLenum target,
|
|||
#endif
|
||||
#endif /* GL_EXT_multisampled_render_to_texture */
|
||||
|
||||
#ifndef GL_EXT_multisampled_render_to_texture2
|
||||
#define GL_EXT_multisampled_render_to_texture2 1
|
||||
#endif /* GL_EXT_multisampled_render_to_texture2 */
|
||||
|
||||
#ifndef GL_EXT_multiview_draw_buffers
|
||||
#define GL_EXT_multiview_draw_buffers 1
|
||||
#define GL_COLOR_ATTACHMENT_EXT 0x90F0
|
||||
|
@ -2444,11 +2459,6 @@ GL_APICALL void GL_APIENTRY glGetPerfQueryInfoINTEL (GLuint queryId, GLuint quer
|
|||
#endif
|
||||
#endif /* GL_INTEL_performance_query */
|
||||
|
||||
#ifndef GL_MESA_framebuffer_flip_x
|
||||
#define GL_MESA_framebuffer_flip_x 1
|
||||
#define GL_FRAMEBUFFER_FLIP_X_MESA 0x8BBC
|
||||
#endif /* GL_MESA_framebuffer_flip_x */
|
||||
|
||||
#ifndef GL_MESA_framebuffer_flip_y
|
||||
#define GL_MESA_framebuffer_flip_y 1
|
||||
#define GL_FRAMEBUFFER_FLIP_Y_MESA 0x8BBB
|
||||
|
@ -2460,11 +2470,6 @@ GL_APICALL void GL_APIENTRY glGetFramebufferParameterivMESA (GLenum target, GLen
|
|||
#endif
|
||||
#endif /* GL_MESA_framebuffer_flip_y */
|
||||
|
||||
#ifndef GL_MESA_framebuffer_swap_xy
|
||||
#define GL_MESA_framebuffer_swap_xy 1
|
||||
#define GL_FRAMEBUFFER_SWAP_XY_MESA 0x8BBD
|
||||
#endif /* GL_MESA_framebuffer_swap_xy */
|
||||
|
||||
#ifndef GL_MESA_program_binary_formats
|
||||
#define GL_MESA_program_binary_formats 1
|
||||
#define GL_PROGRAM_BINARY_FORMAT_MESA 0x875F
|
||||
|
@ -3003,20 +3008,6 @@ GL_APICALL void GL_APIENTRY glNamedBufferAttachMemoryNV (GLuint buffer, GLuint m
|
|||
#endif
|
||||
#endif /* GL_NV_memory_attachment */
|
||||
|
||||
#ifndef GL_NV_memory_object_sparse
|
||||
#define GL_NV_memory_object_sparse 1
|
||||
typedef void (GL_APIENTRYP PFNGLBUFFERPAGECOMMITMENTMEMNVPROC) (GLenum target, GLintptr offset, GLsizeiptr size, GLuint memory, GLuint64 memOffset, GLboolean commit);
|
||||
typedef void (GL_APIENTRYP PFNGLTEXPAGECOMMITMENTMEMNVPROC) (GLenum target, GLint layer, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLuint memory, GLuint64 offset, GLboolean commit);
|
||||
typedef void (GL_APIENTRYP PFNGLNAMEDBUFFERPAGECOMMITMENTMEMNVPROC) (GLuint buffer, GLintptr offset, GLsizeiptr size, GLuint memory, GLuint64 memOffset, GLboolean commit);
|
||||
typedef void (GL_APIENTRYP PFNGLTEXTUREPAGECOMMITMENTMEMNVPROC) (GLuint texture, GLint layer, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLuint memory, GLuint64 offset, GLboolean commit);
|
||||
#ifdef GL_GLEXT_PROTOTYPES
|
||||
GL_APICALL void GL_APIENTRY glBufferPageCommitmentMemNV (GLenum target, GLintptr offset, GLsizeiptr size, GLuint memory, GLuint64 memOffset, GLboolean commit);
|
||||
GL_APICALL void GL_APIENTRY glTexPageCommitmentMemNV (GLenum target, GLint layer, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLuint memory, GLuint64 offset, GLboolean commit);
|
||||
GL_APICALL void GL_APIENTRY glNamedBufferPageCommitmentMemNV (GLuint buffer, GLintptr offset, GLsizeiptr size, GLuint memory, GLuint64 memOffset, GLboolean commit);
|
||||
GL_APICALL void GL_APIENTRY glTexturePageCommitmentMemNV (GLuint texture, GLint layer, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLuint memory, GLuint64 offset, GLboolean commit);
|
||||
#endif
|
||||
#endif /* GL_NV_memory_object_sparse */
|
||||
|
||||
#ifndef GL_NV_mesh_shader
|
||||
#define GL_NV_mesh_shader 1
|
||||
#define GL_MESH_SHADER_NV 0x9559
|
||||
|
@ -3442,12 +3433,6 @@ GL_APICALL void GL_APIENTRY glPolygonModeNV (GLenum face, GLenum mode);
|
|||
#endif
|
||||
#endif /* GL_NV_polygon_mode */
|
||||
|
||||
#ifndef GL_NV_primitive_shading_rate
|
||||
#define GL_NV_primitive_shading_rate 1
|
||||
#define GL_SHADING_RATE_IMAGE_PER_PRIMITIVE_NV 0x95B1
|
||||
#define GL_SHADING_RATE_IMAGE_PALETTE_COUNT_NV 0x95B2
|
||||
#endif /* GL_NV_primitive_shading_rate */
|
||||
|
||||
#ifndef GL_NV_read_buffer
|
||||
#define GL_NV_read_buffer 1
|
||||
#define GL_READ_BUFFER_NV 0x0C02
|
||||
|
@ -3614,23 +3599,6 @@ GL_APICALL void GL_APIENTRY glShadingRateSampleOrderCustomNV (GLenum rate, GLuin
|
|||
#define GL_NV_texture_npot_2D_mipmap 1
|
||||
#endif /* GL_NV_texture_npot_2D_mipmap */
|
||||
|
||||
#ifndef GL_NV_timeline_semaphore
|
||||
#define GL_NV_timeline_semaphore 1
|
||||
#define GL_TIMELINE_SEMAPHORE_VALUE_NV 0x9595
|
||||
#define GL_SEMAPHORE_TYPE_NV 0x95B3
|
||||
#define GL_SEMAPHORE_TYPE_BINARY_NV 0x95B4
|
||||
#define GL_SEMAPHORE_TYPE_TIMELINE_NV 0x95B5
|
||||
#define GL_MAX_TIMELINE_SEMAPHORE_VALUE_DIFFERENCE_NV 0x95B6
|
||||
typedef void (GL_APIENTRYP PFNGLCREATESEMAPHORESNVPROC) (GLsizei n, GLuint *semaphores);
|
||||
typedef void (GL_APIENTRYP PFNGLSEMAPHOREPARAMETERIVNVPROC) (GLuint semaphore, GLenum pname, const GLint *params);
|
||||
typedef void (GL_APIENTRYP PFNGLGETSEMAPHOREPARAMETERIVNVPROC) (GLuint semaphore, GLenum pname, GLint *params);
|
||||
#ifdef GL_GLEXT_PROTOTYPES
|
||||
GL_APICALL void GL_APIENTRY glCreateSemaphoresNV (GLsizei n, GLuint *semaphores);
|
||||
GL_APICALL void GL_APIENTRY glSemaphoreParameterivNV (GLuint semaphore, GLenum pname, const GLint *params);
|
||||
GL_APICALL void GL_APIENTRY glGetSemaphoreParameterivNV (GLuint semaphore, GLenum pname, GLint *params);
|
||||
#endif
|
||||
#endif /* GL_NV_timeline_semaphore */
|
||||
|
||||
#ifndef GL_NV_viewport_array
|
||||
#define GL_NV_viewport_array 1
|
||||
#define GL_MAX_VIEWPORTS_NV 0x825B
|
||||
|
@ -3797,14 +3765,6 @@ GL_APICALL void GL_APIENTRY glExtGetProgramBinarySourceQCOM (GLuint program, GLe
|
|||
#endif
|
||||
#endif /* GL_QCOM_extended_get2 */
|
||||
|
||||
#ifndef GL_QCOM_frame_extrapolation
|
||||
#define GL_QCOM_frame_extrapolation 1
|
||||
typedef void (GL_APIENTRYP PFNGLEXTRAPOLATETEX2DQCOMPROC) (GLuint src1, GLuint src2, GLuint output, GLfloat scaleFactor);
|
||||
#ifdef GL_GLEXT_PROTOTYPES
|
||||
GL_APICALL void GL_APIENTRY glExtrapolateTex2DQCOM (GLuint src1, GLuint src2, GLuint output, GLfloat scaleFactor);
|
||||
#endif
|
||||
#endif /* GL_QCOM_frame_extrapolation */
|
||||
|
||||
#ifndef GL_QCOM_framebuffer_foveated
|
||||
#define GL_QCOM_framebuffer_foveated 1
|
||||
#define GL_FOVEATION_ENABLE_BIT_QCOM 0x00000001
|
||||
|
@ -3817,18 +3777,6 @@ GL_APICALL void GL_APIENTRY glFramebufferFoveationParametersQCOM (GLuint framebu
|
|||
#endif
|
||||
#endif /* GL_QCOM_framebuffer_foveated */
|
||||
|
||||
#ifndef GL_QCOM_motion_estimation
|
||||
#define GL_QCOM_motion_estimation 1
|
||||
#define GL_MOTION_ESTIMATION_SEARCH_BLOCK_X_QCOM 0x8C90
|
||||
#define GL_MOTION_ESTIMATION_SEARCH_BLOCK_Y_QCOM 0x8C91
|
||||
typedef void (GL_APIENTRYP PFNGLTEXESTIMATEMOTIONQCOMPROC) (GLuint ref, GLuint target, GLuint output);
|
||||
typedef void (GL_APIENTRYP PFNGLTEXESTIMATEMOTIONREGIONSQCOMPROC) (GLuint ref, GLuint target, GLuint output, GLuint mask);
|
||||
#ifdef GL_GLEXT_PROTOTYPES
|
||||
GL_APICALL void GL_APIENTRY glTexEstimateMotionQCOM (GLuint ref, GLuint target, GLuint output);
|
||||
GL_APICALL void GL_APIENTRY glTexEstimateMotionRegionsQCOM (GLuint ref, GLuint target, GLuint output, GLuint mask);
|
||||
#endif
|
||||
#endif /* GL_QCOM_motion_estimation */
|
||||
|
||||
#ifndef GL_QCOM_perfmon_global_mode
|
||||
#define GL_QCOM_perfmon_global_mode 1
|
||||
#define GL_PERFMON_GLOBAL_MODE_QCOM 0x8FA0
|
||||
|
@ -3847,22 +3795,6 @@ GL_APICALL void GL_APIENTRY glFramebufferFetchBarrierQCOM (void);
|
|||
#define GL_QCOM_shader_framebuffer_fetch_rate 1
|
||||
#endif /* GL_QCOM_shader_framebuffer_fetch_rate */
|
||||
|
||||
#ifndef GL_QCOM_shading_rate
|
||||
#define GL_QCOM_shading_rate 1
|
||||
#define GL_SHADING_RATE_QCOM 0x96A4
|
||||
#define GL_SHADING_RATE_PRESERVE_ASPECT_RATIO_QCOM 0x96A5
|
||||
#define GL_SHADING_RATE_1X1_PIXELS_QCOM 0x96A6
|
||||
#define GL_SHADING_RATE_1X2_PIXELS_QCOM 0x96A7
|
||||
#define GL_SHADING_RATE_2X1_PIXELS_QCOM 0x96A8
|
||||
#define GL_SHADING_RATE_2X2_PIXELS_QCOM 0x96A9
|
||||
#define GL_SHADING_RATE_4X2_PIXELS_QCOM 0x96AC
|
||||
#define GL_SHADING_RATE_4X4_PIXELS_QCOM 0x96AE
|
||||
typedef void (GL_APIENTRYP PFNGLSHADINGRATEQCOMPROC) (GLenum rate);
|
||||
#ifdef GL_GLEXT_PROTOTYPES
|
||||
GL_APICALL void GL_APIENTRY glShadingRateQCOM (GLenum rate);
|
||||
#endif
|
||||
#endif /* GL_QCOM_shading_rate */
|
||||
|
||||
#ifndef GL_QCOM_texture_foveated
|
||||
#define GL_QCOM_texture_foveated 1
|
||||
#define GL_TEXTURE_FOVEATED_FEATURE_BITS_QCOM 0x8BFB
|
||||
|
@ -3876,11 +3808,6 @@ GL_APICALL void GL_APIENTRY glTextureFoveationParametersQCOM (GLuint texture, GL
|
|||
#endif
|
||||
#endif /* GL_QCOM_texture_foveated */
|
||||
|
||||
#ifndef GL_QCOM_texture_foveated2
|
||||
#define GL_QCOM_texture_foveated2 1
|
||||
#define GL_TEXTURE_FOVEATED_CUTOFF_DENSITY_QCOM 0x96A0
|
||||
#endif /* GL_QCOM_texture_foveated2 */
|
||||
|
||||
#ifndef GL_QCOM_texture_foveated_subsampled_layout
|
||||
#define GL_QCOM_texture_foveated_subsampled_layout 1
|
||||
#define GL_FOVEATION_SUBSAMPLED_LAYOUT_METHOD_BIT_QCOM 0x00000004
|
||||
|
|
|
@ -570,11 +570,6 @@ GL_APICALL void GL_APIENTRY glImportSemaphoreZirconHandleANGLE(GLuint memory,
|
|||
#define GL_PURGED_CONTEXT_RESET_NV 0x92BB
|
||||
#endif /* GL_NV_robustness_video_memory */
|
||||
|
||||
#ifndef GL_ANGLE_get_serialized_context_string
|
||||
#define GL_ANGLE_get_serialized_context_string
|
||||
#define GL_SERIALIZED_CONTEXT_STRING_ANGLE 0x96B0
|
||||
#endif /* GL_ANGLE_get_serialized_context_string */
|
||||
|
||||
// clang-format on
|
||||
|
||||
#endif // INCLUDE_GLES2_GL2EXT_ANGLE_H_
|
||||
|
|
|
@ -150,13 +150,10 @@ typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB4FCONTEXTANGLEPROC)(GLeglContext ctx
|
|||
typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB4FVCONTEXTANGLEPROC)(GLeglContext ctx, GLuint index, const GLfloat *v);
|
||||
typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBPOINTERCONTEXTANGLEPROC)(GLeglContext ctx, GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const void *pointer);
|
||||
typedef void (GL_APIENTRYP PFNGLVIEWPORTCONTEXTANGLEPROC)(GLeglContext ctx, GLint x, GLint y, GLsizei width, GLsizei height);
|
||||
typedef void (GL_APIENTRYP PFNGLACTIVESHADERPROGRAMEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint pipeline, GLuint program);
|
||||
typedef void (GL_APIENTRYP PFNGLBEGINQUERYEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLuint id);
|
||||
typedef void (GL_APIENTRYP PFNGLBINDFRAGDATALOCATIONEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLuint color, const GLchar *name);
|
||||
typedef void (GL_APIENTRYP PFNGLBINDFRAGDATALOCATIONINDEXEDEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLuint colorNumber, GLuint index, const GLchar *name);
|
||||
typedef void (GL_APIENTRYP PFNGLBINDPROGRAMPIPELINEEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint pipeline);
|
||||
typedef void (GL_APIENTRYP PFNGLBINDVERTEXARRAYOESCONTEXTANGLEPROC)(GLeglContext ctx, GLuint array);
|
||||
typedef void (GL_APIENTRYP PFNGLBLENDBARRIERKHRCONTEXTANGLEPROC)(GLeglContext ctx);
|
||||
typedef void (GL_APIENTRYP PFNGLBLENDEQUATIONSEPARATEIEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint buf, GLenum modeRGB, GLenum modeAlpha);
|
||||
typedef void (GL_APIENTRYP PFNGLBLENDEQUATIONSEPARATEIOESCONTEXTANGLEPROC)(GLeglContext ctx, GLuint buf, GLenum modeRGB, GLenum modeAlpha);
|
||||
typedef void (GL_APIENTRYP PFNGLBLENDEQUATIONIEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint buf, GLenum mode);
|
||||
|
@ -166,11 +163,9 @@ typedef void (GL_APIENTRYP PFNGLBLENDFUNCSEPARATEIOESCONTEXTANGLEPROC)(GLeglCont
|
|||
typedef void (GL_APIENTRYP PFNGLBLENDFUNCIEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint buf, GLenum src, GLenum dst);
|
||||
typedef void (GL_APIENTRYP PFNGLBLENDFUNCIOESCONTEXTANGLEPROC)(GLeglContext ctx, GLuint buf, GLenum src, GLenum dst);
|
||||
typedef void (GL_APIENTRYP PFNGLBLITFRAMEBUFFERANGLECONTEXTANGLEPROC)(GLeglContext ctx, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
|
||||
typedef void (GL_APIENTRYP PFNGLBLITFRAMEBUFFERNVCONTEXTANGLEPROC)(GLeglContext ctx, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
|
||||
typedef void (GL_APIENTRYP PFNGLBUFFERSTORAGEEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLsizeiptr size, const void *data, GLbitfield flags);
|
||||
typedef void (GL_APIENTRYP PFNGLBUFFERSTORAGEEXTERNALEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLintptr offset, GLsizeiptr size, GLeglClientBufferEXT clientBuffer, GLbitfield flags);
|
||||
typedef void (GL_APIENTRYP PFNGLBUFFERSTORAGEMEMEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLsizeiptr size, GLuint memory, GLuint64 offset);
|
||||
typedef void (GL_APIENTRYP PFNGLCLIPCONTROLEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLenum origin, GLenum depth);
|
||||
typedef void (GL_APIENTRYP PFNGLCOLORMASKIEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
|
||||
typedef void (GL_APIENTRYP PFNGLCOLORMASKIOESCONTEXTANGLEPROC)(GLeglContext ctx, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
|
||||
typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXIMAGE3DOESCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const void *data);
|
||||
|
@ -179,13 +174,11 @@ typedef void (GL_APIENTRYP PFNGLCOPYIMAGESUBDATAEXTCONTEXTANGLEPROC)(GLeglContex
|
|||
typedef void (GL_APIENTRYP PFNGLCOPYIMAGESUBDATAOESCONTEXTANGLEPROC)(GLeglContext ctx, GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei srcWidth, GLsizei srcHeight, GLsizei srcDepth);
|
||||
typedef void (GL_APIENTRYP PFNGLCOPYTEXSUBIMAGE3DOESCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
|
||||
typedef void (GL_APIENTRYP PFNGLCREATEMEMORYOBJECTSEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLsizei n, GLuint *memoryObjects);
|
||||
typedef GLuint (GL_APIENTRYP PFNGLCREATESHADERPROGRAMVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLenum type, GLsizei count, const GLchar **strings);
|
||||
typedef void (GL_APIENTRYP PFNGLDEBUGMESSAGECALLBACKKHRCONTEXTANGLEPROC)(GLeglContext ctx, GLDEBUGPROCKHR callback, const void *userParam);
|
||||
typedef void (GL_APIENTRYP PFNGLDEBUGMESSAGECONTROLKHRCONTEXTANGLEPROC)(GLeglContext ctx, GLenum source, GLenum type, GLenum severity, GLsizei count, const GLuint *ids, GLboolean enabled);
|
||||
typedef void (GL_APIENTRYP PFNGLDEBUGMESSAGEINSERTKHRCONTEXTANGLEPROC)(GLeglContext ctx, GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar *buf);
|
||||
typedef void (GL_APIENTRYP PFNGLDELETEFENCESNVCONTEXTANGLEPROC)(GLeglContext ctx, GLsizei n, const GLuint *fences);
|
||||
typedef void (GL_APIENTRYP PFNGLDELETEMEMORYOBJECTSEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLsizei n, const GLuint *memoryObjects);
|
||||
typedef void (GL_APIENTRYP PFNGLDELETEPROGRAMPIPELINESEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLsizei n, const GLuint *pipelines);
|
||||
typedef void (GL_APIENTRYP PFNGLDELETEQUERIESEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLsizei n, const GLuint *ids);
|
||||
typedef void (GL_APIENTRYP PFNGLDELETESEMAPHORESEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLsizei n, const GLuint *semaphores);
|
||||
typedef void (GL_APIENTRYP PFNGLDELETEVERTEXARRAYSOESCONTEXTANGLEPROC)(GLeglContext ctx, GLsizei n, const GLuint *arrays);
|
||||
|
@ -210,13 +203,11 @@ typedef void (GL_APIENTRYP PFNGLENABLEIOESCONTEXTANGLEPROC)(GLeglContext ctx, GL
|
|||
typedef void (GL_APIENTRYP PFNGLENDQUERYEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target);
|
||||
typedef void (GL_APIENTRYP PFNGLFINISHFENCENVCONTEXTANGLEPROC)(GLeglContext ctx, GLuint fence);
|
||||
typedef void (GL_APIENTRYP PFNGLFLUSHMAPPEDBUFFERRANGEEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLintptr offset, GLsizeiptr length);
|
||||
typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERFETCHBARRIEREXTCONTEXTANGLEPROC)(GLeglContext ctx);
|
||||
typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTURE2DMULTISAMPLEEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples);
|
||||
typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTURE3DOESCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
|
||||
typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTUREEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLenum attachment, GLuint texture, GLint level);
|
||||
typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTUREMULTIVIEWOVRCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint baseViewIndex, GLsizei numViews);
|
||||
typedef void (GL_APIENTRYP PFNGLGENFENCESNVCONTEXTANGLEPROC)(GLeglContext ctx, GLsizei n, GLuint *fences);
|
||||
typedef void (GL_APIENTRYP PFNGLGENPROGRAMPIPELINESEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLsizei n, GLuint *pipelines);
|
||||
typedef void (GL_APIENTRYP PFNGLGENQUERIESEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLsizei n, GLuint *ids);
|
||||
typedef void (GL_APIENTRYP PFNGLGENSEMAPHORESEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLsizei n, GLuint *semaphores);
|
||||
typedef void (GL_APIENTRYP PFNGLGENVERTEXARRAYSOESCONTEXTANGLEPROC)(GLeglContext ctx, GLsizei n, GLuint *arrays);
|
||||
|
@ -227,27 +218,20 @@ typedef GLint (GL_APIENTRYP PFNGLGETFRAGDATAINDEXEXTCONTEXTANGLEPROC)(GLeglConte
|
|||
typedef GLenum (GL_APIENTRYP PFNGLGETGRAPHICSRESETSTATUSEXTCONTEXTANGLEPROC)(GLeglContext ctx);
|
||||
typedef void (GL_APIENTRYP PFNGLGETINTEGER64VEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLenum pname, GLint64 *data);
|
||||
typedef void (GL_APIENTRYP PFNGLGETMEMORYOBJECTPARAMETERIVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint memoryObject, GLenum pname, GLint *params);
|
||||
typedef void (GL_APIENTRYP PFNGLGETOBJECTLABELEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLenum type, GLuint object, GLsizei bufSize, GLsizei *length, GLchar *label);
|
||||
typedef void (GL_APIENTRYP PFNGLGETOBJECTLABELKHRCONTEXTANGLEPROC)(GLeglContext ctx, GLenum identifier, GLuint name, GLsizei bufSize, GLsizei *length, GLchar *label);
|
||||
typedef void (GL_APIENTRYP PFNGLGETOBJECTPTRLABELKHRCONTEXTANGLEPROC)(GLeglContext ctx, const void *ptr, GLsizei bufSize, GLsizei *length, GLchar *label);
|
||||
typedef void (GL_APIENTRYP PFNGLGETPOINTERVKHRCONTEXTANGLEPROC)(GLeglContext ctx, GLenum pname, void **params);
|
||||
typedef void (GL_APIENTRYP PFNGLGETPROGRAMBINARYOESCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, void *binary);
|
||||
typedef void (GL_APIENTRYP PFNGLGETPROGRAMPIPELINEINFOLOGEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
|
||||
typedef void (GL_APIENTRYP PFNGLGETPROGRAMPIPELINEIVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint pipeline, GLenum pname, GLint *params);
|
||||
typedef GLint (GL_APIENTRYP PFNGLGETPROGRAMRESOURCELOCATIONINDEXEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLenum programInterface, const GLchar *name);
|
||||
typedef void (GL_APIENTRYP PFNGLGETQUERYOBJECTI64VEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint id, GLenum pname, GLint64 *params);
|
||||
typedef void (GL_APIENTRYP PFNGLGETQUERYOBJECTIVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint id, GLenum pname, GLint *params);
|
||||
typedef void (GL_APIENTRYP PFNGLGETQUERYOBJECTUI64VEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint id, GLenum pname, GLuint64 *params);
|
||||
typedef void (GL_APIENTRYP PFNGLGETQUERYOBJECTUIVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint id, GLenum pname, GLuint *params);
|
||||
typedef void (GL_APIENTRYP PFNGLGETQUERYIVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLenum pname, GLint *params);
|
||||
typedef void (GL_APIENTRYP PFNGLGETSAMPLERPARAMETERIIVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint sampler, GLenum pname, GLint *params);
|
||||
typedef void (GL_APIENTRYP PFNGLGETSAMPLERPARAMETERIIVOESCONTEXTANGLEPROC)(GLeglContext ctx, GLuint sampler, GLenum pname, GLint *params);
|
||||
typedef void (GL_APIENTRYP PFNGLGETSAMPLERPARAMETERIUIVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint sampler, GLenum pname, GLuint *params);
|
||||
typedef void (GL_APIENTRYP PFNGLGETSAMPLERPARAMETERIUIVOESCONTEXTANGLEPROC)(GLeglContext ctx, GLuint sampler, GLenum pname, GLuint *params);
|
||||
typedef void (GL_APIENTRYP PFNGLGETSEMAPHOREPARAMETERUI64VEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint semaphore, GLenum pname, GLuint64 *params);
|
||||
typedef void (GL_APIENTRYP PFNGLGETTEXPARAMETERIIVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLenum pname, GLint *params);
|
||||
typedef void (GL_APIENTRYP PFNGLGETTEXPARAMETERIIVOESCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLenum pname, GLint *params);
|
||||
typedef void (GL_APIENTRYP PFNGLGETTEXPARAMETERIUIVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLenum pname, GLuint *params);
|
||||
typedef void (GL_APIENTRYP PFNGLGETTEXPARAMETERIUIVOESCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLenum pname, GLuint *params);
|
||||
typedef void (GL_APIENTRYP PFNGLGETTRANSLATEDSHADERSOURCEANGLECONTEXTANGLEPROC)(GLeglContext ctx, GLuint shader, GLsizei bufsize, GLsizei *length, GLchar *source);
|
||||
typedef void (GL_APIENTRYP PFNGLGETUNSIGNEDBYTEVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLenum pname, GLubyte *data);
|
||||
|
@ -261,11 +245,9 @@ typedef GLboolean (GL_APIENTRYP PFNGLISENABLEDIEXTCONTEXTANGLEPROC)(GLeglContext
|
|||
typedef GLboolean (GL_APIENTRYP PFNGLISENABLEDIOESCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLuint index);
|
||||
typedef GLboolean (GL_APIENTRYP PFNGLISFENCENVCONTEXTANGLEPROC)(GLeglContext ctx, GLuint fence);
|
||||
typedef GLboolean (GL_APIENTRYP PFNGLISMEMORYOBJECTEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint memoryObject);
|
||||
typedef GLboolean (GL_APIENTRYP PFNGLISPROGRAMPIPELINEEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint pipeline);
|
||||
typedef GLboolean (GL_APIENTRYP PFNGLISQUERYEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint id);
|
||||
typedef GLboolean (GL_APIENTRYP PFNGLISSEMAPHOREEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint semaphore);
|
||||
typedef GLboolean (GL_APIENTRYP PFNGLISVERTEXARRAYOESCONTEXTANGLEPROC)(GLeglContext ctx, GLuint array);
|
||||
typedef void (GL_APIENTRYP PFNGLLABELOBJECTEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLenum type, GLuint object, GLsizei length, const GLchar *label);
|
||||
typedef void *(GL_APIENTRYP PFNGLMAPBUFFEROESCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLenum access);
|
||||
typedef void *(GL_APIENTRYP PFNGLMAPBUFFERRANGEEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
|
||||
typedef void (GL_APIENTRYP PFNGLMAXSHADERCOMPILERTHREADSKHRCONTEXTANGLEPROC)(GLeglContext ctx, GLuint count);
|
||||
|
@ -275,54 +257,16 @@ typedef void (GL_APIENTRYP PFNGLMULTIDRAWELEMENTSBASEVERTEXEXTCONTEXTANGLEPROC)(
|
|||
typedef void (GL_APIENTRYP PFNGLNAMEDBUFFERSTORAGEEXTERNALEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint buffer, GLintptr offset, GLsizeiptr size, GLeglClientBufferEXT clientBuffer, GLbitfield flags);
|
||||
typedef void (GL_APIENTRYP PFNGLOBJECTLABELKHRCONTEXTANGLEPROC)(GLeglContext ctx, GLenum identifier, GLuint name, GLsizei length, const GLchar *label);
|
||||
typedef void (GL_APIENTRYP PFNGLOBJECTPTRLABELKHRCONTEXTANGLEPROC)(GLeglContext ctx, const void *ptr, GLsizei length, const GLchar *label);
|
||||
typedef void (GL_APIENTRYP PFNGLPATCHPARAMETERIEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLenum pname, GLint value);
|
||||
typedef void (GL_APIENTRYP PFNGLPOPDEBUGGROUPKHRCONTEXTANGLEPROC)(GLeglContext ctx);
|
||||
typedef void (GL_APIENTRYP PFNGLPOPGROUPMARKEREXTCONTEXTANGLEPROC)(GLeglContext ctx);
|
||||
typedef void (GL_APIENTRYP PFNGLPRIMITIVEBOUNDINGBOXEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLfloat minX, GLfloat minY, GLfloat minZ, GLfloat minW, GLfloat maxX, GLfloat maxY, GLfloat maxZ, GLfloat maxW);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMBINARYOESCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLenum binaryFormat, const void *binary, GLint length);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMPARAMETERIEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLenum pname, GLint value);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1FEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLfloat v0);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1FVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLsizei count, const GLfloat *value);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1IEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLint v0);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1IVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLsizei count, const GLint *value);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1UIEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLuint v0);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1UIVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLsizei count, const GLuint *value);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2FEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLfloat v0, GLfloat v1);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2FVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLsizei count, const GLfloat *value);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2IEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLint v0, GLint v1);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2IVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLsizei count, const GLint *value);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2UIEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLuint v0, GLuint v1);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2UIVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLsizei count, const GLuint *value);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3FEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3FVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLsizei count, const GLfloat *value);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3IEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLint v0, GLint v1, GLint v2);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3IVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLsizei count, const GLint *value);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3UIEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3UIVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLsizei count, const GLuint *value);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4FEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4FVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLsizei count, const GLfloat *value);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4IEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4IVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLsizei count, const GLint *value);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4UIEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4UIVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLsizei count, const GLuint *value);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX2FVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX2X3FVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX2X4FVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX3FVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX3X2FVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX3X4FVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX4FVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX4X2FVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
|
||||
typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX4X3FVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
|
||||
typedef void (GL_APIENTRYP PFNGLPUSHDEBUGGROUPKHRCONTEXTANGLEPROC)(GLeglContext ctx, GLenum source, GLuint id, GLsizei length, const GLchar *message);
|
||||
typedef void (GL_APIENTRYP PFNGLPUSHGROUPMARKEREXTCONTEXTANGLEPROC)(GLeglContext ctx, GLsizei length, const GLchar *marker);
|
||||
typedef void (GL_APIENTRYP PFNGLQUERYCOUNTEREXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint id, GLenum target);
|
||||
typedef void (GL_APIENTRYP PFNGLREADNPIXELSEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, void *data);
|
||||
typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLEANGLECONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
|
||||
typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLEEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
|
||||
typedef void (GL_APIENTRYP PFNGLSAMPLERPARAMETERIIVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint sampler, GLenum pname, const GLint *param);
|
||||
typedef void (GL_APIENTRYP PFNGLSAMPLERPARAMETERIIVOESCONTEXTANGLEPROC)(GLeglContext ctx, GLuint sampler, GLenum pname, const GLint *param);
|
||||
typedef void (GL_APIENTRYP PFNGLSAMPLERPARAMETERIUIVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint sampler, GLenum pname, const GLuint *param);
|
||||
typedef void (GL_APIENTRYP PFNGLSAMPLERPARAMETERIUIVOESCONTEXTANGLEPROC)(GLeglContext ctx, GLuint sampler, GLenum pname, const GLuint *param);
|
||||
typedef void (GL_APIENTRYP PFNGLSEMAPHOREPARAMETERUI64VEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint semaphore, GLenum pname, const GLuint64 *params);
|
||||
typedef void (GL_APIENTRYP PFNGLSETFENCENVCONTEXTANGLEPROC)(GLeglContext ctx, GLuint fence, GLenum condition);
|
||||
|
@ -333,9 +277,7 @@ typedef void (GL_APIENTRYP PFNGLTEXBUFFEROESCONTEXTANGLEPROC)(GLeglContext ctx,
|
|||
typedef void (GL_APIENTRYP PFNGLTEXBUFFERRANGEEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size);
|
||||
typedef void (GL_APIENTRYP PFNGLTEXBUFFERRANGEOESCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size);
|
||||
typedef void (GL_APIENTRYP PFNGLTEXIMAGE3DOESCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const void *pixels);
|
||||
typedef void (GL_APIENTRYP PFNGLTEXPARAMETERIIVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLenum pname, const GLint *params);
|
||||
typedef void (GL_APIENTRYP PFNGLTEXPARAMETERIIVOESCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLenum pname, const GLint *params);
|
||||
typedef void (GL_APIENTRYP PFNGLTEXPARAMETERIUIVEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLenum pname, const GLuint *params);
|
||||
typedef void (GL_APIENTRYP PFNGLTEXPARAMETERIUIVOESCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLenum pname, const GLuint *params);
|
||||
typedef void (GL_APIENTRYP PFNGLTEXSTORAGE1DEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width);
|
||||
typedef void (GL_APIENTRYP PFNGLTEXSTORAGE2DEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height);
|
||||
|
@ -347,8 +289,6 @@ typedef void (GL_APIENTRYP PFNGLTEXSTORAGEMEM3DEXTCONTEXTANGLEPROC)(GLeglContext
|
|||
typedef void (GL_APIENTRYP PFNGLTEXSTORAGEMEM3DMULTISAMPLEEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedSampleLocations, GLuint memory, GLuint64 offset);
|
||||
typedef void (GL_APIENTRYP PFNGLTEXSUBIMAGE3DOESCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const void *pixels);
|
||||
typedef GLboolean (GL_APIENTRYP PFNGLUNMAPBUFFEROESCONTEXTANGLEPROC)(GLeglContext ctx, GLenum target);
|
||||
typedef void (GL_APIENTRYP PFNGLUSEPROGRAMSTAGESEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint pipeline, GLbitfield stages, GLuint program);
|
||||
typedef void (GL_APIENTRYP PFNGLVALIDATEPROGRAMPIPELINEEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint pipeline);
|
||||
typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBDIVISORANGLECONTEXTANGLEPROC)(GLeglContext ctx, GLuint index, GLuint divisor);
|
||||
typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBDIVISOREXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint index, GLuint divisor);
|
||||
typedef void (GL_APIENTRYP PFNGLWAITSEMAPHOREEXTCONTEXTANGLEPROC)(GLeglContext ctx, GLuint semaphore, GLuint numBufferBarriers, const GLuint *buffers, GLuint numTextureBarriers, const GLuint *textures, const GLenum *srcLayouts);
|
||||
|
@ -426,7 +366,7 @@ typedef void (GL_APIENTRYP PFNGLGETQUERYOBJECTUI64VROBUSTANGLECONTEXTANGLEPROC)(
|
|||
typedef void (GL_APIENTRYP PFNGLCOPYTEXTURE3DANGLECONTEXTANGLEPROC)(GLeglContext ctx, GLuint sourceId, GLint sourceLevel, GLenum destTarget, GLuint destId, GLint destLevel, GLint internalFormat, GLenum destType, GLboolean unpackFlipY, GLboolean unpackPremultiplyAlpha, GLboolean unpackUnmultiplyAlpha);
|
||||
typedef void (GL_APIENTRYP PFNGLCOPYSUBTEXTURE3DANGLECONTEXTANGLEPROC)(GLeglContext ctx, GLuint sourceId, GLint sourceLevel, GLenum destTarget, GLuint destId, GLint destLevel, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLint z, GLint width, GLint height, GLint depth, GLboolean unpackFlipY, GLboolean unpackPremultiplyAlpha, GLboolean unpackUnmultiplyAlpha);
|
||||
typedef void (GL_APIENTRYP PFNGLTEXSTORAGE2DMULTISAMPLEANGLECONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
|
||||
typedef void (GL_APIENTRYP PFNGLGETTEXLEVELPARAMETERIVANGLECONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLint level, GLenum pname, GLint *params);
|
||||
typedef void (GL_APIENTRYP PFNGLGETTEXLEVELPARAMETERIVANGLECONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLint level, GLenum pname, GLint * params);
|
||||
typedef void (GL_APIENTRYP PFNGLGETTEXLEVELPARAMETERFVANGLECONTEXTANGLEPROC)(GLeglContext ctx, GLenum target, GLint level, GLenum pname, GLfloat * params);
|
||||
typedef void (GL_APIENTRYP PFNGLMULTIDRAWARRAYSANGLECONTEXTANGLEPROC)(GLeglContext ctx, GLenum mode, const GLint *firsts, const GLsizei *counts, GLsizei drawcount);
|
||||
typedef void (GL_APIENTRYP PFNGLMULTIDRAWARRAYSINSTANCEDANGLECONTEXTANGLEPROC)(GLeglContext ctx, GLenum mode, const GLint *firsts, const GLsizei *counts, const GLsizei *instanceCounts, GLsizei drawcount);
|
||||
|
@ -593,13 +533,10 @@ GL_APICALL void GL_APIENTRY glVertexAttrib4fContextANGLE(GLeglContext ctx, GLuin
|
|||
GL_APICALL void GL_APIENTRY glVertexAttrib4fvContextANGLE(GLeglContext ctx, GLuint index, const GLfloat *v);
|
||||
GL_APICALL void GL_APIENTRY glVertexAttribPointerContextANGLE(GLeglContext ctx, GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const void *pointer);
|
||||
GL_APICALL void GL_APIENTRY glViewportContextANGLE(GLeglContext ctx, GLint x, GLint y, GLsizei width, GLsizei height);
|
||||
GL_APICALL void GL_APIENTRY glActiveShaderProgramEXTContextANGLE(GLeglContext ctx, GLuint pipeline, GLuint program);
|
||||
GL_APICALL void GL_APIENTRY glBeginQueryEXTContextANGLE(GLeglContext ctx, GLenum target, GLuint id);
|
||||
GL_APICALL void GL_APIENTRY glBindFragDataLocationEXTContextANGLE(GLeglContext ctx, GLuint program, GLuint color, const GLchar *name);
|
||||
GL_APICALL void GL_APIENTRY glBindFragDataLocationIndexedEXTContextANGLE(GLeglContext ctx, GLuint program, GLuint colorNumber, GLuint index, const GLchar *name);
|
||||
GL_APICALL void GL_APIENTRY glBindProgramPipelineEXTContextANGLE(GLeglContext ctx, GLuint pipeline);
|
||||
GL_APICALL void GL_APIENTRY glBindVertexArrayOESContextANGLE(GLeglContext ctx, GLuint array);
|
||||
GL_APICALL void GL_APIENTRY glBlendBarrierKHRContextANGLE(GLeglContext ctx);
|
||||
GL_APICALL void GL_APIENTRY glBlendEquationSeparateiEXTContextANGLE(GLeglContext ctx, GLuint buf, GLenum modeRGB, GLenum modeAlpha);
|
||||
GL_APICALL void GL_APIENTRY glBlendEquationSeparateiOESContextANGLE(GLeglContext ctx, GLuint buf, GLenum modeRGB, GLenum modeAlpha);
|
||||
GL_APICALL void GL_APIENTRY glBlendEquationiEXTContextANGLE(GLeglContext ctx, GLuint buf, GLenum mode);
|
||||
|
@ -609,11 +546,9 @@ GL_APICALL void GL_APIENTRY glBlendFuncSeparateiOESContextANGLE(GLeglContext ctx
|
|||
GL_APICALL void GL_APIENTRY glBlendFunciEXTContextANGLE(GLeglContext ctx, GLuint buf, GLenum src, GLenum dst);
|
||||
GL_APICALL void GL_APIENTRY glBlendFunciOESContextANGLE(GLeglContext ctx, GLuint buf, GLenum src, GLenum dst);
|
||||
GL_APICALL void GL_APIENTRY glBlitFramebufferANGLEContextANGLE(GLeglContext ctx, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
|
||||
GL_APICALL void GL_APIENTRY glBlitFramebufferNVContextANGLE(GLeglContext ctx, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
|
||||
GL_APICALL void GL_APIENTRY glBufferStorageEXTContextANGLE(GLeglContext ctx, GLenum target, GLsizeiptr size, const void *data, GLbitfield flags);
|
||||
GL_APICALL void GL_APIENTRY glBufferStorageExternalEXTContextANGLE(GLeglContext ctx, GLenum target, GLintptr offset, GLsizeiptr size, GLeglClientBufferEXT clientBuffer, GLbitfield flags);
|
||||
GL_APICALL void GL_APIENTRY glBufferStorageMemEXTContextANGLE(GLeglContext ctx, GLenum target, GLsizeiptr size, GLuint memory, GLuint64 offset);
|
||||
GL_APICALL void GL_APIENTRY glClipControlEXTContextANGLE(GLeglContext ctx, GLenum origin, GLenum depth);
|
||||
GL_APICALL void GL_APIENTRY glColorMaskiEXTContextANGLE(GLeglContext ctx, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
|
||||
GL_APICALL void GL_APIENTRY glColorMaskiOESContextANGLE(GLeglContext ctx, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
|
||||
GL_APICALL void GL_APIENTRY glCompressedTexImage3DOESContextANGLE(GLeglContext ctx, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const void *data);
|
||||
|
@ -622,13 +557,11 @@ GL_APICALL void GL_APIENTRY glCopyImageSubDataEXTContextANGLE(GLeglContext ctx,
|
|||
GL_APICALL void GL_APIENTRY glCopyImageSubDataOESContextANGLE(GLeglContext ctx, GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei srcWidth, GLsizei srcHeight, GLsizei srcDepth);
|
||||
GL_APICALL void GL_APIENTRY glCopyTexSubImage3DOESContextANGLE(GLeglContext ctx, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
|
||||
GL_APICALL void GL_APIENTRY glCreateMemoryObjectsEXTContextANGLE(GLeglContext ctx, GLsizei n, GLuint *memoryObjects);
|
||||
GL_APICALL GLuint GL_APIENTRY glCreateShaderProgramvEXTContextANGLE(GLeglContext ctx, GLenum type, GLsizei count, const GLchar **strings);
|
||||
GL_APICALL void GL_APIENTRY glDebugMessageCallbackKHRContextANGLE(GLeglContext ctx, GLDEBUGPROCKHR callback, const void *userParam);
|
||||
GL_APICALL void GL_APIENTRY glDebugMessageControlKHRContextANGLE(GLeglContext ctx, GLenum source, GLenum type, GLenum severity, GLsizei count, const GLuint *ids, GLboolean enabled);
|
||||
GL_APICALL void GL_APIENTRY glDebugMessageInsertKHRContextANGLE(GLeglContext ctx, GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar *buf);
|
||||
GL_APICALL void GL_APIENTRY glDeleteFencesNVContextANGLE(GLeglContext ctx, GLsizei n, const GLuint *fences);
|
||||
GL_APICALL void GL_APIENTRY glDeleteMemoryObjectsEXTContextANGLE(GLeglContext ctx, GLsizei n, const GLuint *memoryObjects);
|
||||
GL_APICALL void GL_APIENTRY glDeleteProgramPipelinesEXTContextANGLE(GLeglContext ctx, GLsizei n, const GLuint *pipelines);
|
||||
GL_APICALL void GL_APIENTRY glDeleteQueriesEXTContextANGLE(GLeglContext ctx, GLsizei n, const GLuint *ids);
|
||||
GL_APICALL void GL_APIENTRY glDeleteSemaphoresEXTContextANGLE(GLeglContext ctx, GLsizei n, const GLuint *semaphores);
|
||||
GL_APICALL void GL_APIENTRY glDeleteVertexArraysOESContextANGLE(GLeglContext ctx, GLsizei n, const GLuint *arrays);
|
||||
|
@ -653,13 +586,11 @@ GL_APICALL void GL_APIENTRY glEnableiOESContextANGLE(GLeglContext ctx, GLenum ta
|
|||
GL_APICALL void GL_APIENTRY glEndQueryEXTContextANGLE(GLeglContext ctx, GLenum target);
|
||||
GL_APICALL void GL_APIENTRY glFinishFenceNVContextANGLE(GLeglContext ctx, GLuint fence);
|
||||
GL_APICALL void GL_APIENTRY glFlushMappedBufferRangeEXTContextANGLE(GLeglContext ctx, GLenum target, GLintptr offset, GLsizeiptr length);
|
||||
GL_APICALL void GL_APIENTRY glFramebufferFetchBarrierEXTContextANGLE(GLeglContext ctx);
|
||||
GL_APICALL void GL_APIENTRY glFramebufferTexture2DMultisampleEXTContextANGLE(GLeglContext ctx, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples);
|
||||
GL_APICALL void GL_APIENTRY glFramebufferTexture3DOESContextANGLE(GLeglContext ctx, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
|
||||
GL_APICALL void GL_APIENTRY glFramebufferTextureEXTContextANGLE(GLeglContext ctx, GLenum target, GLenum attachment, GLuint texture, GLint level);
|
||||
GL_APICALL void GL_APIENTRY glFramebufferTextureMultiviewOVRContextANGLE(GLeglContext ctx, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint baseViewIndex, GLsizei numViews);
|
||||
GL_APICALL void GL_APIENTRY glGenFencesNVContextANGLE(GLeglContext ctx, GLsizei n, GLuint *fences);
|
||||
GL_APICALL void GL_APIENTRY glGenProgramPipelinesEXTContextANGLE(GLeglContext ctx, GLsizei n, GLuint *pipelines);
|
||||
GL_APICALL void GL_APIENTRY glGenQueriesEXTContextANGLE(GLeglContext ctx, GLsizei n, GLuint *ids);
|
||||
GL_APICALL void GL_APIENTRY glGenSemaphoresEXTContextANGLE(GLeglContext ctx, GLsizei n, GLuint *semaphores);
|
||||
GL_APICALL void GL_APIENTRY glGenVertexArraysOESContextANGLE(GLeglContext ctx, GLsizei n, GLuint *arrays);
|
||||
|
@ -670,27 +601,20 @@ GL_APICALL GLint GL_APIENTRY glGetFragDataIndexEXTContextANGLE(GLeglContext ctx,
|
|||
GL_APICALL GLenum GL_APIENTRY glGetGraphicsResetStatusEXTContextANGLE(GLeglContext ctx);
|
||||
GL_APICALL void GL_APIENTRY glGetInteger64vEXTContextANGLE(GLeglContext ctx, GLenum pname, GLint64 *data);
|
||||
GL_APICALL void GL_APIENTRY glGetMemoryObjectParameterivEXTContextANGLE(GLeglContext ctx, GLuint memoryObject, GLenum pname, GLint *params);
|
||||
GL_APICALL void GL_APIENTRY glGetObjectLabelEXTContextANGLE(GLeglContext ctx, GLenum type, GLuint object, GLsizei bufSize, GLsizei *length, GLchar *label);
|
||||
GL_APICALL void GL_APIENTRY glGetObjectLabelKHRContextANGLE(GLeglContext ctx, GLenum identifier, GLuint name, GLsizei bufSize, GLsizei *length, GLchar *label);
|
||||
GL_APICALL void GL_APIENTRY glGetObjectPtrLabelKHRContextANGLE(GLeglContext ctx, const void *ptr, GLsizei bufSize, GLsizei *length, GLchar *label);
|
||||
GL_APICALL void GL_APIENTRY glGetPointervKHRContextANGLE(GLeglContext ctx, GLenum pname, void **params);
|
||||
GL_APICALL void GL_APIENTRY glGetProgramBinaryOESContextANGLE(GLeglContext ctx, GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, void *binary);
|
||||
GL_APICALL void GL_APIENTRY glGetProgramPipelineInfoLogEXTContextANGLE(GLeglContext ctx, GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
|
||||
GL_APICALL void GL_APIENTRY glGetProgramPipelineivEXTContextANGLE(GLeglContext ctx, GLuint pipeline, GLenum pname, GLint *params);
|
||||
GL_APICALL GLint GL_APIENTRY glGetProgramResourceLocationIndexEXTContextANGLE(GLeglContext ctx, GLuint program, GLenum programInterface, const GLchar *name);
|
||||
GL_APICALL void GL_APIENTRY glGetQueryObjecti64vEXTContextANGLE(GLeglContext ctx, GLuint id, GLenum pname, GLint64 *params);
|
||||
GL_APICALL void GL_APIENTRY glGetQueryObjectivEXTContextANGLE(GLeglContext ctx, GLuint id, GLenum pname, GLint *params);
|
||||
GL_APICALL void GL_APIENTRY glGetQueryObjectui64vEXTContextANGLE(GLeglContext ctx, GLuint id, GLenum pname, GLuint64 *params);
|
||||
GL_APICALL void GL_APIENTRY glGetQueryObjectuivEXTContextANGLE(GLeglContext ctx, GLuint id, GLenum pname, GLuint *params);
|
||||
GL_APICALL void GL_APIENTRY glGetQueryivEXTContextANGLE(GLeglContext ctx, GLenum target, GLenum pname, GLint *params);
|
||||
GL_APICALL void GL_APIENTRY glGetSamplerParameterIivEXTContextANGLE(GLeglContext ctx, GLuint sampler, GLenum pname, GLint *params);
|
||||
GL_APICALL void GL_APIENTRY glGetSamplerParameterIivOESContextANGLE(GLeglContext ctx, GLuint sampler, GLenum pname, GLint *params);
|
||||
GL_APICALL void GL_APIENTRY glGetSamplerParameterIuivEXTContextANGLE(GLeglContext ctx, GLuint sampler, GLenum pname, GLuint *params);
|
||||
GL_APICALL void GL_APIENTRY glGetSamplerParameterIuivOESContextANGLE(GLeglContext ctx, GLuint sampler, GLenum pname, GLuint *params);
|
||||
GL_APICALL void GL_APIENTRY glGetSemaphoreParameterui64vEXTContextANGLE(GLeglContext ctx, GLuint semaphore, GLenum pname, GLuint64 *params);
|
||||
GL_APICALL void GL_APIENTRY glGetTexParameterIivEXTContextANGLE(GLeglContext ctx, GLenum target, GLenum pname, GLint *params);
|
||||
GL_APICALL void GL_APIENTRY glGetTexParameterIivOESContextANGLE(GLeglContext ctx, GLenum target, GLenum pname, GLint *params);
|
||||
GL_APICALL void GL_APIENTRY glGetTexParameterIuivEXTContextANGLE(GLeglContext ctx, GLenum target, GLenum pname, GLuint *params);
|
||||
GL_APICALL void GL_APIENTRY glGetTexParameterIuivOESContextANGLE(GLeglContext ctx, GLenum target, GLenum pname, GLuint *params);
|
||||
GL_APICALL void GL_APIENTRY glGetTranslatedShaderSourceANGLEContextANGLE(GLeglContext ctx, GLuint shader, GLsizei bufsize, GLsizei *length, GLchar *source);
|
||||
GL_APICALL void GL_APIENTRY glGetUnsignedBytevEXTContextANGLE(GLeglContext ctx, GLenum pname, GLubyte *data);
|
||||
|
@ -704,11 +628,9 @@ GL_APICALL GLboolean GL_APIENTRY glIsEnablediEXTContextANGLE(GLeglContext ctx, G
|
|||
GL_APICALL GLboolean GL_APIENTRY glIsEnablediOESContextANGLE(GLeglContext ctx, GLenum target, GLuint index);
|
||||
GL_APICALL GLboolean GL_APIENTRY glIsFenceNVContextANGLE(GLeglContext ctx, GLuint fence);
|
||||
GL_APICALL GLboolean GL_APIENTRY glIsMemoryObjectEXTContextANGLE(GLeglContext ctx, GLuint memoryObject);
|
||||
GL_APICALL GLboolean GL_APIENTRY glIsProgramPipelineEXTContextANGLE(GLeglContext ctx, GLuint pipeline);
|
||||
GL_APICALL GLboolean GL_APIENTRY glIsQueryEXTContextANGLE(GLeglContext ctx, GLuint id);
|
||||
GL_APICALL GLboolean GL_APIENTRY glIsSemaphoreEXTContextANGLE(GLeglContext ctx, GLuint semaphore);
|
||||
GL_APICALL GLboolean GL_APIENTRY glIsVertexArrayOESContextANGLE(GLeglContext ctx, GLuint array);
|
||||
GL_APICALL void GL_APIENTRY glLabelObjectEXTContextANGLE(GLeglContext ctx, GLenum type, GLuint object, GLsizei length, const GLchar *label);
|
||||
GL_APICALL void *GL_APIENTRY glMapBufferOESContextANGLE(GLeglContext ctx, GLenum target, GLenum access);
|
||||
GL_APICALL void *GL_APIENTRY glMapBufferRangeEXTContextANGLE(GLeglContext ctx, GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
|
||||
GL_APICALL void GL_APIENTRY glMaxShaderCompilerThreadsKHRContextANGLE(GLeglContext ctx, GLuint count);
|
||||
|
@ -718,54 +640,16 @@ GL_APICALL void GL_APIENTRY glMultiDrawElementsBaseVertexEXTContextANGLE(GLeglCo
|
|||
GL_APICALL void GL_APIENTRY glNamedBufferStorageExternalEXTContextANGLE(GLeglContext ctx, GLuint buffer, GLintptr offset, GLsizeiptr size, GLeglClientBufferEXT clientBuffer, GLbitfield flags);
|
||||
GL_APICALL void GL_APIENTRY glObjectLabelKHRContextANGLE(GLeglContext ctx, GLenum identifier, GLuint name, GLsizei length, const GLchar *label);
|
||||
GL_APICALL void GL_APIENTRY glObjectPtrLabelKHRContextANGLE(GLeglContext ctx, const void *ptr, GLsizei length, const GLchar *label);
|
||||
GL_APICALL void GL_APIENTRY glPatchParameteriEXTContextANGLE(GLeglContext ctx, GLenum pname, GLint value);
|
||||
GL_APICALL void GL_APIENTRY glPopDebugGroupKHRContextANGLE(GLeglContext ctx);
|
||||
GL_APICALL void GL_APIENTRY glPopGroupMarkerEXTContextANGLE(GLeglContext ctx);
|
||||
GL_APICALL void GL_APIENTRY glPrimitiveBoundingBoxEXTContextANGLE(GLeglContext ctx, GLfloat minX, GLfloat minY, GLfloat minZ, GLfloat minW, GLfloat maxX, GLfloat maxY, GLfloat maxZ, GLfloat maxW);
|
||||
GL_APICALL void GL_APIENTRY glProgramBinaryOESContextANGLE(GLeglContext ctx, GLuint program, GLenum binaryFormat, const void *binary, GLint length);
|
||||
GL_APICALL void GL_APIENTRY glProgramParameteriEXTContextANGLE(GLeglContext ctx, GLuint program, GLenum pname, GLint value);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniform1fEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLfloat v0);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniform1fvEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLsizei count, const GLfloat *value);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniform1iEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLint v0);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniform1ivEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLsizei count, const GLint *value);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniform1uiEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLuint v0);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniform1uivEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLsizei count, const GLuint *value);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniform2fEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLfloat v0, GLfloat v1);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniform2fvEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLsizei count, const GLfloat *value);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniform2iEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLint v0, GLint v1);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniform2ivEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLsizei count, const GLint *value);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniform2uiEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLuint v0, GLuint v1);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniform2uivEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLsizei count, const GLuint *value);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniform3fEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniform3fvEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLsizei count, const GLfloat *value);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniform3iEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLint v0, GLint v1, GLint v2);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniform3ivEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLsizei count, const GLint *value);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniform3uiEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniform3uivEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLsizei count, const GLuint *value);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniform4fEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniform4fvEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLsizei count, const GLfloat *value);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniform4iEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniform4ivEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLsizei count, const GLint *value);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniform4uiEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniform4uivEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLsizei count, const GLuint *value);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniformMatrix2fvEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniformMatrix2x3fvEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniformMatrix2x4fvEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniformMatrix3fvEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniformMatrix3x2fvEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniformMatrix3x4fvEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniformMatrix4fvEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniformMatrix4x2fvEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
|
||||
GL_APICALL void GL_APIENTRY glProgramUniformMatrix4x3fvEXTContextANGLE(GLeglContext ctx, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
|
||||
GL_APICALL void GL_APIENTRY glPushDebugGroupKHRContextANGLE(GLeglContext ctx, GLenum source, GLuint id, GLsizei length, const GLchar *message);
|
||||
GL_APICALL void GL_APIENTRY glPushGroupMarkerEXTContextANGLE(GLeglContext ctx, GLsizei length, const GLchar *marker);
|
||||
GL_APICALL void GL_APIENTRY glQueryCounterEXTContextANGLE(GLeglContext ctx, GLuint id, GLenum target);
|
||||
GL_APICALL void GL_APIENTRY glReadnPixelsEXTContextANGLE(GLeglContext ctx, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, void *data);
|
||||
GL_APICALL void GL_APIENTRY glRenderbufferStorageMultisampleANGLEContextANGLE(GLeglContext ctx, GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
|
||||
GL_APICALL void GL_APIENTRY glRenderbufferStorageMultisampleEXTContextANGLE(GLeglContext ctx, GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
|
||||
GL_APICALL void GL_APIENTRY glSamplerParameterIivEXTContextANGLE(GLeglContext ctx, GLuint sampler, GLenum pname, const GLint *param);
|
||||
GL_APICALL void GL_APIENTRY glSamplerParameterIivOESContextANGLE(GLeglContext ctx, GLuint sampler, GLenum pname, const GLint *param);
|
||||
GL_APICALL void GL_APIENTRY glSamplerParameterIuivEXTContextANGLE(GLeglContext ctx, GLuint sampler, GLenum pname, const GLuint *param);
|
||||
GL_APICALL void GL_APIENTRY glSamplerParameterIuivOESContextANGLE(GLeglContext ctx, GLuint sampler, GLenum pname, const GLuint *param);
|
||||
GL_APICALL void GL_APIENTRY glSemaphoreParameterui64vEXTContextANGLE(GLeglContext ctx, GLuint semaphore, GLenum pname, const GLuint64 *params);
|
||||
GL_APICALL void GL_APIENTRY glSetFenceNVContextANGLE(GLeglContext ctx, GLuint fence, GLenum condition);
|
||||
|
@ -776,9 +660,7 @@ GL_APICALL void GL_APIENTRY glTexBufferOESContextANGLE(GLeglContext ctx, GLenum
|
|||
GL_APICALL void GL_APIENTRY glTexBufferRangeEXTContextANGLE(GLeglContext ctx, GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size);
|
||||
GL_APICALL void GL_APIENTRY glTexBufferRangeOESContextANGLE(GLeglContext ctx, GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size);
|
||||
GL_APICALL void GL_APIENTRY glTexImage3DOESContextANGLE(GLeglContext ctx, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const void *pixels);
|
||||
GL_APICALL void GL_APIENTRY glTexParameterIivEXTContextANGLE(GLeglContext ctx, GLenum target, GLenum pname, const GLint *params);
|
||||
GL_APICALL void GL_APIENTRY glTexParameterIivOESContextANGLE(GLeglContext ctx, GLenum target, GLenum pname, const GLint *params);
|
||||
GL_APICALL void GL_APIENTRY glTexParameterIuivEXTContextANGLE(GLeglContext ctx, GLenum target, GLenum pname, const GLuint *params);
|
||||
GL_APICALL void GL_APIENTRY glTexParameterIuivOESContextANGLE(GLeglContext ctx, GLenum target, GLenum pname, const GLuint *params);
|
||||
GL_APICALL void GL_APIENTRY glTexStorage1DEXTContextANGLE(GLeglContext ctx, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width);
|
||||
GL_APICALL void GL_APIENTRY glTexStorage2DEXTContextANGLE(GLeglContext ctx, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height);
|
||||
|
@ -790,8 +672,6 @@ GL_APICALL void GL_APIENTRY glTexStorageMem3DEXTContextANGLE(GLeglContext ctx, G
|
|||
GL_APICALL void GL_APIENTRY glTexStorageMem3DMultisampleEXTContextANGLE(GLeglContext ctx, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedSampleLocations, GLuint memory, GLuint64 offset);
|
||||
GL_APICALL void GL_APIENTRY glTexSubImage3DOESContextANGLE(GLeglContext ctx, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const void *pixels);
|
||||
GL_APICALL GLboolean GL_APIENTRY glUnmapBufferOESContextANGLE(GLeglContext ctx, GLenum target);
|
||||
GL_APICALL void GL_APIENTRY glUseProgramStagesEXTContextANGLE(GLeglContext ctx, GLuint pipeline, GLbitfield stages, GLuint program);
|
||||
GL_APICALL void GL_APIENTRY glValidateProgramPipelineEXTContextANGLE(GLeglContext ctx, GLuint pipeline);
|
||||
GL_APICALL void GL_APIENTRY glVertexAttribDivisorANGLEContextANGLE(GLeglContext ctx, GLuint index, GLuint divisor);
|
||||
GL_APICALL void GL_APIENTRY glVertexAttribDivisorEXTContextANGLE(GLeglContext ctx, GLuint index, GLuint divisor);
|
||||
GL_APICALL void GL_APIENTRY glWaitSemaphoreEXTContextANGLE(GLeglContext ctx, GLuint semaphore, GLuint numBufferBarriers, const GLuint *buffers, GLuint numTextureBarriers, const GLuint *textures, const GLenum *srcLayouts);
|
||||
|
@ -869,7 +749,7 @@ GL_APICALL void GL_APIENTRY glGetQueryObjectui64vRobustANGLEContextANGLE(GLeglCo
|
|||
GL_APICALL void GL_APIENTRY glCopyTexture3DANGLEContextANGLE(GLeglContext ctx, GLuint sourceId, GLint sourceLevel, GLenum destTarget, GLuint destId, GLint destLevel, GLint internalFormat, GLenum destType, GLboolean unpackFlipY, GLboolean unpackPremultiplyAlpha, GLboolean unpackUnmultiplyAlpha);
|
||||
GL_APICALL void GL_APIENTRY glCopySubTexture3DANGLEContextANGLE(GLeglContext ctx, GLuint sourceId, GLint sourceLevel, GLenum destTarget, GLuint destId, GLint destLevel, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLint z, GLint width, GLint height, GLint depth, GLboolean unpackFlipY, GLboolean unpackPremultiplyAlpha, GLboolean unpackUnmultiplyAlpha);
|
||||
GL_APICALL void GL_APIENTRY glTexStorage2DMultisampleANGLEContextANGLE(GLeglContext ctx, GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
|
||||
GL_APICALL void GL_APIENTRY glGetTexLevelParameterivANGLEContextANGLE(GLeglContext ctx, GLenum target, GLint level, GLenum pname, GLint *params);
|
||||
GL_APICALL void GL_APIENTRY glGetTexLevelParameterivANGLEContextANGLE(GLeglContext ctx, GLenum target, GLint level, GLenum pname, GLint * params);
|
||||
GL_APICALL void GL_APIENTRY glGetTexLevelParameterfvANGLEContextANGLE(GLeglContext ctx, GLenum target, GLint level, GLenum pname, GLfloat * params);
|
||||
GL_APICALL void GL_APIENTRY glMultiDrawArraysANGLEContextANGLE(GLeglContext ctx, GLenum mode, const GLint *firsts, const GLsizei *counts, GLsizei drawcount);
|
||||
GL_APICALL void GL_APIENTRY glMultiDrawArraysInstancedANGLEContextANGLE(GLeglContext ctx, GLenum mode, const GLint *firsts, const GLsizei *counts, const GLsizei *instanceCounts, GLsizei drawcount);
|
||||
|
|
|
@ -1,17 +1,20 @@
|
|||
#ifndef __gl2platform_h_
|
||||
#define __gl2platform_h_
|
||||
|
||||
/* $Revision: 23328 $ on $Date:: 2013-10-02 02:28:28 -0700 #$ */
|
||||
|
||||
/*
|
||||
** Copyright 2017-2020 The Khronos Group Inc.
|
||||
** SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
* This document is licensed under the SGI Free Software B License Version
|
||||
* 2.0. For details, see http://oss.sgi.com/projects/FreeB/ .
|
||||
*/
|
||||
|
||||
/* Platform-specific types and definitions for OpenGL ES 2.X gl2.h
|
||||
*
|
||||
* Adopters may modify khrplatform.h and this file to suit their platform.
|
||||
* Please contribute modifications back to Khronos as pull requests on the
|
||||
* public github repository:
|
||||
* https://github.com/KhronosGroup/OpenGL-Registry
|
||||
* You are encouraged to submit all modifications to the Khronos group so that
|
||||
* they can be included in future versions of this file. Please submit changes
|
||||
* by sending them to the public Khronos Bugzilla (http://khronos.org/bugzilla)
|
||||
* by filing a bug against product "OpenGL-ES" component "Registry".
|
||||
*/
|
||||
|
||||
#include <KHR/khrplatform.h>
|
||||
|
|
|
@ -6,9 +6,28 @@ extern "C" {
|
|||
#endif
|
||||
|
||||
/*
|
||||
** Copyright 2013-2020 The Khronos Group Inc.
|
||||
** SPDX-License-Identifier: MIT
|
||||
** Copyright (c) 2013-2018 The Khronos Group Inc.
|
||||
**
|
||||
** Permission is hereby granted, free of charge, to any person obtaining a
|
||||
** copy of this software and/or associated documentation files (the
|
||||
** "Materials"), to deal in the Materials without restriction, including
|
||||
** without limitation the rights to use, copy, modify, merge, publish,
|
||||
** distribute, sublicense, and/or sell copies of the Materials, and to
|
||||
** permit persons to whom the Materials are furnished to do so, subject to
|
||||
** the following conditions:
|
||||
**
|
||||
** The above copyright notice and this permission notice shall be included
|
||||
** in all copies or substantial portions of the Materials.
|
||||
**
|
||||
** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
||||
** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
||||
** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
||||
** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
|
||||
*/
|
||||
/*
|
||||
** This header is generated from the Khronos OpenGL / OpenGL ES XML
|
||||
** API Registry. The current version of the Registry, generator scripts
|
||||
** used to make the header, and the header can be found at
|
||||
|
@ -25,7 +44,7 @@ extern "C" {
|
|||
#define GL_GLES_PROTOTYPES 1
|
||||
#endif
|
||||
|
||||
/* Generated on date 20210107 */
|
||||
/* Generated on date 20181130 */
|
||||
|
||||
/* Generated C header for:
|
||||
* API: gles2
|
||||
|
@ -458,7 +477,7 @@ typedef void (GL_APIENTRYP PFNGLRELEASESHADERCOMPILERPROC) (void);
|
|||
typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
|
||||
typedef void (GL_APIENTRYP PFNGLSAMPLECOVERAGEPROC) (GLfloat value, GLboolean invert);
|
||||
typedef void (GL_APIENTRYP PFNGLSCISSORPROC) (GLint x, GLint y, GLsizei width, GLsizei height);
|
||||
typedef void (GL_APIENTRYP PFNGLSHADERBINARYPROC) (GLsizei count, const GLuint *shaders, GLenum binaryFormat, const void *binary, GLsizei length);
|
||||
typedef void (GL_APIENTRYP PFNGLSHADERBINARYPROC) (GLsizei count, const GLuint *shaders, GLenum binaryformat, const void *binary, GLsizei length);
|
||||
typedef void (GL_APIENTRYP PFNGLSHADERSOURCEPROC) (GLuint shader, GLsizei count, const GLchar *const*string, const GLint *length);
|
||||
typedef void (GL_APIENTRYP PFNGLSTENCILFUNCPROC) (GLenum func, GLint ref, GLuint mask);
|
||||
typedef void (GL_APIENTRYP PFNGLSTENCILFUNCSEPARATEPROC) (GLenum face, GLenum func, GLint ref, GLuint mask);
|
||||
|
@ -601,7 +620,7 @@ GL_APICALL void GL_APIENTRY glReleaseShaderCompiler (void);
|
|||
GL_APICALL void GL_APIENTRY glRenderbufferStorage (GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
|
||||
GL_APICALL void GL_APIENTRY glSampleCoverage (GLfloat value, GLboolean invert);
|
||||
GL_APICALL void GL_APIENTRY glScissor (GLint x, GLint y, GLsizei width, GLsizei height);
|
||||
GL_APICALL void GL_APIENTRY glShaderBinary (GLsizei count, const GLuint *shaders, GLenum binaryFormat, const void *binary, GLsizei length);
|
||||
GL_APICALL void GL_APIENTRY glShaderBinary (GLsizei count, const GLuint *shaders, GLenum binaryformat, const void *binary, GLsizei length);
|
||||
GL_APICALL void GL_APIENTRY glShaderSource (GLuint shader, GLsizei count, const GLchar *const*string, const GLint *length);
|
||||
GL_APICALL void GL_APIENTRY glStencilFunc (GLenum func, GLint ref, GLuint mask);
|
||||
GL_APICALL void GL_APIENTRY glStencilFuncSeparate (GLenum face, GLenum func, GLint ref, GLuint mask);
|
||||
|
@ -1049,7 +1068,7 @@ typedef void (GL_APIENTRYP PFNGLDELETESYNCPROC) (GLsync sync);
|
|||
typedef GLenum (GL_APIENTRYP PFNGLCLIENTWAITSYNCPROC) (GLsync sync, GLbitfield flags, GLuint64 timeout);
|
||||
typedef void (GL_APIENTRYP PFNGLWAITSYNCPROC) (GLsync sync, GLbitfield flags, GLuint64 timeout);
|
||||
typedef void (GL_APIENTRYP PFNGLGETINTEGER64VPROC) (GLenum pname, GLint64 *data);
|
||||
typedef void (GL_APIENTRYP PFNGLGETSYNCIVPROC) (GLsync sync, GLenum pname, GLsizei count, GLsizei *length, GLint *values);
|
||||
typedef void (GL_APIENTRYP PFNGLGETSYNCIVPROC) (GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values);
|
||||
typedef void (GL_APIENTRYP PFNGLGETINTEGER64I_VPROC) (GLenum target, GLuint index, GLint64 *data);
|
||||
typedef void (GL_APIENTRYP PFNGLGETBUFFERPARAMETERI64VPROC) (GLenum target, GLenum pname, GLint64 *params);
|
||||
typedef void (GL_APIENTRYP PFNGLGENSAMPLERSPROC) (GLsizei count, GLuint *samplers);
|
||||
|
@ -1076,7 +1095,7 @@ typedef void (GL_APIENTRYP PFNGLINVALIDATEFRAMEBUFFERPROC) (GLenum target, GLsiz
|
|||
typedef void (GL_APIENTRYP PFNGLINVALIDATESUBFRAMEBUFFERPROC) (GLenum target, GLsizei numAttachments, const GLenum *attachments, GLint x, GLint y, GLsizei width, GLsizei height);
|
||||
typedef void (GL_APIENTRYP PFNGLTEXSTORAGE2DPROC) (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height);
|
||||
typedef void (GL_APIENTRYP PFNGLTEXSTORAGE3DPROC) (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth);
|
||||
typedef void (GL_APIENTRYP PFNGLGETINTERNALFORMATIVPROC) (GLenum target, GLenum internalformat, GLenum pname, GLsizei count, GLint *params);
|
||||
typedef void (GL_APIENTRYP PFNGLGETINTERNALFORMATIVPROC) (GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint *params);
|
||||
#if GL_GLES_PROTOTYPES
|
||||
GL_APICALL void GL_APIENTRY glReadBuffer (GLenum src);
|
||||
GL_APICALL void GL_APIENTRY glDrawRangeElements (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const void *indices);
|
||||
|
@ -1154,7 +1173,7 @@ GL_APICALL void GL_APIENTRY glDeleteSync (GLsync sync);
|
|||
GL_APICALL GLenum GL_APIENTRY glClientWaitSync (GLsync sync, GLbitfield flags, GLuint64 timeout);
|
||||
GL_APICALL void GL_APIENTRY glWaitSync (GLsync sync, GLbitfield flags, GLuint64 timeout);
|
||||
GL_APICALL void GL_APIENTRY glGetInteger64v (GLenum pname, GLint64 *data);
|
||||
GL_APICALL void GL_APIENTRY glGetSynciv (GLsync sync, GLenum pname, GLsizei count, GLsizei *length, GLint *values);
|
||||
GL_APICALL void GL_APIENTRY glGetSynciv (GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values);
|
||||
GL_APICALL void GL_APIENTRY glGetInteger64i_v (GLenum target, GLuint index, GLint64 *data);
|
||||
GL_APICALL void GL_APIENTRY glGetBufferParameteri64v (GLenum target, GLenum pname, GLint64 *params);
|
||||
GL_APICALL void GL_APIENTRY glGenSamplers (GLsizei count, GLuint *samplers);
|
||||
|
@ -1181,7 +1200,7 @@ GL_APICALL void GL_APIENTRY glInvalidateFramebuffer (GLenum target, GLsizei numA
|
|||
GL_APICALL void GL_APIENTRY glInvalidateSubFramebuffer (GLenum target, GLsizei numAttachments, const GLenum *attachments, GLint x, GLint y, GLsizei width, GLsizei height);
|
||||
GL_APICALL void GL_APIENTRY glTexStorage2D (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height);
|
||||
GL_APICALL void GL_APIENTRY glTexStorage3D (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth);
|
||||
GL_APICALL void GL_APIENTRY glGetInternalformativ (GLenum target, GLenum internalformat, GLenum pname, GLsizei count, GLint *params);
|
||||
GL_APICALL void GL_APIENTRY glGetInternalformativ (GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint *params);
|
||||
#endif
|
||||
#endif /* GL_ES_VERSION_3_0 */
|
||||
|
||||
|
|
|
@ -1,18 +1,39 @@
|
|||
#ifndef __gles2_gl31_h_
|
||||
#define __gles2_gl31_h_ 1
|
||||
#ifndef __gl31_h_
|
||||
#define __gl31_h_ 1
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*
|
||||
** Copyright 2013-2020 The Khronos Group Inc.
|
||||
** SPDX-License-Identifier: MIT
|
||||
** Copyright (c) 2013-2016 The Khronos Group Inc.
|
||||
**
|
||||
** Permission is hereby granted, free of charge, to any person obtaining a
|
||||
** copy of this software and/or associated documentation files (the
|
||||
** "Materials"), to deal in the Materials without restriction, including
|
||||
** without limitation the rights to use, copy, modify, merge, publish,
|
||||
** distribute, sublicense, and/or sell copies of the Materials, and to
|
||||
** permit persons to whom the Materials are furnished to do so, subject to
|
||||
** the following conditions:
|
||||
**
|
||||
** The above copyright notice and this permission notice shall be included
|
||||
** in all copies or substantial portions of the Materials.
|
||||
**
|
||||
** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
||||
** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
||||
** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
||||
** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
|
||||
*/
|
||||
/*
|
||||
** This header is generated from the Khronos OpenGL / OpenGL ES XML
|
||||
** API Registry. The current version of the Registry, generator scripts
|
||||
** used to make the header, and the header can be found at
|
||||
** https://github.com/KhronosGroup/OpenGL-Registry
|
||||
** http://www.opengl.org/registry/
|
||||
**
|
||||
** Khronos $Revision$ on $Date$
|
||||
*/
|
||||
|
||||
#include <GLES3/gl3platform.h>
|
||||
|
@ -25,7 +46,7 @@ extern "C" {
|
|||
#define GL_GLES_PROTOTYPES 1
|
||||
#endif
|
||||
|
||||
/* Generated on date 20191013 */
|
||||
/* Generated on date 20161024 */
|
||||
|
||||
/* Generated C header for:
|
||||
* API: gles2
|
||||
|
@ -43,8 +64,8 @@ extern "C" {
|
|||
typedef khronos_int8_t GLbyte;
|
||||
typedef khronos_float_t GLclampf;
|
||||
typedef khronos_int32_t GLfixed;
|
||||
typedef khronos_int16_t GLshort;
|
||||
typedef khronos_uint16_t GLushort;
|
||||
typedef short GLshort;
|
||||
typedef unsigned short GLushort;
|
||||
typedef void GLvoid;
|
||||
typedef struct __GLsync *GLsync;
|
||||
typedef khronos_int64_t GLint64;
|
||||
|
@ -651,7 +672,7 @@ GL_APICALL void GL_APIENTRY glViewport (GLint x, GLint y, GLsizei width, GLsizei
|
|||
|
||||
#ifndef GL_ES_VERSION_3_0
|
||||
#define GL_ES_VERSION_3_0 1
|
||||
typedef khronos_uint16_t GLhalf;
|
||||
typedef unsigned short GLhalf;
|
||||
#define GL_READ_BUFFER 0x0C02
|
||||
#define GL_UNPACK_ROW_LENGTH 0x0CF2
|
||||
#define GL_UNPACK_SKIP_ROWS 0x0CF3
|
||||
|
|
|
@ -1,18 +1,39 @@
|
|||
#ifndef __gles2_gl32_h_
|
||||
#define __gles2_gl32_h_ 1
|
||||
#ifndef __gl32_h_
|
||||
#define __gl32_h_ 1
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*
|
||||
** Copyright 2013-2020 The Khronos Group Inc.
|
||||
** SPDX-License-Identifier: MIT
|
||||
** Copyright (c) 2013-2016 The Khronos Group Inc.
|
||||
**
|
||||
** Permission is hereby granted, free of charge, to any person obtaining a
|
||||
** copy of this software and/or associated documentation files (the
|
||||
** "Materials"), to deal in the Materials without restriction, including
|
||||
** without limitation the rights to use, copy, modify, merge, publish,
|
||||
** distribute, sublicense, and/or sell copies of the Materials, and to
|
||||
** permit persons to whom the Materials are furnished to do so, subject to
|
||||
** the following conditions:
|
||||
**
|
||||
** The above copyright notice and this permission notice shall be included
|
||||
** in all copies or substantial portions of the Materials.
|
||||
**
|
||||
** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
||||
** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
||||
** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
||||
** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
|
||||
*/
|
||||
/*
|
||||
** This header is generated from the Khronos OpenGL / OpenGL ES XML
|
||||
** API Registry. The current version of the Registry, generator scripts
|
||||
** used to make the header, and the header can be found at
|
||||
** https://github.com/KhronosGroup/OpenGL-Registry
|
||||
** http://www.opengl.org/registry/
|
||||
**
|
||||
** Khronos $Revision$ on $Date$
|
||||
*/
|
||||
|
||||
#include <GLES3/gl3platform.h>
|
||||
|
@ -25,7 +46,7 @@ extern "C" {
|
|||
#define GL_GLES_PROTOTYPES 1
|
||||
#endif
|
||||
|
||||
/* Generated on date 20191013 */
|
||||
/* Generated on date 20161024 */
|
||||
|
||||
/* Generated C header for:
|
||||
* API: gles2
|
||||
|
@ -43,8 +64,8 @@ extern "C" {
|
|||
typedef khronos_int8_t GLbyte;
|
||||
typedef khronos_float_t GLclampf;
|
||||
typedef khronos_int32_t GLfixed;
|
||||
typedef khronos_int16_t GLshort;
|
||||
typedef khronos_uint16_t GLushort;
|
||||
typedef short GLshort;
|
||||
typedef unsigned short GLushort;
|
||||
typedef void GLvoid;
|
||||
typedef struct __GLsync *GLsync;
|
||||
typedef khronos_int64_t GLint64;
|
||||
|
@ -651,7 +672,7 @@ GL_APICALL void GL_APIENTRY glViewport (GLint x, GLint y, GLsizei width, GLsizei
|
|||
|
||||
#ifndef GL_ES_VERSION_3_0
|
||||
#define GL_ES_VERSION_3_0 1
|
||||
typedef khronos_uint16_t GLhalf;
|
||||
typedef unsigned short GLhalf;
|
||||
#define GL_READ_BUFFER 0x0C02
|
||||
#define GL_UNPACK_ROW_LENGTH 0x0CF2
|
||||
#define GL_UNPACK_SKIP_ROWS 0x0CF3
|
||||
|
|
|
@ -1,17 +1,20 @@
|
|||
#ifndef __gl3platform_h_
|
||||
#define __gl3platform_h_
|
||||
|
||||
/* $Revision: 23328 $ on $Date:: 2013-10-02 02:28:28 -0700 #$ */
|
||||
|
||||
/*
|
||||
** Copyright 2017-2020 The Khronos Group Inc.
|
||||
** SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
* This document is licensed under the SGI Free Software B License Version
|
||||
* 2.0. For details, see http://oss.sgi.com/projects/FreeB/ .
|
||||
*/
|
||||
|
||||
/* Platform-specific types and definitions for OpenGL ES 3.X gl3.h
|
||||
*
|
||||
* Adopters may modify khrplatform.h and this file to suit their platform.
|
||||
* Please contribute modifications back to Khronos as pull requests on the
|
||||
* public github repository:
|
||||
* https://github.com/KhronosGroup/OpenGL-Registry
|
||||
* You are encouraged to submit all modifications to the Khronos group so that
|
||||
* they can be included in future versions of this file. Please submit changes
|
||||
* by sending them to the public Khronos Bugzilla (http://khronos.org/bugzilla)
|
||||
* by filing a bug against product "OpenGL-ES" component "Registry".
|
||||
*/
|
||||
|
||||
#include <KHR/khrplatform.h>
|
||||
|
|
|
@ -26,7 +26,7 @@
|
|||
|
||||
// Version number for shader translation API.
|
||||
// It is incremented every time the API changes.
|
||||
#define ANGLE_SH_VERSION 257
|
||||
#define ANGLE_SH_VERSION 239
|
||||
|
||||
enum ShShaderSpec
|
||||
{
|
||||
|
@ -39,8 +39,6 @@ enum ShShaderSpec
|
|||
SH_GLES3_1_SPEC,
|
||||
SH_WEBGL3_SPEC,
|
||||
|
||||
SH_GLES3_2_SPEC,
|
||||
|
||||
SH_GL_CORE_SPEC,
|
||||
SH_GL_COMPATIBILITY_SPEC,
|
||||
};
|
||||
|
@ -69,11 +67,12 @@ enum ShShaderOutput
|
|||
SH_HLSL_4_1_OUTPUT = 0x8B49, // D3D 11
|
||||
SH_HLSL_4_0_FL9_3_OUTPUT = 0x8B4A, // D3D 11 feature level 9_3
|
||||
|
||||
// Output SPIR-V for the Vulkan backend.
|
||||
SH_SPIRV_VULKAN_OUTPUT = 0x8B4B,
|
||||
// Output specialized GLSL to be fed to glslang for Vulkan SPIR.
|
||||
SH_GLSL_VULKAN_OUTPUT = 0x8B4B,
|
||||
|
||||
// Output SPIR-V to be cross compiled to Metal.
|
||||
SH_SPIRV_METAL_OUTPUT = 0x8B4C,
|
||||
// Output specialized GLSL to be fed to glslang for Vulkan SPIR to be cross compiled to Metal
|
||||
// later.
|
||||
SH_GLSL_METAL_OUTPUT = 0x8B4C,
|
||||
};
|
||||
|
||||
// Compile options.
|
||||
|
@ -88,8 +87,14 @@ const ShCompileOptions SH_VARIABLES = UINT64_C(1) << 3;
|
|||
const ShCompileOptions SH_LINE_DIRECTIVES = UINT64_C(1) << 4;
|
||||
const ShCompileOptions SH_SOURCE_PATH = UINT64_C(1) << 5;
|
||||
|
||||
// If requested, validates the AST after every transformation. Useful for debugging.
|
||||
const ShCompileOptions SH_VALIDATE_AST = UINT64_C(1) << 6;
|
||||
// This flag will keep invariant declaration for input in fragment shader for GLSL >=4.20 on AMD.
|
||||
// From GLSL >= 4.20, it's optional to add invariant for fragment input, but GPU vendors have
|
||||
// different implementations about this. Some drivers forbid invariant in fragment for GLSL>= 4.20,
|
||||
// e.g. Linux Mesa, some drivers treat that as optional, e.g. NVIDIA, some drivers require invariant
|
||||
// must match between vertex and fragment shader, e.g. AMD. The behavior on AMD is obviously wrong.
|
||||
// Remove invariant for input in fragment shader to workaround the restriction on Intel Mesa.
|
||||
// But don't remove on AMD Linux to avoid triggering the bug on AMD.
|
||||
const ShCompileOptions SH_DONT_REMOVE_INVARIANT_FOR_FRAGMENT_INPUT = UINT64_C(1) << 6;
|
||||
|
||||
// Due to spec difference between GLSL 4.1 or lower and ESSL3, some platforms (for example, Mac OSX
|
||||
// core profile) require a variable's "invariant"/"centroid" qualifiers to match between vertex and
|
||||
|
@ -158,40 +163,49 @@ const ShCompileOptions SH_SCALARIZE_VEC_AND_MAT_CONSTRUCTOR_ARGS = UINT64_C(1) <
|
|||
// struct scopes correctly, including all Mac drivers and Linux AMD.
|
||||
const ShCompileOptions SH_REGENERATE_STRUCT_NAMES = UINT64_C(1) << 17;
|
||||
|
||||
// This flag makes the compiler not prune unused function early in the
|
||||
// compilation process. Pruning coupled with SH_LIMIT_CALL_STACK_DEPTH
|
||||
// helps avoid bad shaders causing stack overflows.
|
||||
const ShCompileOptions SH_DONT_PRUNE_UNUSED_FUNCTIONS = UINT64_C(1) << 18;
|
||||
|
||||
// This flag works around a bug in NVIDIA 331 series drivers related
|
||||
// to pow(x, y) where y is a constant vector.
|
||||
const ShCompileOptions SH_REMOVE_POW_WITH_CONSTANT_EXPONENT = UINT64_C(1) << 19;
|
||||
|
||||
// This flag works around bugs in Mac drivers related to do-while by
|
||||
// transforming them into an other construct.
|
||||
const ShCompileOptions SH_REWRITE_DO_WHILE_LOOPS = UINT64_C(1) << 18;
|
||||
const ShCompileOptions SH_REWRITE_DO_WHILE_LOOPS = UINT64_C(1) << 20;
|
||||
|
||||
// This flag works around a bug in the HLSL compiler optimizer that folds certain
|
||||
// constant pow expressions incorrectly. Only applies to the HLSL back-end. It works
|
||||
// by expanding the integer pow expressions into a series of multiplies.
|
||||
const ShCompileOptions SH_EXPAND_SELECT_HLSL_INTEGER_POW_EXPRESSIONS = UINT64_C(1) << 19;
|
||||
const ShCompileOptions SH_EXPAND_SELECT_HLSL_INTEGER_POW_EXPRESSIONS = UINT64_C(1) << 21;
|
||||
|
||||
// Flatten "#pragma STDGL invariant(all)" into the declarations of
|
||||
// varying variables and built-in GLSL variables. This compiler
|
||||
// option is enabled automatically when needed.
|
||||
const ShCompileOptions SH_FLATTEN_PRAGMA_STDGL_INVARIANT_ALL = UINT64_C(1) << 20;
|
||||
const ShCompileOptions SH_FLATTEN_PRAGMA_STDGL_INVARIANT_ALL = UINT64_C(1) << 22;
|
||||
|
||||
// Some drivers do not take into account the base level of the texture in the results of the
|
||||
// HLSL GetDimensions builtin. This flag instructs the compiler to manually add the base level
|
||||
// offsetting.
|
||||
const ShCompileOptions SH_HLSL_GET_DIMENSIONS_IGNORES_BASE_LEVEL = UINT64_C(1) << 21;
|
||||
const ShCompileOptions SH_HLSL_GET_DIMENSIONS_IGNORES_BASE_LEVEL = UINT64_C(1) << 23;
|
||||
|
||||
// This flag works around an issue in translating GLSL function texelFetchOffset on
|
||||
// INTEL drivers. It works by translating texelFetchOffset into texelFetch.
|
||||
const ShCompileOptions SH_REWRITE_TEXELFETCHOFFSET_TO_TEXELFETCH = UINT64_C(1) << 22;
|
||||
const ShCompileOptions SH_REWRITE_TEXELFETCHOFFSET_TO_TEXELFETCH = UINT64_C(1) << 24;
|
||||
|
||||
// This flag works around condition bug of for and while loops in Intel Mac OSX drivers.
|
||||
// Condition calculation is not correct. Rewrite it from "CONDITION" to "CONDITION && true".
|
||||
const ShCompileOptions SH_ADD_AND_TRUE_TO_LOOP_CONDITION = UINT64_C(1) << 23;
|
||||
const ShCompileOptions SH_ADD_AND_TRUE_TO_LOOP_CONDITION = UINT64_C(1) << 25;
|
||||
|
||||
// This flag works around a bug in evaluating unary minus operator on integer on some INTEL
|
||||
// drivers. It works by translating -(int) into ~(int) + 1.
|
||||
const ShCompileOptions SH_REWRITE_INTEGER_UNARY_MINUS_OPERATOR = UINT64_C(1) << 24;
|
||||
const ShCompileOptions SH_REWRITE_INTEGER_UNARY_MINUS_OPERATOR = UINT64_C(1) << 26;
|
||||
|
||||
// This flag works around a bug in evaluating isnan() on some INTEL D3D and Mac OSX drivers.
|
||||
// It works by using an expression to emulate this function.
|
||||
const ShCompileOptions SH_EMULATE_ISNAN_FLOAT_FUNCTION = UINT64_C(1) << 25;
|
||||
const ShCompileOptions SH_EMULATE_ISNAN_FLOAT_FUNCTION = UINT64_C(1) << 27;
|
||||
|
||||
// This flag will use all uniforms of unused std140 and shared uniform blocks at the
|
||||
// beginning of the vertex/fragment shader's main(). It is intended as a workaround for Mac
|
||||
|
@ -199,19 +213,19 @@ const ShCompileOptions SH_EMULATE_ISNAN_FLOAT_FUNCTION = UINT64_C(1) << 25;
|
|||
// std140 and shared uniform blocks' members as inactive. However, WebGL2.0 based on
|
||||
// OpenGL ES3.0.4 requires all members of a named uniform block declared with a shared or std140
|
||||
// layout qualifier to be considered active. The uniform block itself is also considered active.
|
||||
const ShCompileOptions SH_USE_UNUSED_STANDARD_SHARED_BLOCKS = UINT64_C(1) << 26;
|
||||
const ShCompileOptions SH_USE_UNUSED_STANDARD_SHARED_BLOCKS = UINT64_C(1) << 28;
|
||||
|
||||
// This flag works around a bug in unary minus operator on float numbers on Intel
|
||||
// Mac OSX 10.11 drivers. It works by translating -float into 0.0 - float.
|
||||
const ShCompileOptions SH_REWRITE_FLOAT_UNARY_MINUS_OPERATOR = UINT64_C(1) << 27;
|
||||
const ShCompileOptions SH_REWRITE_FLOAT_UNARY_MINUS_OPERATOR = UINT64_C(1) << 29;
|
||||
|
||||
// This flag works around a bug in evaluating atan(y, x) on some NVIDIA OpenGL drivers.
|
||||
// It works by using an expression to emulate this function.
|
||||
const ShCompileOptions SH_EMULATE_ATAN2_FLOAT_FUNCTION = UINT64_C(1) << 28;
|
||||
const ShCompileOptions SH_EMULATE_ATAN2_FLOAT_FUNCTION = UINT64_C(1) << 30;
|
||||
|
||||
// Set to initialize uninitialized local and global temporary variables. Should only be used with
|
||||
// GLSL output. In HLSL output variables are initialized regardless of if this flag is set.
|
||||
const ShCompileOptions SH_INITIALIZE_UNINITIALIZED_LOCALS = UINT64_C(1) << 29;
|
||||
const ShCompileOptions SH_INITIALIZE_UNINITIALIZED_LOCALS = UINT64_C(1) << 31;
|
||||
|
||||
// The flag modifies the shader in the following way:
|
||||
// Every occurrence of gl_InstanceID is replaced by the global temporary variable InstanceID.
|
||||
|
@ -220,7 +234,7 @@ const ShCompileOptions SH_INITIALIZE_UNINITIALIZED_LOCALS = UINT64_C(1) << 29;
|
|||
// ViewID_OVR = uint(gl_InstanceID) % num_views;
|
||||
// InstanceID = gl_InstanceID / num_views;
|
||||
// ViewID_OVR is added as a varying variable to both the vertex and fragment shaders.
|
||||
const ShCompileOptions SH_INITIALIZE_BUILTINS_FOR_INSTANCED_MULTIVIEW = UINT64_C(1) << 30;
|
||||
const ShCompileOptions SH_INITIALIZE_BUILTINS_FOR_INSTANCED_MULTIVIEW = UINT64_C(1) << 32;
|
||||
|
||||
// With the flag enabled the GLSL/ESSL vertex shader is modified to include code for viewport
|
||||
// selection in the following way:
|
||||
|
@ -230,11 +244,11 @@ const ShCompileOptions SH_INITIALIZE_BUILTINS_FOR_INSTANCED_MULTIVIEW = UINT64_C
|
|||
// - A declaration of the uniform multiviewBaseViewLayerIndex.
|
||||
// Note: The SH_INITIALIZE_BUILTINS_FOR_INSTANCED_MULTIVIEW flag also has to be enabled to have the
|
||||
// temporary variable ViewID_OVR declared and initialized.
|
||||
const ShCompileOptions SH_SELECT_VIEW_IN_NV_GLSL_VERTEX_SHADER = UINT64_C(1) << 31;
|
||||
const ShCompileOptions SH_SELECT_VIEW_IN_NV_GLSL_VERTEX_SHADER = UINT64_C(1) << 33;
|
||||
|
||||
// If the flag is enabled, gl_PointSize is clamped to the maximum point size specified in
|
||||
// ShBuiltInResources in vertex shaders.
|
||||
const ShCompileOptions SH_CLAMP_POINT_SIZE = UINT64_C(1) << 32;
|
||||
const ShCompileOptions SH_CLAMP_POINT_SIZE = UINT64_C(1) << 34;
|
||||
|
||||
// Turn some arithmetic operations that operate on a float vector-scalar pair into vector-vector
|
||||
// operations. This is done recursively. Some scalar binary operations inside vector constructors
|
||||
|
@ -242,100 +256,90 @@ const ShCompileOptions SH_CLAMP_POINT_SIZE = UINT64_C(1) << 32;
|
|||
//
|
||||
// This is targeted to work around a bug in NVIDIA OpenGL drivers that was reproducible on NVIDIA
|
||||
// driver version 387.92. It works around the most common occurrences of the bug.
|
||||
const ShCompileOptions SH_REWRITE_VECTOR_SCALAR_ARITHMETIC = UINT64_C(1) << 33;
|
||||
const ShCompileOptions SH_REWRITE_VECTOR_SCALAR_ARITHMETIC = UINT64_C(1) << 35;
|
||||
|
||||
// Don't use loops to initialize uninitialized variables. Only has an effect if some kind of
|
||||
// variable initialization is turned on.
|
||||
const ShCompileOptions SH_DONT_USE_LOOPS_TO_INITIALIZE_VARIABLES = UINT64_C(1) << 34;
|
||||
const ShCompileOptions SH_DONT_USE_LOOPS_TO_INITIALIZE_VARIABLES = UINT64_C(1) << 36;
|
||||
|
||||
// Don't use D3D constant register zero when allocating space for uniforms. This is targeted to work
|
||||
// around a bug in NVIDIA D3D driver version 388.59 where in very specific cases the driver would
|
||||
// not handle constant register zero correctly. Only has an effect on HLSL translation.
|
||||
const ShCompileOptions SH_SKIP_D3D_CONSTANT_REGISTER_ZERO = UINT64_C(1) << 35;
|
||||
const ShCompileOptions SH_SKIP_D3D_CONSTANT_REGISTER_ZERO = UINT64_C(1) << 37;
|
||||
|
||||
// Clamp gl_FragDepth to the range [0.0, 1.0] in case it is statically used.
|
||||
const ShCompileOptions SH_CLAMP_FRAG_DEPTH = UINT64_C(1) << 36;
|
||||
const ShCompileOptions SH_CLAMP_FRAG_DEPTH = UINT64_C(1) << 38;
|
||||
|
||||
// Rewrite expressions like "v.x = z = expression;". Works around a bug in NVIDIA OpenGL drivers
|
||||
// prior to version 397.31.
|
||||
const ShCompileOptions SH_REWRITE_REPEATED_ASSIGN_TO_SWIZZLED = UINT64_C(1) << 37;
|
||||
const ShCompileOptions SH_REWRITE_REPEATED_ASSIGN_TO_SWIZZLED = UINT64_C(1) << 39;
|
||||
|
||||
// Rewrite gl_DrawID as a uniform int
|
||||
const ShCompileOptions SH_EMULATE_GL_DRAW_ID = UINT64_C(1) << 38;
|
||||
const ShCompileOptions SH_EMULATE_GL_DRAW_ID = UINT64_C(1) << 40;
|
||||
|
||||
// This flag initializes shared variables to 0.
|
||||
// It is to avoid ompute shaders being able to read undefined values that could be coming from
|
||||
// another webpage/application.
|
||||
const ShCompileOptions SH_INIT_SHARED_VARIABLES = UINT64_C(1) << 39;
|
||||
const ShCompileOptions SH_INIT_SHARED_VARIABLES = UINT64_C(1) << 41;
|
||||
|
||||
// Forces the value returned from an atomic operations to be always be resolved. This is targeted to
|
||||
// workaround a bug in NVIDIA D3D driver where the return value from
|
||||
// RWByteAddressBuffer.InterlockedAdd does not get resolved when used in the .yzw components of a
|
||||
// RWByteAddressBuffer.Store operation. Only has an effect on HLSL translation.
|
||||
// http://anglebug.com/3246
|
||||
const ShCompileOptions SH_FORCE_ATOMIC_VALUE_RESOLUTION = UINT64_C(1) << 40;
|
||||
const ShCompileOptions SH_FORCE_ATOMIC_VALUE_RESOLUTION = UINT64_C(1) << 42;
|
||||
|
||||
// Rewrite gl_BaseVertex and gl_BaseInstance as uniform int
|
||||
const ShCompileOptions SH_EMULATE_GL_BASE_VERTEX_BASE_INSTANCE = UINT64_C(1) << 41;
|
||||
const ShCompileOptions SH_EMULATE_GL_BASE_VERTEX_BASE_INSTANCE = UINT64_C(1) << 43;
|
||||
|
||||
// Emulate seamful cube map sampling for OpenGL ES2.0. Currently only applies to the Vulkan
|
||||
// backend, as is done after samplers are moved out of structs. Can likely be made to work on
|
||||
// the other backends as well.
|
||||
const ShCompileOptions SH_EMULATE_SEAMFUL_CUBE_MAP_SAMPLING = UINT64_C(1) << 42;
|
||||
const ShCompileOptions SH_EMULATE_SEAMFUL_CUBE_MAP_SAMPLING = UINT64_C(1) << 44;
|
||||
|
||||
// This flag controls how to translate WEBGL_video_texture sampling function.
|
||||
const ShCompileOptions SH_TAKE_VIDEO_TEXTURE_AS_EXTERNAL_OES = UINT64_C(1) << 43;
|
||||
const ShCompileOptions SH_TAKE_VIDEO_TEXTURE_AS_EXTERNAL_OES = UINT64_C(1) << 45;
|
||||
|
||||
// If requested, validates the AST after every transformation. Useful for debugging.
|
||||
const ShCompileOptions SH_VALIDATE_AST = UINT64_C(1) << 46;
|
||||
|
||||
// Use old version of RewriteStructSamplers, which doesn't produce as many
|
||||
// sampler arrays in parameters. This causes a few tests to pass on Android.
|
||||
const ShCompileOptions SH_USE_OLD_REWRITE_STRUCT_SAMPLERS = UINT64_C(1) << 47;
|
||||
|
||||
// This flag works around a inconsistent behavior in Mac AMD driver where gl_VertexID doesn't
|
||||
// include base vertex value. It replaces gl_VertexID with (gl_VertexID + angle_BaseVertex)
|
||||
// when angle_BaseVertex is available.
|
||||
const ShCompileOptions SH_ADD_BASE_VERTEX_TO_VERTEX_ID = UINT64_C(1) << 44;
|
||||
const ShCompileOptions SH_ADD_BASE_VERTEX_TO_VERTEX_ID = UINT64_C(1) << 48;
|
||||
|
||||
// This works around the dynamic lvalue indexing of swizzled vectors on various platforms.
|
||||
const ShCompileOptions SH_REMOVE_DYNAMIC_INDEXING_OF_SWIZZLED_VECTOR = UINT64_C(1) << 45;
|
||||
const ShCompileOptions SH_REMOVE_DYNAMIC_INDEXING_OF_SWIZZLED_VECTOR = UINT64_C(1) << 49;
|
||||
|
||||
// This flag works around a slow fxc compile performance issue with dynamic uniform indexing.
|
||||
const ShCompileOptions SH_ALLOW_TRANSLATE_UNIFORM_BLOCK_TO_STRUCTUREDBUFFER = UINT64_C(1) << 46;
|
||||
const ShCompileOptions SH_ALLOW_TRANSLATE_UNIFORM_BLOCK_TO_STRUCTUREDBUFFER = UINT64_C(1) << 50;
|
||||
|
||||
// This flag indicates whether Bresenham line raster emulation code should be generated. This
|
||||
// emulation is necessary if the backend uses a differnet algorithm to draw lines. Currently only
|
||||
// implemented for the Vulkan backend.
|
||||
const ShCompileOptions SH_ADD_BRESENHAM_LINE_RASTER_EMULATION = UINT64_C(1) << 47;
|
||||
const ShCompileOptions SH_ADD_BRESENHAM_LINE_RASTER_EMULATION = UINT64_C(1) << 51;
|
||||
|
||||
// This flag allows disabling ARB_texture_rectangle on a per-compile basis. This is necessary
|
||||
// for WebGL contexts becuase ARB_texture_rectangle may be necessary for the WebGL implementation
|
||||
// internally but shouldn't be exposed to WebGL user code.
|
||||
const ShCompileOptions SH_DISABLE_ARB_TEXTURE_RECTANGLE = UINT64_C(1) << 48;
|
||||
const ShCompileOptions SH_DISABLE_ARB_TEXTURE_RECTANGLE = UINT64_C(1) << 52;
|
||||
|
||||
// This flag works around a driver bug by rewriting uses of row-major matrices
|
||||
// as column-major in ESSL 3.00 and greater shaders.
|
||||
const ShCompileOptions SH_REWRITE_ROW_MAJOR_MATRICES = UINT64_C(1) << 49;
|
||||
const ShCompileOptions SH_REWRITE_ROW_MAJOR_MATRICES = UINT64_C(1) << 53;
|
||||
|
||||
// Drop any explicit precision qualifiers from shader.
|
||||
const ShCompileOptions SH_IGNORE_PRECISION_QUALIFIERS = UINT64_C(1) << 50;
|
||||
const ShCompileOptions SH_IGNORE_PRECISION_QUALIFIERS = UINT64_C(1) << 54;
|
||||
|
||||
// Allow compiler to do early fragment tests as an optimization.
|
||||
const ShCompileOptions SH_EARLY_FRAGMENT_TESTS_OPTIMIZATION = UINT64_C(1) << 51;
|
||||
const ShCompileOptions SH_EARLY_FRAGMENT_TESTS_OPTIMIZATION = UINT64_C(1) << 55;
|
||||
|
||||
// Allow compiler to insert Android pre-rotation code.
|
||||
const ShCompileOptions SH_ADD_PRE_ROTATION = UINT64_C(1) << 52;
|
||||
|
||||
const ShCompileOptions SH_FORCE_SHADER_PRECISION_HIGHP_TO_MEDIUMP = UINT64_C(1) << 53;
|
||||
|
||||
// Allow compiler to use specialization constant to do pre-rotation and y flip.
|
||||
const ShCompileOptions SH_USE_SPECIALIZATION_CONSTANT = UINT64_C(1) << 54;
|
||||
|
||||
// Ask compiler to generate Vulkan transform feedback emulation support code.
|
||||
const ShCompileOptions SH_ADD_VULKAN_XFB_EMULATION_SUPPORT_CODE = UINT64_C(1) << 55;
|
||||
|
||||
// Ask compiler to generate Vulkan transform feedback support code when using the
|
||||
// VK_EXT_transform_feedback extension.
|
||||
const ShCompileOptions SH_ADD_VULKAN_XFB_EXTENSION_SUPPORT_CODE = UINT64_C(1) << 56;
|
||||
|
||||
// This flag initializes fragment shader's output variables to zero at the beginning of the fragment
|
||||
// shader's main(). It is intended as a workaround for drivers which get context lost if
|
||||
// gl_FragColor is not written.
|
||||
const ShCompileOptions SH_INIT_FRAGMENT_OUTPUT_VARIABLES = UINT64_C(1) << 57;
|
||||
const ShCompileOptions SH_ADD_PRE_ROTATION = UINT64_C(1) << 56;
|
||||
|
||||
// Defines alternate strategies for implementing array index clamping.
|
||||
enum ShArrayIndexClampingStrategy
|
||||
|
@ -380,7 +384,6 @@ struct ShBuiltInResources
|
|||
int EXT_shader_texture_lod;
|
||||
int WEBGL_debug_shader_precision;
|
||||
int EXT_shader_framebuffer_fetch;
|
||||
int EXT_shader_framebuffer_fetch_non_coherent;
|
||||
int NV_shader_framebuffer_fetch;
|
||||
int NV_shader_noperspective_interpolation;
|
||||
int ARM_shader_framebuffer_fetch;
|
||||
|
@ -390,8 +393,6 @@ struct ShBuiltInResources
|
|||
int EXT_multisampled_render_to_texture2;
|
||||
int EXT_YUV_target;
|
||||
int EXT_geometry_shader;
|
||||
int OES_shader_io_blocks;
|
||||
int EXT_shader_io_blocks;
|
||||
int EXT_gpu_shader5;
|
||||
int EXT_shader_non_constant_global_initializers;
|
||||
int OES_texture_storage_multisample_2d_array;
|
||||
|
@ -406,11 +407,8 @@ struct ShBuiltInResources
|
|||
int EXT_shadow_samplers;
|
||||
int OES_shader_multisample_interpolation;
|
||||
int OES_shader_image_atomic;
|
||||
int EXT_tessellation_shader;
|
||||
int OES_texture_buffer;
|
||||
int EXT_texture_buffer;
|
||||
int OES_sample_variables;
|
||||
int EXT_clip_cull_distance;
|
||||
|
||||
// Set to 1 to enable replacing GL_EXT_draw_buffers #extension directives
|
||||
// with GL_NV_draw_buffers in ESSL output. This flag can be used to emulate
|
||||
|
@ -468,10 +466,6 @@ struct ShBuiltInResources
|
|||
// maximum number of available image units
|
||||
int MaxImageUnits;
|
||||
|
||||
// OES_sample_variables constant
|
||||
// maximum number of available samples
|
||||
int MaxSamples;
|
||||
|
||||
// maximum number of image uniforms in a vertex shader
|
||||
int MaxVertexImageUniforms;
|
||||
|
||||
|
@ -554,35 +548,11 @@ struct ShBuiltInResources
|
|||
int MaxGeometryShaderInvocations;
|
||||
int MaxGeometryImageUniforms;
|
||||
|
||||
// EXT_tessellation_shader constants
|
||||
int MaxTessControlInputComponents;
|
||||
int MaxTessControlOutputComponents;
|
||||
int MaxTessControlTextureImageUnits;
|
||||
int MaxTessControlUniformComponents;
|
||||
int MaxTessControlTotalOutputComponents;
|
||||
int MaxTessControlImageUniforms;
|
||||
int MaxTessControlAtomicCounters;
|
||||
int MaxTessControlAtomicCounterBuffers;
|
||||
|
||||
int MaxTessPatchComponents;
|
||||
int MaxPatchVertices;
|
||||
int MaxTessGenLevel;
|
||||
|
||||
int MaxTessEvaluationInputComponents;
|
||||
int MaxTessEvaluationOutputComponents;
|
||||
int MaxTessEvaluationTextureImageUnits;
|
||||
int MaxTessEvaluationUniformComponents;
|
||||
int MaxTessEvaluationImageUniforms;
|
||||
int MaxTessEvaluationAtomicCounters;
|
||||
int MaxTessEvaluationAtomicCounterBuffers;
|
||||
|
||||
// Subpixel bits used in rasterization.
|
||||
int SubPixelBits;
|
||||
|
||||
// APPLE_clip_distance/EXT_clip_cull_distance constant
|
||||
int MaxClipDistances;
|
||||
int MaxCullDistances;
|
||||
int MaxCombinedClipAndCullDistances;
|
||||
};
|
||||
|
||||
//
|
||||
|
@ -596,7 +566,6 @@ using ShHandle = void *;
|
|||
|
||||
namespace sh
|
||||
{
|
||||
using BinaryBlob = std::vector<uint32_t>;
|
||||
|
||||
//
|
||||
// Driver must call this first, once, before doing any other compiler operations.
|
||||
|
@ -659,7 +628,7 @@ void Destruct(ShHandle handle);
|
|||
// compiling for WebGL - it is implied.
|
||||
// SH_INTERMEDIATE_TREE: Writes intermediate tree to info log.
|
||||
// Can be queried by calling sh::GetInfoLog().
|
||||
// SH_OBJECT_CODE: Translates intermediate tree to glsl or hlsl shader, or SPIR-V binary.
|
||||
// SH_OBJECT_CODE: Translates intermediate tree to glsl or hlsl shader.
|
||||
// Can be queried by calling sh::GetObjectCode().
|
||||
// SH_VARIABLES: Extracts attributes, uniforms, and varyings.
|
||||
// Can be queried by calling ShGetVariableInfo().
|
||||
|
@ -683,18 +652,11 @@ ShShaderOutput GetShaderOutputType(const ShHandle handle);
|
|||
// handle: Specifies the compiler
|
||||
const std::string &GetInfoLog(const ShHandle handle);
|
||||
|
||||
// Returns null-terminated object code for a compiled shader. Only valid for output types that
|
||||
// generate human-readable code (GLSL, ESSL or HLSL).
|
||||
// Returns null-terminated object code for a compiled shader.
|
||||
// Parameters:
|
||||
// handle: Specifies the compiler
|
||||
const std::string &GetObjectCode(const ShHandle handle);
|
||||
|
||||
// Returns object binary blob for a compiled shader. Only valid for output types that
|
||||
// generate binary blob (SPIR-V).
|
||||
// Parameters:
|
||||
// handle: Specifies the compiler
|
||||
const BinaryBlob &GetObjectBinaryBlob(const ShHandle handle);
|
||||
|
||||
// Returns a (original_name, hash) map containing all the user defined names in the shader,
|
||||
// including variable names, function names, struct names, and struct field names.
|
||||
// Parameters:
|
||||
|
@ -723,9 +685,6 @@ int GetVertexShaderNumViews(const ShHandle handle);
|
|||
// Returns true if compiler has injected instructions for early fragment tests as an optimization
|
||||
bool HasEarlyFragmentTestsOptimization(const ShHandle handle);
|
||||
|
||||
// Returns specialization constant usage bits
|
||||
uint32_t GetShaderSpecConstUsageBits(const ShHandle handle);
|
||||
|
||||
// Returns true if the passed in variables pack in maxVectors followingthe packing rules from the
|
||||
// GLSL 1.017 spec, Appendix A, section 7.
|
||||
// Returns false otherwise. Also look at the SH_ENFORCE_PACKING_RESTRICTIONS
|
||||
|
@ -760,7 +719,6 @@ bool GetUniformBlockRegister(const ShHandle handle,
|
|||
|
||||
bool ShouldUniformBlockUseStructuredBuffer(const ShHandle handle,
|
||||
const std::string &uniformBlockName);
|
||||
const std::set<std::string> *GetSlowCompilingUniformBlockSet(const ShHandle handle);
|
||||
|
||||
// Gives a map from uniform names to compiler-assigned registers in the default uniform block.
|
||||
// Note that the map contains also registers of samplers that have been extracted from structs.
|
||||
|
@ -782,20 +740,11 @@ const std::set<std::string> *GetUsedImage2DFunctionNames(const ShHandle handle);
|
|||
bool HasValidGeometryShaderInputPrimitiveType(const ShHandle handle);
|
||||
bool HasValidGeometryShaderOutputPrimitiveType(const ShHandle handle);
|
||||
bool HasValidGeometryShaderMaxVertices(const ShHandle handle);
|
||||
bool HasValidTessGenMode(const ShHandle handle);
|
||||
bool HasValidTessGenSpacing(const ShHandle handle);
|
||||
bool HasValidTessGenVertexOrder(const ShHandle handle);
|
||||
bool HasValidTessGenPointMode(const ShHandle handle);
|
||||
GLenum GetGeometryShaderInputPrimitiveType(const ShHandle handle);
|
||||
GLenum GetGeometryShaderOutputPrimitiveType(const ShHandle handle);
|
||||
int GetGeometryShaderInvocations(const ShHandle handle);
|
||||
int GetGeometryShaderMaxVertices(const ShHandle handle);
|
||||
unsigned int GetShaderSharedMemorySize(const ShHandle handle);
|
||||
int GetTessControlShaderVertices(const ShHandle handle);
|
||||
GLenum GetTessGenMode(const ShHandle handle);
|
||||
GLenum GetTessGenSpacing(const ShHandle handle);
|
||||
GLenum GetTessGenVertexOrder(const ShHandle handle);
|
||||
GLenum GetTessGenPointMode(const ShHandle handle);
|
||||
|
||||
//
|
||||
// Helper function to identify specs that are based on the WebGL spec.
|
||||
|
@ -826,36 +775,8 @@ enum class SpecializationConstantId : uint32_t
|
|||
{
|
||||
LineRasterEmulation = 0,
|
||||
SurfaceRotation = 1,
|
||||
DrawableWidth = 2,
|
||||
DrawableHeight = 3,
|
||||
|
||||
InvalidEnum = 4,
|
||||
EnumCount = InvalidEnum,
|
||||
};
|
||||
|
||||
enum class SurfaceRotation : uint32_t
|
||||
{
|
||||
Identity,
|
||||
Rotated90Degrees,
|
||||
Rotated180Degrees,
|
||||
Rotated270Degrees,
|
||||
FlippedIdentity,
|
||||
FlippedRotated90Degrees,
|
||||
FlippedRotated180Degrees,
|
||||
FlippedRotated270Degrees,
|
||||
|
||||
InvalidEnum,
|
||||
EnumCount = InvalidEnum,
|
||||
};
|
||||
|
||||
enum class SpecConstUsage : uint32_t
|
||||
{
|
||||
LineRasterEmulation = 0,
|
||||
YFlip = 1,
|
||||
Rotation = 2,
|
||||
DrawableSize = 3,
|
||||
|
||||
InvalidEnum = 4,
|
||||
InvalidEnum = 2,
|
||||
EnumCount = InvalidEnum,
|
||||
};
|
||||
|
||||
|
@ -877,19 +798,6 @@ extern const char kAtomicCountersBlockName[];
|
|||
// Line raster emulation varying
|
||||
extern const char kLineRasterEmulationPosition[];
|
||||
|
||||
// Transform feedback emulation support
|
||||
extern const char kXfbEmulationGetOffsetsFunctionName[];
|
||||
extern const char kXfbEmulationCaptureFunctionName[];
|
||||
extern const char kXfbEmulationBufferBlockName[];
|
||||
extern const char kXfbEmulationBufferName[];
|
||||
extern const char kXfbEmulationBufferFieldName[];
|
||||
|
||||
// Transform feedback extension support
|
||||
extern const char kXfbExtensionPositionOutName[];
|
||||
|
||||
// EXT_shader_framebuffer_fetch and EXT_shader_framebuffer_fetch_non_coherent
|
||||
extern const char kInputAttachmentName[];
|
||||
|
||||
} // namespace vk
|
||||
|
||||
namespace mtl
|
||||
|
@ -900,13 +808,6 @@ extern const char kCoverageMaskEnabledConstName[];
|
|||
// Specialization constant to emulate rasterizer discard.
|
||||
extern const char kRasterizerDiscardEnabledConstName[];
|
||||
} // namespace mtl
|
||||
|
||||
// For backends that use glslang (the Vulkan shader compiler), i.e. Vulkan and Metal, call these to
|
||||
// initialize and finalize glslang itself. This can be called independently from Initialize() and
|
||||
// Finalize().
|
||||
void InitializeGlslang();
|
||||
void FinalizeGlslang();
|
||||
|
||||
} // namespace sh
|
||||
|
||||
#endif // GLSLANG_SHADERLANG_H_
|
||||
|
|
|
@ -51,6 +51,11 @@ enum class BlockType
|
|||
{
|
||||
BLOCK_UNIFORM,
|
||||
BLOCK_BUFFER,
|
||||
|
||||
// Required in OpenGL ES 3.1 extension GL_OES_shader_io_blocks.
|
||||
// TODO(jiawei.shao@intel.com): add BLOCK_OUT.
|
||||
// Also used in GLSL
|
||||
BLOCK_IN
|
||||
};
|
||||
|
||||
// Base class for all variables defined in shaders, including Varyings, Uniforms, etc
|
||||
|
@ -100,8 +105,6 @@ struct ShaderVariable
|
|||
unsigned int getExternalSize() const;
|
||||
|
||||
bool isStruct() const { return !fields.empty(); }
|
||||
const std::string &getStructName() const { return structOrBlockName; }
|
||||
void setStructName(const std::string &newName) { structOrBlockName = newName; }
|
||||
|
||||
// All of the shader's variables are described using nested data
|
||||
// structures. This is needed in order to disambiguate similar looking
|
||||
|
@ -125,6 +128,14 @@ struct ShaderVariable
|
|||
bool isBuiltIn() const;
|
||||
bool isEmulatedBuiltIn() const;
|
||||
|
||||
GLenum type;
|
||||
GLenum precision;
|
||||
std::string name;
|
||||
std::string mappedName;
|
||||
|
||||
// Used to make an array type. Outermost array size is stored at the end of the vector.
|
||||
std::vector<unsigned int> arraySizes;
|
||||
|
||||
// Offset of this variable in parent arrays. In case the parent is an array of arrays, the
|
||||
// offset is outerArrayElement * innerArraySize + innerArrayElement.
|
||||
// For example, if there's a variable declared as size 3 array of size 4 array of int:
|
||||
|
@ -136,51 +147,10 @@ struct ShaderVariable
|
|||
return hasParentArrayIndex() ? flattenedOffsetInParentArrays : 0;
|
||||
}
|
||||
|
||||
int getFlattenedOffsetInParentArrays() const { return flattenedOffsetInParentArrays; }
|
||||
void setParentArrayIndex(int indexIn) { flattenedOffsetInParentArrays = indexIn; }
|
||||
|
||||
bool hasParentArrayIndex() const { return flattenedOffsetInParentArrays != -1; }
|
||||
|
||||
void resetEffectiveLocation();
|
||||
void updateEffectiveLocation(const sh::ShaderVariable &parent);
|
||||
|
||||
// Decide whether two uniforms are the same at shader link time,
|
||||
// assuming they are from consecutive shader stages.
|
||||
// GLSL ES Spec 3.00.3, section 4.3.5.
|
||||
// GLSL ES Spec 3.10.4, section 4.4.5
|
||||
bool isSameUniformAtLinkTime(const ShaderVariable &other) const;
|
||||
|
||||
// InterfaceBlockField
|
||||
// Decide whether two InterfaceBlock fields are the same at shader
|
||||
// link time, assuming they are from consecutive shader stages.
|
||||
// See GLSL ES Spec 3.00.3, sec 4.3.7.
|
||||
bool isSameInterfaceBlockFieldAtLinkTime(const ShaderVariable &other) const;
|
||||
|
||||
// Decide whether two varyings are the same at shader link time,
|
||||
// assuming they are from consecutive shader stages.
|
||||
// Invariance needs to match only in ESSL1. Relevant spec sections:
|
||||
// GLSL ES 3.00.4, sections 4.6.1 and 4.3.9.
|
||||
// GLSL ES 1.00.17, section 4.6.4.
|
||||
bool isSameVaryingAtLinkTime(const ShaderVariable &other, int shaderVersion) const;
|
||||
// Deprecated version of isSameVaryingAtLinkTime, which assumes ESSL1.
|
||||
bool isSameVaryingAtLinkTime(const ShaderVariable &other) const;
|
||||
|
||||
// Shader I/O blocks may match by block name or instance, based on whether both stages have an
|
||||
// instance name or not.
|
||||
bool isSameNameAtLinkTime(const ShaderVariable &other) const;
|
||||
|
||||
// NOTE: When adding new members, the following functions also need to be updated:
|
||||
// gl::WriteShaderVar(BinaryOutputStream *stream, const sh::ShaderVariable &var)
|
||||
// gl::LoadShaderVar(BinaryInputStream *stream, sh::ShaderVariable *var)
|
||||
|
||||
GLenum type;
|
||||
GLenum precision;
|
||||
std::string name;
|
||||
std::string mappedName;
|
||||
|
||||
// Used to make an array type. Outermost array size is stored at the end of the vector.
|
||||
std::vector<unsigned int> arraySizes;
|
||||
|
||||
// Static use means that the variable is accessed somewhere in the shader source.
|
||||
bool staticUse;
|
||||
// A variable is active unless the compiler determined that it is not accessed by the shader.
|
||||
|
@ -188,11 +158,7 @@ struct ShaderVariable
|
|||
// necessarily active. GLES 3.0.5 section 2.12.6. GLES 3.1 section 7.3.1.
|
||||
bool active;
|
||||
std::vector<ShaderVariable> fields;
|
||||
// structOrBlockName is used for:
|
||||
// - varyings of struct type, in which case it contains the struct name.
|
||||
// - shader I/O blocks, in which case it contains the block name.
|
||||
std::string structOrBlockName;
|
||||
std::string mappedStructOrBlockName;
|
||||
std::string structName;
|
||||
|
||||
// Only applies to interface block fields. Kept here for simplicity.
|
||||
bool isRowMajorLayout;
|
||||
|
@ -200,34 +166,40 @@ struct ShaderVariable
|
|||
// VariableWithLocation
|
||||
int location;
|
||||
|
||||
// The location of inputs or outputs without location layout quailifer will be updated to '-1'.
|
||||
// GLES Spec 3.1, Section 7.3. PROGRAM OBJECTS
|
||||
// Not all active variables are assigned valid locations;
|
||||
// the following variables will have an effective location of -1:
|
||||
bool hasImplicitLocation;
|
||||
|
||||
// Uniform
|
||||
int binding;
|
||||
// Decide whether two uniforms are the same at shader link time,
|
||||
// assuming one from vertex shader and the other from fragment shader.
|
||||
// GLSL ES Spec 3.00.3, section 4.3.5.
|
||||
// GLSL ES Spec 3.10.4, section 4.4.5
|
||||
bool isSameUniformAtLinkTime(const ShaderVariable &other) const;
|
||||
GLenum imageUnitFormat;
|
||||
int offset;
|
||||
bool readonly;
|
||||
bool writeonly;
|
||||
|
||||
// From EXT_shader_framebuffer_fetch
|
||||
bool isFragmentInOut;
|
||||
|
||||
// OutputVariable
|
||||
// From EXT_blend_func_extended.
|
||||
int index;
|
||||
|
||||
// From EXT_YUV_target
|
||||
bool yuv;
|
||||
// InterfaceBlockField
|
||||
// Decide whether two InterfaceBlock fields are the same at shader
|
||||
// link time, assuming one from vertex shader and the other from
|
||||
// fragment shader.
|
||||
// See GLSL ES Spec 3.00.3, sec 4.3.7.
|
||||
bool isSameInterfaceBlockFieldAtLinkTime(const ShaderVariable &other) const;
|
||||
|
||||
// Varying
|
||||
InterpolationType interpolation;
|
||||
bool isInvariant;
|
||||
bool isShaderIOBlock;
|
||||
bool isPatch;
|
||||
// Decide whether two varyings are the same at shader link time,
|
||||
// assuming one from vertex shader and the other from fragment shader.
|
||||
// Invariance needs to match only in ESSL1. Relevant spec sections:
|
||||
// GLSL ES 3.00.4, sections 4.6.1 and 4.3.9.
|
||||
// GLSL ES 1.00.17, section 4.6.4.
|
||||
bool isSameVaryingAtLinkTime(const ShaderVariable &other, int shaderVersion) const;
|
||||
// Deprecated version of isSameVaryingAtLinkTime, which assumes ESSL1.
|
||||
bool isSameVaryingAtLinkTime(const ShaderVariable &other) const;
|
||||
|
||||
// If the variable is a sampler that has ever been statically used with texelFetch
|
||||
bool texelFetchStaticUse;
|
||||
|
@ -237,10 +209,6 @@ struct ShaderVariable
|
|||
bool matchPrecision,
|
||||
bool matchName) const;
|
||||
|
||||
// NOTE: When adding new members, the following functions also need to be updated:
|
||||
// gl::WriteShaderVar(BinaryOutputStream *stream, const sh::ShaderVariable &var)
|
||||
// gl::LoadShaderVar(BinaryInputStream *stream, sh::ShaderVariable *var)
|
||||
|
||||
int flattenedOffsetInParentArrays;
|
||||
};
|
||||
|
||||
|
|
|
@ -90,20 +90,12 @@
|
|||
* int arg2) KHRONOS_APIATTRIBUTES;
|
||||
*/
|
||||
|
||||
#if defined(__SCITECH_SNAP__) && !defined(KHRONOS_STATIC)
|
||||
# define KHRONOS_STATIC 1
|
||||
#endif
|
||||
|
||||
/*-------------------------------------------------------------------------
|
||||
* Definition of KHRONOS_APICALL
|
||||
*-------------------------------------------------------------------------
|
||||
* This precedes the return type of the function in the function prototype.
|
||||
*/
|
||||
#if defined(KHRONOS_STATIC)
|
||||
/* If the preprocessor constant KHRONOS_STATIC is defined, make the
|
||||
* header compatible with static linking. */
|
||||
# define KHRONOS_APICALL
|
||||
#elif defined(_WIN32)
|
||||
#if defined(_WIN32) && !defined(__SCITECH_SNAP__)
|
||||
# define KHRONOS_APICALL __declspec(dllimport)
|
||||
#elif defined (__SYMBIAN32__)
|
||||
# define KHRONOS_APICALL IMPORT_C
|
||||
|
|
|
@ -12,14 +12,14 @@
|
|||
#if !defined(ANGLE_EXPORT)
|
||||
# if defined(_WIN32)
|
||||
# if defined(LIBGLESV2_IMPLEMENTATION) || defined(LIBANGLE_IMPLEMENTATION) || \
|
||||
defined(LIBFEATURE_SUPPORT_IMPLEMENTATION) || defined(LIBCL_IMPLEMENTATION)
|
||||
defined(LIBFEATURE_SUPPORT_IMPLEMENTATION)
|
||||
# define ANGLE_EXPORT __declspec(dllexport)
|
||||
# else
|
||||
# define ANGLE_EXPORT __declspec(dllimport)
|
||||
# endif
|
||||
# elif defined(__GNUC__)
|
||||
# if defined(LIBGLESV2_IMPLEMENTATION) || defined(LIBANGLE_IMPLEMENTATION) || \
|
||||
defined(LIBFEATURE_SUPPORT_IMPLEMENTATION) || defined(LIBCL_IMPLEMENTATION)
|
||||
defined(LIBFEATURE_SUPPORT_IMPLEMENTATION)
|
||||
# define ANGLE_EXPORT __attribute__((visibility("default")))
|
||||
# else
|
||||
# define ANGLE_EXPORT
|
||||
|
|
|
@ -37,10 +37,6 @@ struct FeaturesGL : FeatureSetBase
|
|||
FeatureCategory::OpenGLWorkarounds,
|
||||
"GL_RGBA4 is not color renderable", &members};
|
||||
|
||||
// Newer Intel GPUs natively support ETC2/EAC compressed texture formats.
|
||||
Feature allowEtcFormats = {"allow_etc_formats", FeatureCategory::OpenGLWorkarounds,
|
||||
"Enable ETC2/EAC on desktop OpenGL", &members};
|
||||
|
||||
// When clearing a framebuffer on Intel or AMD drivers, when GL_FRAMEBUFFER_SRGB is enabled, the
|
||||
// driver clears to the linearized clear color despite the framebuffer not supporting SRGB
|
||||
// blending. It only seems to do this when the framebuffer has only linear attachments, mixed
|
||||
|
@ -509,52 +505,6 @@ struct FeaturesGL : FeatureSetBase
|
|||
"set_zero_level_before_generating_mipmap", FeatureCategory::OpenGLWorkarounds,
|
||||
"glGenerateMipmap fails if the zero texture level is not set on some Mac drivers.",
|
||||
&members};
|
||||
|
||||
// On macOS with AMD GPUs, packed color formats like RGB565 and RGBA4444 are buggy. Promote them
|
||||
// to 8 bit per channel formats.
|
||||
Feature promotePackedFormatsTo8BitPerChannel = {
|
||||
"promote_packed_formats_to_8_bit_per_channel", FeatureCategory::OpenGLWorkarounds,
|
||||
"Packed color formats are buggy on Macs with AMD GPUs", &members,
|
||||
"http://anglebug.com/5469"};
|
||||
|
||||
// If gl_FragColor is not written by fragment shader, it may cause context lost with Adreno 42x
|
||||
// and 3xx.
|
||||
Feature initFragmentOutputVariables = {
|
||||
"init_fragment_output_variables", FeatureCategory::OpenGLWorkarounds,
|
||||
"No init gl_FragColor causes context lost", &members, "http://crbug.com/1171371"};
|
||||
|
||||
// On macOS with Intel GPUs, instanced array with divisor > 0 is buggy when first > 0 in
|
||||
// drawArraysInstanced. Shift the attributes with extra offset to workaround.
|
||||
Feature shiftInstancedArrayDataWithExtraOffset = {
|
||||
"shift_instanced_array_data_with_offset", FeatureCategory::OpenGLWorkarounds,
|
||||
"glDrawArraysInstanced is buggy on certain new Mac Intel GPUs", &members,
|
||||
"http://crbug.com/1144207"};
|
||||
|
||||
// ANGLE needs to support devices that have no native VAOs. Sync everything to the default VAO.
|
||||
Feature syncVertexArraysToDefault = {
|
||||
"sync_vertex_arrays_to_default", FeatureCategory::OpenGLWorkarounds,
|
||||
"Only use the default VAO because of missing support or driver bugs", &members,
|
||||
"http://anglebug.com/5577"};
|
||||
|
||||
// On desktop Linux/AMD when using the amdgpu drivers, the precise kernel and DRM version are
|
||||
// leaked via GL_RENDERER. We workaround this to improve user privacy.
|
||||
Feature sanitizeAmdGpuRendererString = {
|
||||
"sanitize_amdgpu_renderer_string", FeatureCategory::OpenGLWorkarounds,
|
||||
"Strip precise kernel and DRM version information from amdgpu renderer strings.", &members,
|
||||
"http://crbug.com/1181193"};
|
||||
|
||||
// Imagination GL drivers are buggy with context switching. We need to ubind fbo to workaround a
|
||||
// crash in the driver.
|
||||
Feature unbindFBOOnContextSwitch = {"unbind_fbo_before_switching_context",
|
||||
FeatureCategory::OpenGLWorkarounds,
|
||||
"Imagination GL drivers are buggy with context switching.",
|
||||
&members, "http://crbug.com/1181193"};
|
||||
|
||||
Feature flushOnFramebufferChange = {"flush_on_framebuffer_change",
|
||||
FeatureCategory::OpenGLWorkarounds,
|
||||
"Switching framebuffers without a flush can lead to "
|
||||
"crashes on Intel 9th Generation GPU Macs.",
|
||||
&members, "http://crbug.com/1181068"};
|
||||
};
|
||||
|
||||
inline FeaturesGL::FeaturesGL() = default;
|
||||
|
|
|
@ -64,13 +64,6 @@ struct FeaturesVk : FeatureSetBase
|
|||
"The point size range reported from the API is inconsistent with the actual behavior",
|
||||
&members, "http://anglebug.com/2970"};
|
||||
|
||||
// On some NVIDIA drivers the depth value is not clamped to [0,1] for floating point depth
|
||||
// buffers. This is NVIDIA bug 3171019, see http://anglebug.com/3970 for details.
|
||||
Feature depthClamping = {
|
||||
"depth_clamping", FeatureCategory::VulkanWorkarounds,
|
||||
"The depth value is not clamped to [0,1] for floating point depth buffers.", &members,
|
||||
"http://anglebug.com/3970"};
|
||||
|
||||
// On some android devices, the memory barrier between the compute shader that converts vertex
|
||||
// attributes and the vertex shader that reads from it is ineffective. Only known workaround is
|
||||
// to perform a flush after the conversion. http://anglebug.com/3016
|
||||
|
@ -208,13 +201,6 @@ struct FeaturesVk : FeatureSetBase
|
|||
"extension with the independentResolveNone feature",
|
||||
&members, "http://anglebug.com/4836"};
|
||||
|
||||
// Whether the VkDevice supports the VK_EXT_multisampled_render_to_single_sampled extension.
|
||||
// http://anglebug.com/4836
|
||||
Feature supportsMultisampledRenderToSingleSampled = {
|
||||
"supportsMultisampledRenderToSingleSampled", FeatureCategory::VulkanFeatures,
|
||||
"VkDevice supports the VK_EXT_multisampled_render_to_single_sampled extension", &members,
|
||||
"http://anglebug.com/4836"};
|
||||
|
||||
// VK_PRESENT_MODE_FIFO_KHR causes random timeouts on Linux Intel. http://anglebug.com/3153
|
||||
Feature disableFifoPresentMode = {"disableFifoPresentMode", FeatureCategory::VulkanWorkarounds,
|
||||
"VK_PRESENT_MODE_FIFO_KHR causes random timeouts", &members,
|
||||
|
@ -262,6 +248,14 @@ struct FeaturesVk : FeatureSetBase
|
|||
"Seamful cube map emulation misbehaves on some drivers, so it's disallowed", &members,
|
||||
"http://anglebug.com/3243"};
|
||||
|
||||
// Qualcomm and SwiftShader shader compiler doesn't support sampler arrays as parameters, so
|
||||
// revert to old RewriteStructSamplers behavior, which produces fewer.
|
||||
Feature forceOldRewriteStructSamplers = {
|
||||
"forceOldRewriteStructSamplers", FeatureCategory::VulkanWorkarounds,
|
||||
"Some shader compilers don't support sampler arrays as parameters, so revert to old "
|
||||
"RewriteStructSamplers behavior, which produces fewer.",
|
||||
&members, "http://anglebug.com/2703"};
|
||||
|
||||
// Vulkan considers vertex attribute accesses to count up to the last multiple of the stride.
|
||||
// This additional access supports AMD's robust buffer access implementation.
|
||||
// AMDVLK in particular will return incorrect values when the vertex access extends into the
|
||||
|
@ -299,17 +293,6 @@ struct FeaturesVk : FeatureSetBase
|
|||
"Fill new allocations with non-zero values to flush out errors.", &members,
|
||||
"http://anglebug.com/4384"};
|
||||
|
||||
// Whether to log each callback from the VK_EXT_device_memory_report extension. This feature is
|
||||
// used for trying to debug GPU memory leaks.
|
||||
Feature logMemoryReportCallbacks = {"logMemoryReportCallbacks", FeatureCategory::VulkanFeatures,
|
||||
"Log each callback from VK_EXT_device_memory_report",
|
||||
&members};
|
||||
|
||||
// Whether to log statistics from the VK_EXT_device_memory_report extension each eglSwapBuffer.
|
||||
Feature logMemoryReportStats = {"logMemoryReportStats", FeatureCategory::VulkanFeatures,
|
||||
"Log stats from VK_EXT_device_memory_report each swap",
|
||||
&members};
|
||||
|
||||
// Allocate a "shadow" buffer for GL buffer objects. For GPU-read only buffers
|
||||
// glMap* latency can be reduced by maintaining a copy of the buffer which is
|
||||
// writeable only by the CPU. We then return this shadow buffer on glMap* calls.
|
||||
|
@ -332,6 +315,11 @@ struct FeaturesVk : FeatureSetBase
|
|||
"Enable Android pre-rotation for landscape applications",
|
||||
&members, "http://anglebug.com/3502"};
|
||||
|
||||
// Cache FramebufferVk objects. Currently hitting a bug on Apple: http://anglebug.com/4442
|
||||
Feature enableFramebufferVkCache = {"enableFramebufferVkCache", FeatureCategory::VulkanFeatures,
|
||||
"Enable FramebufferVk objects to be cached", &members,
|
||||
"http://anglebug.com/4442"};
|
||||
|
||||
// Enable precision qualifiers for shaders generated by Vulkan backend http://anglebug.com/3078
|
||||
Feature enablePrecisionQualifiers = {
|
||||
"enablePrecisionQualifiers", FeatureCategory::VulkanFeatures,
|
||||
|
@ -346,11 +334,19 @@ struct FeaturesVk : FeatureSetBase
|
|||
"fine grained pipeline stage dependency information",
|
||||
&members, "http://anglebug.com/4633"};
|
||||
|
||||
// Tell the Vulkan back-end to use the async command queue to dispatch work to the GPU. Command
|
||||
// buffer work will happened in a worker thread. Otherwise use Renderer::CommandQueue directly.
|
||||
Feature asyncCommandQueue = {"asyncCommandQueue", FeatureCategory::VulkanFeatures,
|
||||
"Use CommandQueue worker thread to dispatch work to GPU.",
|
||||
&members, "http://anglebug.com/4324"};
|
||||
// Tell Vulkan back-end to use CommandProcessor class to dispatch work to the GPU. The work will
|
||||
// happen asynchronously in a different thread if asynchronousCommandProcessing is true.
|
||||
// Otherwise use Renderer::CommandQueue to dispatch work.
|
||||
Feature commandProcessor = {"commandProcessor", FeatureCategory::VulkanFeatures,
|
||||
"Use CommandProcessor class to dispatch work to GPU.", &members,
|
||||
"http://anglebug.com/4324"};
|
||||
|
||||
// Enable parallel thread execution when commandProcessor is enabled.
|
||||
// Currently off by default.
|
||||
Feature asynchronousCommandProcessing = {"asynchronousCommandProcessing",
|
||||
FeatureCategory::VulkanFeatures,
|
||||
"Enable/Disable parallel processing of worker thread",
|
||||
&members, "http://anglebug.com/4324"};
|
||||
|
||||
// Whether the VkDevice supports the VK_KHR_shader_float16_int8 extension and has the
|
||||
// shaderFloat16 feature.
|
||||
|
@ -359,6 +355,14 @@ struct FeaturesVk : FeatureSetBase
|
|||
"and has the shaderFloat16 feature",
|
||||
&members, "http://anglebug.com/4551"};
|
||||
|
||||
// Whether the VkDevice supports the VK_EXT_shader_atomic_flat extension and has the
|
||||
// shaderImageFloat32Atomics feature
|
||||
Feature supportsShaderImageFloat32Atomics = {
|
||||
"supportsShaderImageFloat32Atomics", FeatureCategory::VulkanFeatures,
|
||||
"VkDevice supports the VK_EXT_shader_atomic_float extension and has the "
|
||||
"shaderImageFloat32Atomics feature.",
|
||||
&members, "http://anglebug.com/3578"};
|
||||
|
||||
// Some devices don't meet the limits required to perform mipmap generation using the built-in
|
||||
// compute shader. On some other devices, VK_IMAGE_USAGE_STORAGE_BIT is detrimental to
|
||||
// performance, making this solution impractical.
|
||||
|
@ -423,42 +427,12 @@ struct FeaturesVk : FeatureSetBase
|
|||
"Works around a bug on platforms which destroy oldSwapchain in vkCreateSwapchainKHR.",
|
||||
&members, "http://anglebug.com/5061"};
|
||||
|
||||
// Allow forcing an LOD offset on all sampling operations for performance comparisons. ANGLE is
|
||||
// non-conformant if this feature is enabled.
|
||||
std::array<angle::Feature, 4> forceTextureLODOffset = {
|
||||
angle::Feature{"force_texture_lod_offset_1", angle::FeatureCategory::VulkanWorkarounds,
|
||||
"Increase the minimum texture level-of-detail by 1 when sampling.",
|
||||
&members},
|
||||
angle::Feature{"force_texture_lod_offset_2", angle::FeatureCategory::VulkanWorkarounds,
|
||||
"Increase the minimum texture level-of-detail by 2 when sampling.",
|
||||
&members},
|
||||
angle::Feature{"force_texture_lod_offset_3", angle::FeatureCategory::VulkanWorkarounds,
|
||||
"Increase the minimum texture level-of-detail by 3 when sampling.",
|
||||
&members},
|
||||
angle::Feature{"force_texture_lod_offset_4", angle::FeatureCategory::VulkanWorkarounds,
|
||||
"Increase the minimum texture level-of-detail by 4 when sampling.",
|
||||
&members},
|
||||
};
|
||||
|
||||
// Translate non-nearest filtering modes to nearest for all samplers for performance
|
||||
// comparisons. ANGLE is non-conformant if this feature is enabled.
|
||||
Feature forceNearestFiltering = {"force_nearest_filtering", FeatureCategory::VulkanWorkarounds,
|
||||
"Force nearest filtering when sampling.", &members};
|
||||
|
||||
// Translate non-nearest mip filtering modes to nearest mip for all samplers for performance
|
||||
// comparisons. ANGLE is non-conformant if this feature is enabled.
|
||||
Feature forceNearestMipFiltering = {"forceNearestMipFiltering",
|
||||
FeatureCategory::VulkanWorkarounds,
|
||||
"Force nearest mip filtering when sampling.", &members};
|
||||
|
||||
// Compress float32 vertices in static buffers to float16 at draw time. ANGLE is non-conformant
|
||||
// if this feature is enabled.
|
||||
angle::Feature compressVertexData = {"compress_vertex_data",
|
||||
angle::FeatureCategory::VulkanWorkarounds,
|
||||
"Compress vertex data to smaller data types when "
|
||||
"possible. Using this feature makes ANGLE non-conformant.",
|
||||
&members};
|
||||
|
||||
// Qualcomm missynchronizes vkCmdClearAttachments in the middle of render pass.
|
||||
// https://issuetracker.google.com/166809097
|
||||
Feature preferDrawClearOverVkCmdClearAttachments = {
|
||||
|
@ -481,46 +455,6 @@ struct FeaturesVk : FeatureSetBase
|
|||
Feature emulatedPrerotation270 = {"emulatedPrerotation270", FeatureCategory::VulkanFeatures,
|
||||
"Emulate 270-degree prerotation.", &members,
|
||||
"http://anglebug.com/4901"};
|
||||
|
||||
// Whether we should use driver uniforms over specialization constants for some shader
|
||||
// modifications like yflip and rotation.
|
||||
Feature forceDriverUniformOverSpecConst = {
|
||||
"forceDriverUniformOverSpecConst", FeatureCategory::VulkanWorkarounds,
|
||||
"Forces using driver uniforms instead of specialization constants.", &members,
|
||||
"http://issuetracker.google.com/173636783"};
|
||||
|
||||
// Whether non-conformant configurations and extensions should be exposed. When an extension is
|
||||
// in development, or a GLES version is not supported on a device, we may still want to expose
|
||||
// them for partial testing. This feature is enabled by our test harness.
|
||||
Feature exposeNonConformantExtensionsAndVersions = {
|
||||
"exposeNonConformantExtensionsAndVersions", FeatureCategory::VulkanWorkarounds,
|
||||
"Expose GLES versions and extensions that are not conformant.", &members,
|
||||
"http://anglebug.com/5375"};
|
||||
|
||||
// imageAtomicExchange is expected to work for r32f formats, but support for atomic operations
|
||||
// for VK_FORMAT_R32_SFLOAT is rare. This support is emulated by using an r32ui format for such
|
||||
// images instead.
|
||||
Feature emulateR32fImageAtomicExchange = {
|
||||
"emulateR32fImageAtomicExchange", FeatureCategory::VulkanWorkarounds,
|
||||
"Emulate r32f images with r32ui to support imageAtomicExchange.", &members,
|
||||
"http://anglebug.com/5535"};
|
||||
|
||||
Feature supportsNegativeViewport = {
|
||||
"supportsNegativeViewport", FeatureCategory::VulkanFeatures,
|
||||
"The driver supports inverting the viewport with a negative height.", &members};
|
||||
|
||||
// Whether we should force any highp precision in the fragment shader to mediump.
|
||||
// ANGLE is non-conformant if this feature is enabled.
|
||||
Feature forceFragmentShaderPrecisionHighpToMediump = {
|
||||
"forceFragmentShaderPrecisionHighpToMediump", FeatureCategory::VulkanWorkarounds,
|
||||
"Forces highp precision in fragment shader to mediump.", &members,
|
||||
"https://issuetracker.google.com/184850002"};
|
||||
|
||||
// Whether we should submit at each FBO boundary.
|
||||
Feature preferSubmitAtFBOBoundary = {
|
||||
"preferSubmitAtFBOBoundary", FeatureCategory::VulkanWorkarounds,
|
||||
"Submit commands to driver at each FBO boundary for performance improvements.", &members,
|
||||
"https://issuetracker.google.com/187425444"};
|
||||
};
|
||||
|
||||
inline FeaturesVk::FeaturesVk() = default;
|
||||
|
|
|
@ -48,7 +48,7 @@ struct FrontendFeatures : angle::FeatureSetBase
|
|||
angle::Feature scalarizeVecAndMatConstructorArgs = {
|
||||
"scalarize_vec_and_mat_constructor_args", angle::FeatureCategory::FrontendWorkarounds,
|
||||
"Always rewrite vec/mat constructors to be consistent", &members,
|
||||
"http://crbug.com/1165751"};
|
||||
"http://crbug.com/398694"};
|
||||
|
||||
// Disable support for GL_OES_get_program_binary
|
||||
angle::Feature disableProgramBinary = {
|
||||
|
@ -65,17 +65,6 @@ struct FrontendFeatures : angle::FeatureSetBase
|
|||
angle::Feature allowCompressedFormats = {"allow_compressed_formats",
|
||||
angle::FeatureCategory::FrontendWorkarounds,
|
||||
"Allow compressed formats", &members};
|
||||
|
||||
angle::Feature captureLimits = {"enable_capture_limits",
|
||||
angle::FeatureCategory::FrontendFeatures,
|
||||
"Set the context limits like frame capturing was enabled",
|
||||
&members, "http://anglebug.com/5750"};
|
||||
|
||||
// Whether we should compress pipeline cache in thread pool before it's stored in blob cache.
|
||||
// http://anglebug.com/4722
|
||||
angle::Feature enableCompressingPipelineCacheInThreadPool = {
|
||||
"enableCompressingPipelineCacheInThreadPool", angle::FeatureCategory::FrontendWorkarounds,
|
||||
"Enable compressing pipeline cache in thread pool.", &members, "http://anglebug.com/4722"};
|
||||
};
|
||||
|
||||
inline FrontendFeatures::FrontendFeatures() = default;
|
||||
|
|
|
@ -47,10 +47,9 @@ const VkExternalSemaphoreHandleTypeFlagBits
|
|||
VK_EXTERNAL_SEMAPHORE_HANDLE_TYPE_TEMP_ZIRCON_EVENT_BIT_FUCHSIA =
|
||||
static_cast<VkExternalSemaphoreHandleTypeFlagBits>(0x00100000);
|
||||
|
||||
#ifndef VK_FUCHSIA_external_memory
|
||||
# define VK_FUCHSIA_external_memory 1
|
||||
# define VK_FUCHSIA_EXTERNAL_MEMORY_SPEC_VERSION 1
|
||||
# define VK_FUCHSIA_EXTERNAL_MEMORY_EXTENSION_NAME "VK_FUCHSIA_external_memory"
|
||||
#define VK_FUCHSIA_external_memory 1
|
||||
#define VK_FUCHSIA_EXTERNAL_MEMORY_SPEC_VERSION 1
|
||||
#define VK_FUCHSIA_EXTERNAL_MEMORY_EXTENSION_NAME "VK_FUCHSIA_external_memory"
|
||||
|
||||
typedef struct VkImportMemoryZirconHandleInfoFUCHSIA
|
||||
{
|
||||
|
@ -85,7 +84,7 @@ typedef VkResult(VKAPI_PTR *PFN_vkGetMemoryZirconHandlePropertiesFUCHSIA)(
|
|||
zx_handle_t ZirconHandle,
|
||||
VkMemoryZirconHandlePropertiesFUCHSIA *pMemoryZirconHandleProperties);
|
||||
|
||||
# ifndef VK_NO_PROTOTYPES
|
||||
#ifndef VK_NO_PROTOTYPES
|
||||
VKAPI_ATTR VkResult VKAPI_CALL
|
||||
vkGetMemoryZirconHandleFUCHSIA(VkDevice device,
|
||||
const VkMemoryGetZirconHandleInfoFUCHSIA *pGetZirconHandleInfo,
|
||||
|
@ -96,13 +95,11 @@ VKAPI_ATTR VkResult VKAPI_CALL vkGetMemoryZirconHandlePropertiesFUCHSIA(
|
|||
VkExternalMemoryHandleTypeFlagBits handleType,
|
||||
zx_handle_t ZirconHandle,
|
||||
VkMemoryZirconHandlePropertiesFUCHSIA *pMemoryZirconHandleProperties);
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#ifndef VK_FUCHSIA_external_semaphore
|
||||
# define VK_FUCHSIA_external_semaphore 1
|
||||
# define VK_FUCHSIA_EXTERNAL_SEMAPHORE_SPEC_VERSION 1
|
||||
# define VK_FUCHSIA_EXTERNAL_SEMAPHORE_EXTENSION_NAME "VK_FUCHSIA_external_semaphore"
|
||||
#define VK_FUCHSIA_external_semaphore 1
|
||||
#define VK_FUCHSIA_EXTERNAL_SEMAPHORE_SPEC_VERSION 1
|
||||
#define VK_FUCHSIA_EXTERNAL_SEMAPHORE_EXTENSION_NAME "VK_FUCHSIA_external_semaphore"
|
||||
|
||||
typedef struct VkImportSemaphoreZirconHandleInfoFUCHSIA
|
||||
{
|
||||
|
@ -111,7 +108,7 @@ typedef struct VkImportSemaphoreZirconHandleInfoFUCHSIA
|
|||
VkSemaphore semaphore;
|
||||
VkSemaphoreImportFlags flags;
|
||||
VkExternalSemaphoreHandleTypeFlagBits handleType;
|
||||
zx_handle_t zirconHandle;
|
||||
zx_handle_t handle;
|
||||
} VkImportSemaphoreZirconHandleInfoFUCHSIA;
|
||||
|
||||
typedef struct VkSemaphoreGetZirconHandleInfoFUCHSIA
|
||||
|
@ -130,7 +127,7 @@ typedef VkResult(VKAPI_PTR *PFN_vkGetSemaphoreZirconHandleFUCHSIA)(
|
|||
const VkSemaphoreGetZirconHandleInfoFUCHSIA *pGetZirconHandleInfo,
|
||||
zx_handle_t *pZirconHandle);
|
||||
|
||||
# ifndef VK_NO_PROTOTYPES
|
||||
#ifndef VK_NO_PROTOTYPES
|
||||
VKAPI_ATTR VkResult VKAPI_CALL vkImportSemaphoreZirconHandleFUCHSIA(
|
||||
VkDevice device,
|
||||
const VkImportSemaphoreZirconHandleInfoFUCHSIA *pImportSemaphoreZirconHandleInfo);
|
||||
|
@ -139,7 +136,6 @@ VKAPI_ATTR VkResult VKAPI_CALL
|
|||
vkGetSemaphoreZirconHandleFUCHSIA(VkDevice device,
|
||||
const VkSemaphoreGetZirconHandleInfoFUCHSIA *pGetZirconHandleInfo,
|
||||
zx_handle_t *pZirconHandle);
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
#define ANGLE_COMMIT_HASH "69b749d9f26d"
|
||||
#define ANGLE_COMMIT_HASH "31a43497be09"
|
||||
#define ANGLE_COMMIT_HASH_SIZE 12
|
||||
#define ANGLE_COMMIT_DATE "2021-07-29 10:40:38 -0700"
|
||||
#define ANGLE_COMMIT_POSITION 15718
|
||||
#define ANGLE_COMMIT_DATE "2021-06-11 16:58:24 -0700"
|
||||
#define ANGLE_COMMIT_POSITION 14226
|
||||
|
|
|
@ -70,9 +70,6 @@ class FastVector final
|
|||
void push_back(const value_type &value);
|
||||
void push_back(value_type &&value);
|
||||
|
||||
template <typename... Args>
|
||||
void emplace_back(Args &&... args);
|
||||
|
||||
void pop_back();
|
||||
|
||||
reference front();
|
||||
|
@ -290,17 +287,10 @@ ANGLE_INLINE void FastVector<T, N, Storage>::push_back(const value_type &value)
|
|||
|
||||
template <class T, size_t N, class Storage>
|
||||
ANGLE_INLINE void FastVector<T, N, Storage>::push_back(value_type &&value)
|
||||
{
|
||||
emplace_back(std::move(value));
|
||||
}
|
||||
|
||||
template <class T, size_t N, class Storage>
|
||||
template <typename... Args>
|
||||
ANGLE_INLINE void FastVector<T, N, Storage>::emplace_back(Args &&... args)
|
||||
{
|
||||
if (mSize == mReservedSize)
|
||||
ensure_capacity(mSize + 1);
|
||||
mData[mSize++] = std::move(T(std::forward<Args>(args)...));
|
||||
mData[mSize++] = std::move(value);
|
||||
}
|
||||
|
||||
template <class T, size_t N, class Storage>
|
||||
|
@ -561,17 +551,11 @@ class FastIntegerSet final
|
|||
return (sizedKey < capacity()) && (mKeyData[index].test(offset));
|
||||
}
|
||||
|
||||
ANGLE_INLINE void clear()
|
||||
{
|
||||
for (KeyBitSet &it : mKeyData)
|
||||
{
|
||||
it.reset();
|
||||
}
|
||||
}
|
||||
ANGLE_INLINE void clear() { mKeyData.assign(mKeyData.capacity(), KeyBitSet::Zero()); }
|
||||
|
||||
ANGLE_INLINE bool empty() const
|
||||
{
|
||||
for (const KeyBitSet &it : mKeyData)
|
||||
for (KeyBitSet it : mKeyData)
|
||||
{
|
||||
if (it.any())
|
||||
{
|
||||
|
@ -584,7 +568,7 @@ class FastIntegerSet final
|
|||
ANGLE_INLINE size_t size() const
|
||||
{
|
||||
size_t valid_entries = 0;
|
||||
for (const KeyBitSet &it : mKeyData)
|
||||
for (KeyBitSet it : mKeyData)
|
||||
{
|
||||
valid_entries += it.count();
|
||||
}
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
// GENERATED FILE - DO NOT EDIT.
|
||||
// Generated by gen_packed_gl_enums.py using data from packed_egl_enums.json.
|
||||
//
|
||||
// Copyright 2017 The ANGLE Project Authors. All rights reserved.
|
||||
// Copyright 2020 The ANGLE Project Authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
//
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
// GENERATED FILE - DO NOT EDIT.
|
||||
// Generated by gen_packed_gl_enums.py using data from packed_egl_enums.json.
|
||||
//
|
||||
// Copyright 2017 The ANGLE Project Authors. All rights reserved.
|
||||
// Copyright 2020 The ANGLE Project Authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
//
|
||||
|
@ -14,6 +14,7 @@
|
|||
|
||||
#include <EGL/egl.h>
|
||||
#include <EGL/eglext.h>
|
||||
#include <angle_gl.h>
|
||||
|
||||
#include <cstdint>
|
||||
#include <ostream>
|
||||
|
|
|
@ -132,7 +132,6 @@ TextureType SamplerTypeToTextureType(GLenum samplerType)
|
|||
return TextureType::_2D;
|
||||
|
||||
case GL_SAMPLER_EXTERNAL_OES:
|
||||
case GL_SAMPLER_EXTERNAL_2D_Y2Y_EXT:
|
||||
return TextureType::External;
|
||||
|
||||
case GL_SAMPLER_CUBE:
|
||||
|
@ -185,46 +184,6 @@ TextureType SamplerTypeToTextureType(GLenum samplerType)
|
|||
}
|
||||
}
|
||||
|
||||
TextureType ImageTypeToTextureType(GLenum imageType)
|
||||
{
|
||||
switch (imageType)
|
||||
{
|
||||
case GL_IMAGE_2D:
|
||||
case GL_INT_IMAGE_2D:
|
||||
case GL_UNSIGNED_INT_IMAGE_2D:
|
||||
return TextureType::_2D;
|
||||
|
||||
case GL_IMAGE_CUBE:
|
||||
case GL_INT_IMAGE_CUBE:
|
||||
case GL_UNSIGNED_INT_IMAGE_CUBE:
|
||||
return TextureType::CubeMap;
|
||||
|
||||
case GL_IMAGE_CUBE_MAP_ARRAY:
|
||||
case GL_INT_IMAGE_CUBE_MAP_ARRAY:
|
||||
case GL_UNSIGNED_INT_IMAGE_CUBE_MAP_ARRAY:
|
||||
return TextureType::CubeMapArray;
|
||||
|
||||
case GL_IMAGE_2D_ARRAY:
|
||||
case GL_INT_IMAGE_2D_ARRAY:
|
||||
case GL_UNSIGNED_INT_IMAGE_2D_ARRAY:
|
||||
return TextureType::_2DArray;
|
||||
|
||||
case GL_IMAGE_3D:
|
||||
case GL_INT_IMAGE_3D:
|
||||
case GL_UNSIGNED_INT_IMAGE_3D:
|
||||
return TextureType::_3D;
|
||||
|
||||
case GL_IMAGE_BUFFER:
|
||||
case GL_INT_IMAGE_BUFFER:
|
||||
case GL_UNSIGNED_INT_IMAGE_BUFFER:
|
||||
return TextureType::Buffer;
|
||||
|
||||
default:
|
||||
UNREACHABLE();
|
||||
return TextureType::InvalidEnum;
|
||||
}
|
||||
}
|
||||
|
||||
bool IsMultisampled(TextureType type)
|
||||
{
|
||||
switch (type)
|
||||
|
@ -476,56 +435,6 @@ std::ostream &operator<<(std::ostream &os, VertexAttribType value)
|
|||
}
|
||||
return os;
|
||||
}
|
||||
|
||||
std::ostream &operator<<(std::ostream &os, TessEvaluationType value)
|
||||
{
|
||||
switch (value)
|
||||
{
|
||||
case TessEvaluationType::Triangles:
|
||||
os << "GL_TRIANGLES";
|
||||
break;
|
||||
case TessEvaluationType::Quads:
|
||||
os << "GL_QUADS";
|
||||
break;
|
||||
case TessEvaluationType::Isolines:
|
||||
os << "GL_ISOLINES";
|
||||
break;
|
||||
case TessEvaluationType::EqualSpacing:
|
||||
os << "GL_EQUAL";
|
||||
break;
|
||||
case TessEvaluationType::FractionalEvenSpacing:
|
||||
os << "GL_FRACTIONAL_EVEN";
|
||||
break;
|
||||
case TessEvaluationType::FractionalOddSpacing:
|
||||
os << "GL_FRACTIONAL_ODD";
|
||||
break;
|
||||
case TessEvaluationType::Cw:
|
||||
os << "GL_CW";
|
||||
break;
|
||||
case TessEvaluationType::Ccw:
|
||||
os << "GL_CCW";
|
||||
break;
|
||||
case TessEvaluationType::PointMode:
|
||||
os << "GL_TESS_GEN_POINT_MODE";
|
||||
break;
|
||||
default:
|
||||
os << "GL_INVALID_ENUM";
|
||||
break;
|
||||
}
|
||||
return os;
|
||||
}
|
||||
|
||||
const char *ShaderTypeToString(ShaderType shaderType)
|
||||
{
|
||||
constexpr ShaderMap<const char *> kShaderTypeNameMap = {
|
||||
{ShaderType::Vertex, "Vertex"},
|
||||
{ShaderType::TessControl, "Tessellation control"},
|
||||
{ShaderType::TessEvaluation, "Tessellation evaluation"},
|
||||
{ShaderType::Geometry, "Geometry"},
|
||||
{ShaderType::Fragment, "Fragment"},
|
||||
{ShaderType::Compute, "Compute"}};
|
||||
return kShaderTypeNameMap[shaderType];
|
||||
}
|
||||
} // namespace gl
|
||||
|
||||
namespace egl
|
||||
|
@ -611,4 +520,5 @@ gl::TextureType EGLTextureTargetToTextureType(EGLenum eglTarget)
|
|||
return gl::TextureType::InvalidEnum;
|
||||
}
|
||||
}
|
||||
|
||||
} // namespace egl_gl
|
||||
|
|
|
@ -58,11 +58,11 @@ class EnumIterator final
|
|||
UnderlyingType mValue;
|
||||
};
|
||||
|
||||
template <typename E, size_t MaxSize = EnumSize<E>()>
|
||||
template <typename E>
|
||||
struct AllEnums
|
||||
{
|
||||
EnumIterator<E> begin() const { return {static_cast<E>(0)}; }
|
||||
EnumIterator<E> end() const { return {static_cast<E>(MaxSize)}; }
|
||||
EnumIterator<E> end() const { return {E::InvalidEnum}; }
|
||||
};
|
||||
|
||||
// PackedEnumMap<E, T> is like an std::array<T, E::EnumCount> but is indexed with enum values. It
|
||||
|
@ -156,16 +156,6 @@ class PackedEnumMap
|
|||
bool operator==(const PackedEnumMap &rhs) const { return mPrivateData == rhs.mPrivateData; }
|
||||
bool operator!=(const PackedEnumMap &rhs) const { return mPrivateData != rhs.mPrivateData; }
|
||||
|
||||
template <typename SubT = T>
|
||||
typename std::enable_if<std::is_integral<SubT>::value>::type operator+=(
|
||||
const PackedEnumMap<E, SubT, MaxSize> &rhs)
|
||||
{
|
||||
for (E e : AllEnums<E, MaxSize>())
|
||||
{
|
||||
at(e) += rhs[e];
|
||||
}
|
||||
}
|
||||
|
||||
private:
|
||||
Storage mPrivateData;
|
||||
};
|
||||
|
@ -197,8 +187,15 @@ struct AllCubeFaceTextureTargets
|
|||
angle::EnumIterator<TextureTarget> end() const { return kAfterCubeMapTextureTargetMax; }
|
||||
};
|
||||
|
||||
constexpr std::array<ShaderType, 2> kAllGLES2ShaderTypes = {ShaderType::Vertex,
|
||||
ShaderType::Fragment};
|
||||
constexpr ShaderType kGLES2ShaderTypeMin = ShaderType::Vertex;
|
||||
constexpr ShaderType kGLES2ShaderTypeMax = ShaderType::Fragment;
|
||||
constexpr ShaderType kAfterGLES2ShaderTypeMax =
|
||||
static_cast<ShaderType>(static_cast<uint8_t>(kGLES2ShaderTypeMax) + 1);
|
||||
struct AllGLES2ShaderTypes
|
||||
{
|
||||
angle::EnumIterator<ShaderType> begin() const { return kGLES2ShaderTypeMin; }
|
||||
angle::EnumIterator<ShaderType> end() const { return kAfterGLES2ShaderTypeMax; }
|
||||
};
|
||||
|
||||
constexpr ShaderType kShaderTypeMin = ShaderType::Vertex;
|
||||
constexpr ShaderType kShaderTypeMax = ShaderType::Compute;
|
||||
|
@ -213,8 +210,7 @@ struct AllShaderTypes
|
|||
constexpr size_t kGraphicsShaderCount = static_cast<size_t>(ShaderType::EnumCount) - 1u;
|
||||
// Arrange the shader types in the order of rendering pipeline
|
||||
constexpr std::array<ShaderType, kGraphicsShaderCount> kAllGraphicsShaderTypes = {
|
||||
ShaderType::Vertex, ShaderType::TessControl, ShaderType::TessEvaluation, ShaderType::Geometry,
|
||||
ShaderType::Fragment};
|
||||
ShaderType::Vertex, ShaderType::Geometry, ShaderType::Fragment};
|
||||
|
||||
using ShaderBitSet = angle::PackedEnumBitSet<ShaderType, uint8_t>;
|
||||
static_assert(sizeof(ShaderBitSet) == sizeof(uint8_t), "Unexpected size");
|
||||
|
@ -222,10 +218,7 @@ static_assert(sizeof(ShaderBitSet) == sizeof(uint8_t), "Unexpected size");
|
|||
template <typename T>
|
||||
using ShaderMap = angle::PackedEnumMap<ShaderType, T>;
|
||||
|
||||
const char *ShaderTypeToString(ShaderType shaderType);
|
||||
|
||||
TextureType SamplerTypeToTextureType(GLenum samplerType);
|
||||
TextureType ImageTypeToTextureType(GLenum imageType);
|
||||
|
||||
bool IsMultisampled(gl::TextureType type);
|
||||
bool IsArrayTextureType(gl::TextureType type);
|
||||
|
@ -248,10 +241,9 @@ enum class PrimitiveMode : uint8_t
|
|||
LineStripAdjacency = 0xB,
|
||||
TrianglesAdjacency = 0xC,
|
||||
TriangleStripAdjacency = 0xD,
|
||||
Patches = 0xE,
|
||||
|
||||
InvalidEnum = 0xF,
|
||||
EnumCount = 0xF,
|
||||
InvalidEnum = 0xE,
|
||||
EnumCount = 0xE,
|
||||
};
|
||||
|
||||
template <>
|
||||
|
@ -533,84 +525,6 @@ ANGLE_VALIDATE_PACKED_ENUM(VertexAttribType, UnsignedInt1010102, GL_UNSIGNED_INT
|
|||
|
||||
std::ostream &operator<<(std::ostream &os, VertexAttribType value);
|
||||
|
||||
enum class TessEvaluationType
|
||||
{
|
||||
Triangles = 0,
|
||||
Quads = 1,
|
||||
Isolines = 2,
|
||||
EqualSpacing = 3,
|
||||
FractionalEvenSpacing = 4,
|
||||
FractionalOddSpacing = 5,
|
||||
Cw = 6,
|
||||
Ccw = 7,
|
||||
PointMode = 8,
|
||||
InvalidEnum = 9,
|
||||
EnumCount = 9
|
||||
};
|
||||
|
||||
template <>
|
||||
constexpr TessEvaluationType FromGLenum<TessEvaluationType>(GLenum from)
|
||||
{
|
||||
if (from == GL_TRIANGLES)
|
||||
return TessEvaluationType::Triangles;
|
||||
if (from == GL_QUADS)
|
||||
return TessEvaluationType::Quads;
|
||||
if (from == GL_ISOLINES)
|
||||
return TessEvaluationType::Isolines;
|
||||
if (from == GL_EQUAL)
|
||||
return TessEvaluationType::EqualSpacing;
|
||||
if (from == GL_FRACTIONAL_EVEN)
|
||||
return TessEvaluationType::FractionalEvenSpacing;
|
||||
if (from == GL_FRACTIONAL_ODD)
|
||||
return TessEvaluationType::FractionalOddSpacing;
|
||||
if (from == GL_CW)
|
||||
return TessEvaluationType::Cw;
|
||||
if (from == GL_CCW)
|
||||
return TessEvaluationType::Ccw;
|
||||
if (from == GL_TESS_GEN_POINT_MODE)
|
||||
return TessEvaluationType::PointMode;
|
||||
return TessEvaluationType::InvalidEnum;
|
||||
}
|
||||
|
||||
constexpr GLenum ToGLenum(TessEvaluationType from)
|
||||
{
|
||||
switch (from)
|
||||
{
|
||||
case TessEvaluationType::Triangles:
|
||||
return GL_TRIANGLES;
|
||||
case TessEvaluationType::Quads:
|
||||
return GL_QUADS;
|
||||
case TessEvaluationType::Isolines:
|
||||
return GL_ISOLINES;
|
||||
case TessEvaluationType::EqualSpacing:
|
||||
return GL_EQUAL;
|
||||
case TessEvaluationType::FractionalEvenSpacing:
|
||||
return GL_FRACTIONAL_EVEN;
|
||||
case TessEvaluationType::FractionalOddSpacing:
|
||||
return GL_FRACTIONAL_ODD;
|
||||
case TessEvaluationType::Cw:
|
||||
return GL_CW;
|
||||
case TessEvaluationType::Ccw:
|
||||
return GL_CCW;
|
||||
case TessEvaluationType::PointMode:
|
||||
return GL_TESS_GEN_POINT_MODE;
|
||||
default:
|
||||
return GL_INVALID_ENUM;
|
||||
}
|
||||
}
|
||||
|
||||
ANGLE_VALIDATE_PACKED_ENUM(TessEvaluationType, Triangles, GL_TRIANGLES);
|
||||
ANGLE_VALIDATE_PACKED_ENUM(TessEvaluationType, Quads, GL_QUADS);
|
||||
ANGLE_VALIDATE_PACKED_ENUM(TessEvaluationType, Isolines, GL_ISOLINES);
|
||||
ANGLE_VALIDATE_PACKED_ENUM(TessEvaluationType, EqualSpacing, GL_EQUAL);
|
||||
ANGLE_VALIDATE_PACKED_ENUM(TessEvaluationType, FractionalEvenSpacing, GL_FRACTIONAL_EVEN);
|
||||
ANGLE_VALIDATE_PACKED_ENUM(TessEvaluationType, FractionalOddSpacing, GL_FRACTIONAL_ODD);
|
||||
ANGLE_VALIDATE_PACKED_ENUM(TessEvaluationType, Cw, GL_CW);
|
||||
ANGLE_VALIDATE_PACKED_ENUM(TessEvaluationType, Ccw, GL_CCW);
|
||||
ANGLE_VALIDATE_PACKED_ENUM(TessEvaluationType, PointMode, GL_TESS_GEN_POINT_MODE);
|
||||
|
||||
std::ostream &operator<<(std::ostream &os, TessEvaluationType value);
|
||||
|
||||
// Typesafe object handles.
|
||||
|
||||
template <typename T>
|
||||
|
@ -743,7 +657,7 @@ inline GLuint GetIDValue(ResourceIDType id)
|
|||
|
||||
// First case: handling packed enums.
|
||||
template <typename EnumT, typename FromT>
|
||||
typename std::enable_if<std::is_enum<EnumT>::value, EnumT>::type PackParam(FromT from)
|
||||
typename std::enable_if<std::is_enum<EnumT>::value, EnumT>::type FromGL(FromT from)
|
||||
{
|
||||
return FromGLenum<EnumT>(from);
|
||||
}
|
||||
|
@ -751,7 +665,7 @@ typename std::enable_if<std::is_enum<EnumT>::value, EnumT>::type PackParam(FromT
|
|||
// Second case: handling non-pointer resource ids.
|
||||
template <typename EnumT, typename FromT>
|
||||
typename std::enable_if<!std::is_pointer<FromT>::value && !std::is_enum<EnumT>::value, EnumT>::type
|
||||
PackParam(FromT from)
|
||||
FromGL(FromT from)
|
||||
{
|
||||
return {from};
|
||||
}
|
||||
|
@ -759,16 +673,8 @@ PackParam(FromT from)
|
|||
// Third case: handling pointer resource ids.
|
||||
template <typename EnumT, typename FromT>
|
||||
typename std::enable_if<std::is_pointer<FromT>::value && !std::is_enum<EnumT>::value, EnumT>::type
|
||||
PackParam(FromT from)
|
||||
FromGL(FromT from)
|
||||
{
|
||||
static_assert(sizeof(typename std::remove_pointer<EnumT>::type) ==
|
||||
sizeof(typename std::remove_pointer<FromT>::type),
|
||||
"Types have different sizes");
|
||||
static_assert(
|
||||
std::is_same<
|
||||
decltype(std::remove_pointer<EnumT>::type::value),
|
||||
typename std::remove_const<typename std::remove_pointer<FromT>::type>::type>::value,
|
||||
"Data types are different");
|
||||
return reinterpret_cast<EnumT>(from);
|
||||
}
|
||||
|
||||
|
@ -776,11 +682,6 @@ struct UniformLocation
|
|||
{
|
||||
int value;
|
||||
};
|
||||
|
||||
struct UniformBlockIndex
|
||||
{
|
||||
uint32_t value;
|
||||
};
|
||||
} // namespace gl
|
||||
|
||||
namespace egl
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
// GENERATED FILE - DO NOT EDIT.
|
||||
// Generated by gen_packed_gl_enums.py using data from packed_gl_enums.json.
|
||||
//
|
||||
// Copyright 2017 The ANGLE Project Authors. All rights reserved.
|
||||
// Copyright 2020 The ANGLE Project Authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
//
|
||||
|
@ -1392,14 +1392,10 @@ ShaderType FromGLenum<ShaderType>(GLenum from)
|
|||
{
|
||||
case GL_VERTEX_SHADER:
|
||||
return ShaderType::Vertex;
|
||||
case GL_TESS_CONTROL_SHADER_EXT:
|
||||
return ShaderType::TessControl;
|
||||
case GL_TESS_EVALUATION_SHADER_EXT:
|
||||
return ShaderType::TessEvaluation;
|
||||
case GL_GEOMETRY_SHADER_EXT:
|
||||
return ShaderType::Geometry;
|
||||
case GL_FRAGMENT_SHADER:
|
||||
return ShaderType::Fragment;
|
||||
case GL_GEOMETRY_SHADER_EXT:
|
||||
return ShaderType::Geometry;
|
||||
case GL_COMPUTE_SHADER:
|
||||
return ShaderType::Compute;
|
||||
default:
|
||||
|
@ -1413,14 +1409,10 @@ GLenum ToGLenum(ShaderType from)
|
|||
{
|
||||
case ShaderType::Vertex:
|
||||
return GL_VERTEX_SHADER;
|
||||
case ShaderType::TessControl:
|
||||
return GL_TESS_CONTROL_SHADER_EXT;
|
||||
case ShaderType::TessEvaluation:
|
||||
return GL_TESS_EVALUATION_SHADER_EXT;
|
||||
case ShaderType::Geometry:
|
||||
return GL_GEOMETRY_SHADER_EXT;
|
||||
case ShaderType::Fragment:
|
||||
return GL_FRAGMENT_SHADER;
|
||||
case ShaderType::Geometry:
|
||||
return GL_GEOMETRY_SHADER_EXT;
|
||||
case ShaderType::Compute:
|
||||
return GL_COMPUTE_SHADER;
|
||||
default:
|
||||
|
@ -1436,18 +1428,12 @@ std::ostream &operator<<(std::ostream &os, ShaderType value)
|
|||
case ShaderType::Vertex:
|
||||
os << "GL_VERTEX_SHADER";
|
||||
break;
|
||||
case ShaderType::TessControl:
|
||||
os << "GL_TESS_CONTROL_SHADER_EXT";
|
||||
break;
|
||||
case ShaderType::TessEvaluation:
|
||||
os << "GL_TESS_EVALUATION_SHADER_EXT";
|
||||
case ShaderType::Fragment:
|
||||
os << "GL_FRAGMENT_SHADER";
|
||||
break;
|
||||
case ShaderType::Geometry:
|
||||
os << "GL_GEOMETRY_SHADER_EXT";
|
||||
break;
|
||||
case ShaderType::Fragment:
|
||||
os << "GL_FRAGMENT_SHADER";
|
||||
break;
|
||||
case ShaderType::Compute:
|
||||
os << "GL_COMPUTE_SHADER";
|
||||
break;
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
// GENERATED FILE - DO NOT EDIT.
|
||||
// Generated by gen_packed_gl_enums.py using data from packed_gl_enums.json.
|
||||
//
|
||||
// Copyright 2017 The ANGLE Project Authors. All rights reserved.
|
||||
// Copyright 2020 The ANGLE Project Authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
//
|
||||
|
@ -12,6 +12,8 @@
|
|||
#ifndef COMMON_PACKEDGLENUMS_AUTOGEN_H_
|
||||
#define COMMON_PACKEDGLENUMS_AUTOGEN_H_
|
||||
|
||||
#include <EGL/egl.h>
|
||||
#include <EGL/eglext.h>
|
||||
#include <angle_gl.h>
|
||||
|
||||
#include <cstdint>
|
||||
|
@ -357,15 +359,13 @@ std::ostream &operator<<(std::ostream &os, QueryType value);
|
|||
|
||||
enum class ShaderType : uint8_t
|
||||
{
|
||||
Vertex = 0,
|
||||
TessControl = 1,
|
||||
TessEvaluation = 2,
|
||||
Geometry = 3,
|
||||
Fragment = 4,
|
||||
Compute = 5,
|
||||
Vertex = 0,
|
||||
Fragment = 1,
|
||||
Geometry = 2,
|
||||
Compute = 3,
|
||||
|
||||
InvalidEnum = 6,
|
||||
EnumCount = 6,
|
||||
InvalidEnum = 4,
|
||||
EnumCount = 4,
|
||||
};
|
||||
|
||||
template <>
|
||||
|
|
|
@ -54,7 +54,7 @@ void *AlignedAlloc(size_t size, size_t alignment)
|
|||
|
||||
void AlignedFree(void *ptr)
|
||||
{
|
||||
#if defined(ANGLE_PLATFORM_WINDOWS)
|
||||
#if defined(_MSC_VER)
|
||||
_aligned_free(ptr);
|
||||
#else
|
||||
free(ptr);
|
||||
|
|
|
@ -219,55 +219,6 @@ T1 *offsetPointer(T2 *ptr, int bytes)
|
|||
return reinterpret_cast<T1 *>(reinterpret_cast<intptr_t>(ptr) + bytes);
|
||||
}
|
||||
|
||||
GLenum getPixelFormatInfo(int pixelFormat, bool *isYUV)
|
||||
{
|
||||
*isYUV = false;
|
||||
switch (pixelFormat)
|
||||
{
|
||||
case AHARDWAREBUFFER_FORMAT_R8G8B8A8_UNORM:
|
||||
return GL_RGBA8;
|
||||
case AHARDWAREBUFFER_FORMAT_R8G8B8X8_UNORM:
|
||||
return GL_RGB8;
|
||||
case AHARDWAREBUFFER_FORMAT_R8G8B8_UNORM:
|
||||
return GL_RGB8;
|
||||
case AHARDWAREBUFFER_FORMAT_R5G6B5_UNORM:
|
||||
return GL_RGB565;
|
||||
case AHARDWAREBUFFER_FORMAT_B8G8R8A8_UNORM:
|
||||
return GL_BGRA8_EXT;
|
||||
case AHARDWAREBUFFER_FORMAT_B5G5R5A1_UNORM:
|
||||
return GL_RGB5_A1;
|
||||
case AHARDWAREBUFFER_FORMAT_B4G4R4A4_UNORM:
|
||||
return GL_RGBA4;
|
||||
case AHARDWAREBUFFER_FORMAT_R16G16B16A16_FLOAT:
|
||||
return GL_RGBA16F;
|
||||
case AHARDWAREBUFFER_FORMAT_R10G10B10A2_UNORM:
|
||||
return GL_RGB10_A2;
|
||||
case AHARDWAREBUFFER_FORMAT_BLOB:
|
||||
return GL_NONE;
|
||||
case AHARDWAREBUFFER_FORMAT_D16_UNORM:
|
||||
return GL_DEPTH_COMPONENT16;
|
||||
case AHARDWAREBUFFER_FORMAT_D24_UNORM:
|
||||
return GL_DEPTH_COMPONENT24;
|
||||
case AHARDWAREBUFFER_FORMAT_D24_UNORM_S8_UINT:
|
||||
return GL_DEPTH24_STENCIL8;
|
||||
case AHARDWAREBUFFER_FORMAT_D32_FLOAT:
|
||||
return GL_DEPTH_COMPONENT32F;
|
||||
case AHARDWAREBUFFER_FORMAT_D32_FLOAT_S8_UINT:
|
||||
return GL_DEPTH32F_STENCIL8;
|
||||
case AHARDWAREBUFFER_FORMAT_S8_UINT:
|
||||
return GL_STENCIL_INDEX8;
|
||||
case AHARDWAREBUFFER_FORMAT_Y8Cb8Cr8_420:
|
||||
*isYUV = true;
|
||||
return GL_RGB8;
|
||||
default:
|
||||
// Treat unknown formats as RGB. They are vendor-specific YUV formats that would sample
|
||||
// as RGB.
|
||||
WARN() << "Unknown pixelFormat: " << pixelFormat << ". Treating as RGB8";
|
||||
*isYUV = true;
|
||||
return GL_RGB8;
|
||||
}
|
||||
}
|
||||
|
||||
} // anonymous namespace
|
||||
|
||||
namespace angle
|
||||
|
@ -345,8 +296,48 @@ void GetANativeWindowBufferProperties(const ANativeWindowBuffer *buffer,
|
|||
|
||||
GLenum NativePixelFormatToGLInternalFormat(int pixelFormat)
|
||||
{
|
||||
bool isYuv = false;
|
||||
return getPixelFormatInfo(pixelFormat, &isYuv);
|
||||
switch (pixelFormat)
|
||||
{
|
||||
case AHARDWAREBUFFER_FORMAT_R8G8B8A8_UNORM:
|
||||
return GL_RGBA8;
|
||||
case AHARDWAREBUFFER_FORMAT_R8G8B8X8_UNORM:
|
||||
return GL_RGB8;
|
||||
case AHARDWAREBUFFER_FORMAT_R8G8B8_UNORM:
|
||||
return GL_RGB8;
|
||||
case AHARDWAREBUFFER_FORMAT_R5G6B5_UNORM:
|
||||
return GL_RGB565;
|
||||
case AHARDWAREBUFFER_FORMAT_B8G8R8A8_UNORM:
|
||||
return GL_BGRA8_EXT;
|
||||
case AHARDWAREBUFFER_FORMAT_B5G5R5A1_UNORM:
|
||||
return GL_RGB5_A1;
|
||||
case AHARDWAREBUFFER_FORMAT_B4G4R4A4_UNORM:
|
||||
return GL_RGBA4;
|
||||
case AHARDWAREBUFFER_FORMAT_R16G16B16A16_FLOAT:
|
||||
return GL_RGBA16F;
|
||||
case AHARDWAREBUFFER_FORMAT_R10G10B10A2_UNORM:
|
||||
return GL_RGB10_A2;
|
||||
case AHARDWAREBUFFER_FORMAT_BLOB:
|
||||
return GL_NONE;
|
||||
case AHARDWAREBUFFER_FORMAT_D16_UNORM:
|
||||
return GL_DEPTH_COMPONENT16;
|
||||
case AHARDWAREBUFFER_FORMAT_D24_UNORM:
|
||||
return GL_DEPTH_COMPONENT24;
|
||||
case AHARDWAREBUFFER_FORMAT_D24_UNORM_S8_UINT:
|
||||
return GL_DEPTH24_STENCIL8;
|
||||
case AHARDWAREBUFFER_FORMAT_D32_FLOAT:
|
||||
return GL_DEPTH_COMPONENT32F;
|
||||
case AHARDWAREBUFFER_FORMAT_D32_FLOAT_S8_UINT:
|
||||
return GL_DEPTH32F_STENCIL8;
|
||||
case AHARDWAREBUFFER_FORMAT_S8_UINT:
|
||||
return GL_STENCIL_INDEX8;
|
||||
case AHARDWAREBUFFER_FORMAT_Y8Cb8Cr8_420:
|
||||
return GL_RGB8;
|
||||
default:
|
||||
// Treat unknown formats as RGB. They are vendor-specific YUV formats that would sample
|
||||
// as RGB.
|
||||
WARN() << "Unknown pixelFormat: " << pixelFormat << ". Treating as RGB8";
|
||||
return GL_RGB8;
|
||||
}
|
||||
}
|
||||
|
||||
int GLInternalFormatToNativePixelFormat(GLenum internalFormat)
|
||||
|
@ -389,13 +380,6 @@ int GLInternalFormatToNativePixelFormat(GLenum internalFormat)
|
|||
}
|
||||
}
|
||||
|
||||
bool NativePixelFormatIsYUV(int pixelFormat)
|
||||
{
|
||||
bool isYuv = false;
|
||||
getPixelFormatInfo(pixelFormat, &isYuv);
|
||||
return isYuv;
|
||||
}
|
||||
|
||||
AHardwareBuffer *ANativeWindowBufferToAHardwareBuffer(ANativeWindowBuffer *windowBuffer)
|
||||
{
|
||||
return offsetPointer<AHardwareBuffer>(windowBuffer,
|
||||
|
@ -408,10 +392,5 @@ EGLClientBuffer AHardwareBufferToClientBuffer(const AHardwareBuffer *hardwareBuf
|
|||
kAHardwareBufferToANativeWindowBufferOffset);
|
||||
}
|
||||
|
||||
AHardwareBuffer *ClientBufferToAHardwareBuffer(EGLClientBuffer clientBuffer)
|
||||
{
|
||||
return offsetPointer<AHardwareBuffer>(clientBuffer,
|
||||
-kAHardwareBufferToANativeWindowBufferOffset);
|
||||
}
|
||||
} // namespace android
|
||||
} // namespace angle
|
||||
|
|
|
@ -30,7 +30,6 @@ constexpr std::array<GLenum, 3> kSupportedSizedInternalFormats = {GL_RGBA8, GL_R
|
|||
|
||||
ANativeWindowBuffer *ClientBufferToANativeWindowBuffer(EGLClientBuffer clientBuffer);
|
||||
EGLClientBuffer AHardwareBufferToClientBuffer(const AHardwareBuffer *hardwareBuffer);
|
||||
AHardwareBuffer *ClientBufferToAHardwareBuffer(EGLClientBuffer clientBuffer);
|
||||
|
||||
EGLClientBuffer CreateEGLClientBufferFromAHardwareBuffer(int width,
|
||||
int height,
|
||||
|
@ -46,8 +45,6 @@ void GetANativeWindowBufferProperties(const ANativeWindowBuffer *buffer,
|
|||
GLenum NativePixelFormatToGLInternalFormat(int pixelFormat);
|
||||
int GLInternalFormatToNativePixelFormat(GLenum internalFormat);
|
||||
|
||||
bool NativePixelFormatIsYUV(int pixelFormat);
|
||||
|
||||
AHardwareBuffer *ANativeWindowBufferToAHardwareBuffer(ANativeWindowBuffer *windowBuffer);
|
||||
|
||||
uint64_t GetAHBUsage(int eglNativeBufferUsage);
|
||||
|
|
|
@ -15,10 +15,6 @@
|
|||
# include "absl/container/flat_hash_map.h"
|
||||
#endif // defined(ANGLE_USE_ABSEIL)
|
||||
|
||||
#if defined(ANGLE_WITH_LSAN)
|
||||
# include <sanitizer/lsan_interface.h>
|
||||
#endif // defined(ANGLE_WITH_LSAN)
|
||||
|
||||
#include <climits>
|
||||
#include <cstdarg>
|
||||
#include <cstddef>
|
||||
|
@ -290,10 +286,6 @@ inline bool IsLittleEndian()
|
|||
#define GL_X2_RGB10_UNORM_ANGLEX 0x6AF7
|
||||
#define GL_X2_RGB10_SNORM_ANGLEX 0x6AF8
|
||||
|
||||
// YUV formats
|
||||
#define GL_G8_B8_R8_3PLANE_420_UNORM_ANGLEX 0x6B00
|
||||
#define GL_G8_B8R8_2PLANE_420_UNORM_ANGLEX 0x6B01
|
||||
|
||||
#define ANGLE_CHECK_GL_ALLOC(context, result) \
|
||||
ANGLE_CHECK(context, result, "Failed to allocate host memory", GL_OUT_OF_MEMORY)
|
||||
|
||||
|
@ -304,12 +296,6 @@ inline bool IsLittleEndian()
|
|||
UNREACHABLE(); \
|
||||
ANGLE_CHECK(context, false, "Unreachable Code.", GL_INVALID_OPERATION)
|
||||
|
||||
#if defined(ANGLE_WITH_LSAN)
|
||||
# define ANGLE_SCOPED_DISABLE_LSAN() __lsan::ScopedDisabler lsanDisabler
|
||||
#else
|
||||
# define ANGLE_SCOPED_DISABLE_LSAN()
|
||||
#endif
|
||||
|
||||
// The below inlining code lifted from V8.
|
||||
#if defined(__clang__) || (defined(__GNUC__) && defined(__has_attribute))
|
||||
# define ANGLE_HAS_ATTRIBUTE_ALWAYS_INLINE (__has_attribute(always_inline))
|
||||
|
|
Разница между файлами не показана из-за своего большого размера
Загрузить разницу
|
@ -129,7 +129,7 @@ std::mutex &GetDebugMutex()
|
|||
return *g_debugMutex;
|
||||
}
|
||||
|
||||
ScopedPerfEventHelper::ScopedPerfEventHelper(gl::Context *context, angle::EntryPoint entryPoint)
|
||||
ScopedPerfEventHelper::ScopedPerfEventHelper(gl::Context *context, gl::EntryPoint entryPoint)
|
||||
: mContext(context), mEntryPoint(entryPoint), mFunctionName(nullptr)
|
||||
{}
|
||||
|
||||
|
@ -163,8 +163,8 @@ void ScopedPerfEventHelper::begin(const char *format, ...)
|
|||
LogMessage::LogMessage(const char *file, const char *function, int line, LogSeverity severity)
|
||||
: mFile(file), mFunction(function), mLine(line), mSeverity(severity)
|
||||
{
|
||||
// INFO() and EVENT() do not require additional function(line) info.
|
||||
if (mSeverity > LOG_INFO)
|
||||
// EVENT() does not require additional function(line) info.
|
||||
if (mSeverity != LOG_EVENT)
|
||||
{
|
||||
const char *slash = std::max(strrchr(mFile, '/'), strrchr(mFile, '\\'));
|
||||
mStream << (slash ? (slash + 1) : mFile) << ":" << mLine << " (" << mFunction << "): ";
|
||||
|
@ -179,7 +179,7 @@ LogMessage::~LogMessage()
|
|||
lock = std::unique_lock<std::mutex>(*g_debugMutex);
|
||||
}
|
||||
|
||||
if (DebugAnnotationsInitialized() && (mSeverity > LOG_INFO))
|
||||
if (DebugAnnotationsInitialized() && (mSeverity >= LOG_INFO))
|
||||
{
|
||||
g_debugAnnotator->logMessage(*this);
|
||||
}
|
||||
|
@ -279,7 +279,7 @@ void Trace(LogSeverity severity, const char *message)
|
|||
}
|
||||
#else
|
||||
// Note: we use fprintf because <iostream> includes static initializers.
|
||||
fprintf((severity >= LOG_WARN) ? stderr : stdout, "%s: %s\n", LogSeverityName(severity),
|
||||
fprintf((severity >= LOG_ERR) ? stderr : stdout, "%s: %s\n", LogSeverityName(severity),
|
||||
str.c_str());
|
||||
#endif
|
||||
}
|
||||
|
|
|
@ -20,7 +20,6 @@
|
|||
#include <string>
|
||||
|
||||
#include "common/angleutils.h"
|
||||
#include "common/entry_points_enum_autogen.h"
|
||||
#include "common/platform.h"
|
||||
|
||||
#if !defined(TRACE_OUTPUT_FILE)
|
||||
|
@ -30,19 +29,20 @@
|
|||
namespace gl
|
||||
{
|
||||
class Context;
|
||||
enum class EntryPoint;
|
||||
|
||||
// Pairs a D3D begin event with an end event.
|
||||
class ScopedPerfEventHelper : angle::NonCopyable
|
||||
{
|
||||
public:
|
||||
ScopedPerfEventHelper(Context *context, angle::EntryPoint entryPoint);
|
||||
ScopedPerfEventHelper(gl::Context *context, gl::EntryPoint entryPoint);
|
||||
~ScopedPerfEventHelper();
|
||||
ANGLE_FORMAT_PRINTF(2, 3)
|
||||
void begin(const char *format, ...);
|
||||
|
||||
private:
|
||||
gl::Context *mContext;
|
||||
const angle::EntryPoint mEntryPoint;
|
||||
const gl::EntryPoint mEntryPoint;
|
||||
const char *mFunctionName;
|
||||
};
|
||||
|
||||
|
@ -93,14 +93,14 @@ class DebugAnnotator : angle::NonCopyable
|
|||
DebugAnnotator() {}
|
||||
virtual ~DebugAnnotator() {}
|
||||
virtual void beginEvent(gl::Context *context,
|
||||
angle::EntryPoint entryPoint,
|
||||
gl::EntryPoint entryPoint,
|
||||
const char *eventName,
|
||||
const char *eventMessage) = 0;
|
||||
const char *eventMessage) = 0;
|
||||
virtual void endEvent(gl::Context *context,
|
||||
const char *eventName,
|
||||
angle::EntryPoint entryPoint) = 0;
|
||||
virtual void setMarker(const char *markerName) = 0;
|
||||
virtual bool getStatus() = 0;
|
||||
gl::EntryPoint entryPoint) = 0;
|
||||
virtual void setMarker(const char *markerName) = 0;
|
||||
virtual bool getStatus() = 0;
|
||||
// Log Message Handler that gets passed every log message,
|
||||
// when debug annotations are initialized,
|
||||
// replacing default handling by LogMessage.
|
||||
|
@ -256,31 +256,26 @@ std::ostream &FmtHex(std::ostream &os, T value)
|
|||
// A macro to log a performance event around a scope.
|
||||
#if defined(ANGLE_TRACE_ENABLED)
|
||||
# if defined(_MSC_VER)
|
||||
# define EVENT(context, entryPoint, message, ...) \
|
||||
gl::ScopedPerfEventHelper scopedPerfEventHelper##__LINE__( \
|
||||
context, angle::EntryPoint::entryPoint); \
|
||||
# define EVENT(context, entryPoint, function, message, ...) \
|
||||
gl::ScopedPerfEventHelper scopedPerfEventHelper##__LINE__(context, entryPoint); \
|
||||
do \
|
||||
{ \
|
||||
if (gl::ShouldBeginScopedEvent()) \
|
||||
{ \
|
||||
scopedPerfEventHelper##__LINE__.begin("%s(" message ")", function, \
|
||||
__VA_ARGS__); \
|
||||
} \
|
||||
} while (0)
|
||||
# else
|
||||
# define EVENT(context, entryPoint, function, message, ...) \
|
||||
gl::ScopedPerfEventHelper scopedPerfEventHelper(context, entryPoint); \
|
||||
do \
|
||||
{ \
|
||||
if (gl::ShouldBeginScopedEvent()) \
|
||||
{ \
|
||||
scopedPerfEventHelper##__LINE__.begin( \
|
||||
"%s(" message ")", GetEntryPointName(angle::EntryPoint::entryPoint), \
|
||||
__VA_ARGS__); \
|
||||
scopedPerfEventHelper.begin("%s(" message ")", function, ##__VA_ARGS__); \
|
||||
} \
|
||||
} while (0)
|
||||
# else
|
||||
# define EVENT(context, entryPoint, message, ...) \
|
||||
gl::ScopedPerfEventHelper scopedPerfEventHelper(context, \
|
||||
angle::EntryPoint::entryPoint); \
|
||||
do \
|
||||
{ \
|
||||
if (gl::ShouldBeginScopedEvent()) \
|
||||
{ \
|
||||
scopedPerfEventHelper.begin("%s(" message ")", \
|
||||
GetEntryPointName(angle::EntryPoint::entryPoint), \
|
||||
##__VA_ARGS__); \
|
||||
} \
|
||||
} while (0)
|
||||
# endif // _MSC_VER
|
||||
#else
|
||||
# define EVENT(message, ...) (void(0))
|
||||
|
@ -450,13 +445,4 @@ std::ostream &FmtHex(std::ostream &os, T value)
|
|||
# define ANGLE_REENABLE_WEAK_TEMPLATE_VTABLES_WARNING
|
||||
#endif
|
||||
|
||||
#if defined(__clang__)
|
||||
# define ANGLE_DISABLE_UNUSED_FUNCTION_WARNING \
|
||||
_Pragma("clang diagnostic push") _Pragma("clang diagnostic ignored \"-Wunused-function\"")
|
||||
# define ANGLE_REENABLE_UNUSED_FUNCTION_WARNING _Pragma("clang diagnostic pop")
|
||||
#else
|
||||
# define ANGLE_DISABLE_UNUSED_FUNCTION_WARNING
|
||||
# define ANGLE_REENABLE_UNUSED_FUNCTION_WARNING
|
||||
#endif
|
||||
|
||||
#endif // COMMON_DEBUG_H_
|
||||
|
|
Разница между файлами не показана из-за своего большого размера
Загрузить разницу
Разница между файлами не показана из-за своего большого размера
Загрузить разницу
|
@ -21,11 +21,11 @@ inline std::size_t ComputeGenericHash(const void *key, size_t keySize)
|
|||
|
||||
// We can't support "odd" alignments. ComputeGenericHash requires aligned types
|
||||
ASSERT(keySize % 4 == 0);
|
||||
#if INTPTR_MAX == INT64_MAX
|
||||
#if defined(ANGLE_IS_64_BIT_CPU)
|
||||
return XXH64(key, keySize, kSeed);
|
||||
#else
|
||||
return XXH32(key, keySize, kSeed);
|
||||
#endif // INTPTR_MAX == INT64_MAX
|
||||
#endif // defined(ANGLE_IS_64_BIT_CPU)
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
|
|
|
@ -31,9 +31,6 @@ constexpr int g_sharedexp_bias = 15;
|
|||
// N is the number of mantissa bits per component (9)
|
||||
constexpr int g_sharedexp_mantissabits = 9;
|
||||
|
||||
// number of mantissa bits per component pre-biased
|
||||
constexpr int g_sharedexp_biased_mantissabits = g_sharedexp_bias + g_sharedexp_mantissabits;
|
||||
|
||||
// Emax is the maximum allowed biased exponent value (31)
|
||||
constexpr int g_sharedexp_maxexponent = 31;
|
||||
|
||||
|
@ -54,15 +51,17 @@ unsigned int convertRGBFloatsTo999E5(float red, float green, float blue)
|
|||
const float exp_p =
|
||||
std::max<float>(-g_sharedexp_bias - 1, floor(log(max_c))) + 1 + g_sharedexp_bias;
|
||||
const int max_s = static_cast<int>(
|
||||
floor((max_c / (pow(2.0f, exp_p - g_sharedexp_biased_mantissabits))) + 0.5f));
|
||||
floor((max_c / (pow(2.0f, exp_p - g_sharedexp_bias - g_sharedexp_mantissabits))) + 0.5f));
|
||||
const int exp_s =
|
||||
static_cast<int>((max_s < pow(2.0f, g_sharedexp_mantissabits)) ? exp_p : exp_p + 1);
|
||||
const float pow2_exp = pow(2.0f, static_cast<float>(exp_s) - g_sharedexp_biased_mantissabits);
|
||||
|
||||
RGB9E5Data output;
|
||||
output.R = static_cast<unsigned int>(floor((red_c / pow2_exp) + 0.5f));
|
||||
output.G = static_cast<unsigned int>(floor((green_c / pow2_exp) + 0.5f));
|
||||
output.B = static_cast<unsigned int>(floor((blue_c / pow2_exp) + 0.5f));
|
||||
output.R = static_cast<unsigned int>(
|
||||
floor((red_c / (pow(2.0f, exp_s - g_sharedexp_bias - g_sharedexp_mantissabits))) + 0.5f));
|
||||
output.G = static_cast<unsigned int>(
|
||||
floor((green_c / (pow(2.0f, exp_s - g_sharedexp_bias - g_sharedexp_mantissabits))) + 0.5f));
|
||||
output.B = static_cast<unsigned int>(
|
||||
floor((blue_c / (pow(2.0f, exp_s - g_sharedexp_bias - g_sharedexp_mantissabits))) + 0.5f));
|
||||
output.E = exp_s;
|
||||
|
||||
return bitCast<unsigned int>(output);
|
||||
|
@ -72,12 +71,12 @@ void convert999E5toRGBFloats(unsigned int input, float *red, float *green, float
|
|||
{
|
||||
const RGB9E5Data *inputData = reinterpret_cast<const RGB9E5Data *>(&input);
|
||||
|
||||
const float pow2_exp =
|
||||
pow(2.0f, static_cast<float>(inputData->E) - g_sharedexp_biased_mantissabits);
|
||||
|
||||
*red = inputData->R * pow2_exp;
|
||||
*green = inputData->G * pow2_exp;
|
||||
*blue = inputData->B * pow2_exp;
|
||||
*red =
|
||||
inputData->R * pow(2.0f, (int)inputData->E - g_sharedexp_bias - g_sharedexp_mantissabits);
|
||||
*green =
|
||||
inputData->G * pow(2.0f, (int)inputData->E - g_sharedexp_bias - g_sharedexp_mantissabits);
|
||||
*blue =
|
||||
inputData->B * pow(2.0f, (int)inputData->E - g_sharedexp_bias - g_sharedexp_mantissabits);
|
||||
}
|
||||
|
||||
} // namespace gl
|
||||
|
|
|
@ -1111,7 +1111,7 @@ inline unsigned long ScanForward(uint64_t bits)
|
|||
{
|
||||
ASSERT(bits != 0u);
|
||||
unsigned long firstBitIndex = 0ul;
|
||||
# if INTPTR_MAX == INT64_MAX
|
||||
# if defined(ANGLE_IS_64_BIT_CPU)
|
||||
unsigned char ret = _BitScanForward64(&firstBitIndex, bits);
|
||||
# else
|
||||
unsigned char ret;
|
||||
|
@ -1124,43 +1124,10 @@ inline unsigned long ScanForward(uint64_t bits)
|
|||
{
|
||||
ret = _BitScanForward(&firstBitIndex, static_cast<uint32_t>(bits));
|
||||
}
|
||||
# endif // INTPTR_MAX == INT64_MAX
|
||||
# endif // defined(ANGLE_IS_64_BIT_CPU)
|
||||
ASSERT(ret != 0u);
|
||||
return firstBitIndex;
|
||||
}
|
||||
|
||||
// Return the index of the most significant bit set. Indexing is such that bit 0 is the least
|
||||
// significant bit.
|
||||
inline unsigned long ScanReverse(uint32_t bits)
|
||||
{
|
||||
ASSERT(bits != 0u);
|
||||
unsigned long lastBitIndex = 0ul;
|
||||
unsigned char ret = _BitScanReverse(&lastBitIndex, bits);
|
||||
ASSERT(ret != 0u);
|
||||
return lastBitIndex;
|
||||
}
|
||||
|
||||
inline unsigned long ScanReverse(uint64_t bits)
|
||||
{
|
||||
ASSERT(bits != 0u);
|
||||
unsigned long lastBitIndex = 0ul;
|
||||
# if INTPTR_MAX == INT64_MAX
|
||||
unsigned char ret = _BitScanReverse64(&lastBitIndex, bits);
|
||||
# else
|
||||
unsigned char ret;
|
||||
if (static_cast<uint32_t>(bits >> 32) == 0)
|
||||
{
|
||||
ret = _BitScanReverse(&lastBitIndex, static_cast<uint32_t>(bits));
|
||||
}
|
||||
else
|
||||
{
|
||||
ret = _BitScanReverse(&lastBitIndex, static_cast<uint32_t>(bits >> 32));
|
||||
lastBitIndex += 32ul;
|
||||
}
|
||||
# endif // INTPTR_MAX == INT64_MAX
|
||||
ASSERT(ret != 0u);
|
||||
return lastBitIndex;
|
||||
}
|
||||
#endif // defined(ANGLE_PLATFORM_WINDOWS)
|
||||
|
||||
#if defined(ANGLE_PLATFORM_POSIX)
|
||||
|
@ -1173,37 +1140,13 @@ inline unsigned long ScanForward(uint32_t bits)
|
|||
inline unsigned long ScanForward(uint64_t bits)
|
||||
{
|
||||
ASSERT(bits != 0u);
|
||||
# if INTPTR_MAX == INT64_MAX
|
||||
# if defined(ANGLE_IS_64_BIT_CPU)
|
||||
return static_cast<unsigned long>(__builtin_ctzll(bits));
|
||||
# else
|
||||
return static_cast<unsigned long>(static_cast<uint32_t>(bits) == 0
|
||||
? __builtin_ctz(static_cast<uint32_t>(bits >> 32)) + 32
|
||||
: __builtin_ctz(static_cast<uint32_t>(bits)));
|
||||
# endif // INTPTR_MAX == INT64_MAX
|
||||
}
|
||||
|
||||
inline unsigned long ScanReverse(uint32_t bits)
|
||||
{
|
||||
ASSERT(bits != 0u);
|
||||
return static_cast<unsigned long>(sizeof(uint32_t) * CHAR_BIT - 1 - __builtin_clz(bits));
|
||||
}
|
||||
|
||||
inline unsigned long ScanReverse(uint64_t bits)
|
||||
{
|
||||
ASSERT(bits != 0u);
|
||||
# if INTPTR_MAX == INT64_MAX
|
||||
return static_cast<unsigned long>(sizeof(uint64_t) * CHAR_BIT - 1 - __builtin_clzll(bits));
|
||||
# else
|
||||
if (static_cast<uint32_t>(bits >> 32) == 0)
|
||||
{
|
||||
return sizeof(uint32_t) * CHAR_BIT - 1 - __builtin_clz(static_cast<uint32_t>(bits));
|
||||
}
|
||||
else
|
||||
{
|
||||
return sizeof(uint32_t) * CHAR_BIT - 1 - __builtin_clz(static_cast<uint32_t>(bits >> 32)) +
|
||||
32;
|
||||
}
|
||||
# endif // INTPTR_MAX == INT64_MAX
|
||||
# endif // defined(ANGLE_IS_64_BIT_CPU)
|
||||
}
|
||||
#endif // defined(ANGLE_PLATFORM_POSIX)
|
||||
|
||||
|
@ -1217,14 +1160,21 @@ inline unsigned long ScanForward(uint16_t bits)
|
|||
return ScanForward(static_cast<uint32_t>(bits));
|
||||
}
|
||||
|
||||
inline unsigned long ScanReverse(uint8_t bits)
|
||||
// Return the index of the most significant bit set. Indexing is such that bit 0 is the least
|
||||
// significant bit.
|
||||
inline unsigned long ScanReverse(unsigned long bits)
|
||||
{
|
||||
return ScanReverse(static_cast<uint32_t>(bits));
|
||||
}
|
||||
|
||||
inline unsigned long ScanReverse(uint16_t bits)
|
||||
{
|
||||
return ScanReverse(static_cast<uint32_t>(bits));
|
||||
ASSERT(bits != 0u);
|
||||
#if defined(ANGLE_PLATFORM_WINDOWS)
|
||||
unsigned long lastBitIndex = 0ul;
|
||||
unsigned char ret = _BitScanReverse(&lastBitIndex, bits);
|
||||
ASSERT(ret != 0u);
|
||||
return lastBitIndex;
|
||||
#elif defined(ANGLE_PLATFORM_POSIX)
|
||||
return static_cast<unsigned long>(sizeof(unsigned long) * CHAR_BIT - 1 - __builtin_clzl(bits));
|
||||
#else
|
||||
# error Please implement bit-scan-reverse for your platform!
|
||||
#endif
|
||||
}
|
||||
|
||||
// Returns -1 on 0, otherwise the index of the least significant 1 bit as in GLSL.
|
||||
|
|
|
@ -82,16 +82,8 @@
|
|||
# endif
|
||||
# endif
|
||||
|
||||
// Macros 'near', 'far', 'NEAR' and 'FAR' are defined by 'shared/minwindef.h' in the Windows SDK.
|
||||
// Macros 'near' and 'far' are empty. They are not used by other Windows headers and are undefined
|
||||
// here to avoid identifier conflicts. Macros 'NEAR' and 'FAR' contain 'near' and 'far'. They are
|
||||
// used by other Windows headers and are cleared here to avoid compilation errors.
|
||||
# undef near
|
||||
# undef far
|
||||
# undef NEAR
|
||||
# undef FAR
|
||||
# define NEAR
|
||||
# define FAR
|
||||
#endif
|
||||
|
||||
#if defined(_MSC_VER) && !defined(_M_ARM) && !defined(_M_ARM64)
|
||||
|
|
|
@ -1,120 +0,0 @@
|
|||
//
|
||||
// Copyright 2021 The ANGLE Project Authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
//
|
||||
// spirv_types.h:
|
||||
// Strong types for SPIR-V Ids to prevent mistakes when using the builder and parser APIs.
|
||||
//
|
||||
|
||||
#ifndef COMMON_SPIRV_TYPES_H_
|
||||
#define COMMON_SPIRV_TYPES_H_
|
||||
|
||||
#include "common/FastVector.h"
|
||||
|
||||
#include <vector>
|
||||
|
||||
namespace angle
|
||||
{
|
||||
namespace spirv
|
||||
{
|
||||
template <typename Helper>
|
||||
class BoxedUint32
|
||||
{
|
||||
public:
|
||||
BoxedUint32() : mValue{0} {}
|
||||
explicit BoxedUint32(uint32_t value) : mValue{value} {}
|
||||
template <typename T>
|
||||
T as() const
|
||||
{
|
||||
return T{mValue};
|
||||
}
|
||||
BoxedUint32(const BoxedUint32 &other) = default;
|
||||
BoxedUint32 &operator=(const BoxedUint32 &other) = default;
|
||||
operator uint32_t() const { return mValue.value; }
|
||||
bool operator==(const BoxedUint32 &other) const { return mValue.value == other.mValue.value; }
|
||||
// Applicable to ids, which cannot be 0.
|
||||
bool valid() const { return static_cast<bool>(mValue.value); }
|
||||
|
||||
private:
|
||||
Helper mValue;
|
||||
};
|
||||
|
||||
struct IdRefHelper
|
||||
{
|
||||
uint32_t value;
|
||||
};
|
||||
struct LiteralIntegerHelper
|
||||
{
|
||||
uint32_t value;
|
||||
};
|
||||
|
||||
using IdRef = BoxedUint32<IdRefHelper>;
|
||||
|
||||
template <>
|
||||
inline BoxedUint32<IdRefHelper>::operator uint32_t() const
|
||||
{
|
||||
ASSERT(valid());
|
||||
return mValue.value;
|
||||
}
|
||||
|
||||
// IdResult, IdResultType, IdMemorySemantics and IdScope are all translated as IdRef. This makes
|
||||
// the type verification weaker, but stops the API from becoming tediously verbose.
|
||||
using IdResult = IdRef;
|
||||
using IdResultType = IdRef;
|
||||
using IdMemorySemantics = IdRef;
|
||||
using IdScope = IdRef;
|
||||
using LiteralInteger = BoxedUint32<LiteralIntegerHelper>;
|
||||
using LiteralString = const char *;
|
||||
// Note: In ANGLE's use cases, all literals fit in 32 bits.
|
||||
using LiteralContextDependentNumber = LiteralInteger;
|
||||
// TODO(syoussefi): To be made stronger when generating SPIR-V from the translator.
|
||||
// http://anglebug.com/4889
|
||||
using LiteralExtInstInteger = LiteralInteger;
|
||||
|
||||
struct PairLiteralIntegerIdRef
|
||||
{
|
||||
LiteralInteger literal;
|
||||
IdRef id;
|
||||
};
|
||||
|
||||
struct PairIdRefLiteralInteger
|
||||
{
|
||||
IdRef id;
|
||||
LiteralInteger literal;
|
||||
};
|
||||
|
||||
struct PairIdRefIdRef
|
||||
{
|
||||
IdRef id1;
|
||||
IdRef id2;
|
||||
};
|
||||
|
||||
// Some instructions need 4 components. The drivers uniform struct in ANGLE has 8 fields. A value
|
||||
// of 8 means almost no instruction would end up making dynamic allocations. Notable exceptions are
|
||||
// user-defined structs/blocks and OpEntryPoint.
|
||||
constexpr size_t kFastVectorSize = 8;
|
||||
|
||||
template <typename T>
|
||||
using FastVectorHelper = angle::FastVector<T, kFastVectorSize>;
|
||||
|
||||
using IdRefList = FastVectorHelper<IdRef>;
|
||||
using LiteralIntegerList = FastVectorHelper<LiteralInteger>;
|
||||
using PairLiteralIntegerIdRefList = FastVectorHelper<PairLiteralIntegerIdRef>;
|
||||
using PairIdRefLiteralIntegerList = FastVectorHelper<PairIdRefLiteralInteger>;
|
||||
using PairIdRefIdRefList = FastVectorHelper<PairIdRefIdRef>;
|
||||
|
||||
// Id 0 is invalid in SPIR-V.
|
||||
constexpr uint32_t kMinValidId = 1;
|
||||
|
||||
// The SPIR-V blob is a sequence of uint32_t's
|
||||
using Blob = std::vector<uint32_t>;
|
||||
|
||||
// Returns whether SPIR-V is valid. Useful for ASSERTs. Automatically generates a warning if
|
||||
// SPIR-V is not valid.
|
||||
bool Validate(const Blob &blob);
|
||||
|
||||
} // namespace spirv
|
||||
} // namespace angle
|
||||
|
||||
#endif // COMMON_SPIRV_TYPES_H_
|
|
@ -251,45 +251,4 @@ std::vector<std::string> GetCachedStringsFromEnvironmentVarOrAndroidProperty(
|
|||
std::string environment = GetEnvironmentVarOrAndroidProperty(varName, propertyName);
|
||||
return SplitString(environment, separator, TRIM_WHITESPACE, SPLIT_WANT_NONEMPTY);
|
||||
}
|
||||
|
||||
// reference name can have *.
|
||||
bool NamesMatchWithWildcard(const char *ref, const char *testName)
|
||||
{
|
||||
// Find the first * in ref.
|
||||
const char *firstWildcard = strchr(ref, '*');
|
||||
|
||||
// If there are no wildcards, match the strings precisely.
|
||||
if (firstWildcard == nullptr)
|
||||
{
|
||||
return strcmp(ref, testName) == 0;
|
||||
}
|
||||
|
||||
// Otherwise, match up to the wildcard first.
|
||||
size_t preWildcardLen = firstWildcard - ref;
|
||||
if (strncmp(ref, testName, preWildcardLen) != 0)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
const char *postWildcardRef = ref + preWildcardLen + 1;
|
||||
|
||||
// As a small optimization, if the wildcard is the last character in ref, accept the match
|
||||
// already.
|
||||
if (postWildcardRef[0] == '\0')
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
// Try to match the wildcard with a number of characters.
|
||||
for (size_t matchSize = 0; testName[matchSize] != '\0'; ++matchSize)
|
||||
{
|
||||
if (NamesMatchWithWildcard(postWildcardRef, testName + matchSize))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
} // namespace angle
|
||||
|
|
|
@ -105,8 +105,6 @@ std::vector<std::string> GetCachedStringsFromEnvironmentVarOrAndroidProperty(
|
|||
const char *propertyName,
|
||||
const char *separator);
|
||||
|
||||
// reference name can have *.
|
||||
bool NamesMatchWithWildcard(const char *ref, const char *testName);
|
||||
} // namespace angle
|
||||
|
||||
#endif // LIBANGLE_STRING_UTILS_H_
|
||||
|
|
|
@ -10,10 +10,6 @@
|
|||
|
||||
#include <stdlib.h>
|
||||
|
||||
#if defined(ANGLE_PLATFORM_ANDROID)
|
||||
# include <sys/system_properties.h>
|
||||
#endif
|
||||
|
||||
namespace angle
|
||||
{
|
||||
std::string GetExecutableName()
|
||||
|
@ -52,24 +48,33 @@ std::string GetEnvironmentVarOrAndroidProperty(const char *variableName, const c
|
|||
std::string GetEnvironmentVarOrUnCachedAndroidProperty(const char *variableName,
|
||||
const char *propertyName)
|
||||
{
|
||||
#if defined(ANGLE_PLATFORM_ANDROID) && __ANDROID_API__ >= 26
|
||||
std::string propertyValue;
|
||||
#if defined(ANGLE_PLATFORM_ANDROID) && __ANDROID_API__ >= 21
|
||||
std::string sanitizedPropertyName = propertyName;
|
||||
sanitizedPropertyName.erase(
|
||||
std::remove(sanitizedPropertyName.begin(), sanitizedPropertyName.end(), '\''),
|
||||
sanitizedPropertyName.end());
|
||||
|
||||
const prop_info *propertyInfo = __system_property_find(propertyName);
|
||||
if (propertyInfo != nullptr)
|
||||
std::string command("getprop '");
|
||||
command += sanitizedPropertyName;
|
||||
command += "'";
|
||||
|
||||
// Run the command and open a I/O stream to read the value
|
||||
constexpr int kStreamSize = 64;
|
||||
char stream[kStreamSize] = {};
|
||||
FILE *pipe = popen(command.c_str(), "r");
|
||||
if (pipe != nullptr)
|
||||
{
|
||||
__system_property_read_callback(
|
||||
propertyInfo,
|
||||
[](void *cookie, const char *, const char *value, unsigned) {
|
||||
auto propertyValue = reinterpret_cast<std::string *>(cookie);
|
||||
*propertyValue = value;
|
||||
},
|
||||
&propertyValue);
|
||||
fgets(stream, kStreamSize, pipe);
|
||||
pclose(pipe);
|
||||
}
|
||||
|
||||
// Right strip white space
|
||||
std::string value(stream);
|
||||
value.erase(value.find_last_not_of(" \n\r\t") + 1);
|
||||
|
||||
// Set the environment variable with the value.
|
||||
SetEnvironmentVar(variableName, propertyValue.c_str());
|
||||
return propertyValue;
|
||||
SetEnvironmentVar(variableName, value.c_str());
|
||||
return value;
|
||||
#endif // ANGLE_PLATFORM_ANDROID
|
||||
// Return the environment variable's value.
|
||||
return GetEnvironmentVar(variableName);
|
||||
|
|
|
@ -21,8 +21,44 @@
|
|||
|
||||
namespace angle
|
||||
{
|
||||
std::string GetExecutablePath()
|
||||
{
|
||||
std::string result;
|
||||
|
||||
uint32_t size = 0;
|
||||
_NSGetExecutablePath(nullptr, &size);
|
||||
|
||||
std::vector<char> buffer;
|
||||
buffer.resize(size + 1);
|
||||
|
||||
_NSGetExecutablePath(buffer.data(), &size);
|
||||
buffer[size] = '\0';
|
||||
|
||||
if (!strrchr(buffer.data(), '/'))
|
||||
{
|
||||
return "";
|
||||
}
|
||||
return buffer.data();
|
||||
}
|
||||
|
||||
std::string GetExecutableDirectory()
|
||||
{
|
||||
std::string executablePath = GetExecutablePath();
|
||||
size_t lastPathSepLoc = executablePath.find_last_of("/");
|
||||
return (lastPathSepLoc != std::string::npos) ? executablePath.substr(0, lastPathSepLoc) : "";
|
||||
}
|
||||
|
||||
const char *GetSharedLibraryExtension()
|
||||
{
|
||||
return "dylib";
|
||||
}
|
||||
|
||||
double GetCurrentTime()
|
||||
{
|
||||
mach_timebase_info_data_t timebaseInfo;
|
||||
mach_timebase_info(&timebaseInfo);
|
||||
|
||||
double secondCoeff = timebaseInfo.numer * 1e-9 / timebaseInfo.denom;
|
||||
return secondCoeff * mach_absolute_time();
|
||||
}
|
||||
} // namespace angle
|
||||
|
|
|
@ -103,19 +103,10 @@ Library *OpenSharedLibrary(const char *libraryName, SearchType searchType)
|
|||
std::string directory;
|
||||
if (searchType == SearchType::ApplicationDir)
|
||||
{
|
||||
#if ANGLE_PLATFORM_IOS
|
||||
// On iOS, shared libraries must be loaded from within the app bundle.
|
||||
directory = GetExecutableDirectory() + "/Frameworks/";
|
||||
#else
|
||||
directory = GetHelperExecutableDir();
|
||||
#endif
|
||||
}
|
||||
|
||||
std::string fullPath = directory + libraryName + "." + GetSharedLibraryExtension();
|
||||
#if ANGLE_PLATFORM_IOS
|
||||
// On iOS, dlopen needs a suffix on the framework name to work.
|
||||
fullPath = fullPath + "/" + libraryName;
|
||||
#endif
|
||||
return new PosixLibrary(fullPath);
|
||||
}
|
||||
|
||||
|
|
|
@ -65,7 +65,6 @@ class Win32Library : public Library
|
|||
{
|
||||
if (!mModule)
|
||||
{
|
||||
fprintf(stderr, "Module was not loaded\n");
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
// GENERATED FILE - DO NOT EDIT.
|
||||
// Generated by gen_uniform_type_table.py.
|
||||
//
|
||||
// Copyright 2017 The ANGLE Project Authors. All rights reserved.
|
||||
// Copyright 2020 The ANGLE Project Authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
//
|
||||
|
@ -18,191 +18,202 @@ namespace gl
|
|||
|
||||
namespace
|
||||
{
|
||||
constexpr std::array<UniformTypeInfo, 77> kInfoTable = {
|
||||
constexpr std::array<UniformTypeInfo, 76> kInfoTable = {
|
||||
{{GL_NONE, GL_NONE, GL_NONE, GL_NONE, GL_NONE, SamplerFormat::InvalidEnum, 0, 0, 0, 0, 0 * 0,
|
||||
0 * 0, false, false, false},
|
||||
0 * 0, false, false, false, ""},
|
||||
{GL_BOOL, GL_BOOL, GL_NONE, GL_NONE, GL_NONE, SamplerFormat::InvalidEnum, 1, 1, 1,
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, false, false, false},
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, false, false, false, ""},
|
||||
{GL_BOOL_VEC2, GL_BOOL, GL_NONE, GL_NONE, GL_BOOL_VEC2, SamplerFormat::InvalidEnum, 1, 2, 2,
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 2, false, false, false},
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 2, false, false, false, ""},
|
||||
{GL_BOOL_VEC3, GL_BOOL, GL_NONE, GL_NONE, GL_BOOL_VEC3, SamplerFormat::InvalidEnum, 1, 3, 3,
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 3, false, false, false},
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 3, false, false, false, ""},
|
||||
{GL_BOOL_VEC4, GL_BOOL, GL_NONE, GL_NONE, GL_BOOL_VEC4, SamplerFormat::InvalidEnum, 1, 4, 4,
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 4, false, false, false},
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 4, false, false, false, ""},
|
||||
{GL_FLOAT, GL_FLOAT, GL_NONE, GL_NONE, GL_BOOL, SamplerFormat::InvalidEnum, 1, 1, 1,
|
||||
sizeof(GLfloat), sizeof(GLfloat) * 4, sizeof(GLfloat) * 1, false, false, false},
|
||||
sizeof(GLfloat), sizeof(GLfloat) * 4, sizeof(GLfloat) * 1, false, false, false, ""},
|
||||
{GL_FLOAT_MAT2, GL_FLOAT, GL_NONE, GL_FLOAT_MAT2, GL_NONE, SamplerFormat::InvalidEnum, 2, 2, 4,
|
||||
sizeof(GLfloat), sizeof(GLfloat) * 8, sizeof(GLfloat) * 4, false, true, false},
|
||||
sizeof(GLfloat), sizeof(GLfloat) * 8, sizeof(GLfloat) * 4, false, true, false, ""},
|
||||
{GL_FLOAT_MAT2x3, GL_FLOAT, GL_NONE, GL_FLOAT_MAT3x2, GL_NONE, SamplerFormat::InvalidEnum, 3,
|
||||
2, 6, sizeof(GLfloat), sizeof(GLfloat) * 12, sizeof(GLfloat) * 6, false, true, false},
|
||||
2, 6, sizeof(GLfloat), sizeof(GLfloat) * 12, sizeof(GLfloat) * 6, false, true, false, ""},
|
||||
{GL_FLOAT_MAT2x4, GL_FLOAT, GL_NONE, GL_FLOAT_MAT4x2, GL_NONE, SamplerFormat::InvalidEnum, 4,
|
||||
2, 8, sizeof(GLfloat), sizeof(GLfloat) * 16, sizeof(GLfloat) * 8, false, true, false},
|
||||
2, 8, sizeof(GLfloat), sizeof(GLfloat) * 16, sizeof(GLfloat) * 8, false, true, false, ""},
|
||||
{GL_FLOAT_MAT3, GL_FLOAT, GL_NONE, GL_FLOAT_MAT3, GL_NONE, SamplerFormat::InvalidEnum, 3, 3, 9,
|
||||
sizeof(GLfloat), sizeof(GLfloat) * 12, sizeof(GLfloat) * 9, false, true, false},
|
||||
sizeof(GLfloat), sizeof(GLfloat) * 12, sizeof(GLfloat) * 9, false, true, false, ""},
|
||||
{GL_FLOAT_MAT3x2, GL_FLOAT, GL_NONE, GL_FLOAT_MAT2x3, GL_NONE, SamplerFormat::InvalidEnum, 2,
|
||||
3, 6, sizeof(GLfloat), sizeof(GLfloat) * 8, sizeof(GLfloat) * 6, false, true, false},
|
||||
3, 6, sizeof(GLfloat), sizeof(GLfloat) * 8, sizeof(GLfloat) * 6, false, true, false, ""},
|
||||
{GL_FLOAT_MAT3x4, GL_FLOAT, GL_NONE, GL_FLOAT_MAT4x3, GL_NONE, SamplerFormat::InvalidEnum, 4,
|
||||
3, 12, sizeof(GLfloat), sizeof(GLfloat) * 16, sizeof(GLfloat) * 12, false, true, false},
|
||||
3, 12, sizeof(GLfloat), sizeof(GLfloat) * 16, sizeof(GLfloat) * 12, false, true, false, ""},
|
||||
{GL_FLOAT_MAT4, GL_FLOAT, GL_NONE, GL_FLOAT_MAT4, GL_NONE, SamplerFormat::InvalidEnum, 4, 4,
|
||||
16, sizeof(GLfloat), sizeof(GLfloat) * 16, sizeof(GLfloat) * 16, false, true, false},
|
||||
16, sizeof(GLfloat), sizeof(GLfloat) * 16, sizeof(GLfloat) * 16, false, true, false, ""},
|
||||
{GL_FLOAT_MAT4x2, GL_FLOAT, GL_NONE, GL_FLOAT_MAT2x4, GL_NONE, SamplerFormat::InvalidEnum, 2,
|
||||
4, 8, sizeof(GLfloat), sizeof(GLfloat) * 8, sizeof(GLfloat) * 8, false, true, false},
|
||||
4, 8, sizeof(GLfloat), sizeof(GLfloat) * 8, sizeof(GLfloat) * 8, false, true, false, ""},
|
||||
{GL_FLOAT_MAT4x3, GL_FLOAT, GL_NONE, GL_FLOAT_MAT3x4, GL_NONE, SamplerFormat::InvalidEnum, 3,
|
||||
4, 12, sizeof(GLfloat), sizeof(GLfloat) * 12, sizeof(GLfloat) * 12, false, true, false},
|
||||
4, 12, sizeof(GLfloat), sizeof(GLfloat) * 12, sizeof(GLfloat) * 12, false, true, false, ""},
|
||||
{GL_FLOAT_VEC2, GL_FLOAT, GL_NONE, GL_NONE, GL_BOOL_VEC2, SamplerFormat::InvalidEnum, 1, 2, 2,
|
||||
sizeof(GLfloat), sizeof(GLfloat) * 4, sizeof(GLfloat) * 2, false, false, false},
|
||||
sizeof(GLfloat), sizeof(GLfloat) * 4, sizeof(GLfloat) * 2, false, false, false, ""},
|
||||
{GL_FLOAT_VEC3, GL_FLOAT, GL_NONE, GL_NONE, GL_BOOL_VEC3, SamplerFormat::InvalidEnum, 1, 3, 3,
|
||||
sizeof(GLfloat), sizeof(GLfloat) * 4, sizeof(GLfloat) * 3, false, false, false},
|
||||
sizeof(GLfloat), sizeof(GLfloat) * 4, sizeof(GLfloat) * 3, false, false, false, ""},
|
||||
{GL_FLOAT_VEC4, GL_FLOAT, GL_NONE, GL_NONE, GL_BOOL_VEC4, SamplerFormat::InvalidEnum, 1, 4, 4,
|
||||
sizeof(GLfloat), sizeof(GLfloat) * 4, sizeof(GLfloat) * 4, false, false, false},
|
||||
sizeof(GLfloat), sizeof(GLfloat) * 4, sizeof(GLfloat) * 4, false, false, false, ""},
|
||||
{GL_IMAGE_2D, GL_INT, GL_TEXTURE_2D, GL_NONE, GL_NONE, SamplerFormat::InvalidEnum, 1, 1, 1,
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, false, false, true},
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, false, false, true, "intBitsToFloat"},
|
||||
{GL_IMAGE_2D_ARRAY, GL_INT, GL_TEXTURE_2D_ARRAY, GL_NONE, GL_NONE, SamplerFormat::InvalidEnum,
|
||||
1, 1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, false, false, true},
|
||||
1, 1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, false, false, true,
|
||||
"intBitsToFloat"},
|
||||
{GL_IMAGE_3D, GL_INT, GL_TEXTURE_3D, GL_NONE, GL_NONE, SamplerFormat::InvalidEnum, 1, 1, 1,
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, false, false, true},
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, false, false, true, "intBitsToFloat"},
|
||||
{GL_IMAGE_CUBE, GL_INT, GL_TEXTURE_CUBE_MAP, GL_NONE, GL_NONE, SamplerFormat::InvalidEnum, 1,
|
||||
1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, false, false, true},
|
||||
1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, false, false, true,
|
||||
"intBitsToFloat"},
|
||||
{GL_IMAGE_CUBE_MAP_ARRAY, GL_INT, GL_TEXTURE_CUBE_MAP_ARRAY, GL_NONE, GL_NONE,
|
||||
SamplerFormat::InvalidEnum, 1, 1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1,
|
||||
false, false, true},
|
||||
false, false, true, "intBitsToFloat"},
|
||||
{GL_IMAGE_BUFFER, GL_INT, GL_TEXTURE_BUFFER, GL_NONE, GL_NONE, SamplerFormat::InvalidEnum, 1,
|
||||
1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, false, false, true},
|
||||
1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, false, false, true,
|
||||
"intBitsToFloat"},
|
||||
{GL_INT, GL_INT, GL_NONE, GL_NONE, GL_BOOL, SamplerFormat::InvalidEnum, 1, 1, 1, sizeof(GLint),
|
||||
sizeof(GLint) * 4, sizeof(GLint) * 1, false, false, false},
|
||||
sizeof(GLint) * 4, sizeof(GLint) * 1, false, false, false, "intBitsToFloat"},
|
||||
{GL_INT_IMAGE_2D, GL_INT, GL_TEXTURE_2D, GL_NONE, GL_NONE, SamplerFormat::InvalidEnum, 1, 1, 1,
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, false, false, true},
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, false, false, true, "intBitsToFloat"},
|
||||
{GL_INT_IMAGE_2D_ARRAY, GL_INT, GL_TEXTURE_2D_ARRAY, GL_NONE, GL_NONE,
|
||||
SamplerFormat::InvalidEnum, 1, 1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1,
|
||||
false, false, true},
|
||||
false, false, true, "intBitsToFloat"},
|
||||
{GL_INT_IMAGE_3D, GL_INT, GL_TEXTURE_3D, GL_NONE, GL_NONE, SamplerFormat::InvalidEnum, 1, 1, 1,
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, false, false, true},
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, false, false, true, "intBitsToFloat"},
|
||||
{GL_INT_IMAGE_CUBE, GL_INT, GL_TEXTURE_CUBE_MAP, GL_NONE, GL_NONE, SamplerFormat::InvalidEnum,
|
||||
1, 1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, false, false, true},
|
||||
1, 1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, false, false, true,
|
||||
"intBitsToFloat"},
|
||||
{GL_INT_IMAGE_CUBE_MAP_ARRAY, GL_INT, GL_TEXTURE_CUBE_MAP_ARRAY, GL_NONE, GL_NONE,
|
||||
SamplerFormat::InvalidEnum, 1, 1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1,
|
||||
false, false, true},
|
||||
false, false, true, "intBitsToFloat"},
|
||||
{GL_INT_IMAGE_BUFFER, GL_INT, GL_TEXTURE_BUFFER, GL_NONE, GL_NONE, SamplerFormat::InvalidEnum,
|
||||
1, 1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, false, false, true},
|
||||
1, 1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, false, false, true,
|
||||
"intBitsToFloat"},
|
||||
{GL_INT_SAMPLER_2D, GL_INT, GL_TEXTURE_2D, GL_NONE, GL_NONE, SamplerFormat::Signed, 1, 1, 1,
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false},
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false, "intBitsToFloat"},
|
||||
{GL_INT_SAMPLER_2D_ARRAY, GL_INT, GL_TEXTURE_2D_ARRAY, GL_NONE, GL_NONE, SamplerFormat::Signed,
|
||||
1, 1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false},
|
||||
1, 1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false,
|
||||
"intBitsToFloat"},
|
||||
{GL_INT_SAMPLER_2D_MULTISAMPLE, GL_INT, GL_TEXTURE_2D_MULTISAMPLE, GL_NONE, GL_NONE,
|
||||
SamplerFormat::Signed, 1, 1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true,
|
||||
false, false},
|
||||
false, false, "intBitsToFloat"},
|
||||
{GL_INT_SAMPLER_2D_MULTISAMPLE_ARRAY, GL_INT, GL_TEXTURE_2D_MULTISAMPLE_ARRAY, GL_NONE,
|
||||
GL_NONE, SamplerFormat::Signed, 1, 1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1,
|
||||
true, false, false},
|
||||
true, false, false, "intBitsToFloat"},
|
||||
{GL_INT_SAMPLER_3D, GL_INT, GL_TEXTURE_3D, GL_NONE, GL_NONE, SamplerFormat::Signed, 1, 1, 1,
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false},
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false, "intBitsToFloat"},
|
||||
{GL_INT_SAMPLER_CUBE, GL_INT, GL_TEXTURE_CUBE_MAP, GL_NONE, GL_NONE, SamplerFormat::Signed, 1,
|
||||
1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false},
|
||||
1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false,
|
||||
"intBitsToFloat"},
|
||||
{GL_INT_SAMPLER_CUBE_MAP_ARRAY, GL_INT, GL_TEXTURE_CUBE_MAP_ARRAY, GL_NONE, GL_NONE,
|
||||
SamplerFormat::Signed, 1, 1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true,
|
||||
false, false},
|
||||
false, false, "intBitsToFloat"},
|
||||
{GL_INT_SAMPLER_BUFFER, GL_INT, GL_TEXTURE_BUFFER, GL_NONE, GL_NONE, SamplerFormat::Signed, 1,
|
||||
1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false},
|
||||
1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false,
|
||||
"intBitsToFloat"},
|
||||
{GL_INT_VEC2, GL_INT, GL_NONE, GL_NONE, GL_BOOL_VEC2, SamplerFormat::InvalidEnum, 1, 2, 2,
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 2, false, false, false},
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 2, false, false, false, "intBitsToFloat"},
|
||||
{GL_INT_VEC3, GL_INT, GL_NONE, GL_NONE, GL_BOOL_VEC3, SamplerFormat::InvalidEnum, 1, 3, 3,
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 3, false, false, false},
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 3, false, false, false, "intBitsToFloat"},
|
||||
{GL_INT_VEC4, GL_INT, GL_NONE, GL_NONE, GL_BOOL_VEC4, SamplerFormat::InvalidEnum, 1, 4, 4,
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 4, false, false, false},
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 4, false, false, false, "intBitsToFloat"},
|
||||
{GL_SAMPLER_2D, GL_INT, GL_TEXTURE_2D, GL_NONE, GL_NONE, SamplerFormat::Float, 1, 1, 1,
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false},
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false, "intBitsToFloat"},
|
||||
{GL_SAMPLER_2D_ARRAY, GL_INT, GL_TEXTURE_2D_ARRAY, GL_NONE, GL_NONE, SamplerFormat::Float, 1,
|
||||
1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false},
|
||||
1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false,
|
||||
"intBitsToFloat"},
|
||||
{GL_SAMPLER_2D_ARRAY_SHADOW, GL_INT, GL_TEXTURE_2D_ARRAY, GL_NONE, GL_NONE,
|
||||
SamplerFormat::Shadow, 1, 1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true,
|
||||
false, false},
|
||||
false, false, "intBitsToFloat"},
|
||||
{GL_SAMPLER_2D_MULTISAMPLE, GL_INT, GL_TEXTURE_2D_MULTISAMPLE, GL_NONE, GL_NONE,
|
||||
SamplerFormat::Float, 1, 1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true,
|
||||
false, false},
|
||||
false, false, "intBitsToFloat"},
|
||||
{GL_SAMPLER_2D_MULTISAMPLE_ARRAY, GL_INT, GL_TEXTURE_2D_MULTISAMPLE_ARRAY, GL_NONE, GL_NONE,
|
||||
SamplerFormat::Float, 1, 1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true,
|
||||
false, false},
|
||||
false, false, "intBitsToFloat"},
|
||||
{GL_SAMPLER_2D_RECT_ANGLE, GL_INT, GL_TEXTURE_2D, GL_NONE, GL_NONE, SamplerFormat::Float, 1, 1,
|
||||
1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false},
|
||||
1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false, "intBitsToFloat"},
|
||||
{GL_SAMPLER_2D_SHADOW, GL_INT, GL_TEXTURE_2D, GL_NONE, GL_NONE, SamplerFormat::Shadow, 1, 1, 1,
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false},
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false, "intBitsToFloat"},
|
||||
{GL_SAMPLER_3D, GL_INT, GL_TEXTURE_3D, GL_NONE, GL_NONE, SamplerFormat::Float, 1, 1, 1,
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false},
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false, "intBitsToFloat"},
|
||||
{GL_SAMPLER_CUBE, GL_INT, GL_TEXTURE_CUBE_MAP, GL_NONE, GL_NONE, SamplerFormat::Float, 1, 1, 1,
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false},
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false, "intBitsToFloat"},
|
||||
{GL_SAMPLER_CUBE_MAP_ARRAY, GL_INT, GL_TEXTURE_CUBE_MAP_ARRAY, GL_NONE, GL_NONE,
|
||||
SamplerFormat::Float, 1, 1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true,
|
||||
false, false},
|
||||
false, false, "intBitsToFloat"},
|
||||
{GL_SAMPLER_BUFFER, GL_INT, GL_TEXTURE_BUFFER, GL_NONE, GL_NONE, SamplerFormat::Float, 1, 1, 1,
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false},
|
||||
sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false, "intBitsToFloat"},
|
||||
{GL_SAMPLER_CUBE_SHADOW, GL_INT, GL_TEXTURE_CUBE_MAP, GL_NONE, GL_NONE, SamplerFormat::Shadow,
|
||||
1, 1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false},
|
||||
1, 1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false,
|
||||
"intBitsToFloat"},
|
||||
{GL_SAMPLER_CUBE_MAP_ARRAY_SHADOW, GL_INT, GL_NONE, GL_NONE, GL_NONE, SamplerFormat::Shadow, 1,
|
||||
1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false},
|
||||
1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false,
|
||||
"intBitsToFloat"},
|
||||
{GL_SAMPLER_EXTERNAL_OES, GL_INT, GL_TEXTURE_EXTERNAL_OES, GL_NONE, GL_NONE,
|
||||
SamplerFormat::Float, 1, 1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true,
|
||||
false, false},
|
||||
false, false, "intBitsToFloat"},
|
||||
{GL_UNSIGNED_INT, GL_UNSIGNED_INT, GL_NONE, GL_NONE, GL_BOOL, SamplerFormat::InvalidEnum, 1, 1,
|
||||
1, sizeof(GLuint), sizeof(GLuint) * 4, sizeof(GLuint) * 1, false, false, false},
|
||||
1, sizeof(GLuint), sizeof(GLuint) * 4, sizeof(GLuint) * 1, false, false, false,
|
||||
"uintBitsToFloat"},
|
||||
{GL_UNSIGNED_INT_ATOMIC_COUNTER, GL_UNSIGNED_INT, GL_NONE, GL_NONE, GL_NONE,
|
||||
SamplerFormat::InvalidEnum, 1, 1, 1, sizeof(GLuint), sizeof(GLuint) * 4, sizeof(GLuint) * 1,
|
||||
false, false, false},
|
||||
false, false, false, "uintBitsToFloat"},
|
||||
{GL_UNSIGNED_INT_IMAGE_2D, GL_UNSIGNED_INT, GL_TEXTURE_2D, GL_NONE, GL_NONE,
|
||||
SamplerFormat::InvalidEnum, 1, 1, 1, sizeof(GLuint), sizeof(GLuint) * 4, sizeof(GLuint) * 1,
|
||||
false, false, true},
|
||||
false, false, true, "uintBitsToFloat"},
|
||||
{GL_UNSIGNED_INT_IMAGE_2D_ARRAY, GL_UNSIGNED_INT, GL_TEXTURE_2D_ARRAY, GL_NONE, GL_NONE,
|
||||
SamplerFormat::InvalidEnum, 1, 1, 1, sizeof(GLuint), sizeof(GLuint) * 4, sizeof(GLuint) * 1,
|
||||
false, false, true},
|
||||
false, false, true, "uintBitsToFloat"},
|
||||
{GL_UNSIGNED_INT_IMAGE_3D, GL_UNSIGNED_INT, GL_TEXTURE_3D, GL_NONE, GL_NONE,
|
||||
SamplerFormat::InvalidEnum, 1, 1, 1, sizeof(GLuint), sizeof(GLuint) * 4, sizeof(GLuint) * 1,
|
||||
false, false, true},
|
||||
false, false, true, "uintBitsToFloat"},
|
||||
{GL_UNSIGNED_INT_IMAGE_CUBE, GL_UNSIGNED_INT, GL_TEXTURE_CUBE_MAP, GL_NONE, GL_NONE,
|
||||
SamplerFormat::InvalidEnum, 1, 1, 1, sizeof(GLuint), sizeof(GLuint) * 4, sizeof(GLuint) * 1,
|
||||
false, false, true},
|
||||
false, false, true, "uintBitsToFloat"},
|
||||
{GL_UNSIGNED_INT_IMAGE_CUBE_MAP_ARRAY, GL_UNSIGNED_INT, GL_TEXTURE_CUBE_MAP_ARRAY, GL_NONE,
|
||||
GL_NONE, SamplerFormat::InvalidEnum, 1, 1, 1, sizeof(GLuint), sizeof(GLuint) * 4,
|
||||
sizeof(GLuint) * 1, false, false, true},
|
||||
sizeof(GLuint) * 1, false, false, true, "uintBitsToFloat"},
|
||||
{GL_UNSIGNED_INT_IMAGE_BUFFER, GL_UNSIGNED_INT, GL_TEXTURE_BUFFER, GL_NONE, GL_NONE,
|
||||
SamplerFormat::InvalidEnum, 1, 1, 1, sizeof(GLuint), sizeof(GLuint) * 4, sizeof(GLuint) * 1,
|
||||
false, false, true},
|
||||
false, false, true, "uintBitsToFloat"},
|
||||
{GL_UNSIGNED_INT_SAMPLER_2D, GL_UNSIGNED_INT, GL_TEXTURE_2D, GL_NONE, GL_NONE,
|
||||
SamplerFormat::Unsigned, 1, 1, 1, sizeof(GLuint), sizeof(GLuint) * 4, sizeof(GLuint) * 1,
|
||||
true, false, false},
|
||||
true, false, false, "uintBitsToFloat"},
|
||||
{GL_UNSIGNED_INT_SAMPLER_2D_ARRAY, GL_UNSIGNED_INT, GL_TEXTURE_2D_ARRAY, GL_NONE, GL_NONE,
|
||||
SamplerFormat::Unsigned, 1, 1, 1, sizeof(GLuint), sizeof(GLuint) * 4, sizeof(GLuint) * 1,
|
||||
true, false, false},
|
||||
true, false, false, "uintBitsToFloat"},
|
||||
{GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE, GL_UNSIGNED_INT, GL_TEXTURE_2D_MULTISAMPLE, GL_NONE,
|
||||
GL_NONE, SamplerFormat::Unsigned, 1, 1, 1, sizeof(GLuint), sizeof(GLuint) * 4,
|
||||
sizeof(GLuint) * 1, true, false, false},
|
||||
sizeof(GLuint) * 1, true, false, false, "uintBitsToFloat"},
|
||||
{GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY, GL_UNSIGNED_INT,
|
||||
GL_TEXTURE_2D_MULTISAMPLE_ARRAY, GL_NONE, GL_NONE, SamplerFormat::Unsigned, 1, 1, 1,
|
||||
sizeof(GLuint), sizeof(GLuint) * 4, sizeof(GLuint) * 1, true, false, false},
|
||||
sizeof(GLuint), sizeof(GLuint) * 4, sizeof(GLuint) * 1, true, false, false,
|
||||
"uintBitsToFloat"},
|
||||
{GL_UNSIGNED_INT_SAMPLER_3D, GL_UNSIGNED_INT, GL_TEXTURE_3D, GL_NONE, GL_NONE,
|
||||
SamplerFormat::Unsigned, 1, 1, 1, sizeof(GLuint), sizeof(GLuint) * 4, sizeof(GLuint) * 1,
|
||||
true, false, false},
|
||||
true, false, false, "uintBitsToFloat"},
|
||||
{GL_UNSIGNED_INT_SAMPLER_CUBE, GL_UNSIGNED_INT, GL_TEXTURE_CUBE_MAP, GL_NONE, GL_NONE,
|
||||
SamplerFormat::Unsigned, 1, 1, 1, sizeof(GLuint), sizeof(GLuint) * 4, sizeof(GLuint) * 1,
|
||||
true, false, false},
|
||||
true, false, false, "uintBitsToFloat"},
|
||||
{GL_UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY, GL_UNSIGNED_INT, GL_TEXTURE_CUBE_MAP_ARRAY, GL_NONE,
|
||||
GL_NONE, SamplerFormat::Unsigned, 1, 1, 1, sizeof(GLuint), sizeof(GLuint) * 4,
|
||||
sizeof(GLuint) * 1, true, false, false},
|
||||
sizeof(GLuint) * 1, true, false, false, "uintBitsToFloat"},
|
||||
{GL_UNSIGNED_INT_SAMPLER_BUFFER, GL_UNSIGNED_INT, GL_TEXTURE_BUFFER, GL_NONE, GL_NONE,
|
||||
SamplerFormat::Unsigned, 1, 1, 1, sizeof(GLuint), sizeof(GLuint) * 4, sizeof(GLuint) * 1,
|
||||
true, false, false},
|
||||
true, false, false, "uintBitsToFloat"},
|
||||
{GL_UNSIGNED_INT_VEC2, GL_UNSIGNED_INT, GL_NONE, GL_NONE, GL_BOOL_VEC2,
|
||||
SamplerFormat::InvalidEnum, 1, 2, 2, sizeof(GLuint), sizeof(GLuint) * 4, sizeof(GLuint) * 2,
|
||||
false, false, false},
|
||||
false, false, false, "uintBitsToFloat"},
|
||||
{GL_UNSIGNED_INT_VEC3, GL_UNSIGNED_INT, GL_NONE, GL_NONE, GL_BOOL_VEC3,
|
||||
SamplerFormat::InvalidEnum, 1, 3, 3, sizeof(GLuint), sizeof(GLuint) * 4, sizeof(GLuint) * 3,
|
||||
false, false, false},
|
||||
false, false, false, "uintBitsToFloat"},
|
||||
{GL_UNSIGNED_INT_VEC4, GL_UNSIGNED_INT, GL_NONE, GL_NONE, GL_BOOL_VEC4,
|
||||
SamplerFormat::InvalidEnum, 1, 4, 4, sizeof(GLuint), sizeof(GLuint) * 4, sizeof(GLuint) * 4,
|
||||
false, false, false},
|
||||
false, false, false, "uintBitsToFloat"},
|
||||
{GL_SAMPLER_VIDEO_IMAGE_WEBGL, GL_INT, GL_TEXTURE_VIDEO_IMAGE_WEBGL, GL_NONE, GL_NONE,
|
||||
SamplerFormat::Float, 1, 1, 1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true,
|
||||
false, false},
|
||||
{GL_SAMPLER_EXTERNAL_2D_Y2Y_EXT, GL_INT, GL_NONE, GL_NONE, GL_NONE, SamplerFormat::Float, 1, 1,
|
||||
1, sizeof(GLint), sizeof(GLint) * 4, sizeof(GLint) * 1, true, false, false}}};
|
||||
false, false, "intBitsToFloat"}}};
|
||||
|
||||
size_t GetTypeInfoIndex(GLenum uniformType)
|
||||
{
|
||||
|
@ -360,8 +371,6 @@ size_t GetTypeInfoIndex(GLenum uniformType)
|
|||
return 74;
|
||||
case GL_SAMPLER_VIDEO_IMAGE_WEBGL:
|
||||
return 75;
|
||||
case GL_SAMPLER_EXTERNAL_2D_Y2Y_EXT:
|
||||
return 76;
|
||||
default:
|
||||
UNREACHABLE();
|
||||
return 0;
|
||||
|
|
|
@ -10,7 +10,6 @@
|
|||
#include "GLES3/gl3.h"
|
||||
#include "common/mathutil.h"
|
||||
#include "common/platform.h"
|
||||
#include "common/string_utils.h"
|
||||
|
||||
#include <set>
|
||||
|
||||
|
@ -171,7 +170,6 @@ GLenum VariableComponentType(GLenum type)
|
|||
case GL_UNSIGNED_INT_IMAGE_BUFFER:
|
||||
case GL_UNSIGNED_INT_ATOMIC_COUNTER:
|
||||
case GL_SAMPLER_VIDEO_IMAGE_WEBGL:
|
||||
case GL_SAMPLER_EXTERNAL_2D_Y2Y_EXT:
|
||||
return GL_INT;
|
||||
case GL_UNSIGNED_INT:
|
||||
case GL_UNSIGNED_INT_VEC2:
|
||||
|
@ -362,7 +360,6 @@ int VariableRowCount(GLenum type)
|
|||
case GL_INT_IMAGE_BUFFER:
|
||||
case GL_UNSIGNED_INT_IMAGE_BUFFER:
|
||||
case GL_SAMPLER_VIDEO_IMAGE_WEBGL:
|
||||
case GL_SAMPLER_EXTERNAL_2D_Y2Y_EXT:
|
||||
return 1;
|
||||
case GL_FLOAT_MAT2:
|
||||
case GL_FLOAT_MAT3x2:
|
||||
|
@ -443,7 +440,6 @@ int VariableColumnCount(GLenum type)
|
|||
case GL_UNSIGNED_INT_IMAGE_CUBE:
|
||||
case GL_UNSIGNED_INT_ATOMIC_COUNTER:
|
||||
case GL_SAMPLER_VIDEO_IMAGE_WEBGL:
|
||||
case GL_SAMPLER_EXTERNAL_2D_Y2Y_EXT:
|
||||
return 1;
|
||||
case GL_BOOL_VEC2:
|
||||
case GL_FLOAT_VEC2:
|
||||
|
@ -511,7 +507,6 @@ bool IsSamplerType(GLenum type)
|
|||
case GL_SAMPLER_2D_ARRAY_SHADOW:
|
||||
case GL_SAMPLER_CUBE_MAP_ARRAY_SHADOW:
|
||||
case GL_SAMPLER_VIDEO_IMAGE_WEBGL:
|
||||
case GL_SAMPLER_EXTERNAL_2D_Y2Y_EXT:
|
||||
return true;
|
||||
}
|
||||
|
||||
|
@ -532,18 +527,6 @@ bool IsSamplerCubeType(GLenum type)
|
|||
return false;
|
||||
}
|
||||
|
||||
bool IsSamplerYUVType(GLenum type)
|
||||
{
|
||||
switch (type)
|
||||
{
|
||||
case GL_SAMPLER_EXTERNAL_2D_Y2Y_EXT:
|
||||
return true;
|
||||
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
bool IsImageType(GLenum type)
|
||||
{
|
||||
switch (type)
|
||||
|
@ -877,7 +860,6 @@ int VariableSortOrder(GLenum type)
|
|||
case GL_UNSIGNED_INT_IMAGE_CUBE:
|
||||
case GL_UNSIGNED_INT_ATOMIC_COUNTER:
|
||||
case GL_SAMPLER_VIDEO_IMAGE_WEBGL:
|
||||
case GL_SAMPLER_EXTERNAL_2D_Y2Y_EXT:
|
||||
return 6;
|
||||
|
||||
default:
|
||||
|
@ -921,11 +903,6 @@ std::string ParseResourceName(const std::string &name, std::vector<unsigned int>
|
|||
return name.substr(0, baseNameLength);
|
||||
}
|
||||
|
||||
bool IsBuiltInName(const char *name)
|
||||
{
|
||||
return angle::BeginsWith(name, "gl_");
|
||||
}
|
||||
|
||||
std::string StripLastArrayIndex(const std::string &name)
|
||||
{
|
||||
size_t strippedNameLength = name.find_last_of('[');
|
||||
|
@ -1129,69 +1106,6 @@ const char *GetDebugMessageSeverityString(GLenum severity)
|
|||
return "Unknown Severity";
|
||||
}
|
||||
}
|
||||
|
||||
ShaderType GetShaderTypeFromBitfield(size_t singleShaderType)
|
||||
{
|
||||
switch (singleShaderType)
|
||||
{
|
||||
case GL_VERTEX_SHADER_BIT:
|
||||
return ShaderType::Vertex;
|
||||
case GL_FRAGMENT_SHADER_BIT:
|
||||
return ShaderType::Fragment;
|
||||
case GL_COMPUTE_SHADER_BIT:
|
||||
return ShaderType::Compute;
|
||||
case GL_GEOMETRY_SHADER_BIT:
|
||||
return ShaderType::Geometry;
|
||||
case GL_TESS_CONTROL_SHADER_BIT:
|
||||
return ShaderType::TessControl;
|
||||
case GL_TESS_EVALUATION_SHADER_BIT:
|
||||
return ShaderType::TessEvaluation;
|
||||
default:
|
||||
return ShaderType::InvalidEnum;
|
||||
}
|
||||
}
|
||||
|
||||
GLbitfield GetBitfieldFromShaderType(ShaderType shaderType)
|
||||
{
|
||||
switch (shaderType)
|
||||
{
|
||||
case ShaderType::Vertex:
|
||||
return GL_VERTEX_SHADER_BIT;
|
||||
case ShaderType::Fragment:
|
||||
return GL_FRAGMENT_SHADER_BIT;
|
||||
case ShaderType::Compute:
|
||||
return GL_COMPUTE_SHADER_BIT;
|
||||
case ShaderType::Geometry:
|
||||
return GL_GEOMETRY_SHADER_BIT;
|
||||
case ShaderType::TessControl:
|
||||
return GL_TESS_CONTROL_SHADER_BIT;
|
||||
case ShaderType::TessEvaluation:
|
||||
return GL_TESS_EVALUATION_SHADER_BIT;
|
||||
default:
|
||||
UNREACHABLE();
|
||||
return GL_ZERO;
|
||||
}
|
||||
}
|
||||
|
||||
bool ShaderTypeSupportsTransformFeedback(ShaderType shaderType)
|
||||
{
|
||||
switch (shaderType)
|
||||
{
|
||||
case ShaderType::Vertex:
|
||||
case ShaderType::Geometry:
|
||||
case ShaderType::TessEvaluation:
|
||||
return true;
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
ShaderType GetLastPreFragmentStage(ShaderBitSet shaderTypes)
|
||||
{
|
||||
shaderTypes.reset(ShaderType::Fragment);
|
||||
shaderTypes.reset(ShaderType::Compute);
|
||||
return shaderTypes.any() ? shaderTypes.last() : ShaderType::InvalidEnum;
|
||||
}
|
||||
} // namespace gl
|
||||
|
||||
namespace egl
|
||||
|
@ -1255,7 +1169,6 @@ bool IsExternalImageTarget(EGLenum target)
|
|||
case EGL_NATIVE_BUFFER_ANDROID:
|
||||
case EGL_D3D11_TEXTURE_ANGLE:
|
||||
case EGL_LINUX_DMA_BUF_EXT:
|
||||
case EGL_METAL_TEXTURE_ANGLE:
|
||||
return true;
|
||||
|
||||
default:
|
||||
|
|
|
@ -39,7 +39,6 @@ int VariableRowCount(GLenum type);
|
|||
int VariableColumnCount(GLenum type);
|
||||
bool IsSamplerType(GLenum type);
|
||||
bool IsSamplerCubeType(GLenum type);
|
||||
bool IsSamplerYUVType(GLenum type);
|
||||
bool IsImageType(GLenum type);
|
||||
bool IsImage2DType(GLenum type);
|
||||
bool IsAtomicCounterType(GLenum type);
|
||||
|
@ -62,12 +61,6 @@ int AllocateFirstFreeBits(unsigned int *bits, unsigned int allocationSize, unsig
|
|||
// outSubscripts.
|
||||
std::string ParseResourceName(const std::string &name, std::vector<unsigned int> *outSubscripts);
|
||||
|
||||
bool IsBuiltInName(const char *name);
|
||||
ANGLE_INLINE bool IsBuiltInName(const std::string &name)
|
||||
{
|
||||
return IsBuiltInName(name.c_str());
|
||||
}
|
||||
|
||||
// Strips only the last array index from a resource name.
|
||||
std::string StripLastArrayIndex(const std::string &name);
|
||||
|
||||
|
@ -148,7 +141,8 @@ struct UniformTypeInfo final : angle::NonCopyable
|
|||
size_t externalSize,
|
||||
bool isSampler,
|
||||
bool isMatrixType,
|
||||
bool isImageType);
|
||||
bool isImageType,
|
||||
const char *glslAsFloat);
|
||||
|
||||
GLenum type;
|
||||
GLenum componentType;
|
||||
|
@ -165,6 +159,7 @@ struct UniformTypeInfo final : angle::NonCopyable
|
|||
bool isSampler;
|
||||
bool isMatrixType;
|
||||
bool isImageType;
|
||||
const char *glslAsFloat;
|
||||
};
|
||||
|
||||
inline constexpr UniformTypeInfo::UniformTypeInfo(GLenum type,
|
||||
|
@ -181,7 +176,8 @@ inline constexpr UniformTypeInfo::UniformTypeInfo(GLenum type,
|
|||
size_t externalSize,
|
||||
bool isSampler,
|
||||
bool isMatrixType,
|
||||
bool isImageType)
|
||||
bool isImageType,
|
||||
const char *glslAsFloat)
|
||||
: type(type),
|
||||
componentType(componentType),
|
||||
textureType(textureType),
|
||||
|
@ -196,7 +192,8 @@ inline constexpr UniformTypeInfo::UniformTypeInfo(GLenum type,
|
|||
externalSize(externalSize),
|
||||
isSampler(isSampler),
|
||||
isMatrixType(isMatrixType),
|
||||
isImageType(isImageType)
|
||||
isImageType(isImageType),
|
||||
glslAsFloat(glslAsFloat)
|
||||
{}
|
||||
|
||||
const UniformTypeInfo &GetUniformTypeInfo(GLenum uniformType);
|
||||
|
@ -241,23 +238,6 @@ enum class SrgbOverride
|
|||
Linear
|
||||
};
|
||||
|
||||
// For use with EXT_sRGB_write_control
|
||||
// A render target may be forced to convert to a linear colorspace, or may be allowed to do whatever
|
||||
// colorspace conversion is appropriate for its format. There is no option to force linear->sRGB, it
|
||||
// can only convert from sRGB->linear
|
||||
enum class SrgbWriteControlMode
|
||||
{
|
||||
Default = 0,
|
||||
Linear = 1
|
||||
};
|
||||
|
||||
ShaderType GetShaderTypeFromBitfield(size_t singleShaderType);
|
||||
GLbitfield GetBitfieldFromShaderType(ShaderType shaderType);
|
||||
bool ShaderTypeSupportsTransformFeedback(ShaderType shaderType);
|
||||
// Given a set of shader stages, returns the last vertex processing stage. This is the stage that
|
||||
// interfaces the fragment shader.
|
||||
ShaderType GetLastPreFragmentStage(ShaderBitSet shaderTypes);
|
||||
|
||||
} // namespace gl
|
||||
|
||||
namespace egl
|
||||
|
|
|
@ -170,7 +170,7 @@ void DirectiveParser::lex(Token *token)
|
|||
parseDirective(token);
|
||||
mPastFirstStatement = true;
|
||||
}
|
||||
else if (!isEOD(token) && !skipping())
|
||||
else if (!isEOD(token))
|
||||
{
|
||||
mSeenNonPreprocessorToken = true;
|
||||
}
|
||||
|
|
|
@ -134,6 +134,9 @@ enum TBasicType
|
|||
EbtImage2DMSArray,
|
||||
EbtIImage2DMSArray,
|
||||
EbtUImage2DMSArray,
|
||||
EbtImage2DRect,
|
||||
EbtIImage2DRect,
|
||||
EbtUImage2DRect,
|
||||
EbtImageCubeArray,
|
||||
EbtIImageCubeArray,
|
||||
EbtUImageCubeArray,
|
||||
|
@ -145,17 +148,14 @@ enum TBasicType
|
|||
EbtUImageBuffer,
|
||||
EbtGuardImageEnd = EbtUImageBuffer,
|
||||
|
||||
// Subpass Input
|
||||
EbtGuardSubpassInputBegin,
|
||||
EbtSubpassInput = EbtGuardSubpassInputBegin,
|
||||
EbtSubpassInput,
|
||||
EbtISubpassInput,
|
||||
EbtUSubpassInput,
|
||||
EbtSubpassInputMS,
|
||||
EbtISubpassInputMS,
|
||||
EbtUSubpassInputMS,
|
||||
EbtGuardSubpassInputEnd = EbtUSubpassInputMS,
|
||||
|
||||
EbtLastSimpleType = EbtGuardSubpassInputEnd,
|
||||
EbtLastSimpleType = EbtUSubpassInputMS,
|
||||
|
||||
EbtStruct,
|
||||
EbtInterfaceBlock,
|
||||
|
@ -221,14 +221,9 @@ inline bool IsAtomicCounter(TBasicType type)
|
|||
return type == EbtAtomicCounter;
|
||||
}
|
||||
|
||||
inline bool IsSubpassInputType(TBasicType type)
|
||||
{
|
||||
return type >= EbtGuardSubpassInputBegin && type <= EbtGuardSubpassInputEnd;
|
||||
}
|
||||
|
||||
inline bool IsOpaqueType(TBasicType type)
|
||||
{
|
||||
return IsSampler(type) || IsImage(type) || IsAtomicCounter(type) || IsSubpassInputType(type);
|
||||
return IsSampler(type) || IsImage(type) || IsAtomicCounter(type);
|
||||
}
|
||||
|
||||
inline bool IsIntegerSampler(TBasicType type)
|
||||
|
@ -360,6 +355,7 @@ inline bool IsFloatImage(TBasicType type)
|
|||
case EbtImageCube:
|
||||
case EbtImage2DMS:
|
||||
case EbtImage2DMSArray:
|
||||
case EbtImage2DRect:
|
||||
case EbtImageCubeArray:
|
||||
case EbtImageRect:
|
||||
case EbtImageBuffer:
|
||||
|
@ -384,6 +380,7 @@ inline bool IsIntegerImage(TBasicType type)
|
|||
case EbtIImageCube:
|
||||
case EbtIImage2DMS:
|
||||
case EbtIImage2DMSArray:
|
||||
case EbtIImage2DRect:
|
||||
case EbtIImageCubeArray:
|
||||
case EbtIImageRect:
|
||||
case EbtIImageBuffer:
|
||||
|
@ -408,6 +405,7 @@ inline bool IsUnsignedImage(TBasicType type)
|
|||
case EbtUImageCube:
|
||||
case EbtUImage2DMS:
|
||||
case EbtUImage2DMSArray:
|
||||
case EbtUImage2DRect:
|
||||
case EbtUImageCubeArray:
|
||||
case EbtUImageRect:
|
||||
case EbtUImageBuffer:
|
||||
|
@ -708,6 +706,9 @@ inline bool IsImage2D(TBasicType type)
|
|||
case EbtImage2D:
|
||||
case EbtIImage2D:
|
||||
case EbtUImage2D:
|
||||
case EbtImage2DRect:
|
||||
case EbtIImage2DRect:
|
||||
case EbtUImage2DRect:
|
||||
case EbtImage2DMS:
|
||||
case EbtIImage2DMS:
|
||||
case EbtUImage2DMS:
|
||||
|
@ -776,6 +777,9 @@ inline bool IsImage3D(TBasicType type)
|
|||
case EbtImage2DMSArray:
|
||||
case EbtIImage2DMSArray:
|
||||
case EbtUImage2DMSArray:
|
||||
case EbtImage2DRect:
|
||||
case EbtIImage2DRect:
|
||||
case EbtUImage2DRect:
|
||||
case EbtImageCubeArray:
|
||||
case EbtIImageCubeArray:
|
||||
case EbtUImageCubeArray:
|
||||
|
@ -822,6 +826,9 @@ inline bool IsImage2DArray(TBasicType type)
|
|||
case EbtImage2DMS:
|
||||
case EbtIImage2DMS:
|
||||
case EbtUImage2DMS:
|
||||
case EbtImage2DRect:
|
||||
case EbtIImage2DRect:
|
||||
case EbtUImage2DRect:
|
||||
case EbtImageCubeArray:
|
||||
case EbtIImageCubeArray:
|
||||
case EbtUImageCubeArray:
|
||||
|
@ -868,6 +875,9 @@ inline bool IsImageCube(TBasicType type)
|
|||
case EbtImage2DMSArray:
|
||||
case EbtIImage2DMSArray:
|
||||
case EbtUImage2DMSArray:
|
||||
case EbtImage2DRect:
|
||||
case EbtIImage2DRect:
|
||||
case EbtUImage2DRect:
|
||||
case EbtImageCubeArray:
|
||||
case EbtIImageCubeArray:
|
||||
case EbtUImageCubeArray:
|
||||
|
@ -911,15 +921,12 @@ enum TQualifier
|
|||
EvqVaryingOut, // vertex shaders only read/write
|
||||
EvqUniform, // Readonly, vertex and fragment
|
||||
EvqBuffer, // read/write, vertex, fragment and compute shader
|
||||
EvqPatch, // EXT_tessellation_shader storage qualifier
|
||||
|
||||
EvqVertexIn, // Vertex shader input
|
||||
EvqFragmentOut, // Fragment shader output
|
||||
EvqVertexOut, // Vertex shader output
|
||||
EvqFragmentIn, // Fragment shader input
|
||||
|
||||
EvqFragmentInOut, // EXT_shader_framebuffer_fetch qualifier
|
||||
|
||||
// parameters
|
||||
EvqIn,
|
||||
EvqOut,
|
||||
|
@ -936,6 +943,9 @@ enum TQualifier
|
|||
|
||||
EvqDrawID, // ANGLE_multi_draw
|
||||
|
||||
EvqBaseVertex, // ANGLE_base_vertex_base_instance
|
||||
EvqBaseInstance, // ANGLE_base_vertex_base_instance
|
||||
|
||||
// built-ins read by fragment shader
|
||||
EvqFragCoord,
|
||||
EvqFrontFacing,
|
||||
|
@ -956,7 +966,6 @@ enum TQualifier
|
|||
EvqViewportIndex, // gl_ViewportIndex
|
||||
|
||||
EvqClipDistance, // APPLE_clip_distance/EXT_clip_cull_distance
|
||||
EvqCullDistance, // EXT_clip_cull_distance
|
||||
|
||||
// built-ins written by the shader_framebuffer_fetch extension(s)
|
||||
EvqLastFragColor,
|
||||
|
@ -979,13 +988,6 @@ enum TQualifier
|
|||
EvqCentroidIn, // Implies smooth
|
||||
EvqSampleIn,
|
||||
|
||||
// GLSL ES 3.0 extension OES_sample_variables
|
||||
EvqSampleID,
|
||||
EvqSamplePosition,
|
||||
EvqSampleMaskIn,
|
||||
EvqSampleMask,
|
||||
EvqNumSamples,
|
||||
|
||||
// GLSL ES 3.1 compute shader special variables
|
||||
EvqShared,
|
||||
EvqComputeIn,
|
||||
|
@ -1015,21 +1017,6 @@ enum TQualifier
|
|||
// GLSL ES 3.1 extension EXT_gpu_shader5 qualifiers
|
||||
EvqPrecise,
|
||||
|
||||
// GLES ES 3.1 extension EXT_tessellation_shader qualifiers
|
||||
EvqPatchIn,
|
||||
EvqPatchOut,
|
||||
|
||||
EvqTessControlIn,
|
||||
EvqTessControlOut,
|
||||
EvqPerVertexOut,
|
||||
EvqPatchVerticesIn,
|
||||
EvqTessLevelOuter,
|
||||
EvqTessLevelInner,
|
||||
|
||||
EvqTessEvaluationIn,
|
||||
EvqTessEvaluationOut,
|
||||
EvqTessCoord,
|
||||
|
||||
// end of list
|
||||
EvqLast
|
||||
};
|
||||
|
@ -1049,8 +1036,6 @@ inline bool IsShaderIn(TQualifier qualifier)
|
|||
switch (qualifier)
|
||||
{
|
||||
case EvqVertexIn:
|
||||
case EvqTessControlIn:
|
||||
case EvqTessEvaluationIn:
|
||||
case EvqGeometryIn:
|
||||
case EvqFragmentIn:
|
||||
case EvqAttribute:
|
||||
|
@ -1060,7 +1045,6 @@ inline bool IsShaderIn(TQualifier qualifier)
|
|||
case EvqNoPerspectiveIn:
|
||||
case EvqCentroidIn:
|
||||
case EvqSampleIn:
|
||||
case EvqPatchIn:
|
||||
return true;
|
||||
default:
|
||||
return false;
|
||||
|
@ -1072,8 +1056,6 @@ inline bool IsShaderOut(TQualifier qualifier)
|
|||
switch (qualifier)
|
||||
{
|
||||
case EvqVertexOut:
|
||||
case EvqTessControlOut:
|
||||
case EvqTessEvaluationOut:
|
||||
case EvqGeometryOut:
|
||||
case EvqFragmentOut:
|
||||
case EvqVaryingOut:
|
||||
|
@ -1082,28 +1064,6 @@ inline bool IsShaderOut(TQualifier qualifier)
|
|||
case EvqNoPerspectiveOut:
|
||||
case EvqCentroidOut:
|
||||
case EvqSampleOut:
|
||||
case EvqPatchOut:
|
||||
case EvqFragmentInOut:
|
||||
return true;
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
inline bool IsShaderIoBlock(TQualifier qualifier)
|
||||
{
|
||||
switch (qualifier)
|
||||
{
|
||||
case EvqPerVertexIn:
|
||||
case EvqPerVertexOut:
|
||||
case EvqVertexOut:
|
||||
case EvqTessControlIn:
|
||||
case EvqTessControlOut:
|
||||
case EvqTessEvaluationIn:
|
||||
case EvqTessEvaluationOut:
|
||||
case EvqGeometryIn:
|
||||
case EvqGeometryOut:
|
||||
case EvqFragmentIn:
|
||||
return true;
|
||||
default:
|
||||
return false;
|
||||
|
@ -1164,20 +1124,6 @@ enum TLayoutPrimitiveType
|
|||
EptTriangleStrip
|
||||
};
|
||||
|
||||
enum TLayoutTessEvaluationType
|
||||
{
|
||||
EtetUndefined,
|
||||
EtetTriangles,
|
||||
EtetQuads,
|
||||
EtetIsolines,
|
||||
EtetEqualSpacing,
|
||||
EtetFractionalEvenSpacing,
|
||||
EtetFractionalOddSpacing,
|
||||
EtetCw,
|
||||
EtetCcw,
|
||||
EtetPointMode
|
||||
};
|
||||
|
||||
struct TLayoutQualifier
|
||||
{
|
||||
// Must have a trivial default constructor since it is used in YYSTYPE.
|
||||
|
@ -1191,10 +1137,7 @@ struct TLayoutQualifier
|
|||
earlyFragmentTests == false && matrixPacking == EmpUnspecified &&
|
||||
blockStorage == EbsUnspecified && !localSize.isAnyValueSet() &&
|
||||
imageInternalFormat == EiifUnspecified && primitiveType == EptUndefined &&
|
||||
invocations == 0 && maxVertices == -1 && vertices == 0 &&
|
||||
tesPrimitiveType == EtetUndefined && tesVertexSpacingType == EtetUndefined &&
|
||||
tesOrderingType == EtetUndefined && tesPointType == EtetUndefined && index == -1 &&
|
||||
inputAttachmentIndex == -1 && noncoherent == false;
|
||||
invocations == 0 && maxVertices == -1 && index == -1;
|
||||
}
|
||||
|
||||
bool isCombinationValid() const
|
||||
|
@ -1203,7 +1146,6 @@ struct TLayoutQualifier
|
|||
bool numViewsSet = (numViews != -1);
|
||||
bool geometryShaderSpecified =
|
||||
(primitiveType != EptUndefined) || (invocations != 0) || (maxVertices != -1);
|
||||
bool subpassInputSpecified = (inputAttachmentIndex != -1);
|
||||
bool otherLayoutQualifiersSpecified =
|
||||
(location != -1 || binding != -1 || index != -1 || matrixPacking != EmpUnspecified ||
|
||||
blockStorage != EbsUnspecified || imageInternalFormat != EiifUnspecified);
|
||||
|
@ -1213,8 +1155,7 @@ struct TLayoutQualifier
|
|||
// qualifiers.
|
||||
return (workGroupSizeSpecified ? 1 : 0) + (numViewsSet ? 1 : 0) + (yuv ? 1 : 0) +
|
||||
(earlyFragmentTests ? 1 : 0) + (otherLayoutQualifiersSpecified ? 1 : 0) +
|
||||
(geometryShaderSpecified ? 1 : 0) + (subpassInputSpecified ? 1 : 0) +
|
||||
(noncoherent ? 1 : 0) <=
|
||||
(geometryShaderSpecified ? 1 : 0) <=
|
||||
1;
|
||||
}
|
||||
|
||||
|
@ -1251,20 +1192,9 @@ struct TLayoutQualifier
|
|||
int invocations;
|
||||
int maxVertices;
|
||||
|
||||
// EXT_tessellation_shader shader layout qualifiers
|
||||
int vertices;
|
||||
TLayoutTessEvaluationType tesPrimitiveType;
|
||||
TLayoutTessEvaluationType tesVertexSpacingType;
|
||||
TLayoutTessEvaluationType tesOrderingType;
|
||||
TLayoutTessEvaluationType tesPointType;
|
||||
|
||||
// EXT_blend_func_extended fragment output layout qualifier
|
||||
int index;
|
||||
|
||||
// EXT_shader_framebuffer_fetch layout qualifiers.
|
||||
int inputAttachmentIndex;
|
||||
bool noncoherent;
|
||||
|
||||
private:
|
||||
explicit constexpr TLayoutQualifier(int /*placeholder*/)
|
||||
: location(-1),
|
||||
|
@ -1281,14 +1211,7 @@ struct TLayoutQualifier
|
|||
primitiveType(EptUndefined),
|
||||
invocations(0),
|
||||
maxVertices(-1),
|
||||
vertices(0),
|
||||
tesPrimitiveType(EtetUndefined),
|
||||
tesVertexSpacingType(EtetUndefined),
|
||||
tesOrderingType(EtetUndefined),
|
||||
tesPointType(EtetUndefined),
|
||||
index(-1),
|
||||
inputAttachmentIndex(-1),
|
||||
noncoherent(false)
|
||||
index(-1)
|
||||
{}
|
||||
};
|
||||
|
||||
|
@ -1357,7 +1280,6 @@ inline const char *getQualifierString(TQualifier q)
|
|||
case EvqVaryingOut: return "varying";
|
||||
case EvqUniform: return "uniform";
|
||||
case EvqBuffer: return "buffer";
|
||||
case EvqPatch: return "patch";
|
||||
case EvqVertexIn: return "in";
|
||||
case EvqFragmentOut: return "out";
|
||||
case EvqVertexOut: return "out";
|
||||
|
@ -1371,6 +1293,8 @@ inline const char *getQualifierString(TQualifier q)
|
|||
case EvqPosition: return "Position";
|
||||
case EvqPointSize: return "PointSize";
|
||||
case EvqDrawID: return "DrawID";
|
||||
case EvqBaseVertex: return "BaseVertex";
|
||||
case EvqBaseInstance: return "BaseInstance";
|
||||
case EvqFragCoord: return "FragCoord";
|
||||
case EvqFrontFacing: return "FrontFacing";
|
||||
case EvqHelperInvocation: return "HelperInvocation";
|
||||
|
@ -1386,7 +1310,6 @@ inline const char *getQualifierString(TQualifier q)
|
|||
case EvqLayer: return "Layer";
|
||||
case EvqLastFragColor: return "LastFragColor";
|
||||
case EvqLastFragData: return "LastFragData";
|
||||
case EvqFragmentInOut: return "inout";
|
||||
case EvqSmoothOut: return "smooth out";
|
||||
case EvqCentroidOut: return "smooth centroid out";
|
||||
case EvqFlatOut: return "flat out";
|
||||
|
@ -1412,30 +1335,11 @@ inline const char *getQualifierString(TQualifier q)
|
|||
case EvqGeometryIn: return "in";
|
||||
case EvqGeometryOut: return "out";
|
||||
case EvqPerVertexIn: return "gl_in";
|
||||
case EvqPrimitiveIDIn: return "gl_PrimitiveIDIn";
|
||||
case EvqInvocationID: return "gl_InvocationID";
|
||||
case EvqPrimitiveID: return "gl_PrimitiveID";
|
||||
case EvqPrecise: return "precise";
|
||||
case EvqClipDistance: return "ClipDistance";
|
||||
case EvqSample: return "sample";
|
||||
case EvqSampleIn: return "sample in";
|
||||
case EvqSampleOut: return "sample out";
|
||||
case EvqSampleID: return "SampleID";
|
||||
case EvqSamplePosition: return "SamplePosition";
|
||||
case EvqSampleMaskIn: return "SampleMaskIn";
|
||||
case EvqSampleMask: return "SampleMask";
|
||||
case EvqNumSamples: return "NumSamples";
|
||||
case EvqPatchIn: return "patch in";
|
||||
case EvqPatchOut: return "patch out";
|
||||
case EvqTessControlIn: return "in";
|
||||
case EvqTessControlOut: return "out";
|
||||
case EvqPerVertexOut: return "gl_out";
|
||||
case EvqPatchVerticesIn: return "PatchVerticesIn";
|
||||
case EvqTessLevelOuter: return "TessLevelOuter";
|
||||
case EvqTessLevelInner: return "TessLevelInner";
|
||||
case EvqTessEvaluationIn: return "in";
|
||||
case EvqTessEvaluationOut: return "out";
|
||||
case EvqTessCoord: return "TessCoord";
|
||||
default: UNREACHABLE(); return "unknown qualifier";
|
||||
}
|
||||
// clang-format on
|
||||
|
@ -1564,34 +1468,6 @@ inline const char *getGeometryShaderPrimitiveTypeString(TLayoutPrimitiveType pri
|
|||
}
|
||||
}
|
||||
|
||||
inline const char *getTessEvaluationShaderTypeString(TLayoutTessEvaluationType type)
|
||||
{
|
||||
switch (type)
|
||||
{
|
||||
case EtetTriangles:
|
||||
return "triangles";
|
||||
case EtetQuads:
|
||||
return "quads";
|
||||
case EtetIsolines:
|
||||
return "isolines";
|
||||
case EtetEqualSpacing:
|
||||
return "equal_spacing";
|
||||
case EtetFractionalEvenSpacing:
|
||||
return "fractional_even_spacing";
|
||||
case EtetFractionalOddSpacing:
|
||||
return "fractional_odd_spacing";
|
||||
case EtetCw:
|
||||
return "cw";
|
||||
case EtetCcw:
|
||||
return "ccw";
|
||||
case EtetPointMode:
|
||||
return "point_mode";
|
||||
default:
|
||||
UNREACHABLE();
|
||||
return "unknown tessellation evaluation shader variable type";
|
||||
}
|
||||
}
|
||||
|
||||
} // namespace sh
|
||||
|
||||
#endif // COMPILER_TRANSLATOR_BASETYPES_H_
|
||||
|
|
|
@ -34,6 +34,7 @@ class TBuiltinsWorkaroundGLSL : public TIntermTraverser
|
|||
ShCompileOptions mCompileOptions;
|
||||
|
||||
bool isBaseInstanceDeclared = false;
|
||||
bool isBaseVertexDeclared = false;
|
||||
};
|
||||
|
||||
TBuiltinsWorkaroundGLSL::TBuiltinsWorkaroundGLSL(TSymbolTable *symbolTable,
|
||||
|
@ -80,7 +81,7 @@ bool TBuiltinsWorkaroundGLSL::visitDeclaration(Visit, TIntermDeclaration *node)
|
|||
for (TIntermNode *variableNode : sequence)
|
||||
{
|
||||
TIntermSymbol *variable = variableNode->getAsSymbolNode();
|
||||
if (variable && variable->variable().symbolType() == SymbolType::BuiltIn)
|
||||
if (variable && variable->variable().symbolType() == SymbolType::AngleInternal)
|
||||
{
|
||||
if (variable->getName() == "angle_BaseInstance")
|
||||
{
|
||||
|
|
|
@ -38,6 +38,7 @@ BlockLayoutType GetBlockLayoutType(TLayoutBlockStorage blockStorage)
|
|||
}
|
||||
}
|
||||
|
||||
// TODO(jiawei.shao@intel.com): implement GL_EXT_shader_io_blocks.
|
||||
BlockType GetBlockType(TQualifier qualifier)
|
||||
{
|
||||
switch (qualifier)
|
||||
|
@ -46,6 +47,8 @@ BlockType GetBlockType(TQualifier qualifier)
|
|||
return BlockType::BLOCK_UNIFORM;
|
||||
case EvqBuffer:
|
||||
return BlockType::BLOCK_BUFFER;
|
||||
case EvqPerVertexIn:
|
||||
return BlockType::BLOCK_IN;
|
||||
default:
|
||||
UNREACHABLE();
|
||||
return BlockType::BLOCK_UNIFORM;
|
||||
|
@ -96,18 +99,6 @@ ShaderVariable *FindVariableInInterfaceBlock(const ImmutableString &name,
|
|||
return FindVariable(name, &namedBlock->fields);
|
||||
}
|
||||
|
||||
ShaderVariable *FindShaderIOBlockVariable(const ImmutableString &blockName,
|
||||
std::vector<ShaderVariable> *infoList)
|
||||
{
|
||||
for (size_t index = 0; index < infoList->size(); ++index)
|
||||
{
|
||||
if (blockName == (*infoList)[index].structOrBlockName)
|
||||
return &(*infoList)[index];
|
||||
}
|
||||
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
// Traverses the intermediate tree to collect all attributes, uniforms, varyings, fragment outputs,
|
||||
// shared data and interface blocks.
|
||||
class CollectVariablesTraverser : public TIntermTraverser
|
||||
|
@ -121,12 +112,11 @@ class CollectVariablesTraverser : public TIntermTraverser
|
|||
std::vector<ShaderVariable> *sharedVariables,
|
||||
std::vector<InterfaceBlock> *uniformBlocks,
|
||||
std::vector<InterfaceBlock> *shaderStorageBlocks,
|
||||
std::vector<InterfaceBlock> *inBlocks,
|
||||
ShHashFunction64 hashFunction,
|
||||
TSymbolTable *symbolTable,
|
||||
GLenum shaderType,
|
||||
const TExtensionBehavior &extensionBehavior,
|
||||
const ShBuiltInResources &resources,
|
||||
int tessControlShaderOutputVertices);
|
||||
const TExtensionBehavior &extensionBehavior);
|
||||
|
||||
bool visitGlobalQualifierDeclaration(Visit visit,
|
||||
TIntermGlobalQualifierDeclaration *node) override;
|
||||
|
@ -139,14 +129,10 @@ class CollectVariablesTraverser : public TIntermTraverser
|
|||
|
||||
void setFieldOrVariableProperties(const TType &type,
|
||||
bool staticUse,
|
||||
bool isShaderIOBlock,
|
||||
bool isPatch,
|
||||
ShaderVariable *variableOut) const;
|
||||
void setFieldProperties(const TType &type,
|
||||
const ImmutableString &name,
|
||||
bool staticUse,
|
||||
bool isShaderIOBlock,
|
||||
bool isPatch,
|
||||
ShaderVariable *variableOut) const;
|
||||
void setCommonVariableProperties(const TType &type,
|
||||
const TVariable &variable,
|
||||
|
@ -167,6 +153,7 @@ class CollectVariablesTraverser : public TIntermTraverser
|
|||
std::vector<ShaderVariable> *varyings);
|
||||
void recordBuiltInFragmentOutputUsed(const TVariable &variable, bool *addedFlag);
|
||||
void recordBuiltInAttributeUsed(const TVariable &variable, bool *addedFlag);
|
||||
InterfaceBlock *recordGLInUsed(const TType &glInType);
|
||||
InterfaceBlock *findNamedInterfaceBlock(const ImmutableString &name) const;
|
||||
|
||||
std::vector<ShaderVariable> *mAttribs;
|
||||
|
@ -177,12 +164,12 @@ class CollectVariablesTraverser : public TIntermTraverser
|
|||
std::vector<ShaderVariable> *mSharedVariables;
|
||||
std::vector<InterfaceBlock> *mUniformBlocks;
|
||||
std::vector<InterfaceBlock> *mShaderStorageBlocks;
|
||||
std::vector<InterfaceBlock> *mInBlocks;
|
||||
|
||||
std::map<std::string, ShaderVariable *> mInterfaceBlockFields;
|
||||
|
||||
// Shader uniforms
|
||||
bool mDepthRangeAdded;
|
||||
bool mNumSamplesAdded;
|
||||
|
||||
// Compute Shader builtins
|
||||
bool mNumWorkGroupsAdded;
|
||||
|
@ -196,11 +183,12 @@ class CollectVariablesTraverser : public TIntermTraverser
|
|||
bool mVertexIDAdded;
|
||||
bool mPointSizeAdded;
|
||||
bool mDrawIDAdded;
|
||||
bool mBaseVertexAdded;
|
||||
bool mBaseInstanceAdded;
|
||||
|
||||
// Vertex Shader and Geometry Shader builtins
|
||||
bool mPositionAdded;
|
||||
bool mClipDistanceAdded;
|
||||
bool mCullDistanceAdded;
|
||||
|
||||
// Fragment Shader builtins
|
||||
bool mPointCoordAdded;
|
||||
|
@ -214,16 +202,9 @@ class CollectVariablesTraverser : public TIntermTraverser
|
|||
bool mFragDepthAdded;
|
||||
bool mSecondaryFragColorEXTAdded;
|
||||
bool mSecondaryFragDataEXTAdded;
|
||||
bool mSampleIDAdded;
|
||||
bool mSamplePositionAdded;
|
||||
bool mSampleMaskAdded;
|
||||
bool mSampleMaskInAdded;
|
||||
|
||||
// Geometry and Tessellation Shader builtins
|
||||
bool mPerVertexInAdded;
|
||||
bool mPerVertexOutAdded;
|
||||
|
||||
// Geometry Shader builtins
|
||||
bool mPerVertexInAdded;
|
||||
bool mPrimitiveIDInAdded;
|
||||
bool mInvocationIDAdded;
|
||||
|
||||
|
@ -234,18 +215,10 @@ class CollectVariablesTraverser : public TIntermTraverser
|
|||
// Shared memory variables
|
||||
bool mSharedVariableAdded;
|
||||
|
||||
// Tessellation Shader builtins
|
||||
bool mPatchVerticesInAdded;
|
||||
bool mTessLevelOuterAdded;
|
||||
bool mTessLevelInnerAdded;
|
||||
bool mTessCoordAdded;
|
||||
const int mTessControlShaderOutputVertices;
|
||||
|
||||
ShHashFunction64 mHashFunction;
|
||||
|
||||
GLenum mShaderType;
|
||||
const TExtensionBehavior &mExtensionBehavior;
|
||||
const ShBuiltInResources &mResources;
|
||||
};
|
||||
|
||||
CollectVariablesTraverser::CollectVariablesTraverser(
|
||||
|
@ -257,12 +230,11 @@ CollectVariablesTraverser::CollectVariablesTraverser(
|
|||
std::vector<sh::ShaderVariable> *sharedVariables,
|
||||
std::vector<sh::InterfaceBlock> *uniformBlocks,
|
||||
std::vector<sh::InterfaceBlock> *shaderStorageBlocks,
|
||||
std::vector<sh::InterfaceBlock> *inBlocks,
|
||||
ShHashFunction64 hashFunction,
|
||||
TSymbolTable *symbolTable,
|
||||
GLenum shaderType,
|
||||
const TExtensionBehavior &extensionBehavior,
|
||||
const ShBuiltInResources &resources,
|
||||
int tessControlShaderOutputVertices)
|
||||
const TExtensionBehavior &extensionBehavior)
|
||||
: TIntermTraverser(true, false, false, symbolTable),
|
||||
mAttribs(attribs),
|
||||
mOutputVariables(outputVariables),
|
||||
|
@ -272,8 +244,8 @@ CollectVariablesTraverser::CollectVariablesTraverser(
|
|||
mSharedVariables(sharedVariables),
|
||||
mUniformBlocks(uniformBlocks),
|
||||
mShaderStorageBlocks(shaderStorageBlocks),
|
||||
mInBlocks(inBlocks),
|
||||
mDepthRangeAdded(false),
|
||||
mNumSamplesAdded(false),
|
||||
mNumWorkGroupsAdded(false),
|
||||
mWorkGroupIDAdded(false),
|
||||
mLocalInvocationIDAdded(false),
|
||||
|
@ -283,9 +255,10 @@ CollectVariablesTraverser::CollectVariablesTraverser(
|
|||
mVertexIDAdded(false),
|
||||
mPointSizeAdded(false),
|
||||
mDrawIDAdded(false),
|
||||
mBaseVertexAdded(false),
|
||||
mBaseInstanceAdded(false),
|
||||
mPositionAdded(false),
|
||||
mClipDistanceAdded(false),
|
||||
mCullDistanceAdded(false),
|
||||
mPointCoordAdded(false),
|
||||
mFrontFacingAdded(false),
|
||||
mHelperInvocationAdded(false),
|
||||
|
@ -297,26 +270,15 @@ CollectVariablesTraverser::CollectVariablesTraverser(
|
|||
mFragDepthAdded(false),
|
||||
mSecondaryFragColorEXTAdded(false),
|
||||
mSecondaryFragDataEXTAdded(false),
|
||||
mSampleIDAdded(false),
|
||||
mSamplePositionAdded(false),
|
||||
mSampleMaskAdded(false),
|
||||
mSampleMaskInAdded(false),
|
||||
mPerVertexInAdded(false),
|
||||
mPerVertexOutAdded(false),
|
||||
mPrimitiveIDInAdded(false),
|
||||
mInvocationIDAdded(false),
|
||||
mPrimitiveIDAdded(false),
|
||||
mLayerAdded(false),
|
||||
mSharedVariableAdded(false),
|
||||
mPatchVerticesInAdded(false),
|
||||
mTessLevelOuterAdded(false),
|
||||
mTessLevelInnerAdded(false),
|
||||
mTessCoordAdded(false),
|
||||
mTessControlShaderOutputVertices(tessControlShaderOutputVertices),
|
||||
mHashFunction(hashFunction),
|
||||
mShaderType(shaderType),
|
||||
mExtensionBehavior(extensionBehavior),
|
||||
mResources(resources)
|
||||
mExtensionBehavior(extensionBehavior)
|
||||
{}
|
||||
|
||||
std::string CollectVariablesTraverser::getMappedName(const TSymbol *symbol) const
|
||||
|
@ -332,12 +294,7 @@ void CollectVariablesTraverser::setBuiltInInfoFromSymbol(const TVariable &variab
|
|||
info->name = variable.name().data();
|
||||
info->mappedName = variable.name().data();
|
||||
|
||||
bool isShaderIOBlock =
|
||||
IsShaderIoBlock(type.getQualifier()) && type.getInterfaceBlock() != nullptr;
|
||||
bool isPatch =
|
||||
type.getQualifier() == EvqTessLevelInner || type.getQualifier() == EvqTessLevelOuter;
|
||||
|
||||
setFieldOrVariableProperties(type, true, isShaderIOBlock, isPatch, info);
|
||||
setFieldOrVariableProperties(type, true, info);
|
||||
}
|
||||
|
||||
void CollectVariablesTraverser::recordBuiltInVaryingUsed(const TVariable &variable,
|
||||
|
@ -384,6 +341,24 @@ void CollectVariablesTraverser::recordBuiltInAttributeUsed(const TVariable &vari
|
|||
}
|
||||
}
|
||||
|
||||
InterfaceBlock *CollectVariablesTraverser::recordGLInUsed(const TType &glInType)
|
||||
{
|
||||
if (!mPerVertexInAdded)
|
||||
{
|
||||
ASSERT(glInType.getQualifier() == EvqPerVertexIn);
|
||||
InterfaceBlock info;
|
||||
recordInterfaceBlock("gl_in", glInType, &info);
|
||||
|
||||
mPerVertexInAdded = true;
|
||||
mInBlocks->push_back(info);
|
||||
return &mInBlocks->back();
|
||||
}
|
||||
else
|
||||
{
|
||||
return FindVariable(ImmutableString("gl_PerVertex"), mInBlocks);
|
||||
}
|
||||
}
|
||||
|
||||
bool CollectVariablesTraverser::visitGlobalQualifierDeclaration(
|
||||
Visit visit,
|
||||
TIntermGlobalQualifierDeclaration *node)
|
||||
|
@ -413,30 +388,15 @@ void CollectVariablesTraverser::visitSymbol(TIntermSymbol *symbol)
|
|||
|
||||
// Check the qualifier from the variable, not from the symbol node. The node may have a
|
||||
// different qualifier if it's the result of a folded ternary node.
|
||||
TQualifier qualifier = symbol->variable().getType().getQualifier();
|
||||
const TInterfaceBlock *interfaceBlock = symbol->getType().getInterfaceBlock();
|
||||
TQualifier qualifier = symbol->variable().getType().getQualifier();
|
||||
|
||||
if (IsVaryingIn(qualifier))
|
||||
{
|
||||
if (interfaceBlock)
|
||||
{
|
||||
var = FindShaderIOBlockVariable(interfaceBlock->name(), mInputVaryings);
|
||||
}
|
||||
else
|
||||
{
|
||||
var = FindVariable(symbolName, mInputVaryings);
|
||||
}
|
||||
var = FindVariable(symbolName, mInputVaryings);
|
||||
}
|
||||
else if (IsVaryingOut(qualifier))
|
||||
{
|
||||
if (interfaceBlock)
|
||||
{
|
||||
var = FindShaderIOBlockVariable(interfaceBlock->name(), mOutputVaryings);
|
||||
}
|
||||
else
|
||||
{
|
||||
var = FindVariable(symbolName, mOutputVaryings);
|
||||
}
|
||||
var = FindVariable(symbolName, mOutputVaryings);
|
||||
}
|
||||
else if (symbol->getType().getBasicType() == EbtInterfaceBlock)
|
||||
{
|
||||
|
@ -489,48 +449,6 @@ void CollectVariablesTraverser::visitSymbol(TIntermSymbol *symbol)
|
|||
mDepthRangeAdded = true;
|
||||
}
|
||||
}
|
||||
else if (symbolName == "gl_NumSamples")
|
||||
{
|
||||
ASSERT(qualifier == EvqUniform);
|
||||
|
||||
if (!mNumSamplesAdded)
|
||||
{
|
||||
ShaderVariable info;
|
||||
const char kName[] = "gl_NumSamples";
|
||||
info.name = kName;
|
||||
info.mappedName = kName;
|
||||
info.type = GL_INT;
|
||||
info.precision = GL_LOW_INT;
|
||||
info.staticUse = true;
|
||||
info.active = true;
|
||||
|
||||
mUniforms->push_back(info);
|
||||
mNumSamplesAdded = true;
|
||||
}
|
||||
}
|
||||
else if (symbolName == "gl_LastFragData" && qualifier == EvqGlobal)
|
||||
{
|
||||
// If gl_LastFragData is redeclared, the qualifier of redeclaration is EvqGlobal, and it
|
||||
// makes "gl_LastFragData" can't be collected in this function. That's because
|
||||
// "gl_LastFragData" is redeclared like below. E.g., "highp vec4
|
||||
// gl_LastFragData[gl_MaxDrawBuffers];" So, if gl_LastFragData can be parsed with a correct
|
||||
// qualifier in PasreContext.cpp, this code isn't needed.
|
||||
if (!mLastFragDataAdded)
|
||||
{
|
||||
ShaderVariable info;
|
||||
|
||||
const TType &type = symbol->getType();
|
||||
|
||||
info.name = symbolName.data();
|
||||
info.mappedName = symbolName.data();
|
||||
setFieldOrVariableProperties(type, true, false, false, &info);
|
||||
info.active = true;
|
||||
|
||||
mInputVaryings->push_back(info);
|
||||
mLastFragDataAdded = true;
|
||||
}
|
||||
return;
|
||||
}
|
||||
else
|
||||
{
|
||||
switch (qualifier)
|
||||
|
@ -540,11 +458,11 @@ void CollectVariablesTraverser::visitSymbol(TIntermSymbol *symbol)
|
|||
var = FindVariable(symbolName, mAttribs);
|
||||
break;
|
||||
case EvqFragmentOut:
|
||||
case EvqFragmentInOut:
|
||||
var = FindVariable(symbolName, mOutputVariables);
|
||||
break;
|
||||
case EvqUniform:
|
||||
{
|
||||
const TInterfaceBlock *interfaceBlock = symbol->getType().getInterfaceBlock();
|
||||
if (interfaceBlock)
|
||||
{
|
||||
var = FindVariableInInterfaceBlock(symbolName, interfaceBlock, mUniformBlocks);
|
||||
|
@ -560,6 +478,7 @@ void CollectVariablesTraverser::visitSymbol(TIntermSymbol *symbol)
|
|||
break;
|
||||
case EvqBuffer:
|
||||
{
|
||||
const TInterfaceBlock *interfaceBlock = symbol->getType().getInterfaceBlock();
|
||||
var =
|
||||
FindVariableInInterfaceBlock(symbolName, interfaceBlock, mShaderStorageBlocks);
|
||||
}
|
||||
|
@ -611,6 +530,12 @@ void CollectVariablesTraverser::visitSymbol(TIntermSymbol *symbol)
|
|||
case EvqDrawID:
|
||||
recordBuiltInAttributeUsed(symbol->variable(), &mDrawIDAdded);
|
||||
return;
|
||||
case EvqBaseVertex:
|
||||
recordBuiltInAttributeUsed(symbol->variable(), &mBaseVertexAdded);
|
||||
return;
|
||||
case EvqBaseInstance:
|
||||
recordBuiltInAttributeUsed(symbol->variable(), &mBaseInstanceAdded);
|
||||
return;
|
||||
case EvqLastFragData:
|
||||
recordBuiltInVaryingUsed(symbol->variable(), &mLastFragDataAdded, mInputVaryings);
|
||||
return;
|
||||
|
@ -658,9 +583,7 @@ void CollectVariablesTraverser::visitSymbol(TIntermSymbol *symbol)
|
|||
}
|
||||
else
|
||||
{
|
||||
ASSERT(mShaderType == GL_FRAGMENT_SHADER ||
|
||||
mShaderType == GL_TESS_CONTROL_SHADER ||
|
||||
mShaderType == GL_TESS_EVALUATION_SHADER);
|
||||
ASSERT(mShaderType == GL_FRAGMENT_SHADER);
|
||||
recordBuiltInVaryingUsed(symbol->variable(), &mPrimitiveIDAdded,
|
||||
mInputVaryings);
|
||||
}
|
||||
|
@ -691,54 +614,6 @@ void CollectVariablesTraverser::visitSymbol(TIntermSymbol *symbol)
|
|||
case EvqClipDistance:
|
||||
recordBuiltInVaryingUsed(symbol->variable(), &mClipDistanceAdded, mOutputVaryings);
|
||||
return;
|
||||
case EvqSampleID:
|
||||
recordBuiltInVaryingUsed(symbol->variable(), &mSampleIDAdded, mInputVaryings);
|
||||
return;
|
||||
case EvqSamplePosition:
|
||||
recordBuiltInVaryingUsed(symbol->variable(), &mSamplePositionAdded, mInputVaryings);
|
||||
return;
|
||||
case EvqSampleMaskIn:
|
||||
recordBuiltInVaryingUsed(symbol->variable(), &mSampleMaskInAdded, mInputVaryings);
|
||||
return;
|
||||
case EvqSampleMask:
|
||||
recordBuiltInFragmentOutputUsed(symbol->variable(), &mSampleMaskAdded);
|
||||
return;
|
||||
case EvqCullDistance:
|
||||
recordBuiltInVaryingUsed(symbol->variable(), &mCullDistanceAdded, mOutputVaryings);
|
||||
return;
|
||||
case EvqPatchVerticesIn:
|
||||
recordBuiltInVaryingUsed(symbol->variable(), &mPatchVerticesInAdded,
|
||||
mInputVaryings);
|
||||
break;
|
||||
case EvqTessCoord:
|
||||
recordBuiltInVaryingUsed(symbol->variable(), &mTessCoordAdded, mInputVaryings);
|
||||
break;
|
||||
case EvqTessLevelOuter:
|
||||
if (mShaderType == GL_TESS_CONTROL_SHADER)
|
||||
{
|
||||
recordBuiltInVaryingUsed(symbol->variable(), &mTessLevelOuterAdded,
|
||||
mOutputVaryings);
|
||||
}
|
||||
else
|
||||
{
|
||||
ASSERT(mShaderType == GL_TESS_EVALUATION_SHADER);
|
||||
recordBuiltInVaryingUsed(symbol->variable(), &mTessLevelOuterAdded,
|
||||
mInputVaryings);
|
||||
}
|
||||
break;
|
||||
case EvqTessLevelInner:
|
||||
if (mShaderType == GL_TESS_CONTROL_SHADER)
|
||||
{
|
||||
recordBuiltInVaryingUsed(symbol->variable(), &mTessLevelInnerAdded,
|
||||
mOutputVaryings);
|
||||
}
|
||||
else
|
||||
{
|
||||
ASSERT(mShaderType == GL_TESS_EVALUATION_SHADER);
|
||||
recordBuiltInVaryingUsed(symbol->variable(), &mTessLevelInnerAdded,
|
||||
mInputVaryings);
|
||||
}
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
@ -751,25 +626,25 @@ void CollectVariablesTraverser::visitSymbol(TIntermSymbol *symbol)
|
|||
|
||||
void CollectVariablesTraverser::setFieldOrVariableProperties(const TType &type,
|
||||
bool staticUse,
|
||||
bool isShaderIOBlock,
|
||||
bool isPatch,
|
||||
ShaderVariable *variableOut) const
|
||||
{
|
||||
ASSERT(variableOut);
|
||||
|
||||
variableOut->staticUse = staticUse;
|
||||
variableOut->isShaderIOBlock = isShaderIOBlock;
|
||||
variableOut->isPatch = isPatch;
|
||||
variableOut->staticUse = staticUse;
|
||||
|
||||
const TStructure *structure = type.getStruct();
|
||||
const TInterfaceBlock *interfaceBlock = type.getInterfaceBlock();
|
||||
if (structure)
|
||||
const TStructure *structure = type.getStruct();
|
||||
if (!structure)
|
||||
{
|
||||
variableOut->type = GLVariableType(type);
|
||||
variableOut->precision = GLVariablePrecision(type);
|
||||
}
|
||||
else
|
||||
{
|
||||
// Structures use a NONE type that isn't exposed outside ANGLE.
|
||||
variableOut->type = GL_NONE;
|
||||
if (structure->symbolType() != SymbolType::Empty)
|
||||
{
|
||||
variableOut->structOrBlockName = structure->name().data();
|
||||
variableOut->structName = structure->name().data();
|
||||
}
|
||||
|
||||
const TFieldList &fields = structure->fields();
|
||||
|
@ -779,73 +654,24 @@ void CollectVariablesTraverser::setFieldOrVariableProperties(const TType &type,
|
|||
// Regardless of the variable type (uniform, in/out etc.) its fields are always plain
|
||||
// ShaderVariable objects.
|
||||
ShaderVariable fieldVariable;
|
||||
setFieldProperties(*field->type(), field->name(), staticUse, isShaderIOBlock, isPatch,
|
||||
&fieldVariable);
|
||||
setFieldProperties(*field->type(), field->name(), staticUse, &fieldVariable);
|
||||
variableOut->fields.push_back(fieldVariable);
|
||||
}
|
||||
}
|
||||
else if (interfaceBlock && isShaderIOBlock)
|
||||
{
|
||||
variableOut->type = GL_NONE;
|
||||
if (interfaceBlock->symbolType() != SymbolType::Empty)
|
||||
{
|
||||
variableOut->structOrBlockName = interfaceBlock->name().data();
|
||||
variableOut->mappedStructOrBlockName =
|
||||
HashName(interfaceBlock->name(), mHashFunction, nullptr).data();
|
||||
}
|
||||
const TFieldList &fields = interfaceBlock->fields();
|
||||
for (const TField *field : fields)
|
||||
{
|
||||
ShaderVariable fieldVariable;
|
||||
setFieldProperties(*field->type(), field->name(), staticUse, true, isPatch,
|
||||
&fieldVariable);
|
||||
fieldVariable.isShaderIOBlock = true;
|
||||
variableOut->fields.push_back(fieldVariable);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
variableOut->type = GLVariableType(type);
|
||||
variableOut->precision = GLVariablePrecision(type);
|
||||
}
|
||||
|
||||
const TSpan<const unsigned int> &arraySizes = type.getArraySizes();
|
||||
if (!arraySizes.empty())
|
||||
{
|
||||
variableOut->arraySizes.assign(arraySizes.begin(), arraySizes.end());
|
||||
|
||||
if (arraySizes[0] == 0)
|
||||
{
|
||||
// Tessellation Control & Evaluation shader inputs:
|
||||
// Declaring an array size is optional. If no size is specified, it will be taken from
|
||||
// the implementation-dependent maximum patch size (gl_MaxPatchVertices).
|
||||
if (type.getQualifier() == EvqTessControlIn ||
|
||||
type.getQualifier() == EvqTessEvaluationIn)
|
||||
{
|
||||
variableOut->arraySizes[0] = mResources.MaxPatchVertices;
|
||||
}
|
||||
|
||||
// Tessellation Control shader outputs:
|
||||
// Declaring an array size is optional. If no size is specified, it will be taken from
|
||||
// output patch size declared in the shader.
|
||||
if (type.getQualifier() == EvqTessControlOut)
|
||||
{
|
||||
ASSERT(mTessControlShaderOutputVertices > 0);
|
||||
variableOut->arraySizes[0] = mTessControlShaderOutputVertices;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void CollectVariablesTraverser::setFieldProperties(const TType &type,
|
||||
const ImmutableString &name,
|
||||
bool staticUse,
|
||||
bool isShaderIOBlock,
|
||||
bool isPatch,
|
||||
ShaderVariable *variableOut) const
|
||||
{
|
||||
ASSERT(variableOut);
|
||||
setFieldOrVariableProperties(type, staticUse, isShaderIOBlock, isPatch, variableOut);
|
||||
setFieldOrVariableProperties(type, staticUse, variableOut);
|
||||
variableOut->name.assign(name.data(), name.length());
|
||||
variableOut->mappedName = HashName(name, mHashFunction, nullptr).data();
|
||||
}
|
||||
|
@ -855,37 +681,12 @@ void CollectVariablesTraverser::setCommonVariableProperties(const TType &type,
|
|||
ShaderVariable *variableOut) const
|
||||
{
|
||||
ASSERT(variableOut);
|
||||
ASSERT(type.getInterfaceBlock() == nullptr || IsShaderIoBlock(type.getQualifier()) ||
|
||||
type.getQualifier() == EvqPatchIn || type.getQualifier() == EvqPatchOut);
|
||||
|
||||
const bool staticUse = mSymbolTable->isStaticallyUsed(variable);
|
||||
const bool isShaderIOBlock = type.getInterfaceBlock() != nullptr;
|
||||
const bool isPatch = type.getQualifier() == EvqPatchIn || type.getQualifier() == EvqPatchOut;
|
||||
|
||||
setFieldOrVariableProperties(type, staticUse, isShaderIOBlock, isPatch, variableOut);
|
||||
|
||||
const bool isNamed = variable.symbolType() != SymbolType::Empty;
|
||||
|
||||
ASSERT(isNamed || isShaderIOBlock);
|
||||
if (isNamed)
|
||||
{
|
||||
variableOut->name.assign(variable.name().data(), variable.name().length());
|
||||
variableOut->mappedName = getMappedName(&variable);
|
||||
}
|
||||
|
||||
// For I/O blocks, additionally store the name of the block as blockName. If the variable is
|
||||
// unnamed, this name will be used instead for the purpose of interface matching.
|
||||
if (isShaderIOBlock)
|
||||
{
|
||||
const TInterfaceBlock *interfaceBlock = type.getInterfaceBlock();
|
||||
ASSERT(interfaceBlock);
|
||||
|
||||
variableOut->structOrBlockName.assign(interfaceBlock->name().data(),
|
||||
interfaceBlock->name().length());
|
||||
variableOut->mappedStructOrBlockName =
|
||||
HashName(interfaceBlock->name(), mHashFunction, nullptr).data();
|
||||
variableOut->isShaderIOBlock = true;
|
||||
}
|
||||
variableOut->staticUse = mSymbolTable->isStaticallyUsed(variable);
|
||||
setFieldOrVariableProperties(type, variableOut->staticUse, variableOut);
|
||||
ASSERT(variable.symbolType() != SymbolType::Empty);
|
||||
variableOut->name.assign(variable.name().data(), variable.name().length());
|
||||
variableOut->mappedName = getMappedName(&variable);
|
||||
}
|
||||
|
||||
ShaderVariable CollectVariablesTraverser::recordAttribute(const TIntermSymbol &variable) const
|
||||
|
@ -910,7 +711,6 @@ ShaderVariable CollectVariablesTraverser::recordOutputVariable(const TIntermSymb
|
|||
|
||||
outputVariable.location = type.getLayoutQualifier().location;
|
||||
outputVariable.index = type.getLayoutQualifier().index;
|
||||
outputVariable.yuv = type.getLayoutQualifier().yuv;
|
||||
return outputVariable;
|
||||
}
|
||||
|
||||
|
@ -938,64 +738,15 @@ ShaderVariable CollectVariablesTraverser::recordVarying(const TIntermSymbol &var
|
|||
varying.isInvariant = true;
|
||||
}
|
||||
break;
|
||||
case EvqPatchIn:
|
||||
case EvqPatchOut:
|
||||
varying.isPatch = true;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
varying.interpolation = GetInterpolationType(type.getQualifier());
|
||||
|
||||
// Shader I/O block properties
|
||||
if (type.getBasicType() == EbtInterfaceBlock)
|
||||
{
|
||||
bool isBlockImplicitLocation = false;
|
||||
int location = type.getLayoutQualifier().location;
|
||||
|
||||
// when a interface has not location in layout, assign to the zero.
|
||||
if (location < 0)
|
||||
{
|
||||
location = 0;
|
||||
isBlockImplicitLocation = true;
|
||||
}
|
||||
|
||||
const TInterfaceBlock *blockType = type.getInterfaceBlock();
|
||||
ASSERT(blockType->fields().size() == varying.fields.size());
|
||||
|
||||
for (size_t fieldIndex = 0; fieldIndex < varying.fields.size(); ++fieldIndex)
|
||||
{
|
||||
const TField *blockField = blockType->fields()[fieldIndex];
|
||||
ShaderVariable &fieldVariable = varying.fields[fieldIndex];
|
||||
const TType &fieldType = *blockField->type();
|
||||
|
||||
fieldVariable.hasImplicitLocation = isBlockImplicitLocation;
|
||||
fieldVariable.isPatch = varying.isPatch;
|
||||
|
||||
int fieldLocation = fieldType.getLayoutQualifier().location;
|
||||
if (fieldLocation >= 0)
|
||||
{
|
||||
fieldVariable.hasImplicitLocation = false;
|
||||
fieldVariable.location = fieldLocation;
|
||||
location = fieldLocation;
|
||||
}
|
||||
else
|
||||
{
|
||||
fieldVariable.location = location;
|
||||
location += fieldType.getLocationCount();
|
||||
}
|
||||
|
||||
if (fieldType.getQualifier() != EvqGlobal)
|
||||
{
|
||||
fieldVariable.interpolation = GetFieldInterpolationType(fieldType.getQualifier());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return varying;
|
||||
}
|
||||
|
||||
// TODO(jiawei.shao@intel.com): implement GL_EXT_shader_io_blocks.
|
||||
void CollectVariablesTraverser::recordInterfaceBlock(const char *instanceName,
|
||||
const TType &interfaceBlockType,
|
||||
InterfaceBlock *interfaceBlock) const
|
||||
|
@ -1008,13 +759,11 @@ void CollectVariablesTraverser::recordInterfaceBlock(const char *instanceName,
|
|||
|
||||
interfaceBlock->name = blockType->name().data();
|
||||
interfaceBlock->mappedName = getMappedName(blockType);
|
||||
|
||||
const bool isGLInBuiltin = (instanceName != nullptr) && strncmp(instanceName, "gl_in", 5u) == 0;
|
||||
if (instanceName != nullptr)
|
||||
{
|
||||
interfaceBlock->instanceName = instanceName;
|
||||
const TSymbol *blockSymbol = nullptr;
|
||||
if (isGLInBuiltin)
|
||||
if (strncmp(instanceName, "gl_in", 5u) == 0)
|
||||
{
|
||||
blockSymbol = mSymbolTable->getGlInVariableWithArraySize();
|
||||
}
|
||||
|
@ -1026,7 +775,6 @@ void CollectVariablesTraverser::recordInterfaceBlock(const char *instanceName,
|
|||
interfaceBlock->staticUse =
|
||||
mSymbolTable->isStaticallyUsed(*static_cast<const TVariable *>(blockSymbol));
|
||||
}
|
||||
|
||||
ASSERT(!interfaceBlockType.isArrayOfArrays()); // Disallowed by GLSL ES 3.10 section 4.3.9
|
||||
interfaceBlock->arraySize =
|
||||
interfaceBlockType.isArray() ? interfaceBlockType.getOutermostArraySize() : 0;
|
||||
|
@ -1043,7 +791,6 @@ void CollectVariablesTraverser::recordInterfaceBlock(const char *instanceName,
|
|||
|
||||
// Gather field information
|
||||
bool anyFieldStaticallyUsed = false;
|
||||
|
||||
for (const TField *field : blockType->fields())
|
||||
{
|
||||
const TType &fieldType = *field->type();
|
||||
|
@ -1064,7 +811,7 @@ void CollectVariablesTraverser::recordInterfaceBlock(const char *instanceName,
|
|||
}
|
||||
|
||||
ShaderVariable fieldVariable;
|
||||
setFieldProperties(fieldType, field->name(), staticUse, false, false, &fieldVariable);
|
||||
setFieldProperties(fieldType, field->name(), staticUse, &fieldVariable);
|
||||
fieldVariable.isRowMajorLayout =
|
||||
(fieldType.getLayoutQualifier().matrixPacking == EmpRowMajor);
|
||||
interfaceBlock->fields.push_back(fieldVariable);
|
||||
|
@ -1098,8 +845,8 @@ bool CollectVariablesTraverser::visitDeclaration(Visit, TIntermDeclaration *node
|
|||
TQualifier qualifier = typedNode.getQualifier();
|
||||
|
||||
bool isShaderVariable = qualifier == EvqAttribute || qualifier == EvqVertexIn ||
|
||||
qualifier == EvqFragmentOut || qualifier == EvqFragmentInOut ||
|
||||
qualifier == EvqUniform || IsVarying(qualifier);
|
||||
qualifier == EvqFragmentOut || qualifier == EvqUniform ||
|
||||
IsVarying(qualifier);
|
||||
|
||||
if (typedNode.getBasicType() != EbtInterfaceBlock && !isShaderVariable)
|
||||
{
|
||||
|
@ -1119,21 +866,15 @@ bool CollectVariablesTraverser::visitDeclaration(Visit, TIntermDeclaration *node
|
|||
continue;
|
||||
}
|
||||
|
||||
// SpirvTransformer::transform uses a map of ShaderVariables, it needs member variables and
|
||||
// (named or unnamed) structure as ShaderVariable. at link between two shaders, validation
|
||||
// between of named and unnamed, needs the same structure, its members, and members order
|
||||
// except instance name.
|
||||
if (typedNode.getBasicType() == EbtInterfaceBlock && !IsShaderIoBlock(qualifier) &&
|
||||
qualifier != EvqPatchIn && qualifier != EvqPatchOut)
|
||||
// TODO(jiawei.shao@intel.com): implement GL_EXT_shader_io_blocks.
|
||||
if (typedNode.getBasicType() == EbtInterfaceBlock)
|
||||
{
|
||||
InterfaceBlock interfaceBlock;
|
||||
bool isUnnamed = variable.variable().symbolType() == SymbolType::Empty;
|
||||
const TType &type = variable.getType();
|
||||
recordInterfaceBlock(isUnnamed ? nullptr : variable.getName().data(), type,
|
||||
&interfaceBlock);
|
||||
recordInterfaceBlock(variable.variable().symbolType() != SymbolType::Empty
|
||||
? variable.getName().data()
|
||||
: nullptr,
|
||||
variable.getType(), &interfaceBlock);
|
||||
|
||||
// all fields in interface block will be added for updating interface variables because
|
||||
// the temporal structure variable will be ignored.
|
||||
switch (qualifier)
|
||||
{
|
||||
case EvqUniform:
|
||||
|
@ -1148,9 +889,7 @@ bool CollectVariablesTraverser::visitDeclaration(Visit, TIntermDeclaration *node
|
|||
}
|
||||
else
|
||||
{
|
||||
ASSERT(variable.variable().symbolType() != SymbolType::Empty ||
|
||||
IsShaderIoBlock(qualifier) || qualifier == EvqPatchIn ||
|
||||
qualifier == EvqPatchOut);
|
||||
ASSERT(variable.variable().symbolType() != SymbolType::Empty);
|
||||
switch (qualifier)
|
||||
{
|
||||
case EvqAttribute:
|
||||
|
@ -1158,7 +897,6 @@ bool CollectVariablesTraverser::visitDeclaration(Visit, TIntermDeclaration *node
|
|||
mAttribs->push_back(recordAttribute(variable));
|
||||
break;
|
||||
case EvqFragmentOut:
|
||||
case EvqFragmentInOut:
|
||||
mOutputVariables->push_back(recordOutputVariable(variable));
|
||||
break;
|
||||
case EvqUniform:
|
||||
|
@ -1184,6 +922,8 @@ bool CollectVariablesTraverser::visitDeclaration(Visit, TIntermDeclaration *node
|
|||
return false;
|
||||
}
|
||||
|
||||
// TODO(jiawei.shao@intel.com): add search on mInBlocks and mOutBlocks when implementing
|
||||
// GL_EXT_shader_io_blocks.
|
||||
InterfaceBlock *CollectVariablesTraverser::findNamedInterfaceBlock(
|
||||
const ImmutableString &blockName) const
|
||||
{
|
||||
|
@ -1212,63 +952,37 @@ bool CollectVariablesTraverser::visitBinary(Visit, TIntermBinary *binaryNode)
|
|||
TIntermBinary *interfaceIndexingNode = blockNode->getAsBinaryNode();
|
||||
if (interfaceIndexingNode)
|
||||
{
|
||||
ASSERT(interfaceIndexingNode->getOp() == EOpIndexDirect ||
|
||||
interfaceIndexingNode->getOp() == EOpIndexIndirect);
|
||||
traverseIndexExpression = true;
|
||||
blockNode = interfaceIndexingNode->getLeft();
|
||||
}
|
||||
TIntermTyped *interfaceNode = interfaceIndexingNode->getLeft()->getAsTyped();
|
||||
ASSERT(interfaceNode);
|
||||
|
||||
const TType &interfaceNodeType = blockNode->getType();
|
||||
const TInterfaceBlock *interfaceBlock = interfaceNodeType.getInterfaceBlock();
|
||||
const TQualifier qualifier = interfaceNodeType.getQualifier();
|
||||
|
||||
// If it's a shader I/O block, look in varyings
|
||||
ShaderVariable *ioBlockVar = nullptr;
|
||||
if (qualifier == EvqPerVertexIn)
|
||||
{
|
||||
TIntermSymbol *symbolNode = blockNode->getAsSymbolNode();
|
||||
ASSERT(symbolNode);
|
||||
recordBuiltInVaryingUsed(symbolNode->variable(), &mPerVertexInAdded, mInputVaryings);
|
||||
ioBlockVar = FindShaderIOBlockVariable(interfaceBlock->name(), mInputVaryings);
|
||||
}
|
||||
else if (IsVaryingIn(qualifier))
|
||||
{
|
||||
ioBlockVar = FindShaderIOBlockVariable(interfaceBlock->name(), mInputVaryings);
|
||||
}
|
||||
else if (qualifier == EvqPerVertexOut)
|
||||
{
|
||||
TIntermSymbol *symbolNode = blockNode->getAsSymbolNode();
|
||||
ASSERT(symbolNode);
|
||||
recordBuiltInVaryingUsed(symbolNode->variable(), &mPerVertexOutAdded, mOutputVaryings);
|
||||
ioBlockVar = FindShaderIOBlockVariable(interfaceBlock->name(), mOutputVaryings);
|
||||
}
|
||||
else if (IsVaryingOut(qualifier))
|
||||
{
|
||||
ioBlockVar = FindShaderIOBlockVariable(interfaceBlock->name(), mOutputVaryings);
|
||||
}
|
||||
|
||||
if (ioBlockVar)
|
||||
{
|
||||
MarkActive(ioBlockVar);
|
||||
}
|
||||
else
|
||||
{
|
||||
if (!namedBlock)
|
||||
const TType &interfaceType = interfaceNode->getType();
|
||||
if (interfaceType.getQualifier() == EvqPerVertexIn)
|
||||
{
|
||||
namedBlock = findNamedInterfaceBlock(interfaceBlock->name());
|
||||
namedBlock = recordGLInUsed(interfaceType);
|
||||
ASSERT(namedBlock);
|
||||
}
|
||||
ASSERT(namedBlock);
|
||||
ASSERT(namedBlock->staticUse);
|
||||
namedBlock->active = true;
|
||||
unsigned int fieldIndex = static_cast<unsigned int>(constantUnion->getIConst(0));
|
||||
ASSERT(fieldIndex < namedBlock->fields.size());
|
||||
// TODO(oetuaho): Would be nicer to record static use of fields of named interface
|
||||
// blocks more accurately at parse time - now we only mark the fields statically used if
|
||||
// they are active. http://anglebug.com/2440 We need to mark this field and all of its
|
||||
// sub-fields, as static/active
|
||||
MarkActive(&namedBlock->fields[fieldIndex]);
|
||||
|
||||
// We need to continue traversing to collect useful variables in the index expression
|
||||
// of the interface block array or gl_in in the case of the if above.
|
||||
traverseIndexExpression = true;
|
||||
}
|
||||
|
||||
const TInterfaceBlock *interfaceBlock = blockNode->getType().getInterfaceBlock();
|
||||
if (!namedBlock)
|
||||
{
|
||||
namedBlock = findNamedInterfaceBlock(interfaceBlock->name());
|
||||
}
|
||||
ASSERT(namedBlock);
|
||||
ASSERT(namedBlock->staticUse);
|
||||
namedBlock->active = true;
|
||||
unsigned int fieldIndex = static_cast<unsigned int>(constantUnion->getIConst(0));
|
||||
ASSERT(fieldIndex < namedBlock->fields.size());
|
||||
// TODO(oetuaho): Would be nicer to record static use of fields of named interface blocks
|
||||
// more accurately at parse time - now we only mark the fields statically used if they are
|
||||
// active. http://anglebug.com/2440
|
||||
// We need to mark this field and all of its sub-fields, as static/active
|
||||
MarkActive(&namedBlock->fields[fieldIndex]);
|
||||
|
||||
if (traverseIndexExpression)
|
||||
{
|
||||
ASSERT(interfaceIndexingNode);
|
||||
|
@ -1291,17 +1005,16 @@ void CollectVariables(TIntermBlock *root,
|
|||
std::vector<ShaderVariable> *sharedVariables,
|
||||
std::vector<InterfaceBlock> *uniformBlocks,
|
||||
std::vector<InterfaceBlock> *shaderStorageBlocks,
|
||||
std::vector<InterfaceBlock> *inBlocks,
|
||||
ShHashFunction64 hashFunction,
|
||||
TSymbolTable *symbolTable,
|
||||
GLenum shaderType,
|
||||
const TExtensionBehavior &extensionBehavior,
|
||||
const ShBuiltInResources &resources,
|
||||
int tessControlShaderOutputVertices)
|
||||
const TExtensionBehavior &extensionBehavior)
|
||||
{
|
||||
CollectVariablesTraverser collect(
|
||||
attributes, outputVariables, uniforms, inputVaryings, outputVaryings, sharedVariables,
|
||||
uniformBlocks, shaderStorageBlocks, hashFunction, symbolTable, shaderType,
|
||||
extensionBehavior, resources, tessControlShaderOutputVertices);
|
||||
CollectVariablesTraverser collect(attributes, outputVariables, uniforms, inputVaryings,
|
||||
outputVaryings, sharedVariables, uniformBlocks,
|
||||
shaderStorageBlocks, inBlocks, hashFunction, symbolTable,
|
||||
shaderType, extensionBehavior);
|
||||
root->traverse(&collect);
|
||||
}
|
||||
|
||||
|
|
|
@ -27,12 +27,11 @@ void CollectVariables(TIntermBlock *root,
|
|||
std::vector<ShaderVariable> *sharedVariables,
|
||||
std::vector<InterfaceBlock> *uniformBlocks,
|
||||
std::vector<InterfaceBlock> *shaderStorageBlocks,
|
||||
std::vector<InterfaceBlock> *inBlocks,
|
||||
ShHashFunction64 hashFunction,
|
||||
TSymbolTable *symbolTable,
|
||||
GLenum shaderType,
|
||||
const TExtensionBehavior &extensionBehavior,
|
||||
const ShBuiltInResources &resources,
|
||||
int tessControlShaderOutputVertices);
|
||||
const TExtensionBehavior &extensionBehavior);
|
||||
} // namespace sh
|
||||
|
||||
#endif // COMPILER_TRANSLATOR_COLLECTVARIABLES_H_
|
||||
|
|
|
@ -52,10 +52,11 @@ typedef std::basic_string<char, std::char_traits<char>, TStringAllocator> TStrin
|
|||
typedef std::basic_ostringstream<char, std::char_traits<char>, TStringAllocator> TStringStream;
|
||||
|
||||
//
|
||||
// Persistent memory. Should only be used for strings that survive across compiles.
|
||||
// Persistent string memory. Should only be used for strings that survive
|
||||
// across compiles.
|
||||
//
|
||||
using TPersistString = std::string;
|
||||
using TPersistStringStream = std::ostringstream;
|
||||
#define TPersistString std::string
|
||||
#define TPersistStringStream std::ostringstream
|
||||
|
||||
//
|
||||
// Pool allocator versions of vectors, lists, and maps
|
||||
|
|
|
@ -16,41 +16,39 @@
|
|||
#include "compiler/translator/IsASTDepthBelowLimit.h"
|
||||
#include "compiler/translator/OutputTree.h"
|
||||
#include "compiler/translator/ParseContext.h"
|
||||
#include "compiler/translator/ValidateBarrierFunctionCall.h"
|
||||
#include "compiler/translator/ValidateClipCullDistance.h"
|
||||
#include "compiler/translator/ValidateLimitations.h"
|
||||
#include "compiler/translator/ValidateMaxParameters.h"
|
||||
#include "compiler/translator/ValidateOutputs.h"
|
||||
#include "compiler/translator/ValidateVaryingLocations.h"
|
||||
#include "compiler/translator/VariablePacker.h"
|
||||
#include "compiler/translator/tree_ops/AddAndTrueToLoopCondition.h"
|
||||
#include "compiler/translator/tree_ops/ClampFragDepth.h"
|
||||
#include "compiler/translator/tree_ops/ClampPointSize.h"
|
||||
#include "compiler/translator/tree_ops/DeclareAndInitBuiltinsForInstancedMultiview.h"
|
||||
#include "compiler/translator/tree_ops/DeferGlobalInitializers.h"
|
||||
#include "compiler/translator/tree_ops/EarlyFragmentTestsOptimization.h"
|
||||
#include "compiler/translator/tree_ops/EmulateGLFragColorBroadcast.h"
|
||||
#include "compiler/translator/tree_ops/EmulateMultiDrawShaderBuiltins.h"
|
||||
#include "compiler/translator/tree_ops/EmulatePrecision.h"
|
||||
#include "compiler/translator/tree_ops/FoldExpressions.h"
|
||||
#include "compiler/translator/tree_ops/ForcePrecisionQualifier.h"
|
||||
#include "compiler/translator/tree_ops/InitializeVariables.h"
|
||||
#include "compiler/translator/tree_ops/PruneEmptyCases.h"
|
||||
#include "compiler/translator/tree_ops/PruneNoOps.h"
|
||||
#include "compiler/translator/tree_ops/RegenerateStructNames.h"
|
||||
#include "compiler/translator/tree_ops/RemoveArrayLengthMethod.h"
|
||||
#include "compiler/translator/tree_ops/RemoveDynamicIndexing.h"
|
||||
#include "compiler/translator/tree_ops/RemoveInvariantDeclaration.h"
|
||||
#include "compiler/translator/tree_ops/RemovePow.h"
|
||||
#include "compiler/translator/tree_ops/RemoveUnreferencedVariables.h"
|
||||
#include "compiler/translator/tree_ops/RewriteDoWhile.h"
|
||||
#include "compiler/translator/tree_ops/RewriteRepeatedAssignToSwizzled.h"
|
||||
#include "compiler/translator/tree_ops/ScalarizeVecAndMatConstructorArgs.h"
|
||||
#include "compiler/translator/tree_ops/SeparateDeclarations.h"
|
||||
#include "compiler/translator/tree_ops/SimplifyLoopConditions.h"
|
||||
#include "compiler/translator/tree_ops/SplitSequenceOperator.h"
|
||||
#include "compiler/translator/tree_ops/gl/ClampFragDepth.h"
|
||||
#include "compiler/translator/tree_ops/gl/RegenerateStructNames.h"
|
||||
#include "compiler/translator/tree_ops/gl/RewriteRepeatedAssignToSwizzled.h"
|
||||
#include "compiler/translator/tree_ops/gl/UseInterfaceBlockFields.h"
|
||||
#include "compiler/translator/tree_ops/gl/VectorizeVectorScalarArithmetic.h"
|
||||
#include "compiler/translator/tree_ops/gl/mac/AddAndTrueToLoopCondition.h"
|
||||
#include "compiler/translator/tree_ops/gl/mac/RewriteDoWhile.h"
|
||||
#include "compiler/translator/tree_ops/gl/mac/UnfoldShortCircuitAST.h"
|
||||
#include "compiler/translator/tree_ops/vulkan/EarlyFragmentTestsOptimization.h"
|
||||
#include "compiler/translator/tree_ops/UnfoldShortCircuitAST.h"
|
||||
#include "compiler/translator/tree_ops/UseInterfaceBlockFields.h"
|
||||
#include "compiler/translator/tree_ops/VectorizeVectorScalarArithmetic.h"
|
||||
#include "compiler/translator/tree_util/BuiltIn.h"
|
||||
#include "compiler/translator/tree_util/IntermNodePatternMatcher.h"
|
||||
#include "compiler/translator/tree_util/ReplaceShadowingVariables.h"
|
||||
|
@ -220,8 +218,6 @@ int GetMaxShaderVersionForSpec(ShShaderSpec spec)
|
|||
case SH_GLES3_1_SPEC:
|
||||
case SH_WEBGL3_SPEC:
|
||||
return 310;
|
||||
case SH_GLES3_2_SPEC:
|
||||
return 320;
|
||||
case SH_GL_CORE_SPEC:
|
||||
case SH_GL_COMPATIBILITY_SPEC:
|
||||
return 460;
|
||||
|
@ -305,11 +301,6 @@ TCompiler::TCompiler(sh::GLenum type, ShShaderSpec spec, ShShaderOutput output)
|
|||
mGeometryShaderInvocations(0),
|
||||
mGeometryShaderInputPrimitiveType(EptUndefined),
|
||||
mGeometryShaderOutputPrimitiveType(EptUndefined),
|
||||
mTessControlShaderOutputVertices(0),
|
||||
mTessEvaluationShaderInputPrimitiveType(EtetUndefined),
|
||||
mTessEvaluationShaderInputVertexSpacingType(EtetUndefined),
|
||||
mTessEvaluationShaderInputOrderingType(EtetUndefined),
|
||||
mTessEvaluationShaderInputPointType(EtetUndefined),
|
||||
mCompileOptions(0)
|
||||
{}
|
||||
|
||||
|
@ -321,7 +312,7 @@ bool TCompiler::shouldRunLoopAndIndexingValidation(ShCompileOptions compileOptio
|
|||
// validate loop and indexing as well (to verify that the shader only uses minimal functionality
|
||||
// of ESSL 1.00 as in Appendix A of the spec).
|
||||
return (IsWebGLBasedSpec(mShaderSpec) && mShaderVersion == 100) ||
|
||||
(compileOptions & SH_VALIDATE_LOOP_INDEXING) != 0;
|
||||
(compileOptions & SH_VALIDATE_LOOP_INDEXING);
|
||||
}
|
||||
|
||||
bool TCompiler::Init(const ShBuiltInResources &resources)
|
||||
|
@ -364,7 +355,7 @@ TIntermBlock *TCompiler::compileTreeImpl(const char *const shaderStrings[],
|
|||
|
||||
// If gl_DrawID is not supported, remove it from the available extensions
|
||||
// Currently we only allow emulation of gl_DrawID
|
||||
const bool glDrawIDSupported = (compileOptions & SH_EMULATE_GL_DRAW_ID) != 0;
|
||||
const bool glDrawIDSupported = (compileOptions & SH_EMULATE_GL_DRAW_ID) != 0u;
|
||||
if (!glDrawIDSupported)
|
||||
{
|
||||
auto it = mExtensionBehavior.find(TExtension::ANGLE_multi_draw);
|
||||
|
@ -375,7 +366,7 @@ TIntermBlock *TCompiler::compileTreeImpl(const char *const shaderStrings[],
|
|||
}
|
||||
|
||||
const bool glBaseVertexBaseInstanceSupported =
|
||||
(compileOptions & SH_EMULATE_GL_BASE_VERTEX_BASE_INSTANCE) != 0;
|
||||
(compileOptions & SH_EMULATE_GL_BASE_VERTEX_BASE_INSTANCE) != 0u;
|
||||
if (!glBaseVertexBaseInstanceSupported)
|
||||
{
|
||||
auto it = mExtensionBehavior.find(TExtension::ANGLE_base_vertex_base_instance);
|
||||
|
@ -387,7 +378,7 @@ TIntermBlock *TCompiler::compileTreeImpl(const char *const shaderStrings[],
|
|||
|
||||
// First string is path of source file if flag is set. The actual source follows.
|
||||
size_t firstSource = 0;
|
||||
if ((compileOptions & SH_SOURCE_PATH) != 0)
|
||||
if (compileOptions & SH_SOURCE_PATH)
|
||||
{
|
||||
mSourcePath = shaderStrings[0];
|
||||
++firstSource;
|
||||
|
@ -458,8 +449,9 @@ bool TCompiler::checkShaderVersion(TParseContext *parseContext)
|
|||
"Geometry shader is not supported in this shader version.");
|
||||
return false;
|
||||
}
|
||||
else if (mShaderVersion == 310)
|
||||
else
|
||||
{
|
||||
ASSERT(mShaderVersion == 310);
|
||||
if (!parseContext->checkCanUseExtension(sh::TSourceLoc(),
|
||||
TExtension::EXT_geometry_shader))
|
||||
{
|
||||
|
@ -468,24 +460,6 @@ bool TCompiler::checkShaderVersion(TParseContext *parseContext)
|
|||
}
|
||||
break;
|
||||
|
||||
case GL_TESS_CONTROL_SHADER_EXT:
|
||||
case GL_TESS_EVALUATION_SHADER_EXT:
|
||||
if (mShaderVersion < 310)
|
||||
{
|
||||
mDiagnostics.globalError(
|
||||
"Tessellation shaders are not supported in this shader version.");
|
||||
return false;
|
||||
}
|
||||
else if (mShaderVersion == 310)
|
||||
{
|
||||
if (!parseContext->checkCanUseExtension(sh::TSourceLoc(),
|
||||
TExtension::EXT_tessellation_shader))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
@ -514,20 +488,6 @@ void TCompiler::setASTMetadata(const TParseContext &parseContext)
|
|||
mGeometryShaderMaxVertices = parseContext.getGeometryShaderMaxVertices();
|
||||
mGeometryShaderInvocations = parseContext.getGeometryShaderInvocations();
|
||||
}
|
||||
if (mShaderType == GL_TESS_CONTROL_SHADER_EXT)
|
||||
{
|
||||
mTessControlShaderOutputVertices = parseContext.getTessControlShaderOutputVertices();
|
||||
}
|
||||
if (mShaderType == GL_TESS_EVALUATION_SHADER_EXT)
|
||||
{
|
||||
mTessEvaluationShaderInputPrimitiveType =
|
||||
parseContext.getTessEvaluationShaderInputPrimitiveType();
|
||||
mTessEvaluationShaderInputVertexSpacingType =
|
||||
parseContext.getTessEvaluationShaderInputVertexSpacingType();
|
||||
mTessEvaluationShaderInputOrderingType =
|
||||
parseContext.getTessEvaluationShaderInputOrderingType();
|
||||
mTessEvaluationShaderInputPointType = parseContext.getTessEvaluationShaderInputPointType();
|
||||
}
|
||||
}
|
||||
|
||||
unsigned int TCompiler::getSharedMemorySize() const
|
||||
|
@ -547,12 +507,6 @@ bool TCompiler::validateAST(TIntermNode *root)
|
|||
{
|
||||
bool valid = ValidateAST(root, &mDiagnostics, mValidateASTOptions);
|
||||
|
||||
#if defined(ANGLE_ENABLE_ASSERTS)
|
||||
if (!valid)
|
||||
{
|
||||
fprintf(stderr, "AST validation error(s):\n%s\n", mInfoSink.info.c_str());
|
||||
}
|
||||
#endif
|
||||
// In debug, assert validation. In release, validation errors will be returned back to the
|
||||
// application as internal ANGLE errors.
|
||||
ASSERT(valid);
|
||||
|
@ -566,14 +520,8 @@ bool TCompiler::checkAndSimplifyAST(TIntermBlock *root,
|
|||
const TParseContext &parseContext,
|
||||
ShCompileOptions compileOptions)
|
||||
{
|
||||
mValidateASTOptions = {};
|
||||
if (!validateAST(root))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
// Disallow expressions deemed too complex.
|
||||
if ((compileOptions & SH_LIMIT_EXPRESSION_COMPLEXITY) != 0 && !limitExpressionComplexity(root))
|
||||
if ((compileOptions & SH_LIMIT_EXPRESSION_COMPLEXITY) && !limitExpressionComplexity(root))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
@ -611,11 +559,10 @@ bool TCompiler::checkAndSimplifyAST(TIntermBlock *root,
|
|||
}
|
||||
|
||||
// We need to generate globals early if we have non constant initializers enabled
|
||||
bool initializeLocalsAndGlobals = (compileOptions & SH_INITIALIZE_UNINITIALIZED_LOCALS) != 0 &&
|
||||
!IsOutputHLSL(getOutputType());
|
||||
bool canUseLoopsToInitialize =
|
||||
(compileOptions & SH_DONT_USE_LOOPS_TO_INITIALIZE_VARIABLES) == 0;
|
||||
bool highPrecisionSupported = mShaderVersion > 100 || mShaderType != GL_FRAGMENT_SHADER ||
|
||||
bool initializeLocalsAndGlobals =
|
||||
(compileOptions & SH_INITIALIZE_UNINITIALIZED_LOCALS) && !IsOutputHLSL(getOutputType());
|
||||
bool canUseLoopsToInitialize = !(compileOptions & SH_DONT_USE_LOOPS_TO_INITIALIZE_VARIABLES);
|
||||
bool highPrecisionSupported = mShaderVersion > 100 || mShaderType != GL_FRAGMENT_SHADER ||
|
||||
mResources.FragmentPrecisionHigh == 1;
|
||||
bool enableNonConstantInitializers = IsExtensionEnabled(
|
||||
mExtensionBehavior, TExtension::EXT_shader_non_constant_global_initializers);
|
||||
|
@ -632,7 +579,7 @@ bool TCompiler::checkAndSimplifyAST(TIntermBlock *root,
|
|||
return false;
|
||||
}
|
||||
|
||||
if ((compileOptions & SH_LIMIT_CALL_STACK_DEPTH) != 0 && !checkCallDepth())
|
||||
if ((compileOptions & SH_LIMIT_CALL_STACK_DEPTH) && !checkCallDepth())
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
@ -645,7 +592,10 @@ bool TCompiler::checkAndSimplifyAST(TIntermBlock *root,
|
|||
return false;
|
||||
}
|
||||
|
||||
pruneUnusedFunctions(root);
|
||||
if (!(compileOptions & SH_DONT_PRUNE_UNUSED_FUNCTIONS))
|
||||
{
|
||||
pruneUnusedFunctions(root);
|
||||
}
|
||||
if (IsSpecWithFunctionBodyNewScope(mShaderSpec, mShaderVersion))
|
||||
{
|
||||
if (!ReplaceShadowingVariables(this, root, &mSymbolTable))
|
||||
|
@ -665,11 +615,6 @@ bool TCompiler::checkAndSimplifyAST(TIntermBlock *root,
|
|||
return false;
|
||||
}
|
||||
|
||||
if (mShaderType == GL_TESS_CONTROL_SHADER && !ValidateBarrierFunctionCall(root, &mDiagnostics))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
// Fail compilation if precision emulation not supported.
|
||||
if (getResources().WEBGL_debug_shader_precision && getPragma().debugShaderPrecision &&
|
||||
!EmulatePrecision::SupportedInLanguage(mOutputType))
|
||||
|
@ -678,22 +623,13 @@ bool TCompiler::checkAndSimplifyAST(TIntermBlock *root,
|
|||
return false;
|
||||
}
|
||||
|
||||
if (parseContext.isExtensionEnabled(TExtension::EXT_clip_cull_distance))
|
||||
{
|
||||
if (!ValidateClipCullDistance(root, &mDiagnostics,
|
||||
mResources.MaxCombinedClipAndCullDistances))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
// Clamping uniform array bounds needs to happen after validateLimitations pass.
|
||||
if ((compileOptions & SH_CLAMP_INDIRECT_ARRAY_BOUNDS) != 0)
|
||||
if (compileOptions & SH_CLAMP_INDIRECT_ARRAY_BOUNDS)
|
||||
{
|
||||
mArrayBoundsClamper.MarkIndirectArrayBoundsForClamping(root);
|
||||
}
|
||||
|
||||
if ((compileOptions & SH_INITIALIZE_BUILTINS_FOR_INSTANCED_MULTIVIEW) != 0 &&
|
||||
if ((compileOptions & SH_INITIALIZE_BUILTINS_FOR_INSTANCED_MULTIVIEW) &&
|
||||
(parseContext.isExtensionEnabled(TExtension::OVR_multiview2) ||
|
||||
parseContext.isExtensionEnabled(TExtension::OVR_multiview)) &&
|
||||
getShaderType() != GL_COMPUTE_SHADER)
|
||||
|
@ -706,7 +642,7 @@ bool TCompiler::checkAndSimplifyAST(TIntermBlock *root,
|
|||
}
|
||||
|
||||
// This pass might emit short circuits so keep it before the short circuit unfolding
|
||||
if ((compileOptions & SH_REWRITE_DO_WHILE_LOOPS) != 0)
|
||||
if (compileOptions & SH_REWRITE_DO_WHILE_LOOPS)
|
||||
{
|
||||
if (!RewriteDoWhile(this, root, &mSymbolTable))
|
||||
{
|
||||
|
@ -714,7 +650,7 @@ bool TCompiler::checkAndSimplifyAST(TIntermBlock *root,
|
|||
}
|
||||
}
|
||||
|
||||
if ((compileOptions & SH_ADD_AND_TRUE_TO_LOOP_CONDITION) != 0)
|
||||
if (compileOptions & SH_ADD_AND_TRUE_TO_LOOP_CONDITION)
|
||||
{
|
||||
if (!AddAndTrueToLoopCondition(this, root))
|
||||
{
|
||||
|
@ -722,7 +658,7 @@ bool TCompiler::checkAndSimplifyAST(TIntermBlock *root,
|
|||
}
|
||||
}
|
||||
|
||||
if ((compileOptions & SH_UNFOLD_SHORT_CIRCUIT) != 0)
|
||||
if (compileOptions & SH_UNFOLD_SHORT_CIRCUIT)
|
||||
{
|
||||
if (!UnfoldShortCircuitAST(this, root))
|
||||
{
|
||||
|
@ -730,9 +666,19 @@ bool TCompiler::checkAndSimplifyAST(TIntermBlock *root,
|
|||
}
|
||||
}
|
||||
|
||||
if ((compileOptions & SH_REGENERATE_STRUCT_NAMES) != 0)
|
||||
if (compileOptions & SH_REMOVE_POW_WITH_CONSTANT_EXPONENT)
|
||||
{
|
||||
if (!RegenerateStructNames(this, root, &mSymbolTable))
|
||||
if (!RemovePow(this, root, &mSymbolTable))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
if (compileOptions & SH_REGENERATE_STRUCT_NAMES)
|
||||
{
|
||||
RegenerateStructNames gen(&mSymbolTable);
|
||||
root->traverse(&gen);
|
||||
if (!validateAST(root))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
@ -741,7 +687,7 @@ bool TCompiler::checkAndSimplifyAST(TIntermBlock *root,
|
|||
if (mShaderType == GL_VERTEX_SHADER &&
|
||||
IsExtensionEnabled(mExtensionBehavior, TExtension::ANGLE_multi_draw))
|
||||
{
|
||||
if ((compileOptions & SH_EMULATE_GL_DRAW_ID) != 0)
|
||||
if ((compileOptions & SH_EMULATE_GL_DRAW_ID) != 0u)
|
||||
{
|
||||
if (!EmulateGLDrawID(this, root, &mSymbolTable, &mUniforms,
|
||||
shouldCollectVariables(compileOptions)))
|
||||
|
@ -754,11 +700,11 @@ bool TCompiler::checkAndSimplifyAST(TIntermBlock *root,
|
|||
if (mShaderType == GL_VERTEX_SHADER &&
|
||||
IsExtensionEnabled(mExtensionBehavior, TExtension::ANGLE_base_vertex_base_instance))
|
||||
{
|
||||
if ((compileOptions & SH_EMULATE_GL_BASE_VERTEX_BASE_INSTANCE) != 0)
|
||||
if ((compileOptions & SH_EMULATE_GL_BASE_VERTEX_BASE_INSTANCE) != 0u)
|
||||
{
|
||||
if (!EmulateGLBaseVertexBaseInstance(
|
||||
this, root, &mSymbolTable, &mUniforms, shouldCollectVariables(compileOptions),
|
||||
(compileOptions & SH_ADD_BASE_VERTEX_TO_VERTEX_ID) != 0))
|
||||
if (!EmulateGLBaseVertexBaseInstance(this, root, &mSymbolTable, &mUniforms,
|
||||
shouldCollectVariables(compileOptions),
|
||||
compileOptions & SH_ADD_BASE_VERTEX_TO_VERTEX_ID))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
@ -776,7 +722,7 @@ bool TCompiler::checkAndSimplifyAST(TIntermBlock *root,
|
|||
}
|
||||
}
|
||||
|
||||
int simplifyScalarized = (compileOptions & SH_SCALARIZE_VEC_AND_MAT_CONSTRUCTOR_ARGS) != 0
|
||||
int simplifyScalarized = (compileOptions & SH_SCALARIZE_VEC_AND_MAT_CONSTRUCTOR_ARGS)
|
||||
? IntermNodePatternMatcher::kScalarizedVecOrMatConstructor
|
||||
: 0;
|
||||
|
||||
|
@ -835,7 +781,7 @@ bool TCompiler::checkAndSimplifyAST(TIntermBlock *root,
|
|||
GetGlobalPoolAllocator()->unlock();
|
||||
mBuiltInFunctionEmulator.markBuiltInFunctionsForEmulation(root);
|
||||
|
||||
if ((compileOptions & SH_SCALARIZE_VEC_AND_MAT_CONSTRUCTOR_ARGS) != 0)
|
||||
if (compileOptions & SH_SCALARIZE_VEC_AND_MAT_CONSTRUCTOR_ARGS)
|
||||
{
|
||||
if (!ScalarizeVecAndMatConstructorArgs(this, root, mShaderType, highPrecisionSupported,
|
||||
&mSymbolTable))
|
||||
|
@ -844,31 +790,23 @@ bool TCompiler::checkAndSimplifyAST(TIntermBlock *root,
|
|||
}
|
||||
}
|
||||
|
||||
if ((compileOptions & SH_FORCE_SHADER_PRECISION_HIGHP_TO_MEDIUMP) != 0)
|
||||
{
|
||||
if (!ForceShaderPrecisionToMediump(root, &mSymbolTable, mShaderType))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
if (shouldCollectVariables(compileOptions))
|
||||
{
|
||||
ASSERT(!mVariablesCollected);
|
||||
CollectVariables(root, &mAttributes, &mOutputVariables, &mUniforms, &mInputVaryings,
|
||||
&mOutputVaryings, &mSharedVariables, &mUniformBlocks,
|
||||
&mShaderStorageBlocks, mResources.HashFunction, &mSymbolTable, mShaderType,
|
||||
mExtensionBehavior, mResources, mTessControlShaderOutputVertices);
|
||||
&mShaderStorageBlocks, &mInBlocks, mResources.HashFunction, &mSymbolTable,
|
||||
mShaderType, mExtensionBehavior);
|
||||
collectInterfaceBlocks();
|
||||
mVariablesCollected = true;
|
||||
if ((compileOptions & SH_USE_UNUSED_STANDARD_SHARED_BLOCKS) != 0)
|
||||
if (compileOptions & SH_USE_UNUSED_STANDARD_SHARED_BLOCKS)
|
||||
{
|
||||
if (!useAllMembersInUnusedStandardAndSharedBlocks(root))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
if ((compileOptions & SH_ENFORCE_PACKING_RESTRICTIONS) != 0)
|
||||
if (compileOptions & SH_ENFORCE_PACKING_RESTRICTIONS)
|
||||
{
|
||||
int maxUniformVectors = GetMaxUniformVectorsForShaderType(mShaderType, mResources);
|
||||
// Returns true if, after applying the packing rules in the GLSL ES 1.00.17 spec
|
||||
|
@ -879,12 +817,7 @@ bool TCompiler::checkAndSimplifyAST(TIntermBlock *root,
|
|||
return false;
|
||||
}
|
||||
}
|
||||
bool needInitializeOutputVariables =
|
||||
(compileOptions & SH_INIT_OUTPUT_VARIABLES) != 0 && mShaderType != GL_COMPUTE_SHADER;
|
||||
needInitializeOutputVariables |=
|
||||
(compileOptions & SH_INIT_FRAGMENT_OUTPUT_VARIABLES) != 0 &&
|
||||
mShaderType == GL_FRAGMENT_SHADER;
|
||||
if (needInitializeOutputVariables)
|
||||
if ((compileOptions & SH_INIT_OUTPUT_VARIABLES) && (mShaderType != GL_COMPUTE_SHADER))
|
||||
{
|
||||
if (!initializeOutputVariables(root))
|
||||
{
|
||||
|
@ -907,8 +840,7 @@ bool TCompiler::checkAndSimplifyAST(TIntermBlock *root,
|
|||
// It may have been already initialized among other output variables, in that case we don't
|
||||
// need to initialize it twice.
|
||||
if (mShaderType == GL_VERTEX_SHADER && !mGLPositionInitialized &&
|
||||
((compileOptions & SH_INIT_GL_POSITION) != 0 ||
|
||||
mOutputType == SH_GLSL_COMPATIBILITY_OUTPUT))
|
||||
((compileOptions & SH_INIT_GL_POSITION) || (mOutputType == SH_GLSL_COMPATIBILITY_OUTPUT)))
|
||||
{
|
||||
if (!initializeGLPosition(root))
|
||||
{
|
||||
|
@ -959,7 +891,7 @@ bool TCompiler::checkAndSimplifyAST(TIntermBlock *root,
|
|||
}
|
||||
}
|
||||
|
||||
if (getShaderType() == GL_VERTEX_SHADER && (compileOptions & SH_CLAMP_POINT_SIZE) != 0)
|
||||
if (getShaderType() == GL_VERTEX_SHADER && (compileOptions & SH_CLAMP_POINT_SIZE))
|
||||
{
|
||||
if (!ClampPointSize(this, root, mResources.MaxPointSize, &getSymbolTable()))
|
||||
{
|
||||
|
@ -967,7 +899,7 @@ bool TCompiler::checkAndSimplifyAST(TIntermBlock *root,
|
|||
}
|
||||
}
|
||||
|
||||
if (getShaderType() == GL_FRAGMENT_SHADER && (compileOptions & SH_CLAMP_FRAG_DEPTH) != 0)
|
||||
if (getShaderType() == GL_FRAGMENT_SHADER && (compileOptions & SH_CLAMP_FRAG_DEPTH))
|
||||
{
|
||||
if (!ClampFragDepth(this, root, &getSymbolTable()))
|
||||
{
|
||||
|
@ -975,7 +907,7 @@ bool TCompiler::checkAndSimplifyAST(TIntermBlock *root,
|
|||
}
|
||||
}
|
||||
|
||||
if ((compileOptions & SH_REWRITE_REPEATED_ASSIGN_TO_SWIZZLED) != 0)
|
||||
if (compileOptions & SH_REWRITE_REPEATED_ASSIGN_TO_SWIZZLED)
|
||||
{
|
||||
if (!sh::RewriteRepeatedAssignToSwizzled(this, root))
|
||||
{
|
||||
|
@ -983,7 +915,7 @@ bool TCompiler::checkAndSimplifyAST(TIntermBlock *root,
|
|||
}
|
||||
}
|
||||
|
||||
if ((compileOptions & SH_REWRITE_VECTOR_SCALAR_ARITHMETIC) != 0)
|
||||
if (compileOptions & SH_REWRITE_VECTOR_SCALAR_ARITHMETIC)
|
||||
{
|
||||
if (!VectorizeVectorScalarArithmetic(this, root, &getSymbolTable()))
|
||||
{
|
||||
|
@ -991,7 +923,7 @@ bool TCompiler::checkAndSimplifyAST(TIntermBlock *root,
|
|||
}
|
||||
}
|
||||
|
||||
if ((compileOptions & SH_REMOVE_DYNAMIC_INDEXING_OF_SWIZZLED_VECTOR) != 0)
|
||||
if (compileOptions & SH_REMOVE_DYNAMIC_INDEXING_OF_SWIZZLED_VECTOR)
|
||||
{
|
||||
if (!sh::RemoveDynamicIndexingOfSwizzledVector(this, root, &getSymbolTable(), nullptr))
|
||||
{
|
||||
|
@ -1000,7 +932,7 @@ bool TCompiler::checkAndSimplifyAST(TIntermBlock *root,
|
|||
}
|
||||
|
||||
mEarlyFragmentTestsOptimized = false;
|
||||
if ((compileOptions & SH_EARLY_FRAGMENT_TESTS_OPTIMIZATION) != 0)
|
||||
if (compileOptions & SH_EARLY_FRAGMENT_TESTS_OPTIMIZATION)
|
||||
{
|
||||
if (mShaderVersion <= 300 && mShaderType == GL_FRAGMENT_SHADER &&
|
||||
!isEarlyFragmentTestsSpecified())
|
||||
|
@ -1038,12 +970,12 @@ bool TCompiler::compile(const char *const shaderStrings[],
|
|||
|
||||
if (root)
|
||||
{
|
||||
if ((compileOptions & SH_INTERMEDIATE_TREE) != 0)
|
||||
if (compileOptions & SH_INTERMEDIATE_TREE)
|
||||
{
|
||||
OutputTree(root, mInfoSink.info);
|
||||
}
|
||||
|
||||
if ((compileOptions & SH_OBJECT_CODE) != 0)
|
||||
if (compileOptions & SH_OBJECT_CODE)
|
||||
{
|
||||
PerformanceDiagnostics perfDiagnostics(&mDiagnostics);
|
||||
if (!translate(root, compileOptions, &perfDiagnostics))
|
||||
|
@ -1056,11 +988,11 @@ bool TCompiler::compile(const char *const shaderStrings[],
|
|||
{
|
||||
bool lookForDrawID =
|
||||
IsExtensionEnabled(mExtensionBehavior, TExtension::ANGLE_multi_draw) &&
|
||||
(compileOptions & SH_EMULATE_GL_DRAW_ID) != 0;
|
||||
((compileOptions & SH_EMULATE_GL_DRAW_ID) != 0u);
|
||||
bool lookForBaseVertexBaseInstance =
|
||||
IsExtensionEnabled(mExtensionBehavior,
|
||||
TExtension::ANGLE_base_vertex_base_instance) &&
|
||||
(compileOptions & SH_EMULATE_GL_BASE_VERTEX_BASE_INSTANCE) != 0;
|
||||
((compileOptions & SH_EMULATE_GL_BASE_VERTEX_BASE_INSTANCE) != 0u);
|
||||
|
||||
if (lookForDrawID || lookForBaseVertexBaseInstance)
|
||||
{
|
||||
|
@ -1136,15 +1068,12 @@ void TCompiler::setResourceString()
|
|||
<< ":EXT_frag_depth:" << mResources.EXT_frag_depth
|
||||
<< ":EXT_shader_texture_lod:" << mResources.EXT_shader_texture_lod
|
||||
<< ":EXT_shader_framebuffer_fetch:" << mResources.EXT_shader_framebuffer_fetch
|
||||
<< ":EXT_shader_framebuffer_fetch_non_coherent:" << mResources.EXT_shader_framebuffer_fetch_non_coherent
|
||||
<< ":NV_shader_framebuffer_fetch:" << mResources.NV_shader_framebuffer_fetch
|
||||
<< ":ARM_shader_framebuffer_fetch:" << mResources.ARM_shader_framebuffer_fetch
|
||||
<< ":OVR_multiview2:" << mResources.OVR_multiview2
|
||||
<< ":OVR_multiview:" << mResources.OVR_multiview
|
||||
<< ":EXT_YUV_target:" << mResources.EXT_YUV_target
|
||||
<< ":EXT_geometry_shader:" << mResources.EXT_geometry_shader
|
||||
<< ":OES_shader_io_blocks:" << mResources.OES_shader_io_blocks
|
||||
<< ":EXT_shader_io_blocks:" << mResources.EXT_shader_io_blocks
|
||||
<< ":EXT_gpu_shader5:" << mResources.EXT_gpu_shader5
|
||||
<< ":OES_texture_3D:" << mResources.OES_texture_3D
|
||||
<< ":MaxVertexOutputVectors:" << mResources.MaxVertexOutputVectors
|
||||
|
@ -1163,15 +1092,11 @@ void TCompiler::setResourceString()
|
|||
<< ":EXT_shadow_samplers:" << mResources.EXT_shadow_samplers
|
||||
<< ":OES_shader_multisample_interpolation:" << mResources.OES_shader_multisample_interpolation
|
||||
<< ":OES_shader_image_atomic:" << mResources.OES_shader_image_atomic
|
||||
<< ":EXT_tessellation_shader:" << mResources.EXT_tessellation_shader
|
||||
<< ":OES_texture_buffer:" << mResources.OES_texture_buffer
|
||||
<< ":EXT_texture_buffer:" << mResources.EXT_texture_buffer
|
||||
<< ":OES_sample_variables:" << mResources.OES_sample_variables
|
||||
<< ":EXT_clip_cull_distance:" << mResources.EXT_clip_cull_distance
|
||||
<< ":MinProgramTextureGatherOffset:" << mResources.MinProgramTextureGatherOffset
|
||||
<< ":MaxProgramTextureGatherOffset:" << mResources.MaxProgramTextureGatherOffset
|
||||
<< ":MaxImageUnits:" << mResources.MaxImageUnits
|
||||
<< ":MaxSamples:" << mResources.MaxSamples
|
||||
<< ":MaxVertexImageUniforms:" << mResources.MaxVertexImageUniforms
|
||||
<< ":MaxFragmentImageUniforms:" << mResources.MaxFragmentImageUniforms
|
||||
<< ":MaxComputeImageUniforms:" << mResources.MaxComputeImageUniforms
|
||||
|
@ -1207,27 +1132,7 @@ void TCompiler::setResourceString()
|
|||
<< ":MaxGeometryShaderStorageBlocks:" << mResources.MaxGeometryShaderStorageBlocks
|
||||
<< ":MaxGeometryShaderInvocations:" << mResources.MaxGeometryShaderInvocations
|
||||
<< ":MaxGeometryImageUniforms:" << mResources.MaxGeometryImageUniforms
|
||||
<< ":MaxClipDistances" << mResources.MaxClipDistances
|
||||
<< ":MaxCullDistances" << mResources.MaxCullDistances
|
||||
<< ":MaxCombinedClipAndCullDistances" << mResources.MaxCombinedClipAndCullDistances
|
||||
<< ":MaxTessControlInputComponents:" << mResources.MaxTessControlInputComponents
|
||||
<< ":MaxTessControlOutputComponents:" << mResources.MaxTessControlOutputComponents
|
||||
<< ":MaxTessControlTextureImageUnits:" << mResources.MaxTessControlTextureImageUnits
|
||||
<< ":MaxTessControlUniformComponents:" << mResources.MaxTessControlUniformComponents
|
||||
<< ":MaxTessControlTotalOutputComponents:" << mResources.MaxTessControlTotalOutputComponents
|
||||
<< ":MaxTessControlImageUniforms:" << mResources.MaxTessControlImageUniforms
|
||||
<< ":MaxTessControlAtomicCounters:" << mResources.MaxTessControlAtomicCounters
|
||||
<< ":MaxTessControlAtomicCounterBuffers:" << mResources.MaxTessControlAtomicCounterBuffers
|
||||
<< ":MaxTessPatchComponents:" << mResources.MaxTessPatchComponents
|
||||
<< ":MaxPatchVertices:" << mResources.MaxPatchVertices
|
||||
<< ":MaxTessGenLevel:" << mResources.MaxTessGenLevel
|
||||
<< ":MaxTessEvaluationInputComponents:" << mResources.MaxTessEvaluationInputComponents
|
||||
<< ":MaxTessEvaluationOutputComponents:" << mResources.MaxTessEvaluationOutputComponents
|
||||
<< ":MaxTessEvaluationTextureImageUnits:" << mResources.MaxTessEvaluationTextureImageUnits
|
||||
<< ":MaxTessEvaluationUniformComponents:" << mResources.MaxTessEvaluationUniformComponents
|
||||
<< ":MaxTessEvaluationImageUniforms:" << mResources.MaxTessEvaluationImageUniforms
|
||||
<< ":MaxTessEvaluationAtomicCounters:" << mResources.MaxTessEvaluationAtomicCounters
|
||||
<< ":MaxTessEvaluationAtomicCounterBuffers:" << mResources.MaxTessEvaluationAtomicCounterBuffers;
|
||||
<< ":MaxClipDistances" << mResources.MaxClipDistances;
|
||||
// clang-format on
|
||||
|
||||
mBuiltInResourcesString = strstream.str();
|
||||
|
@ -1236,10 +1141,12 @@ void TCompiler::setResourceString()
|
|||
void TCompiler::collectInterfaceBlocks()
|
||||
{
|
||||
ASSERT(mInterfaceBlocks.empty());
|
||||
mInterfaceBlocks.reserve(mUniformBlocks.size() + mShaderStorageBlocks.size());
|
||||
mInterfaceBlocks.reserve(mUniformBlocks.size() + mShaderStorageBlocks.size() +
|
||||
mInBlocks.size());
|
||||
mInterfaceBlocks.insert(mInterfaceBlocks.end(), mUniformBlocks.begin(), mUniformBlocks.end());
|
||||
mInterfaceBlocks.insert(mInterfaceBlocks.end(), mShaderStorageBlocks.begin(),
|
||||
mShaderStorageBlocks.end());
|
||||
mInterfaceBlocks.insert(mInterfaceBlocks.end(), mInBlocks.begin(), mInBlocks.end());
|
||||
}
|
||||
|
||||
bool TCompiler::emulatePrecisionIfNeeded(TIntermBlock *root,
|
||||
|
@ -1279,6 +1186,7 @@ void TCompiler::clearResults()
|
|||
mInterfaceBlocks.clear();
|
||||
mUniformBlocks.clear();
|
||||
mShaderStorageBlocks.clear();
|
||||
mInBlocks.clear();
|
||||
mVariablesCollected = false;
|
||||
mGLPositionInitialized = false;
|
||||
|
||||
|
@ -1289,12 +1197,6 @@ void TCompiler::clearResults()
|
|||
mGeometryShaderInvocations = 0;
|
||||
mGeometryShaderMaxVertices = -1;
|
||||
|
||||
mTessControlShaderOutputVertices = 0;
|
||||
mTessEvaluationShaderInputPrimitiveType = EtetUndefined;
|
||||
mTessEvaluationShaderInputVertexSpacingType = EtetUndefined;
|
||||
mTessEvaluationShaderInputOrderingType = EtetUndefined;
|
||||
mTessEvaluationShaderInputPointType = EtetUndefined;
|
||||
|
||||
mBuiltInFunctionEmulator.cleanup();
|
||||
|
||||
mNameMap.clear();
|
||||
|
@ -1332,7 +1234,7 @@ bool TCompiler::checkCallDepth()
|
|||
int depth = 0;
|
||||
const CallDAG::Record &record = mCallDag.getRecordFromIndex(i);
|
||||
|
||||
for (int calleeIndex : record.callees)
|
||||
for (const int &calleeIndex : record.callees)
|
||||
{
|
||||
depth = std::max(depth, depths[calleeIndex] + 1);
|
||||
}
|
||||
|
@ -1496,9 +1398,11 @@ bool TCompiler::wereVariablesCollected() const
|
|||
|
||||
bool TCompiler::initializeGLPosition(TIntermBlock *root)
|
||||
{
|
||||
InitVariableList list;
|
||||
sh::ShaderVariable var(GL_FLOAT_VEC4);
|
||||
var.name = "gl_Position";
|
||||
return InitializeVariables(this, root, {var}, &mSymbolTable, mShaderVersion, mExtensionBehavior,
|
||||
list.push_back(var);
|
||||
return InitializeVariables(this, root, list, &mSymbolTable, mShaderVersion, mExtensionBehavior,
|
||||
false, false);
|
||||
}
|
||||
|
||||
|
@ -1521,7 +1425,6 @@ bool TCompiler::useAllMembersInUnusedStandardAndSharedBlocks(TIntermBlock *root)
|
|||
bool TCompiler::initializeOutputVariables(TIntermBlock *root)
|
||||
{
|
||||
InitVariableList list;
|
||||
list.reserve(mOutputVaryings.size());
|
||||
if (mShaderType == GL_VERTEX_SHADER || mShaderType == GL_GEOMETRY_SHADER_EXT)
|
||||
{
|
||||
for (const sh::ShaderVariable &var : mOutputVaryings)
|
||||
|
@ -1578,7 +1481,7 @@ const BuiltInFunctionEmulator &TCompiler::getBuiltInFunctionEmulator() const
|
|||
|
||||
void TCompiler::writePragma(ShCompileOptions compileOptions)
|
||||
{
|
||||
if ((compileOptions & SH_FLATTEN_PRAGMA_STDGL_INVARIANT_ALL) == 0)
|
||||
if (!(compileOptions & SH_FLATTEN_PRAGMA_STDGL_INVARIANT_ALL))
|
||||
{
|
||||
TInfoSinkBase &sink = mInfoSink.obj;
|
||||
if (mPragma.stdgl.invariantAll)
|
||||
|
@ -1636,12 +1539,12 @@ void EmitMultiviewGLSL(const TCompiler &compiler,
|
|||
return;
|
||||
|
||||
const bool isVertexShader = (compiler.getShaderType() == GL_VERTEX_SHADER);
|
||||
if ((compileOptions & SH_INITIALIZE_BUILTINS_FOR_INSTANCED_MULTIVIEW) != 0)
|
||||
if (compileOptions & SH_INITIALIZE_BUILTINS_FOR_INSTANCED_MULTIVIEW)
|
||||
{
|
||||
// Emit ARB_shader_viewport_layer_array/NV_viewport_array2 in a vertex shader if the
|
||||
// SH_SELECT_VIEW_IN_NV_GLSL_VERTEX_SHADER option is set and the
|
||||
// OVR_multiview(2) extension is requested.
|
||||
if (isVertexShader && (compileOptions & SH_SELECT_VIEW_IN_NV_GLSL_VERTEX_SHADER) != 0)
|
||||
if (isVertexShader && (compileOptions & SH_SELECT_VIEW_IN_NV_GLSL_VERTEX_SHADER))
|
||||
{
|
||||
sink << "#if defined(GL_ARB_shader_viewport_layer_array)\n"
|
||||
<< "#extension GL_ARB_shader_viewport_layer_array : require\n"
|
||||
|
|
|
@ -16,7 +16,6 @@
|
|||
|
||||
#include <GLSLANG/ShaderVars.h>
|
||||
|
||||
#include "common/PackedEnums.h"
|
||||
#include "compiler/translator/BuiltInFunctionEmulator.h"
|
||||
#include "compiler/translator/CallDAG.h"
|
||||
#include "compiler/translator/Diagnostics.h"
|
||||
|
@ -37,8 +36,6 @@ class TParseContext;
|
|||
class TranslatorHLSL;
|
||||
#endif // ANGLE_ENABLE_HLSL
|
||||
|
||||
using SpecConstUsageBits = angle::PackedEnumBitSet<vk::SpecConstUsage, uint32_t>;
|
||||
|
||||
//
|
||||
// Helper function to check if the shader type is GLSL.
|
||||
//
|
||||
|
@ -103,7 +100,6 @@ class TCompiler : public TShHandleBase
|
|||
|
||||
bool isEarlyFragmentTestsSpecified() const { return mEarlyFragmentTestsSpecified; }
|
||||
bool isEarlyFragmentTestsOptimized() const { return mEarlyFragmentTestsOptimized; }
|
||||
SpecConstUsageBits getSpecConstUsageBits() const { return mSpecConstUsageBits; }
|
||||
|
||||
bool isComputeShaderLocalSizeDeclared() const { return mComputeShaderLocalSizeDeclared; }
|
||||
const sh::WorkGroupSize &getComputeShaderLocalSize() const { return mComputeShaderLocalSize; }
|
||||
|
@ -123,6 +119,7 @@ class TCompiler : public TShHandleBase
|
|||
{
|
||||
return mShaderStorageBlocks;
|
||||
}
|
||||
const std::vector<sh::InterfaceBlock> &getInBlocks() const { return mInBlocks; }
|
||||
|
||||
ShHashFunction64 getHashFunction() const { return mResources.HashFunction; }
|
||||
NameMap &getNameMap() { return mNameMap; }
|
||||
|
@ -148,25 +145,6 @@ class TCompiler : public TShHandleBase
|
|||
}
|
||||
|
||||
unsigned int getStructSize(const ShaderVariable &var) const;
|
||||
|
||||
int getTessControlShaderOutputVertices() const { return mTessControlShaderOutputVertices; }
|
||||
TLayoutTessEvaluationType getTessEvaluationShaderInputPrimitiveType() const
|
||||
{
|
||||
return mTessEvaluationShaderInputPrimitiveType;
|
||||
}
|
||||
TLayoutTessEvaluationType getTessEvaluationShaderInputVertexSpacingType() const
|
||||
{
|
||||
return mTessEvaluationShaderInputVertexSpacingType;
|
||||
}
|
||||
TLayoutTessEvaluationType getTessEvaluationShaderInputOrderingType() const
|
||||
{
|
||||
return mTessEvaluationShaderInputOrderingType;
|
||||
}
|
||||
TLayoutTessEvaluationType getTessEvaluationShaderInputPointType() const
|
||||
{
|
||||
return mTessEvaluationShaderInputPointType;
|
||||
}
|
||||
|
||||
unsigned int getSharedMemorySize() const;
|
||||
|
||||
sh::GLenum getShaderType() const { return mShaderType; }
|
||||
|
@ -213,12 +191,7 @@ class TCompiler : public TShHandleBase
|
|||
std::vector<sh::InterfaceBlock> mInterfaceBlocks;
|
||||
std::vector<sh::InterfaceBlock> mUniformBlocks;
|
||||
std::vector<sh::InterfaceBlock> mShaderStorageBlocks;
|
||||
|
||||
// Track what should be validated given passes currently applied.
|
||||
ValidateASTOptions mValidateASTOptions;
|
||||
|
||||
// Specialization constant usage bits
|
||||
SpecConstUsageBits mSpecConstUsageBits;
|
||||
std::vector<sh::InterfaceBlock> mInBlocks;
|
||||
|
||||
private:
|
||||
// Initialize symbol-table with built-in symbols.
|
||||
|
@ -321,18 +294,14 @@ class TCompiler : public TShHandleBase
|
|||
TLayoutPrimitiveType mGeometryShaderInputPrimitiveType;
|
||||
TLayoutPrimitiveType mGeometryShaderOutputPrimitiveType;
|
||||
|
||||
// tesssellation shader parameters
|
||||
int mTessControlShaderOutputVertices;
|
||||
TLayoutTessEvaluationType mTessEvaluationShaderInputPrimitiveType;
|
||||
TLayoutTessEvaluationType mTessEvaluationShaderInputVertexSpacingType;
|
||||
TLayoutTessEvaluationType mTessEvaluationShaderInputOrderingType;
|
||||
TLayoutTessEvaluationType mTessEvaluationShaderInputPointType;
|
||||
|
||||
// name hashing.
|
||||
NameMap mNameMap;
|
||||
|
||||
TPragma mPragma;
|
||||
|
||||
// Track what should be validated given passes currently applied.
|
||||
ValidateASTOptions mValidateASTOptions;
|
||||
|
||||
ShCompileOptions mCompileOptions;
|
||||
};
|
||||
|
||||
|
|
|
@ -167,40 +167,12 @@ void TDirectiveHandler::handleExtension(const angle::pp::SourceLocation &loc,
|
|||
// OVR_multiview is implicitly enabled when OVR_multiview2 is enabled
|
||||
if (name == "GL_OVR_multiview2")
|
||||
{
|
||||
constexpr char kMultiviewExtName[] = "GL_OVR_multiview";
|
||||
iter = mExtensionBehavior.find(GetExtensionByName(kMultiviewExtName));
|
||||
if (iter != mExtensionBehavior.end())
|
||||
const std::string multiview = "GL_OVR_multiview";
|
||||
TExtensionBehavior::iterator iterMultiview =
|
||||
mExtensionBehavior.find(GetExtensionByName(multiview.c_str()));
|
||||
if (iterMultiview != mExtensionBehavior.end())
|
||||
{
|
||||
iter->second = behaviorVal;
|
||||
}
|
||||
}
|
||||
// EXT_shader_io_blocks is implicitly enabled when EXT_geometry_shader or
|
||||
// EXT_tessellation_shader is enabled.
|
||||
if (name == "GL_EXT_geometry_shader" || name == "GL_EXT_tessellation_shader")
|
||||
{
|
||||
constexpr char kIOBlocksExtName[] = "GL_EXT_shader_io_blocks";
|
||||
iter = mExtensionBehavior.find(GetExtensionByName(kIOBlocksExtName));
|
||||
if (iter != mExtensionBehavior.end())
|
||||
{
|
||||
iter->second = behaviorVal;
|
||||
}
|
||||
}
|
||||
// GL_APPLE_clip_distance is implicitly enabled when GL_EXT_clip_cull_distance is enabled
|
||||
else if (name == "GL_EXT_clip_cull_distance")
|
||||
{
|
||||
// This extension only can be enabled on greater than ESSL 300
|
||||
if (mShaderVersion < 300)
|
||||
{
|
||||
mDiagnostics.error(loc, "extension can be enabled on greater than ESSL 300",
|
||||
name.c_str());
|
||||
return;
|
||||
}
|
||||
|
||||
constexpr char kAPPLEClipDistanceEXTName[] = "GL_APPLE_clip_distance";
|
||||
iter = mExtensionBehavior.find(GetExtensionByName(kAPPLEClipDistanceEXTName));
|
||||
if (iter != mExtensionBehavior.end())
|
||||
{
|
||||
iter->second = behaviorVal;
|
||||
iterMultiview->second = behaviorVal;
|
||||
}
|
||||
}
|
||||
return;
|
||||
|
@ -226,8 +198,7 @@ void TDirectiveHandler::handleVersion(const angle::pp::SourceLocation &loc,
|
|||
int version,
|
||||
ShShaderSpec spec)
|
||||
{
|
||||
if (((version == 100 || version == 300 || version == 310 || version == 320) &&
|
||||
!IsDesktopGLSpec(spec)) ||
|
||||
if (((version == 100 || version == 300 || version == 310) && !IsDesktopGLSpec(spec)) ||
|
||||
IsDesktopGLSpec(spec))
|
||||
{
|
||||
mShaderVersion = version;
|
||||
|
|
|
@ -20,19 +20,14 @@
|
|||
OP(ARB_texture_rectangle) \
|
||||
OP(ARM_shader_framebuffer_fetch) \
|
||||
OP(EXT_blend_func_extended) \
|
||||
OP(EXT_clip_cull_distance) \
|
||||
OP(EXT_draw_buffers) \
|
||||
OP(EXT_frag_depth) \
|
||||
OP(EXT_geometry_shader) \
|
||||
OP(OES_shader_io_blocks) \
|
||||
OP(EXT_shader_io_blocks) \
|
||||
OP(EXT_gpu_shader5) \
|
||||
OP(EXT_shader_framebuffer_fetch) \
|
||||
OP(EXT_shader_framebuffer_fetch_non_coherent) \
|
||||
OP(EXT_shader_non_constant_global_initializers) \
|
||||
OP(EXT_shader_texture_lod) \
|
||||
OP(EXT_shadow_samplers) \
|
||||
OP(EXT_tessellation_shader) \
|
||||
OP(EXT_texture_buffer) \
|
||||
OP(EXT_texture_cube_map_array) \
|
||||
OP(EXT_YUV_target) \
|
||||
|
@ -41,7 +36,6 @@
|
|||
OP(NV_shader_noperspective_interpolation) \
|
||||
OP(OES_EGL_image_external) \
|
||||
OP(OES_EGL_image_external_essl3) \
|
||||
OP(OES_sample_variables) \
|
||||
OP(OES_shader_multisample_interpolation) \
|
||||
OP(OES_shader_image_atomic) \
|
||||
OP(OES_standard_derivatives) \
|
||||
|
|
|
@ -26,19 +26,14 @@ enum class TExtension : uint8_t
|
|||
ARB_texture_rectangle,
|
||||
ARM_shader_framebuffer_fetch,
|
||||
EXT_blend_func_extended,
|
||||
EXT_clip_cull_distance,
|
||||
EXT_draw_buffers,
|
||||
EXT_frag_depth,
|
||||
EXT_geometry_shader,
|
||||
OES_shader_io_blocks,
|
||||
EXT_shader_io_blocks,
|
||||
EXT_gpu_shader5,
|
||||
EXT_shader_framebuffer_fetch,
|
||||
EXT_shader_framebuffer_fetch_non_coherent,
|
||||
EXT_shader_non_constant_global_initializers,
|
||||
EXT_shader_texture_lod,
|
||||
EXT_shadow_samplers,
|
||||
EXT_tessellation_shader,
|
||||
EXT_texture_buffer,
|
||||
EXT_texture_cube_map_array,
|
||||
EXT_YUV_target,
|
||||
|
@ -47,7 +42,6 @@ enum class TExtension : uint8_t
|
|||
NV_shader_noperspective_interpolation,
|
||||
OES_EGL_image_external,
|
||||
OES_EGL_image_external_essl3,
|
||||
OES_sample_variables,
|
||||
OES_shader_multisample_interpolation,
|
||||
OES_shader_image_atomic,
|
||||
OES_standard_derivatives,
|
||||
|
|
|
@ -69,7 +69,7 @@ ImmutableString HashName(const ImmutableString &name,
|
|||
// have as long names and could conflict.
|
||||
return name;
|
||||
}
|
||||
if (name == "gl_ClipDistance" || name == "gl_CullDistance" || name == "gl_LastFragData")
|
||||
if (name == "gl_ClipDistance")
|
||||
{
|
||||
// NOTE(hqle): When gl_ClipDistance is re-declared, it will become an UserDefined
|
||||
// symbol. Normally, UserDefined symbols will have "_u" prefix added to their names by
|
||||
|
@ -81,7 +81,7 @@ ImmutableString HashName(const ImmutableString &name,
|
|||
// re-declaration occurs. AngleInternal symbols will have their name intact. However,
|
||||
// the issue is that the current code put a lot of restrictions on AngleInternal
|
||||
// symbols. For examples:
|
||||
// - CollectVariables.cpp will not consider AngleInternal as varying output variables.
|
||||
// - CollectVariables.cpp will not consider AngleInternal as varying output variales.
|
||||
// - SymbolTable.cpp will throw an exception if AngleInternal symbols are declared by
|
||||
// users. In this case, it would be gl_ClipDistance. This is because
|
||||
// TSymbolTable::declare() only accepts an UserDefined symbol.
|
||||
|
@ -96,8 +96,6 @@ ImmutableString HashName(const ImmutableString &name,
|
|||
// Compare to only this place has to be handled if re-declared gl_ClipDistance is
|
||||
// treated as an UserDefined symbol.
|
||||
//
|
||||
// Also, gl_LastFragData should be added.
|
||||
//
|
||||
return name;
|
||||
}
|
||||
ImmutableStringBuilder prefixedName(kUnhashedNamePrefix.length() + name.length());
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
// Generated by gen_builtin_symbols.py using data from builtin_variables.json and
|
||||
// builtin_function_declarations.txt.
|
||||
//
|
||||
// Copyright 2020 The ANGLE Project Authors. All rights reserved.
|
||||
// Copyright 2021 The ANGLE Project Authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
//
|
||||
|
@ -26,216 +26,222 @@ std::ostream &operator<<(std::ostream &os, const sh::ImmutableString &str)
|
|||
namespace
|
||||
{
|
||||
|
||||
constexpr int mangledkT1[] = {1180, 782, 1103, 563, 2974, 1464, 855, 2226, 533, 946,
|
||||
2364, 1527, 2823, 1963, 1949, 406, 1029, 185, 2724, 2797,
|
||||
2341, 264, 1903, 2150, 3196, 1935, 1186, 1337, 65, 194,
|
||||
557, 2982, 1963, 2229, 2382, 1040, 776, 2536, 2699, 2002};
|
||||
constexpr int mangledkT2[] = {243, 2806, 2646, 900, 1556, 238, 1079, 2379, 1830, 1969,
|
||||
1294, 2251, 438, 1259, 2530, 476, 2188, 2765, 253, 197,
|
||||
3034, 1339, 1962, 2836, 1405, 1808, 2356, 1708, 1616, 2555,
|
||||
2384, 835, 1185, 1976, 1471, 1429, 2833, 3097, 1699, 752};
|
||||
constexpr int mangledkT1[] = {2734, 3205, 2084, 1788, 3161, 2931, 522, 1310, 3219, 312,
|
||||
846, 1760, 2276, 1722, 1120, 2959, 635, 824, 165, 3043,
|
||||
2565, 2264, 746, 617, 2636, 2543, 1826, 416, 714, 2484,
|
||||
543, 804, 1480, 2234, 2318, 216, 904};
|
||||
constexpr int mangledkT2[] = {851, 1107, 1845, 815, 2730, 2221, 609, 1079, 544, 822,
|
||||
273, 3003, 1431, 2738, 2683, 447, 2771, 193, 3093, 2494,
|
||||
3167, 1523, 698, 2773, 2875, 1068, 2229, 694, 2203, 235,
|
||||
3100, 3190, 320, 3137, 784, 3099, 3224};
|
||||
constexpr int mangledkG[] = {
|
||||
0, 0, 0, 0, 0, 0, 0, 847, 1062, 0, 0, 0, 0, 0, 0, 0,
|
||||
0, 0, 0, 1632, 2907, 0, 400, 938, 0, 0, 1116, 0, 922, 663, 0, 0,
|
||||
0, 0, 0, 0, 0, 0, 0, 0, 1408, 0, 0, 0, 0, 0, 0, 0,
|
||||
0, 2659, 0, 0, 441, 0, 0, 0, 0, 0, 0, 0, 0, 2742, 0, 0,
|
||||
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2161, 0, 656, 0, 0, 0,
|
||||
0, 0, 0, 0, 2567, 0, 1174, 1979, 0, 0, 0, 0, 0, 0, 0, 0,
|
||||
0, 0, 0, 0, 0, 38, 1120, 0, 0, 0, 0, 2702, 1330, 1414, 381, 0,
|
||||
0, 0, 1483, 0, 0, 2871, 0, 0, 0, 123, 0, 2565, 0, 0, 0, 1217,
|
||||
312, 269, 0, 1357, 760, 0, 0, 0, 0, 2653, 0, 321, 0, 0, 0, 0,
|
||||
0, 0, 3020, 0, 0, 0, 2585, 367, 0, 0, 0, 0, 0, 0, 0, 0,
|
||||
1932, 0, 2090, 0, 0, 0, 0, 0, 188, 0, 0, 0, 47, 0, 0, 0,
|
||||
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2935, 1013, 2352, 424,
|
||||
0, 193, 570, 0, 0, 0, 0, 0, 66, 0, 0, 1811, 0, 2718, 0, 0,
|
||||
1154, 0, 0, 33, 0, 2278, 0, 0, 0, 3156, 0, 0, 0, 0, 0, 0,
|
||||
0, 0, 0, 1071, 0, 1440, 0, 0, 2822, 0, 3116, 819, 576, 0, 1925, 0,
|
||||
0, 0, 370, 2518, 1977, 1323, 0, 1991, 1123, 0, 0, 1835, 0, 780, 609, 0,
|
||||
2709, 1441, 0, 1921, 2084, 0, 0, 0, 950, 3037, 0, 2011, 2476, 0, 0, 2009,
|
||||
83, 0, 0, 0, 0, 0, 901, 0, 752, 0, 2786, 0, 0, 231, 1597, 0,
|
||||
1303, 0, 2279, 0, 0, 0, 725, 0, 0, 495, 0, 0, 0, 0, 1552, 611,
|
||||
0, 931, 0, 341, 0, 0, 0, 68, 2626, 0, 0, 1904, 0, 989, 0, 0,
|
||||
0, 197, 0, 404, 737, 1583, 0, 3057, 0, 2403, 0, 0, 0, 0, 0, 0,
|
||||
1356, 2560, 0, 2901, 533, 938, 363, 3092, 2901, 0, 3193, 0, 0, 354, 202, 0,
|
||||
1248, 0, 457, 0, 0, 0, 0, 1223, 1217, 0, 0, 0, 1673, 0, 0, 0,
|
||||
707, 0, 0, 1367, 0, 2737, 0, 0, 1103, 1064, 0, 1607, 0, 0, 0, 0,
|
||||
1277, 0, 0, 0, 0, 885, 0, 1649, 0, 689, 3019, 0, 0, 0, 0, 236,
|
||||
0, 1099, 972, 0, 305, 1626, 0, 2138, 0, 0, 0, 0, 0, 0, 0, 0,
|
||||
0, 0, 682, 1952, 1708, 0, 0, 0, 0, 0, 0, 879, 642, 0, 0, 0,
|
||||
586, 2856, 0, 0, 1623, 0, 0, 0, 0, 0, 0, 0, 287, 399, 1796, 0,
|
||||
0, 0, 0, 1120, 0, 610, 1122, 3035, 0, 1346, 1185, 0, 0, 0, 740, 0,
|
||||
0, 144, 0, 0, 3017, 0, 0, 0, 3012, 2171, 1137, 1488, 2289, 0, 395, 0,
|
||||
0, 0, 1012, 0, 426, 0, 0, 0, 0, 142, 663, 0, 1782, 772, 1585, 0,
|
||||
0, 0, 0, 0, 3201, 547, 482, 0, 0, 740, 576, 0, 0, 0, 0, 1420,
|
||||
0, 481, 0, 0, 0, 2613, 0, 2040, 0, 0, 0, 0, 0, 2850, 683, 0,
|
||||
0, 0, 2562, 0, 2545, 0, 802, 0, 0, 1074, 0, 0, 0, 0, 0, 0,
|
||||
0, 2994, 319, 0, 0, 2725, 323, 0, 0, 0, 0, 0, 0, 0, 2942, 0,
|
||||
934, 0, 0, 0, 0, 0, 1508, 0, 0, 2146, 1074, 0, 2205, 0, 0, 2542,
|
||||
0, 156, 0, 125, 0, 0, 0, 1723, 0, 0, 3007, 165, 236, 850, 0, 88,
|
||||
0, 2584, 0, 1069, 0, 0, 2887, 0, 0, 0, 933, 420, 448, 641, 0, 0,
|
||||
0, 797, 0, 0, 0, 0, 0, 789, 0, 886, 284, 0, 0, 2655, 3009, 0,
|
||||
0, 2545, 2271, 2146, 626, 1496, 1350, 2318, 0, 2455, 0, 0, 0, 0, 0, 1033,
|
||||
2556, 0, 1590, 0, 0, 0, 0, 1158, 3166, 0, 605, 960, 0, 0, 1220, 3107,
|
||||
860, 0, 0, 2588, 0, 0, 2493, 2966, 0, 0, 313, 1351, 1944, 2018, 2300, 802,
|
||||
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 106, 0, 3010, 3186, 273, 694,
|
||||
0, 1087, 3100, 676, 0, 0, 0, 0, 0, 967, 0, 264, 554, 2879, 0, 0,
|
||||
769, 1774, 619, 646, 0, 0, 1414, 0, 0, 528, 0, 0, 0, 0, 0, 3197,
|
||||
2588, 0, 0, 0, 160, 2111, 0, 0, 1752, 1520, 0, 0, 0, 0, 0, 0,
|
||||
2716, 1011, 1403, 2238, 867, 0, 0, 0, 0, 616, 0, 0, 495, 0, 209, 182,
|
||||
846, 2251, 54, 0, 1124, 0, 0, 445, 0, 3105, 1952, 0, 0, 0, 782, 0,
|
||||
0, 0, 0, 0, 686, 1103, 3085, 0, 0, 1016, 992, 0, 151, 1358, 1410, 0,
|
||||
0, 0, 0, 0, 3080, 2685, 2829, 0, 0, 0, 0, 604, 0, 2476, 0, 2564,
|
||||
0, 0, 1964, 1284, 0, 1538, 0, 0, 1511, 2442, 0, 0, 129, 0, 0, 0,
|
||||
145, 0, 2411, 0, 2015, 527, 316, 889, 0, 0, 0, 0, 0, 1272, 141, 2488,
|
||||
0, 0, 0, 0, 1556, 184, 0, 0, 0, 0, 0, 1707, 134, 0, 1840, 0,
|
||||
0, 869, 1061, 0, 811, 2766, 539, 0, 0, 2445, 0, 0, 0, 0, 708, 0,
|
||||
0, 205, 1341, 0, 986, 0, 0, 2064, 0, 0, 0, 0, 850, 359, 0, 1914,
|
||||
1185, 1121, 1411, 0, 0, 0, 0, 2389, 593, 213, 669, 510, 2437, 149, 685, 0,
|
||||
0, 0, 2911, 0, 1224, 1067, 892, 0, 388, 1281, 505, 0, 1081, 216, 378, 0,
|
||||
0, 134, 0, 322, 2508, 329, 2259, 0, 0, 1633, 3003, 6, 1405, 0, 0, 0,
|
||||
0, 0, 80, 374, 85, 0, 3192, 0, 447, 0, 0, 0, 701, 1489, 0, 2020,
|
||||
0, 2989, 1950, 3143, 2769, 1053, 0, 0, 2726, 0, 327, 0, 1071, 0, 532, 1860,
|
||||
0, 0, 982, 1831, 2858, 674, 0, 0, 262, 0, 0, 217, 0, 0, 622, 691,
|
||||
990, 0, 0, 0, 50, 334, 1890, 2667, 0, 0, 0, 0, 1452, 13, 0, 1785,
|
||||
0, 0, 445, 0, 248, 2909, 421, 0, 0, 2909, 0, 2245, 0, 0, 1016, 0,
|
||||
0, 0, 0, 223, 3178, 0, 0, 541, 0, 0, 2679, 0, 0, 0, 0, 1620,
|
||||
0, 0, 2898, 475, 0, 2146, 1126, 3107, 0, 129, 0, 1634, 1733, 1074, 1158, 0,
|
||||
0, 0, 785, 0, 585, 364, 0, 0, 0, 262, 807, 0, 1728, 0, 0, 1599,
|
||||
0, 192, 793, 0, 0, 448, 506, 0, 0, 0, 0, 3002, 1950, 0, 0, 200,
|
||||
0, 0, 886, 183, 2792, 0, 303, 0, 2898, 3034, 2175, 0, 953, 0, 0, 0,
|
||||
2874, 2662, 0, 0, 469, 263, 0, 0, 1339, 374, 0, 585, 798, 0, 1028, 0,
|
||||
0, 0, 0, 0, 0, 0, 551, 2769, 0, 0, 0, 2384, 2320, 0, 332, 0,
|
||||
0, 0, 0, 0, 0, 0, 0, 593, 0, 0, 186, 210, 1350, 3113, 0, 63,
|
||||
402, 1159, 708, 0, 107, 0, 0, 0, 777, 2343, 0, 117, 2046, 2923, 2434, 2458,
|
||||
0, 738, 2690, 0, 0, 0, 2608, 0, 836, 524, 845, 0, 0, 0, 62, 0,
|
||||
0, 1842, 1557, 775, 178, 0, 0, 0, 0, 27, 0, 0, 0, 174, 2027, 0,
|
||||
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 481, 0, 0, 0, 0, 1528,
|
||||
0, 0, 1069, 844, 0, 1368, 0, 0, 0, 0, 0, 0, 160, 407, 0, 0,
|
||||
0, 0, 0, 304, 77, 0, 1527, 0, 0, 0, 298, 0, 0, 0, 0, 2785,
|
||||
0, 0, 0, 0, 2284, 0, 0, 1493, 0, 0, 0, 2511, 0, 0, 0, 1046,
|
||||
792, 0, 0, 0, 1095, 278, 0, 0, 0, 1605, 697, 2981, 0, 572, 786, 422,
|
||||
0, 0, 0, 770, 2488, 0, 460, 1500, 2460, 351, 0, 83, 0, 907, 681, 0,
|
||||
1114, 462, 567, 0, 0, 0, 1136, 678, 0, 1131, 0, 0, 112, 0, 0, 0,
|
||||
0, 0, 22, 0, 0, 482, 496, 0, 2643, 0, 444, 2532, 0, 2683, 958, 0,
|
||||
1042, 0, 3099, 1311, 1111, 0, 1350, 810, 520, 1320, 0, 817, 1761, 0, 0, 2889,
|
||||
685, 0, 965, 0, 1454, 0, 2781, 0, 3171, 0, 0, 2749, 0, 0, 0, 0,
|
||||
0, 4, 0, 0, 229, 0, 0, 2418, 0, 870, 924, 1547, 0, 3193, 1187, 0,
|
||||
1199, 0, 3205, 0, 350, 0, 0, 0, 54, 883, 0, 0, 0, 1859, 0, 1914,
|
||||
2493, 863, 3183, 0, 1460, 0, 1283, 0, 0, 639, 0, 2154, 0, 0, 0, 0,
|
||||
725, 0, 0, 0, 476, 0, 1306, 931, 0, 3133, 2670, 394, 740, 0, 0, 0,
|
||||
0, 0, 0, 276, 0, 0, 0, 47, 0, 0, 2659, 1055, 0, 1378, 0, 0,
|
||||
2304, 2876, 347, 928, 0, 416, 0, 0, 0, 1033, 0, 0, 0, 0, 0, 0,
|
||||
683, 275, 0, 0, 626, 0, 362, 0, 0, 0, 0, 0, 2282, 0, 1260, 387,
|
||||
0, 2260, 0, 0, 693, 0, 703, 0, 0, 0, 768, 1102, 0, 1579, 0, 1137,
|
||||
0, 0, 0, 407, 0, 18, 1000, 0, 0, 2715, 709, 0, 0, 78, 0, 0,
|
||||
0, 29, 2506, 0, 0, 0, 0, 426, 180, 0, 2420, 0, 0, 604, 2649, 0,
|
||||
0, 0, 137, 0, 1223, 0, 560, 0, 0, 2797, 1225, 900, 0, 1694, 0, 0,
|
||||
454, 584, 0, 0, 0, 0, 2280, 0, 0, 0, 0, 1765, 1352, 0, 0, 493,
|
||||
0, 142, 0, 2635, 1495, 495, 1211, 471, 453, 1148, 580, 1580, 239, 1017, 373, 1536,
|
||||
1949, 0, 63, 30, 0, 0, 0, 0, 0, 0, 0, 219, 0, 0, 0, 0,
|
||||
355, 1372, 250, 1563, 0, 414, 68, 2752, 1193, 0, 0, 794, 0, 102, 0, 2866,
|
||||
1305, 0, 671, 525, 2971, 3020, 933, 0, 0, 1857, 737, 0, 1660, 0, 0, 2937,
|
||||
0, 0, 0, 3034, 0, 462, 1325, 0, 0, 957, 0, 0, 539, 0, 0, 776,
|
||||
279, 962, 671, 0, 2906, 299, 874, 0, 0, 1361, 0, 0, 426, 0, 2637, 0,
|
||||
785, 2336, 1254, 663, 0, 2283, 140, 0, 605, 0, 0, 0, 11, 245, 1258, 0,
|
||||
0, 839, 0, 245, 1054, 48, 2396, 3000, 93, 3041, 2984, 0, 2975, 0, 0, 0,
|
||||
1374, 0, 1930, 0, 0, 0, 0, 2037, 1128, 2873, 499, 0, 0, 2052, 473, 0,
|
||||
82, 554, 1336, 0, 0, 0, 2530, 2316, 1155, 0, 0, 549, 0, 591, 0, 21,
|
||||
2280, 3011, 1071, 0, 1043, 0, 2308, 0, 0, 634, 0, 872, 269, 0, 0, 0,
|
||||
174, 0, 0, 0, 133, 0, 0, 204, 1313, 115, 2534, 2169, 0, 1285, 25, 1213,
|
||||
871, 0, 982, 0, 341, 1478, 1980, 2621, 0, 0, 1246, 408, 2072, 773, 0, 858,
|
||||
298, 1299, 719, 0, 0, 735, 1142, 0, 36, 0, 21, 0, 1387, 0, 297, 0,
|
||||
0, 326, 623, 1295, 595, 1394, 0, 0, 1626, 0, 2648, 0, 0, 1517, 783, 2036,
|
||||
478, 2580, 624, 2506, 0, 631, 0, 0, 1596, 0, 1851, 0, 0, 838, 149, 894,
|
||||
1544, 749, 152, 606, 0, 396, 2649, 1280, 0, 3120, 963, 716, 0, 0, 457, 1185,
|
||||
227, 2150, 1130, 0, 0, 0, 5, 5, 0, 70, 1048, 770, 2997, 713, 2093, 0,
|
||||
1015, 0, 0, 746, 0, 1144, 0, 449, 0, 430, 815, 312, 2555, 1230, 0, 0,
|
||||
2205, 2182, 527, 1447, 3134, 866, 0, 0, 1774, 1150, 0, 1448, 0, 2, 1472, 464,
|
||||
0, 2635, 0, 0, 0, 1033, 2789, 973, 1404, 2793, 906, 167, 0, 1165, 1164, 2927,
|
||||
0, 1229, 0, 394, 1423, 0, 177, 2183, 0, 0, 1260, 211, 0, 0, 1240, 429,
|
||||
0, 164, 948, 473, 3135, 0, 0, 1326, 0, 0, 1126, 0, 353, 1251, 0, 2417,
|
||||
0, 1626, 0, 0, 18, 1449, 957, 262, 0, 2729, 0, 0, 0, 1398, 0, 0,
|
||||
0, 0, 208, 1539, 0, 0, 0, 0, 938, 0, 0, 2614, 0, 104, 843, 0,
|
||||
2677, 0, 1115, 0, 0, 186, 2456, 236, 8, 0, 110, 795, 0, 0, 0, 0,
|
||||
0, 0, 0, 3126, 1492, 0, 558, 718, 813, 0, 0, 545, 668, 406, 1468, 526,
|
||||
0, 0, 2977, 0, 1206, 749, 2023, 269, 961, 0, 952, 0, 1723, 0, 1330, 485,
|
||||
1402, 0, 1098, 3055, 2116, 0, 494, 0, 0, 3115, 0, 71, 0, 0, 0, 0,
|
||||
114, 345, 0, 0, 2829, 1036, 3108, 0, 407, 0, 506, 0, 0, 0, 1145, 550,
|
||||
0, 766, 2420, 0, 1234, 87, 199, 3112, 0, 0, 51, 0, 3076, 0, 1263, 0,
|
||||
433, 0, 1151, 0, 0, 3038, 2198, 0, 0, 0, 793, 880, 1119, 0, 0, 0,
|
||||
561, 0, 0, 1024, 0, 455, 321, 0, 1001, 1483, 0, 810, 1188, 837, 0, 0,
|
||||
52, 187, 0, 0, 1409, 1261, 0, 3119, 709, 0, 873, 2982, 0, 3201, 2875, 0,
|
||||
3155, 285, 0, 1942, 2041, 240, 1357, 1148, 0, 2395, 0, 856, 1582, 0, 249, 0,
|
||||
1191, 1138, 0, 0, 818, 116, 355, 2602, 1176, 0, 1872, 1610, 627, 0, 0, 0,
|
||||
3179, 2939, 0, 1085, 255, 38, 2231, 1289, 793, 351, 0, 1281, 0, 3062, 648, 1247,
|
||||
0, 0, 3024, 2952, 1299, 386, 2135, 512, 3067, 0, 0, 887, 0, 0, 1334, 0,
|
||||
657, 160, 0, 89, 0, 678, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
|
||||
2189, 0, 0, 2813, 0, 1022, 972, 0, 486, 0, 1438, 3198, 1329, 975, 1369, 1129,
|
||||
3142, 0, 1193, 869, 2229, 123, 2669, 0, 1030, 0, 1384, 0, 0, 1247, 42, 2501,
|
||||
75, 0, 157, 0, 2659, 2776, 1723, 1146, 641, 0, 0, 330, 0, 0, 1294, 0,
|
||||
0, 0, 1209, 0, 807, 0, 881, 1398, 258, 0, 1759, 3186, 0, 0, 246, 55,
|
||||
579, 1565, 1625, 0, 273, 0, 2759, 800, 0, 234, 1569, 968, 2369, 1184, 0, 2749,
|
||||
0, 3032, 1408, 601, 941, 215, 268, 779, 164, 2058, 1391, 0, 3153, 0, 1454, 2713,
|
||||
0, 0, 2924, 1875, 0, 1041, 325, 0, 1943, 345, 454, 12, 2946, 0, 1064, 2969,
|
||||
2061, 223, 3090, 2964, 116, 0, 1199, 0, 3196, 329, 1141, 705, 0, 1566, 0, 0,
|
||||
0, 0, 287, 0, 0, 625, 0, 0, 1575, 205, 0, 0, 0, 1729, 0, 0,
|
||||
782, 3054, 0, 0, 0, 0, 73, 0, 4, 0, 2291, 0, 212, 1208, 0, 0,
|
||||
0, 689, 521, 498, 710, 532, 0, 0, 2116, 2876, 0, 1471, 415, 836, 0, 0,
|
||||
0, 0, 1325, 0, 0, 0, 1801, 2443, 1076, 1747, 8, 1985, 0, 0, 575, 2979,
|
||||
0, 0, 3161, 2217, 0, 0, 729, 0, 490, 664, 0, 0, 503, 0, 850, 0,
|
||||
991, 2970, 3046, 2957, 1375, 0, 0, 0, 0, 2986, 273, 0, 0, 904, 275, 0,
|
||||
2418, 0, 0, 1365, 905, 720, 666, 0, 0, 1389, 998, 0, 1509, 0, 89, 0,
|
||||
3148, 0, 0, 0, 249, 0, 0, 0, 1143, 290, 2213, 0, 281, 0, 0, 1172,
|
||||
0, 0, 0, 1088, 1517, 739, 2866, 0, 0, 0, 1293, 2021, 2205, 0, 1452, 0,
|
||||
185, 1428, 0, 1773, 122, 623, 1339, 1011, 3181, 3203, 888, 2269, 315, 0, 688, 0,
|
||||
1231, 0, 1211, 921, 340, 1222, 0, 0, 0, 2695, 0, 1644, 0, 1594, 0, 673,
|
||||
0, 3044, 0, 1142, 911, 0, 836, 1135, 2803, 1578, 1905, 1394, 442, 0, 0, 2977,
|
||||
0, 0, 989, 296, 162, 0, 0, 534, 0, 1375, 994, 1355, 0, 1701, 987, 0,
|
||||
2372, 84, 0, 0, 2699, 0, 1163, 2190, 425, 0, 0, 600, 0, 1570, 0, 946,
|
||||
0, 2218, 0, 63, 371, 0, 0, 598, 0, 0, 256, 0, 0, 0, 0, 0,
|
||||
0, 763, 3142, 533, 2393, 2685, 0, 595, 57, 0, 2809, 0, 0, 2531, 0, 1029,
|
||||
69, 0, 0, 1224, 1218, 0, 1445, 0, 1482, 992, 628, 1284, 0, 602, 183, 0,
|
||||
0, 1875, 1232, 3168, 2071, 2553, 0, 0, 0, 2826, 1483, 2353, 0, 2989, 1153, 632,
|
||||
0, 835, 1448, 1601, 2235, 33, 1979, 0, 93, 0, 0, 0, 2288, 2900, 0, 1407,
|
||||
1356, 359, 0, 1183, 0, 0, 0, 0, 1728, 2729, 2295, 0, 1089, 0, 1305, 2909,
|
||||
1257, 1725, 0, 712, 1094, 1398, 0, 2559, 1688, 3158, 0, 1392, 1797, 0, 0, 1077,
|
||||
953, 932, 1249, 0, 143, 416, 83, 42, 0, 2751, 2643, 0, 0, 0, 1791, 0,
|
||||
31, 97, 0, 65, 747, 434, 0, 0, 878, 0, 0, 0, 2447, 1019, 0, 0,
|
||||
3047, 0, 0, 0, 1196, 1159, 0, 743, 2813, 1036, 0, 397, 2959, 938, 0, 1305,
|
||||
0, 0, 0, 2577, 1608, 194, 574, 0, 898, 0, 0, 258, 2770, 0, 0, 935,
|
||||
0, 0, 0, 0, 778, 622, 0, 1765, 0, 0, 3094, 1571, 1164, 0, 0, 40,
|
||||
1040, 469, 0, 112, 0, 1079, 2325, 0, 0, 1063, 3191, 0, 1109, 1135, 2512, 0,
|
||||
0, 489, 0, 201, 3181, 2271, 1243, 3103, 0, 0, 374, 0, 0, 0, 0, 0,
|
||||
287, 149, 2440, 1147, 592, 1654, 818, 0, 2474, 264, 0, 0, 0, 92, 218, 0,
|
||||
0, 7, 0, 0, 180, 0, 1239, 0, 0, 0, 0, 0, 0, 0, 0, 0,
|
||||
1563, 1353, 2730, 809, 2634, 0, 1613, 2930, 0, 1782, 2507, 0, 501, 1563, 881, 2102,
|
||||
3069, 0, 760, 1075, 652, 473, 934, 1850, 0, 0, 3095, 0, 0, 1747, 0, 572,
|
||||
358, 2230, 0, 0, 1014, 0, 0, 213, 2911, 3096, 0, 1044, 2263, 1765, 87, 1069,
|
||||
471, 550, 263, 839, 1306, 58, 163, 3188, 0, 198, 0, 2496, 1537, 24, 0, 814,
|
||||
0, 0, 206, 0, 2592, 1146, 0, 25, 1094, 3047, 2936, 0, 1452, 1484, 1547, 0,
|
||||
0, 0, 2035, 1113, 305, 0, 46, 0, 2216, 1719, 3040, 0, 293, 954, 124, 0,
|
||||
94, 383, 1980, 535, 2437, 43, 0, 327, 0, 0, 2589, 0, 0, 1208, 2780, 181,
|
||||
1859, 0, 2628, 0, 0, 991, 445, 62, 0, 0, 802, 0, 0, 0, 0, 0,
|
||||
647, 451, 1025, 1001, 1236, 2275, 1180, 0, 0, 0, 1566, 1183, 171, 0, 2709, 1448,
|
||||
0, 0, 0, 300, 0, 0, 596, 0, 1252, 1318, 2538, 1070, 280, 844, 0, 1317,
|
||||
257, 2916, 1154, 493, 39, 173, 777, 0, 1030, 303, 492, 0, 0, 0, 2121, 0,
|
||||
0, 1464, 1394, 0, 0, 1007, 0, 2732, 0, 0, 705, 1341, 0, 1237, 0, 0,
|
||||
0, 0, 0, 1552, 668, 959, 883, 0, 712, 1254, 2745, 0, 0, 3137, 0, 0,
|
||||
0, 1806, 13, 395, 0, 1916, 0, 0, 518, 0, 545, 2529, 0, 0, 0, 2919,
|
||||
1111, 385, 921, 2879, 0, 148, 1283, 325, 0, 2639, 800, 0, 245, 0, 341, 0,
|
||||
2805, 0, 0, 2031, 1100, 591, 0, 2903, 2980, 3182, 0, 463, 1761, 1686, 827, 142,
|
||||
2462, 282, 0, 0, 1621, 513, 0, 370, 327, 0, 373, 1344, 0, 771, 1473, 537,
|
||||
3127, 0, 0, 0, 0, 1173, 0, 0, 808, 2341, 2994, 0, 0, 1236, 3106, 2511,
|
||||
500, 2494, 1327, 973, 0, 726, 0, 2432, 2508, 1090, 140, 0, 2047, 0, 511, 0,
|
||||
752, 412, 0, 409, 942, 1193, 0, 2991, 1436, 508, 0, 1071, 1244, 731, 0, 1206,
|
||||
305, 2007, 374, 533, 117, 146, 654, 1276, 1018, 0, 0, 0, 1418, 1541, 0, 0,
|
||||
230, 0, 724, 319, 2258, 1057, 653, 0, 2684, 0, 2969, 1282, 0, 248, 0, 1048,
|
||||
3139, 0, 1511, 0, 1044, 0, 576, 1503, 0, 0, 69, 2572, 0, 0, 546, 90,
|
||||
80, 0, 0, 438, 313, 0, 0, 0, 0, 0, 0, 2621, 1538, 3045, 0, 70,
|
||||
1078, 384, 2885, 1182, 2890, 11, 0, 1108, 1542, 0, 0, 914, 1443, 0, 2325, 1529,
|
||||
0, 606, 0, 972, 0, 825, 0, 225, 1047, 1322, 1051, 1864, 513, 308, 0, 0,
|
||||
456, 0, 422, 2906, 767, 0, 2102, 434, 1426, 581, 0, 757, 761, 1614, 376, 86,
|
||||
531, 299, 0, 0, 161, 1362, 613, 0};
|
||||
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 627, 0, 0, 0, 0, 0,
|
||||
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
|
||||
0, 2220, 0, 0, 0, 0, 0, 0, 1500, 0, 0, 0, 1490, 0, 0, 0,
|
||||
0, 0, 0, 0, 0, 0, 0, 0, 3061, 0, 0, 0, 0, 0, 0, 2799,
|
||||
0, 0, 0, 0, 2903, 0, 0, 0, 915, 0, 1508, 0, 0, 0, 0, 1952,
|
||||
463, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2133, 1276, 0,
|
||||
0, 0, 0, 0, 0, 921, 1132, 0, 0, 0, 0, 0, 0, 0, 0, 0,
|
||||
0, 0, 0, 0, 0, 0, 0, 2153, 0, 2232, 0, 0, 3143, 0, 775, 0,
|
||||
0, 1897, 0, 2153, 670, 0, 0, 0, 0, 0, 256, 1445, 0, 0, 1586, 0,
|
||||
0, 0, 1585, 3175, 0, 0, 0, 0, 366, 0, 2016, 0, 1506, 0, 215, 0,
|
||||
0, 0, 0, 0, 0, 299, 0, 1534, 0, 1656, 0, 120, 0, 0, 821, 0,
|
||||
0, 0, 0, 0, 1925, 0, 0, 0, 0, 0, 0, 0, 0, 1629, 3041, 0,
|
||||
0, 0, 2949, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
|
||||
0, 0, 2871, 0, 0, 0, 0, 0, 0, 139, 0, 0, 0, 0, 0, 610,
|
||||
142, 0, 2263, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
|
||||
0, 0, 1111, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
|
||||
766, 0, 2602, 436, 716, 0, 1932, 3003, 1221, 0, 0, 2847, 0, 975, 0, 675,
|
||||
0, 0, 0, 0, 0, 0, 0, 0, 904, 0, 1211, 0, 0, 0, 303, 0,
|
||||
993, 1316, 0, 1954, 0, 0, 0, 0, 0, 0, 1824, 0, 0, 3, 0, 0,
|
||||
800, 0, 0, 0, 0, 0, 0, 162, 576, 0, 0, 1173, 808, 0, 0, 0,
|
||||
0, 0, 0, 0, 520, 529, 0, 818, 0, 0, 0, 0, 96, 485, 0, 757,
|
||||
0, 2614, 0, 0, 1096, 0, 0, 0, 0, 0, 1533, 0, 3259, 0, 0, 1381,
|
||||
3226, 0, 53, 0, 0, 0, 1810, 0, 0, 0, 0, 0, 1537, 0, 0, 0,
|
||||
0, 561, 0, 0, 2413, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1673, 0,
|
||||
0, 2868, 2328, 0, 564, 0, 114, 0, 0, 326, 2334, 0, 1432, 0, 871, 0,
|
||||
714, 0, 873, 0, 1419, 0, 0, 0, 313, 0, 0, 0, 0, 0, 0, 1188,
|
||||
0, 0, 0, 647, 0, 40, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
|
||||
0, 0, 0, 0, 1870, 0, 0, 0, 2946, 0, 814, 579, 0, 0, 0, 2392,
|
||||
31, 0, 2796, 0, 225, 0, 0, 548, 940, 200, 3063, 0, 2953, 0, 0, 0,
|
||||
0, 229, 0, 127, 0, 0, 0, 0, 0, 2899, 0, 612, 0, 0, 1964, 0,
|
||||
1223, 0, 0, 427, 0, 1881, 2511, 3195, 0, 0, 2920, 0, 0, 1159, 0, 0,
|
||||
0, 0, 0, 1355, 1182, 0, 574, 0, 525, 0, 0, 0, 0, 0, 2958, 1711,
|
||||
0, 0, 0, 0, 0, 3067, 0, 0, 2757, 1415, 0, 2287, 708, 0, 1186, 0,
|
||||
0, 0, 667, 0, 0, 0, 1152, 2362, 0, 0, 1678, 0, 630, 1810, 0, 0,
|
||||
3046, 0, 0, 0, 0, 2067, 725, 0, 0, 0, 2605, 0, 0, 2, 0, 504,
|
||||
0, 0, 0, 0, 1176, 335, 0, 215, 921, 851, 671, 2963, 0, 0, 44, 2700,
|
||||
0, 0, 0, 941, 0, 1980, 867, 0, 0, 0, 0, 895, 0, 0, 0, 0,
|
||||
0, 375, 0, 0, 2831, 0, 0, 0, 0, 3245, 2317, 922, 0, 0, 0, 859,
|
||||
645, 0, 0, 0, 0, 0, 523, 0, 0, 2041, 0, 0, 0, 2825, 2797, 0,
|
||||
0, 17, 0, 0, 0, 981, 1412, 0, 397, 1314, 873, 0, 1099, 0, 0, 2191,
|
||||
0, 0, 0, 2123, 136, 1329, 0, 0, 0, 0, 0, 0, 0, 0, 816, 0,
|
||||
1634, 0, 0, 559, 202, 0, 0, 0, 1691, 0, 1017, 1199, 0, 1357, 0, 0,
|
||||
2926, 254, 3299, 1945, 928, 0, 0, 0, 0, 0, 1769, 0, 0, 0, 0, 0,
|
||||
1444, 0, 0, 0, 0, 680, 0, 0, 0, 3160, 0, 0, 0, 0, 720, 0,
|
||||
0, 0, 0, 0, 0, 0, 0, 0, 63, 0, 0, 0, 0, 0, 1908, 3064,
|
||||
356, 0, 0, 0, 0, 0, 395, 0, 0, 0, 0, 772, 0, 0, 0, 0,
|
||||
0, 310, 0, 0, 0, 0, 3133, 0, 1475, 0, 0, 0, 0, 0, 0, 0,
|
||||
278, 0, 0, 0, 1517, 0, 1085, 0, 336, 3208, 0, 0, 0, 0, 1151, 0,
|
||||
672, 2958, 439, 3079, 1783, 0, 2512, 0, 0, 371, 0, 0, 0, 0, 124, 0,
|
||||
733, 0, 772, 1020, 3046, 0, 0, 407, 0, 20, 0, 361, 2698, 0, 0, 246,
|
||||
1393, 175, 658, 0, 0, 0, 583, 2931, 839, 850, 1292, 0, 0, 0, 0, 342,
|
||||
0, 0, 3209, 275, 49, 0, 1475, 67, 2326, 0, 357, 1135, 799, 0, 1939, 0,
|
||||
0, 0, 0, 1108, 0, 0, 0, 660, 0, 1839, 0, 0, 113, 12, 0, 685,
|
||||
629, 0, 330, 0, 0, 700, 0, 0, 0, 1273, 65, 0, 835, 0, 0, 520,
|
||||
0, 0, 0, 0, 0, 0, 65, 0, 322, 686, 0, 1406, 0, 0, 2015, 0,
|
||||
0, 3051, 0, 1698, 2186, 0, 3098, 0, 0, 302, 3003, 0, 0, 0, 236, 0,
|
||||
0, 0, 380, 0, 198, 0, 396, 0, 0, 0, 825, 0, 1272, 0, 0, 0,
|
||||
689, 1879, 0, 2524, 0, 142, 0, 1181, 0, 0, 2336, 0, 0, 3240, 2739, 0,
|
||||
2878, 0, 0, 747, 0, 0, 2777, 0, 1040, 0, 0, 3054, 0, 0, 0, 346,
|
||||
0, 0, 957, 0, 0, 0, 418, 0, 0, 0, 127, 0, 0, 0, 0, 1889,
|
||||
259, 0, 619, 643, 440, 0, 737, 3064, 0, 1746, 1507, 0, 0, 407, 2421, 0,
|
||||
1353, 3085, 721, 0, 0, 514, 0, 1617, 929, 598, 0, 944, 0, 0, 0, 1401,
|
||||
0, 0, 1929, 0, 0, 3206, 0, 0, 2882, 0, 0, 3254, 2691, 0, 92, 742,
|
||||
0, 0, 0, 2333, 0, 0, 0, 0, 0, 665, 2720, 0, 392, 2568, 0, 0,
|
||||
0, 2053, 57, 0, 418, 854, 0, 143, 1437, 498, 0, 0, 547, 0, 121, 0,
|
||||
0, 0, 0, 0, 150, 0, 0, 1261, 0, 0, 395, 0, 2592, 0, 0, 0,
|
||||
629, 0, 0, 0, 528, 0, 1717, 2226, 1817, 0, 1772, 795, 836, 1093, 388, 2462,
|
||||
0, 2877, 2852, 1994, 647, 2210, 2646, 0, 0, 0, 0, 0, 0, 0, 0, 0,
|
||||
1120, 0, 0, 2592, 2766, 2901, 0, 383, 0, 0, 0, 2199, 2653, 0, 0, 0,
|
||||
0, 0, 0, 1742, 0, 0, 0, 0, 0, 831, 868, 0, 0, 0, 40, 943,
|
||||
169, 0, 2929, 2038, 0, 0, 658, 0, 0, 0, 0, 1013, 0, 0, 17, 872,
|
||||
782, 727, 0, 0, 0, 2617, 426, 0, 0, 2833, 2460, 0, 546, 0, 0, 125,
|
||||
0, 1026, 0, 2107, 1204, 1055, 0, 0, 0, 0, 867, 1592, 0, 2720, 187, 0,
|
||||
0, 2817, 2641, 0, 1549, 0, 1871, 0, 2049, 0, 1118, 2829, 911, 2599, 1543, 0,
|
||||
0, 1552, 0, 1311, 1372, 1098, 0, 0, 611, 0, 1770, 1626, 731, 0, 2470, 2241,
|
||||
73, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1180, 0, 41, 0, 0, 0,
|
||||
0, 1407, 559, 0, 0, 3017, 1347, 0, 201, 0, 0, 269, 3079, 3160, 707, 89,
|
||||
1442, 0, 486, 1369, 2711, 865, 2936, 0, 1101, 2153, 0, 0, 734, 925, 0, 1903,
|
||||
0, 0, 279, 0, 1013, 0, 0, 0, 112, 0, 0, 0, 0, 0, 530, 2499,
|
||||
789, 857, 560, 0, 0, 1295, 285, 1256, 0, 0, 2971, 218, 233, 0, 955, 363,
|
||||
1292, 600, 0, 0, 1910, 0, 0, 0, 0, 333, 2408, 0, 0, 0, 934, 1296,
|
||||
0, 0, 2400, 838, 2330, 0, 0, 668, 1797, 901, 0, 0, 517, 0, 0, 0,
|
||||
1197, 583, 3147, 2068, 2510, 1252, 0, 0, 0, 0, 0, 250, 1981, 1739, 0, 2012,
|
||||
0, 0, 0, 0, 0, 0, 2693, 0, 0, 469, 0, 0, 0, 0, 2774, 0,
|
||||
0, 838, 0, 982, 409, 0, 0, 528, 0, 0, 0, 911, 0, 0, 2771, 1431,
|
||||
0, 0, 362, 0, 623, 0, 0, 0, 0, 0, 0, 0, 3266, 1063, 0, 0,
|
||||
708, 0, 670, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 768,
|
||||
0, 0, 361, 0, 0, 0, 3262, 2995, 860, 56, 2932, 0, 149, 0, 0, 75,
|
||||
1524, 1486, 1249, 500, 0, 136, 174, 660, 0, 961, 0, 0, 0, 0, 2607, 127,
|
||||
0, 0, 0, 495, 0, 0, 0, 1084, 0, 0, 2521, 1342, 0, 0, 1237, 166,
|
||||
0, 0, 0, 2668, 715, 401, 619, 0, 763, 0, 1364, 1499, 0, 0, 0, 1190,
|
||||
0, 2195, 3049, 281, 0, 242, 721, 226, 286, 282, 2820, 0, 0, 0, 510, 2447,
|
||||
313, 2557, 350, 0, 0, 2913, 0, 182, 160, 2824, 284, 0, 0, 1296, 0, 0,
|
||||
686, 0, 0, 520, 926, 0, 770, 1525, 0, 2836, 2052, 0, 0, 3021, 483, 0,
|
||||
1432, 0, 2986, 0, 0, 783, 1500, 317, 0, 752, 0, 0, 2465, 0, 0, 0,
|
||||
2980, 0, 146, 0, 0, 0, 851, 0, 0, 0, 0, 0, 0, 1404, 0, 0,
|
||||
2674, 459, 0, 2687, 2302, 3204, 0, 0, 0, 0, 3099, 3015, 462, 0, 2763, 0,
|
||||
2671, 0, 1842, 0, 0, 1270, 713, 88, 524, 23, 0, 1638, 2307, 1462, 1058, 1771,
|
||||
84, 0, 2392, 0, 0, 0, 0, 0, 1258, 0, 1864, 1049, 983, 0, 0, 1156,
|
||||
848, 0, 1739, 0, 1562, 0, 0, 1228, 153, 0, 122, 853, 0, 579, 0, 0,
|
||||
0, 0, 781, 0, 777, 965, 354, 278, 557, 0, 2486, 0, 898, 0, 392, 948,
|
||||
1039, 1008, 0, 0, 2001, 0, 869, 0, 930, 0, 0, 0, 0, 0, 0, 0,
|
||||
2895, 0, 775, 0, 3186, 0, 2204, 863, 835, 0, 0, 749, 0, 0, 482, 3132,
|
||||
0, 0, 0, 2905, 0, 1860, 907, 1417, 3257, 1426, 0, 0, 1955, 1949, 1036, 0,
|
||||
0, 3272, 2532, 0, 273, 0, 2579, 0, 0, 0, 0, 39, 2138, 198, 2816, 0,
|
||||
271, 0, 0, 3193, 929, 786, 3266, 0, 1423, 0, 1011, 0, 0, 0, 1902, 0,
|
||||
139, 2634, 0, 0, 2904, 1750, 3280, 0, 0, 1150, 0, 0, 0, 0, 326, 0,
|
||||
977, 0, 2022, 331, 147, 1519, 0, 3166, 0, 2976, 1409, 834, 0, 0, 669, 1344,
|
||||
0, 960, 0, 220, 2351, 0, 0, 1077, 0, 0, 588, 0, 0, 0, 1531, 62,
|
||||
0, 2540, 672, 0, 0, 1357, 789, 0, 0, 0, 2713, 588, 375, 1044, 2439, 828,
|
||||
1134, 111, 2289, 0, 1904, 3132, 0, 831, 492, 1493, 830, 1659, 101, 792, 2310, 0,
|
||||
2507, 1399, 0, 3068, 0, 935, 2461, 992, 0, 0, 324, 113, 0, 0, 178, 0,
|
||||
1262, 0, 1417, 0, 0, 1401, 209, 435, 1222, 1254, 0, 2642, 1198, 36, 2308, 1515,
|
||||
601, 0, 1802, 160, 318, 1953, 0, 596, 0, 0, 0, 665, 0, 3147, 1442, 1167,
|
||||
3003, 0, 942, 0, 860, 0, 0, 928, 0, 1280, 978, 753, 0, 0, 1086, 2673,
|
||||
2500, 774, 0, 0, 840, 0, 0, 885, 1326, 0, 0, 0, 0, 1210, 875, 2798,
|
||||
0, 0, 11, 3016, 86, 0, 223, 1204, 0, 3219, 0, 0, 683, 906, 2296, 2981,
|
||||
0, 837, 0, 956, 2920, 0, 0, 2561, 1333, 2340, 95, 0, 649, 2945, 0, 0,
|
||||
1092, 0, 0, 745, 163, 2487, 0, 1045, 0, 2817, 0, 2118, 1340, 0, 1540, 0,
|
||||
3281, 600, 648, 2869, 0, 3112, 0, 880, 1297, 0, 0, 2980, 277, 0, 0, 0,
|
||||
88, 217, 1160, 0, 953, 886, 0, 1116, 0, 2340, 0, 1264, 0, 38, 2048, 1247,
|
||||
105, 0, 276, 465, 0, 2140, 0, 1638, 3227, 0, 1100, 0, 0, 0, 1120, 2650,
|
||||
0, 1304, 1394, 1183, 0, 0, 1411, 610, 0, 3166, 2865, 0, 173, 0, 0, 879,
|
||||
645, 0, 70, 0, 52, 2561, 0, 0, 365, 0, 1060, 0, 86, 0, 330, 0,
|
||||
0, 0, 433, 407, 38, 0, 2968, 639, 0, 0, 0, 497, 773, 0, 0, 243,
|
||||
0, 466, 522, 0, 1434, 321, 772, 0, 890, 1398, 0, 0, 1226, 1151, 0, 0,
|
||||
340, 0, 3152, 453, 526, 0, 2673, 1668, 0, 0, 0, 0, 0, 0, 1144, 433,
|
||||
533, 3044, 1075, 0, 449, 2086, 657, 0, 581, 0, 0, 0, 2933, 2651, 361, 3030,
|
||||
0, 0, 201, 0, 1305, 0, 0, 1162, 1195, 1613, 0, 0, 1660, 2533, 2556, 0,
|
||||
0, 0, 0, 0, 666, 578, 1132, 0, 1006, 165, 1256, 298, 123, 2218, 0, 0,
|
||||
0, 3049, 0, 973, 0, 953, 2275, 781, 0, 0, 0, 0, 0, 364, 0, 2150,
|
||||
323, 0, 0, 0, 904, 2266, 2603, 2568, 909, 0, 2955, 438, 483, 0, 0, 760,
|
||||
1359, 372, 3127, 0, 0, 0, 590, 1112, 219, 0, 1223, 162, 0, 1501, 0, 584,
|
||||
2319, 0, 0, 1841, 411, 159, 697, 0, 1866, 1546, 0, 0, 407, 94, 2064, 0,
|
||||
969, 0, 2392, 2754, 1420, 2441, 3133, 1385, 652, 738, 2915, 3225, 1242, 0, 1777, 1899,
|
||||
0, 0, 0, 2900, 0, 0, 243, 711, 820, 0, 0, 0, 0, 1438, 1797, 692,
|
||||
1354, 0, 0, 1631, 0, 1738, 2882, 473, 0, 677, 42, 250, 0, 674, 0, 0,
|
||||
96, 0, 712, 0, 0, 399, 1814, 805, 65, 681, 0, 0, 0, 312, 2194, 223,
|
||||
0, 1318, 1458, 311, 0, 1197, 990, 1422, 802, 0, 180, 917, 0, 0, 0, 259,
|
||||
0, 1911, 0, 1118, 0, 1067, 1283, 0, 0, 0, 815, 2366, 1093, 0, 2823, 286,
|
||||
0, 0, 0, 0, 471, 0, 0, 803, 503, 66, 0, 1390, 370, 0, 1241, 19,
|
||||
0, 1186, 133, 0, 2137, 0, 0, 481, 0, 0, 662, 2804, 2502, 690, 0, 0,
|
||||
0, 0, 0, 0, 0, 1129, 1533, 0, 0, 572, 443, 843, 556, 651, 0, 0,
|
||||
240, 0, 103, 467, 1225, 780, 2047, 1245, 1096, 989, 2629, 626, 0, 0, 1897, 0,
|
||||
339, 2523, 885, 274, 0, 2042, 0, 3152, 0, 2551, 718, 1301, 1561, 3035, 0, 0,
|
||||
3023, 0, 0, 3290, 719, 0, 1142, 0, 1186, 1334, 733, 0, 0, 0, 1121, 1311,
|
||||
0, 338, 2196, 0, 2956, 1485, 1320, 2980, 594, 0, 1421, 0, 1260, 925, 278, 0,
|
||||
0, 0, 0, 0, 2729, 0, 0, 0, 332, 1473, 1925, 230, 438, 515, 2478, 0,
|
||||
0, 810, 0, 796, 2985, 393, 1135, 0, 412, 0, 575, 287, 0, 0, 0, 2694,
|
||||
0, 0, 0, 334, 466, 1405, 0, 0, 707, 0, 0, 0, 2358, 0, 3096, 0,
|
||||
877, 0, 1442, 1041, 102, 2544, 2609, 0, 696, 0, 790, 740, 0, 0, 154, 0,
|
||||
1117, 0, 0, 0, 50, 0, 2195, 97, 0, 959, 0, 0, 2126, 277, 0, 1371,
|
||||
0, 2996, 0, 1164, 1419, 404, 326, 3238, 539, 0, 0, 33, 0, 74, 708, 2305,
|
||||
0, 0, 2829, 529, 0, 1286, 103, 320, 0, 0, 1241, 0, 0, 0, 2060, 2724,
|
||||
468, 0, 19, 99, 0, 0, 679, 2560, 0, 0, 0, 1583, 1169, 775, 0, 936,
|
||||
1425, 152, 2188, 0, 1443, 949, 834, 0, 0, 810, 735, 2456, 2528, 1107, 0, 0,
|
||||
128, 0, 337, 0, 881, 0, 3297, 0, 371, 716, 594, 0, 96, 0, 1508, 0,
|
||||
0, 0, 0, 0, 2768, 0, 0, 572, 0, 1115, 0, 0, 23, 0, 0, 154,
|
||||
224, 1249, 2703, 0, 0, 3270, 0, 1399, 0, 0, 453, 0, 690, 0, 3006, 0,
|
||||
0, 1679, 0, 1070, 0, 0, 2209, 566, 0, 2841, 0, 2426, 1302, 0, 192, 1174,
|
||||
963, 2696, 1459, 1367, 1560, 1579, 53, 1705, 0, 156, 0, 1378, 2547, 769, 0, 0,
|
||||
1587, 0, 2936, 56, 605, 0, 0, 2022, 0, 351, 433, 0, 0, 0, 192, 0,
|
||||
991, 0, 642, 708, 1837, 0, 0, 0, 2729, 577, 272, 2931, 749, 2765, 0, 607,
|
||||
0, 3128, 264, 2373, 0, 0, 1536, 3275, 0, 0, 3110, 981, 0, 957, 0, 638,
|
||||
0, 0, 0, 0, 0, 2793, 1916, 0, 2381, 2733, 1002, 1126, 0, 0, 0, 56,
|
||||
2056, 165, 0, 734, 672, 0, 834, 1507, 0, 518, 2923, 0, 0, 1471, 0, 2104,
|
||||
242, 53, 1349, 0, 571, 551, 0, 2565, 557, 1109, 0, 2970, 1297, 0, 1192, 1285,
|
||||
2401, 813, 2793, 649, 0, 378, 726, 2164, 904, 2303, 0, 0, 760, 982, 1030, 0,
|
||||
0, 640, 1161, 969, 0, 2998, 0, 0, 841, 158, 1813, 645, 0, 893, 2543, 853,
|
||||
201, 0, 3063, 0, 15, 0, 702, 145, 1497, 225, 54, 287, 472, 0, 0, 0,
|
||||
0, 552, 737, 0, 1969, 0, 3262, 0, 3229, 2462, 0, 1464, 0, 95, 1526, 0,
|
||||
432, 5, 1067, 0, 302, 2892, 0, 1535, 401, 0, 1675, 0, 1213, 1250, 0, 3081,
|
||||
3006, 222, 2055, 0, 0, 796, 0, 597, 863, 966, 542, 0, 0, 899, 962, 0,
|
||||
3088, 0, 1173, 97, 415, 582, 0, 1250, 728, 0, 0, 0, 686, 299, 573, 2775,
|
||||
0, 1771, 1614, 461, 0, 855, 0, 998, 1403, 238, 155, 0, 937, 2959, 0, 1023,
|
||||
1139, 555, 0, 336, 1511, 0, 1006, 863, 3226, 655, 3006, 0, 980, 1177, 0, 2375,
|
||||
0, 1554, 74, 1484, 1681, 0, 0, 863, 2363, 0, 0, 0, 3080, 518, 806, 0,
|
||||
0, 0, 2800, 768, 355, 0, 3259, 930, 199, 2369, 1409, 0, 0, 0, 0, 1064,
|
||||
0, 0, 914, 200, 424, 3295, 0, 0, 1706, 1456, 0, 0, 1275, 2952, 3050, 0,
|
||||
0, 1147, 671, 0, 3107, 210, 519, 171, 1361, 0, 811, 0, 0, 0, 0, 882,
|
||||
1124, 764, 0, 0, 307, 603, 1906, 120, 0, 0, 570, 0, 0, 862, 0, 0,
|
||||
617, 0, 1962, 0, 1502, 0, 0, 0, 0, 0, 0, 2412, 1463, 809, 1015, 0,
|
||||
0, 1145, 247, 0, 0, 0, 385, 232, 0, 2946, 0, 32, 0, 0, 445, 329,
|
||||
866, 0, 0, 0, 3039, 0, 188, 168, 337, 695, 145, 0, 0, 0, 2319, 635,
|
||||
856, 1185, 0, 1456, 0, 0, 0, 0, 1418, 0, 209, 901, 1352, 271, 0, 1215,
|
||||
797, 763, 0, 0, 2686, 2690, 0, 0, 1575, 0, 0, 3012, 194, 2785, 1024, 73,
|
||||
781, 960, 0, 1428, 1340, 0, 486, 0, 0, 0, 715, 0, 0, 3161, 1209, 0,
|
||||
1008, 0, 1392, 1427, 0, 0, 0, 559, 2880, 0, 1100, 171, 0, 0, 379, 1327,
|
||||
0, 0, 2403, 1153, 885, 423, 0, 0, 760, 28, 0, 0, 0, 0, 2055, 0,
|
||||
282, 244, 0, 1509, 1154, 104, 0, 143, 490, 0, 0, 1021, 0, 931, 0, 153,
|
||||
0, 34, 728, 0, 130, 2970, 0, 455, 593, 266, 613, 0, 96, 0, 1006, 1319,
|
||||
1617, 359, 0, 0, 47, 226, 3079, 871, 0, 0, 0, 1144, 0, 2399, 51, 2104,
|
||||
0, 0, 253, 0, 984, 315, 0, 2771, 0, 0, 115, 730, 0, 116, 0, 3166,
|
||||
0, 0, 0, 746, 0, 784, 0, 0, 2489, 0, 1607, 0, 845, 0, 480, 789,
|
||||
992, 1550, 1047, 2728, 1191, 1844, 0, 0, 0, 114, 2398, 0, 3113, 844, 2660, 0,
|
||||
0, 3298, 0, 90, 2705, 1157, 845, 684, 1586, 0, 241, 0, 0, 3266, 0, 1557,
|
||||
3056, 908, 2595, 488, 0, 0, 3062, 0, 6, 2633, 657, 2657, 0, 0, 1472, 0,
|
||||
0, 0, 182, 0, 39, 2165, 2700, 2871, 710, 0, 3109, 183, 1341, 0, 0, 559,
|
||||
1149, 0, 0, 0, 0, 373, 478, 1047, 0, 475, 1310, 463, 0, 0, 535, 0,
|
||||
513, 2606, 288, 680, 0, 545, 0, 0, 1118, 417, 2946, 981, 305, 765, 0, 275,
|
||||
0, 3272, 394, 0, 2216, 0, 1290, 0, 25, 0, 0, 0, 1287, 548, 0, 1200,
|
||||
1119, 1572, 1638, 0, 2253, 0, 0, 2504, 608, 1342, 374, 0, 870, 0, 0, 765,
|
||||
1057, 0, 0, 0, 760, 132, 1464, 0, 0, 2342, 0, 0, 0, 0, 1985, 0,
|
||||
3125, 0, 1414, 0, 1037, 1094, 0, 1165, 97, 0, 1785, 2910, 1980, 2016, 135, 0,
|
||||
1590, 242, 0, 827, 0, 185, 1573, 0, 0, 2752, 140, 2917, 0, 330, 2137, 0,
|
||||
448, 0, 1915, 0, 0, 0, 1165, 831, 0, 1355, 0, 1579, 1108, 0, 0, 2038,
|
||||
1290, 0, 1313, 1045};
|
||||
|
||||
int MangledHashG(const char *key, const int *T)
|
||||
{
|
||||
|
@ -244,40 +250,39 @@ int MangledHashG(const char *key, const int *T)
|
|||
for (int i = 0; key[i] != '\0'; i++)
|
||||
{
|
||||
sum += T[i] * key[i];
|
||||
sum %= 3208;
|
||||
sum %= 3300;
|
||||
}
|
||||
return mangledkG[sum];
|
||||
}
|
||||
|
||||
int MangledPerfectHash(const char *key)
|
||||
{
|
||||
if (strlen(key) > 40)
|
||||
if (strlen(key) > 37)
|
||||
return 0;
|
||||
|
||||
return (MangledHashG(key, mangledkT1) + MangledHashG(key, mangledkT2)) % 3208;
|
||||
return (MangledHashG(key, mangledkT1) + MangledHashG(key, mangledkT2)) % 3300;
|
||||
}
|
||||
|
||||
constexpr int unmangledkT1[] = {246, 133, 248, 237, 59, 207, 93, 240, 98, 265, 137, 42, 147,
|
||||
269, 280, 3, 248, 202, 278, 80, 240, 202, 142, 149, 257, 17};
|
||||
constexpr int unmangledkT2[] = {166, 291, 199, 102, 183, 190, 20, 31, 50, 30, 134, 213, 202,
|
||||
55, 268, 11, 15, 108, 22, 43, 119, 187, 239, 91, 190, 47};
|
||||
constexpr int unmangledkT1[] = {154, 95, 278, 6, 35, 255, 255, 225, 266, 107, 238, 214, 59,
|
||||
198, 267, 139, 100, 265, 109, 264, 131, 194, 214, 44, 182, 215};
|
||||
constexpr int unmangledkT2[] = {5, 249, 205, 267, 173, 112, 278, 212, 74, 228, 266, 117, 51,
|
||||
32, 189, 252, 56, 269, 171, 211, 27, 253, 18, 16, 129, 107};
|
||||
constexpr int unmangledkG[] = {
|
||||
0, 42, 0, 0, 0, 127, 0, 0, 0, 291, 0, 201, 0, 0, 234, 0, 0, 0, 0,
|
||||
45, 0, 0, 0, 0, 0, 152, 156, 0, 67, 0, 230, 127, 0, 0, 161, 0, 0, 59,
|
||||
0, 265, 0, 241, 0, 160, 155, 0, 0, 46, 25, 0, 109, 0, 147, 21, 0, 32, 0,
|
||||
0, 0, 0, 84, 23, 16, 142, 177, 0, 18, 0, 27, 66, 255, 142, 135, 59, 222, 57,
|
||||
39, 0, 0, 99, 142, 122, 0, 32, 0, 0, 75, 0, 0, 136, 291, 68, 0, 0, 0,
|
||||
19, 64, 205, 0, 238, 274, 176, 120, 80, 81, 105, 0, 201, 42, 0, 0, 60, 268, 3,
|
||||
277, 0, 39, 0, 31, 14, 0, 54, 181, 93, 277, 149, 0, 146, 153, 0, 0, 0, 158,
|
||||
278, 0, 0, 65, 238, 158, 0, 73, 276, 0, 0, 185, 140, 0, 0, 0, 179, 0, 38,
|
||||
0, 39, 0, 166, 88, 54, 0, 232, 0, 0, 57, 0, 80, 0, 0, 30, 0, 91, 0,
|
||||
0, 75, 0, 108, 0, 9, 212, 0, 55, 0, 196, 21, 0, 0, 153, 76, 239, 0, 0,
|
||||
119, 86, 0, 193, 282, 0, 0, 0, 98, 2, 0, 102, 0, 13, 64, 0, 25, 58, 67,
|
||||
0, 117, 159, 0, 0, 5, 29, 0, 56, 186, 54, 0, 254, 180, 84, 290, 0, 120, 0,
|
||||
204, 39, 5, 0, 0, 44, 151, 0, 0, 254, 0, 93, 136, 194, 152, 0, 166, 115, 87,
|
||||
0, 0, 0, 0, 138, 0, 62, 15, 0, 0, 41, 274, 90, 239, 113, 0, 0, 118, 246,
|
||||
273, 226, 0, 133, 0, 269, 0, 3, 0, 0, 98, 277, 86, 151, 156, 218, 282, 0, 0,
|
||||
0, 0, 29, 51, 0, 129, 63};
|
||||
0, 0, 0, 0, 259, 157, 231, 0, 81, 131, 0, 271, 0, 0, 0, 111, 0, 0, 55,
|
||||
75, 47, 73, 70, 0, 0, 242, 83, 0, 0, 198, 127, 8, 82, 100, 23, 0, 100, 0,
|
||||
216, 123, 55, 242, 215, 0, 0, 0, 56, 0, 0, 0, 0, 34, 104, 0, 16, 149, 0,
|
||||
0, 160, 30, 0, 0, 0, 0, 0, 0, 96, 277, 76, 82, 234, 0, 0, 120, 8, 28,
|
||||
0, 173, 100, 97, 0, 0, 215, 0, 0, 78, 0, 67, 253, 0, 6, 35, 139, 241, 271,
|
||||
29, 254, 0, 9, 0, 209, 36, 219, 266, 28, 0, 27, 24, 221, 45, 109, 219, 0, 13,
|
||||
0, 90, 0, 188, 0, 0, 116, 78, 0, 75, 42, 146, 0, 0, 0, 0, 25, 0, 0,
|
||||
163, 0, 0, 0, 141, 222, 255, 0, 0, 86, 99, 0, 124, 157, 260, 259, 0, 142, 159,
|
||||
0, 23, 0, 0, 5, 67, 190, 0, 0, 202, 54, 0, 0, 34, 1, 103, 87, 51, 0,
|
||||
0, 0, 10, 0, 25, 154, 161, 143, 0, 61, 0, 255, 239, 27, 126, 7, 162, 66, 0,
|
||||
103, 144, 192, 0, 45, 83, 0, 46, 0, 0, 63, 110, 215, 130, 271, 21, 217, 0, 0,
|
||||
0, 251, 0, 18, 15, 0, 0, 0, 266, 115, 0, 55, 137, 189, 0, 89, 142, 0, 0,
|
||||
60, 96, 0, 0, 0, 137, 92, 227, 58, 70, 0, 159, 21, 38, 198, 105, 0, 72, 53,
|
||||
0, 66, 30, 100, 113, 239, 0, 0, 0, 51, 0, 0, 0, 264, 0, 0, 0, 0, 0,
|
||||
166, 25, 0, 135, 9, 167, 278, 0, 117, 0, 92, 0, 76};
|
||||
|
||||
int UnmangledHashG(const char *key, const int *T)
|
||||
{
|
||||
|
@ -286,7 +291,7 @@ int UnmangledHashG(const char *key, const int *T)
|
|||
for (int i = 0; key[i] != '\0'; i++)
|
||||
{
|
||||
sum += T[i] * key[i];
|
||||
sum %= 292;
|
||||
sum %= 279;
|
||||
}
|
||||
return unmangledkG[sum];
|
||||
}
|
||||
|
@ -296,7 +301,7 @@ int UnmangledPerfectHash(const char *key)
|
|||
if (strlen(key) > 26)
|
||||
return 0;
|
||||
|
||||
return (UnmangledHashG(key, unmangledkT1) + UnmangledHashG(key, unmangledkT2)) % 292;
|
||||
return (UnmangledHashG(key, unmangledkT1) + UnmangledHashG(key, unmangledkT2)) % 279;
|
||||
}
|
||||
|
||||
} // namespace
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
// Generated by gen_builtin_symbols.py using data from builtin_variables.json and
|
||||
// builtin_function_declarations.txt.
|
||||
//
|
||||
// Copyright 2020 The ANGLE Project Authors. All rights reserved.
|
||||
// Copyright 2021 The ANGLE Project Authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
//
|
||||
|
@ -26,260 +26,294 @@ std::ostream &operator<<(std::ostream &os, const sh::ImmutableString &str)
|
|||
namespace
|
||||
{
|
||||
|
||||
constexpr int mangledkT1[] = {3102, 1325, 1351, 3001, 1248, 3253, 589, 739, 2360, 2951,
|
||||
1700, 3759, 2038, 664, 3245, 3120, 1585, 527, 2294, 2587,
|
||||
1485, 188, 2635, 932, 884, 1991, 918, 320, 2213, 3603,
|
||||
676, 1242, 115, 2611, 2163, 2535, 3233, 54, 3230, 1500};
|
||||
constexpr int mangledkT2[] = {1129, 226, 3871, 1567, 3267, 3307, 452, 3099, 2330, 3246,
|
||||
3512, 1556, 3216, 909, 1679, 1812, 3619, 2551, 2821, 3333,
|
||||
3764, 2526, 2149, 2101, 1636, 2341, 2985, 454, 627, 1307,
|
||||
466, 537, 2536, 736, 2238, 1704, 1050, 3135, 564, 182};
|
||||
constexpr int mangledkT1[] = {3064, 1851, 1414, 3139, 4344, 3861, 2198, 569, 2942, 936,
|
||||
1011, 2797, 994, 3172, 2246, 1929, 3580, 2059, 3211, 2760,
|
||||
3315, 3834, 4289, 1359, 1965, 849, 1949, 3923, 2685, 4274,
|
||||
4060, 2274, 1752, 1405, 743, 2453, 2110};
|
||||
constexpr int mangledkT2[] = {3974, 952, 3020, 19, 962, 3302, 1369, 968, 2483, 3954,
|
||||
2409, 949, 1306, 577, 1474, 224, 2913, 2365, 494, 208,
|
||||
654, 3238, 2268, 54, 1039, 35, 3881, 44, 150, 967,
|
||||
1157, 2004, 4019, 4114, 1201, 3022, 2477};
|
||||
constexpr int mangledkG[] = {
|
||||
0, 0, 0, 0, 0, 0, 0, 0, 0, 973, 0, 0, 2762, 0, 0, 3695,
|
||||
2780, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2474,
|
||||
0, 616, 0, 0, 0, 0, 0, 626, 0, 0, 0, 0, 0, 242, 0, 0,
|
||||
0, 2505, 1729, 3344, 0, 0, 362, 0, 139, 0, 0, 0, 0, 3022, 2925, 0,
|
||||
0, 0, 0, 0, 0, 961, 0, 2450, 0, 0, 0, 0, 0, 0, 0, 0,
|
||||
0, 1206, 0, 0, 0, 0, 0, 2292, 0, 0, 0, 0, 0, 0, 0, 0,
|
||||
0, 0, 0, 0, 2294, 0, 0, 0, 0, 0, 0, 3243, 0, 0, 1832, 1889,
|
||||
3015, 2347, 397, 0, 0, 0, 0, 0, 2268, 487, 1220, 0, 0, 2970, 0, 0,
|
||||
0, 0, 0, 0, 0, 192, 1062, 0, 0, 0, 0, 0, 0, 0, 0, 1118,
|
||||
0, 0, 1389, 0, 0, 0, 0, 3334, 0, 0, 1866, 0, 0, 0, 3268, 0,
|
||||
0, 1397, 0, 0, 0, 0, 0, 735, 0, 0, 0, 193, 15, 0, 3158, 0,
|
||||
0, 0, 3298, 2376, 0, 1462, 2924, 183, 0, 2649, 0, 0, 3226, 3552, 3343, 0,
|
||||
2502, 3258, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1942, 0, 0, 397,
|
||||
1413, 2818, 0, 0, 0, 0, 2738, 2414, 3786, 0, 0, 0, 67, 0, 0, 236,
|
||||
0, 0, 0, 0, 2668, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1223, 0,
|
||||
0, 0, 0, 0, 264, 1411, 0, 0, 820, 0, 1770, 0, 806, 833, 0, 0,
|
||||
1814, 3051, 0, 3651, 2100, 0, 66, 0, 878, 0, 0, 0, 1974, 854, 0, 2011,
|
||||
0, 0, 0, 0, 3393, 1300, 0, 0, 0, 109, 0, 0, 0, 0, 3313, 0,
|
||||
3075, 0, 0, 0, 617, 0, 0, 2650, 0, 0, 465, 3456, 152, 84, 3232, 752,
|
||||
1075, 0, 0, 1699, 0, 224, 863, 0, 0, 0, 0, 0, 0, 2953, 0, 0,
|
||||
0, 3203, 0, 121, 0, 2641, 0, 0, 0, 204, 0, 0, 1953, 0, 0, 0,
|
||||
0, 3898, 3511, 0, 1586, 696, 0, 0, 2698, 0, 2432, 3277, 0, 0, 1511, 663,
|
||||
0, 0, 1570, 0, 604, 3199, 0, 0, 1463, 393, 0, 0, 0, 0, 2089, 1937,
|
||||
752, 0, 532, 0, 1645, 0, 939, 3461, 2351, 1982, 0, 3505, 0, 661, 0, 0,
|
||||
0, 0, 0, 1720, 753, 3334, 0, 2086, 164, 0, 2217, 1863, 0, 0, 0, 0,
|
||||
0, 3788, 1074, 0, 1229, 0, 403, 0, 910, 345, 0, 1835, 129, 2886, 0, 0,
|
||||
0, 0, 2440, 2572, 0, 0, 0, 0, 0, 3718, 0, 3856, 13, 0, 2909, 449,
|
||||
0, 0, 0, 0, 0, 3898, 0, 0, 0, 0, 0, 0, 0, 1796, 0, 3301,
|
||||
0, 3374, 0, 0, 0, 2637, 0, 0, 0, 0, 0, 2487, 24, 1432, 0, 1127,
|
||||
99, 0, 0, 0, 0, 3601, 3638, 2083, 0, 3667, 676, 1955, 0, 0, 0, 0,
|
||||
0, 0, 0, 0, 0, 0, 2263, 2650, 0, 0, 813, 2872, 0, 0, 1530, 1263,
|
||||
0, 0, 0, 0, 27, 0, 0, 0, 0, 0, 0, 0, 0, 0, 509, 2814,
|
||||
1472, 1384, 0, 0, 0, 0, 0, 3528, 0, 0, 0, 0, 923, 649, 0, 0,
|
||||
0, 0, 0, 0, 0, 0, 0, 0, 34, 0, 0, 0, 0, 183, 0, 439,
|
||||
1359, 0, 0, 0, 0, 1291, 167, 0, 0, 591, 0, 1224, 0, 1753, 0, 0,
|
||||
0, 0, 418, 3560, 0, 1326, 2703, 0, 0, 2694, 0, 104, 440, 0, 0, 0,
|
||||
0, 0, 0, 0, 0, 2005, 0, 2661, 0, 0, 2969, 1668, 3653, 0, 0, 0,
|
||||
0, 0, 0, 3832, 0, 2835, 380, 0, 3081, 0, 0, 0, 199, 0, 653, 3303,
|
||||
0, 3432, 0, 1524, 1795, 2718, 0, 2461, 0, 0, 1838, 0, 0, 724, 1453, 0,
|
||||
0, 578, 2660, 2676, 1297, 0, 0, 0, 0, 3364, 0, 0, 0, 0, 0, 1997,
|
||||
0, 0, 0, 79, 0, 319, 1270, 1804, 515, 254, 0, 0, 0, 0, 0, 0,
|
||||
0, 0, 0, 0, 0, 0, 0, 1728, 0, 938, 2011, 1135, 419, 3847, 0, 0,
|
||||
992, 0, 1601, 0, 0, 0, 0, 0, 3562, 867, 0, 0, 0, 27, 0, 0,
|
||||
1426, 0, 0, 2559, 686, 0, 0, 0, 0, 608, 1880, 3358, 0, 0, 76, 0,
|
||||
0, 0, 0, 1686, 1122, 780, 0, 0, 2811, 0, 805, 0, 3568, 3098, 0, 0,
|
||||
0, 0, 0, 0, 0, 0, 2172, 429, 3755, 0, 819, 0, 0, 0, 538, 3871,
|
||||
3617, 2269, 0, 147, 0, 3475, 2291, 0, 0, 868, 2865, 2720, 738, 0, 9, 766,
|
||||
353, 2940, 521, 0, 0, 0, 0, 0, 3649, 1789, 121, 0, 0, 438, 2023, 0,
|
||||
0, 1124, 0, 0, 0, 0, 0, 469, 3089, 0, 3837, 2214, 273, 1776, 722, 0,
|
||||
0, 0, 0, 0, 0, 3583, 3394, 0, 0, 1302, 3405, 0, 1191, 1277, 0, 3244,
|
||||
0, 1010, 0, 771, 775, 0, 1234, 340, 0, 0, 0, 1029, 0, 0, 1037, 306,
|
||||
2918, 0, 0, 1276, 2437, 948, 3700, 2008, 0, 0, 0, 486, 0, 3645, 510, 287,
|
||||
1555, 1946, 483, 0, 3344, 0, 3126, 0, 0, 0, 0, 0, 0, 0, 0, 0,
|
||||
0, 3249, 0, 0, 0, 2124, 1044, 0, 2645, 0, 0, 0, 0, 3079, 0, 0,
|
||||
0, 0, 0, 0, 0, 581, 3109, 0, 934, 0, 0, 0, 0, 0, 3881, 1317,
|
||||
0, 1109, 781, 1122, 0, 1191, 1355, 3154, 0, 817, 3560, 765, 2974, 0, 0, 461,
|
||||
2776, 1285, 154, 0, 0, 1414, 0, 0, 0, 0, 525, 0, 0, 0, 0, 0,
|
||||
2040, 0, 1688, 1493, 342, 0, 1988, 2055, 3664, 0, 0, 0, 0, 3009, 1412, 1879,
|
||||
0, 3385, 0, 0, 0, 2079, 0, 0, 1781, 1010, 108, 723, 0, 1690, 2810, 3783,
|
||||
0, 3575, 0, 3907, 0, 0, 0, 0, 0, 270, 0, 0, 0, 2331, 0, 2006,
|
||||
3770, 0, 0, 1036, 632, 0, 0, 0, 0, 2318, 0, 0, 0, 0, 3878, 1634,
|
||||
0, 0, 1529, 0, 0, 2716, 0, 0, 0, 0, 1054, 0, 896, 0, 0, 0,
|
||||
0, 2124, 481, 0, 2613, 0, 912, 0, 0, 3746, 305, 2703, 0, 0, 1175, 1283,
|
||||
3886, 2628, 0, 92, 0, 0, 0, 0, 1490, 178, 0, 503, 702, 158, 0, 2096,
|
||||
0, 0, 0, 0, 1670, 1409, 0, 0, 0, 0, 2260, 0, 0, 1825, 0, 1631,
|
||||
635, 330, 0, 0, 1900, 2157, 3669, 3727, 1122, 2498, 0, 0, 1377, 2971, 321, 1839,
|
||||
0, 0, 3277, 141, 2528, 0, 0, 227, 1866, 0, 0, 339, 0, 0, 404, 0,
|
||||
2374, 1075, 2268, 1018, 2103, 0, 0, 0, 0, 0, 922, 0, 0, 2266, 0, 2027,
|
||||
0, 3904, 0, 654, 0, 484, 2286, 0, 0, 1868, 161, 0, 3515, 255, 1416, 3170,
|
||||
0, 0, 0, 528, 711, 1932, 0, 0, 0, 0, 288, 0, 3459, 0, 0, 0,
|
||||
655, 0, 2951, 571, 2357, 0, 0, 0, 0, 0, 0, 0, 2590, 1535, 0, 0,
|
||||
912, 0, 0, 0, 1011, 821, 0, 0, 1799, 0, 0, 0, 0, 0, 0, 0,
|
||||
0, 2238, 0, 1591, 0, 3622, 2020, 2798, 0, 0, 0, 3522, 0, 87, 2687, 3437,
|
||||
0, 0, 0, 0, 3307, 386, 2148, 0, 1410, 0, 0, 3563, 3214, 0, 0, 2854,
|
||||
3813, 0, 480, 1560, 1760, 0, 0, 871, 0, 0, 0, 2318, 1249, 1689, 1358, 2132,
|
||||
2163, 2945, 0, 991, 332, 2860, 139, 63, 0, 2621, 2871, 1084, 0, 0, 470, 729,
|
||||
0, 0, 0, 0, 1442, 485, 3878, 740, 267, 0, 3366, 1, 2026, 0, 0, 214,
|
||||
914, 2285, 0, 0, 1395, 0, 0, 0, 848, 1362, 0, 1670, 0, 0, 0, 1754,
|
||||
0, 240, 0, 2923, 803, 0, 3737, 0, 932, 0, 2561, 0, 0, 2481, 0, 1902,
|
||||
2426, 1238, 2118, 1248, 0, 3123, 0, 3614, 0, 0, 1562, 0, 0, 1264, 0, 0,
|
||||
2517, 1042, 0, 1322, 1074, 397, 0, 0, 3245, 0, 307, 0, 0, 2735, 0, 0,
|
||||
0, 2187, 3421, 0, 78, 1464, 0, 2229, 1124, 1620, 0, 1851, 1266, 3861, 3570, 2512,
|
||||
3721, 0, 2434, 0, 898, 595, 1028, 0, 0, 674, 552, 1303, 107, 0, 2828, 1223,
|
||||
2115, 488, 1162, 1495, 297, 1451, 0, 1263, 2406, 2547, 3691, 58, 0, 0, 901, 0,
|
||||
188, 3764, 552, 1100, 2652, 1908, 0, 0, 3509, 2174, 0, 2721, 1608, 3120, 0, 0,
|
||||
2208, 2502, 0, 0, 0, 141, 0, 0, 3513, 1495, 1346, 0, 0, 0, 3470, 212,
|
||||
1489, 558, 414, 0, 286, 1218, 0, 0, 1959, 397, 0, 687, 0, 3477, 0, 1961,
|
||||
0, 1080, 0, 3273, 3838, 2167, 0, 539, 259, 2751, 2004, 591, 1961, 0, 0, 3217,
|
||||
2929, 0, 55, 1744, 0, 1974, 1200, 3712, 0, 1782, 437, 0, 0, 0, 0, 0,
|
||||
2641, 1928, 0, 3837, 0, 0, 3330, 2153, 1863, 170, 55, 0, 607, 0, 157, 0,
|
||||
1080, 622, 0, 0, 2132, 3659, 0, 0, 1926, 327, 1581, 580, 0, 1385, 0, 279,
|
||||
0, 590, 2185, 0, 0, 3600, 655, 1765, 0, 0, 0, 2349, 0, 1604, 0, 0,
|
||||
0, 378, 821, 0, 9, 1375, 1667, 787, 0, 0, 1331, 0, 0, 30, 1701, 3175,
|
||||
0, 0, 520, 3496, 1961, 0, 0, 0, 2421, 328, 0, 0, 0, 705, 0, 196,
|
||||
649, 0, 2141, 0, 0, 0, 3375, 142, 0, 1235, 467, 1317, 0, 0, 0, 2020,
|
||||
1310, 1774, 0, 1984, 1970, 1576, 1253, 1666, 5, 0, 0, 0, 0, 3866, 1608, 1022,
|
||||
2036, 1541, 0, 0, 3463, 2681, 0, 151, 0, 1514, 1431, 0, 0, 657, 2420, 1138,
|
||||
0, 511, 0, 2862, 0, 0, 2112, 335, 374, 0, 1633, 3431, 2234, 0, 1917, 0,
|
||||
0, 0, 1463, 0, 1479, 2534, 0, 0, 3101, 3053, 2960, 426, 3640, 2198, 2870, 1132,
|
||||
3408, 0, 2876, 1012, 0, 0, 0, 0, 3071, 0, 0, 1005, 315, 44, 0, 0,
|
||||
1002, 1920, 1183, 0, 0, 2613, 2154, 1517, 0, 3444, 0, 3593, 0, 2733, 1891, 3882,
|
||||
40, 918, 242, 0, 3341, 1565, 2210, 1290, 1846, 3872, 2684, 1526, 58, 815, 1012, 2657,
|
||||
1402, 0, 0, 0, 84, 2751, 0, 0, 0, 3074, 0, 3785, 1199, 0, 924, 3605,
|
||||
0, 0, 1074, 0, 3857, 167, 2251, 0, 0, 0, 0, 0, 1650, 1696, 0, 0,
|
||||
0, 0, 910, 2774, 1579, 643, 0, 1834, 0, 3599, 0, 0, 0, 116, 2817, 754,
|
||||
0, 0, 0, 3835, 662, 826, 638, 0, 818, 0, 2527, 0, 0, 0, 376, 0,
|
||||
2114, 0, 523, 2881, 1323, 3508, 293, 830, 2124, 490, 1006, 3688, 0, 3863, 2800, 0,
|
||||
0, 878, 0, 2214, 0, 0, 210, 1404, 0, 0, 0, 0, 3177, 255, 0, 0,
|
||||
3673, 540, 1528, 2066, 452, 1568, 1052, 2062, 0, 2630, 2504, 0, 448, 408, 0, 672,
|
||||
1255, 720, 0, 1607, 1228, 0, 1921, 0, 0, 2585, 0, 34, 0, 0, 1571, 3473,
|
||||
0, 315, 409, 628, 0, 0, 0, 3006, 1559, 2084, 1538, 1570, 2157, 0, 582, 0,
|
||||
0, 1519, 0, 1262, 0, 3257, 2850, 0, 0, 1074, 0, 0, 0, 748, 1477, 1600,
|
||||
0, 0, 0, 2851, 3302, 0, 0, 0, 0, 219, 1185, 2753, 1834, 0, 3303, 0,
|
||||
2714, 0, 908, 0, 3167, 1033, 1614, 0, 2484, 0, 0, 138, 285, 0, 0, 83,
|
||||
0, 1725, 1523, 0, 782, 0, 1889, 1651, 2226, 0, 2741, 1363, 1560, 0, 0, 2891,
|
||||
0, 1451, 0, 493, 0, 2128, 403, 1797, 3240, 1981, 1644, 3337, 260, 39, 614, 1547,
|
||||
1877, 1072, 1355, 0, 0, 0, 2458, 645, 2145, 181, 1081, 0, 0, 0, 0, 0,
|
||||
0, 1268, 0, 0, 0, 0, 0, 693, 2656, 326, 0, 689, 582, 2199, 3405, 1820,
|
||||
1081, 1843, 634, 0, 0, 0, 0, 3336, 0, 3418, 0, 1685, 0, 0, 0, 0,
|
||||
1697, 2997, 2608, 409, 921, 0, 0, 624, 3482, 0, 0, 1992, 1272, 2445, 0, 0,
|
||||
1328, 0, 989, 3597, 0, 3585, 3883, 3195, 1598, 0, 0, 1417, 0, 2660, 2003, 0,
|
||||
0, 0, 0, 1971, 0, 431, 160, 512, 1344, 863, 0, 1273, 1499, 3397, 1480, 0,
|
||||
0, 0, 3238, 0, 0, 1553, 0, 0, 0, 2065, 0, 143, 733, 910, 1186, 1340,
|
||||
0, 0, 0, 1678, 0, 0, 736, 0, 2918, 699, 0, 0, 33, 478, 3397, 0,
|
||||
2897, 2569, 2150, 701, 2982, 3486, 0, 2549, 998, 0, 2305, 412, 149, 1843, 498, 3831,
|
||||
245, 0, 2317, 1282, 0, 0, 3008, 0, 0, 0, 771, 5, 0, 2406, 481, 333,
|
||||
0, 3753, 0, 0, 0, 1925, 0, 1245, 2106, 133, 0, 942, 563, 1043, 0, 54,
|
||||
0, 0, 2897, 3358, 0, 213, 1382, 0, 0, 1246, 0, 0, 3242, 0, 2560, 1193,
|
||||
1880, 3657, 0, 0, 0, 0, 3103, 1572, 3218, 976, 1336, 1869, 0, 3441, 0, 0,
|
||||
0, 1761, 0, 475, 3499, 2223, 1580, 3241, 1448, 1505, 340, 2161, 971, 2778, 0, 0,
|
||||
0, 0, 2277, 1238, 0, 0, 0, 0, 1550, 2419, 3198, 269, 0, 215, 1443, 1331,
|
||||
0, 0, 0, 0, 312, 1759, 644, 0, 2454, 2484, 0, 1085, 2497, 1881, 0, 733,
|
||||
2926, 2823, 2087, 0, 3876, 2674, 1042, 1476, 0, 825, 0, 0, 2309, 0, 3179, 1074,
|
||||
0, 2737, 0, 2037, 164, 1974, 0, 0, 3615, 0, 557, 2285, 543, 0, 3274, 0,
|
||||
0, 0, 1549, 3418, 3545, 1415, 0, 3788, 927, 3182, 0, 0, 0, 147, 0, 2151,
|
||||
929, 0, 575, 0, 2082, 0, 0, 0, 2292, 2688, 0, 1215, 2858, 3040, 0, 0,
|
||||
0, 727, 0, 486, 0, 0, 0, 2010, 0, 3631, 791, 3414, 2056, 0, 0, 0,
|
||||
0, 0, 320, 0, 1929, 1448, 2701, 867, 44, 0, 827, 8, 0, 2172, 0, 3685,
|
||||
1006, 1809, 421, 1808, 1618, 2961, 1651, 0, 2796, 0, 0, 276, 0, 141, 0, 0,
|
||||
0, 1427, 0, 0, 3638, 0, 0, 0, 2652, 1428, 2064, 558, 3346, 0, 0, 0,
|
||||
1444, 2779, 0, 1502, 0, 0, 7, 523, 3403, 3075, 454, 0, 0, 0, 963, 1610,
|
||||
1687, 753, 0, 0, 0, 2369, 348, 0, 0, 0, 1220, 3088, 1970, 1862, 0, 2015,
|
||||
0, 0, 861, 69, 947, 1072, 0, 0, 0, 2095, 1403, 0, 0, 0, 668, 3574,
|
||||
0, 0, 1587, 0, 2643, 766, 3064, 839, 1646, 1932, 967, 0, 1379, 159, 747, 0,
|
||||
2986, 0, 1369, 0, 0, 2173, 0, 0, 0, 2164, 2861, 0, 1971, 0, 924, 2951,
|
||||
1118, 0, 3774, 54, 1008, 0, 3208, 0, 1540, 1133, 0, 1514, 0, 3621, 737, 3311,
|
||||
0, 0, 0, 0, 0, 235, 1998, 776, 0, 1671, 214, 2035, 0, 0, 0, 0,
|
||||
500, 0, 191, 0, 0, 3520, 0, 2050, 1952, 3160, 0, 2269, 222, 1112, 229, 716,
|
||||
140, 0, 1725, 2620, 1604, 3612, 2868, 670, 1860, 1275, 1799, 123, 0, 1244, 2992, 0,
|
||||
0, 3772, 0, 1911, 0, 2896, 1208, 52, 594, 20, 0, 0, 0, 0, 3813, 673,
|
||||
543, 521, 2132, 0, 2137, 2681, 0, 496, 2754, 369, 0, 3887, 0, 1005, 1821, 0,
|
||||
3674, 996, 0, 1672, 1164, 0, 1661, 3564, 564, 0, 151, 2700, 0, 0, 0, 1941,
|
||||
683, 0, 0, 0, 2105, 0, 1640, 1792, 1356, 2551, 1462, 2050, 0, 823, 646, 0,
|
||||
91, 0, 0, 2709, 798, 0, 1885, 3777, 0, 1968, 2045, 3416, 3606, 1968, 3614, 2815,
|
||||
54, 2233, 0, 0, 0, 2119, 1871, 0, 1299, 217, 0, 0, 0, 753, 0, 0,
|
||||
1621, 2166, 2026, 778, 1997, 732, 2396, 0, 0, 310, 882, 1292, 0, 886, 3716, 3263,
|
||||
338, 0, 0, 0, 0, 3015, 3108, 2660, 1977, 0, 776, 1231, 0, 550, 432, 1992,
|
||||
276, 0, 0, 0, 0, 0, 2115, 2554, 2917, 915, 1098, 0, 439, 0, 630, 2970,
|
||||
0, 626, 2180, 1762, 0, 966, 66, 760, 1864, 1993, 951, 357, 0, 0, 1268, 0,
|
||||
0, 259, 0, 0, 3066, 2879, 0, 0, 1747, 3380, 0, 1650, 352, 2055, 626, 1650,
|
||||
0, 2663, 0, 0, 102, 0, 2088, 0, 1340, 3313, 1109, 650, 0, 0, 0, 2916,
|
||||
3143, 972, 1052, 2786, 0, 0, 1334, 1546, 672, 381, 3707, 2004, 0, 3114, 1348, 0,
|
||||
55, 0, 2183, 0, 2973, 1513, 1206, 0, 742, 2276, 0, 2719, 0, 0, 315, 0,
|
||||
0, 1075, 684, 3143, 3873, 3825, 1541, 1932, 0, 1638, 0, 0, 0, 3215, 3824, 2212,
|
||||
2929, 560, 748, 0, 1287, 3340, 410, 2005, 1419, 3408, 2366, 0, 0, 0, 2126, 3536,
|
||||
1576, 1016, 0, 3899, 0, 593, 2370, 0, 0, 2878, 0, 40, 1304, 1411, 0, 816,
|
||||
3294, 0, 2800, 0, 3428, 578, 3641, 3056, 129, 3496, 709, 2110, 0, 0, 1387, 69,
|
||||
873, 3302, 3226, 0, 1736, 3183, 566, 531, 0, 3203, 687, 3338, 0, 202, 2062, 0,
|
||||
0, 895, 0, 0, 1546, 0, 1288, 2919, 1815, 0, 0, 1287, 0, 3736, 1315, 266,
|
||||
821, 2741, 33, 0, 3497, 0, 1059, 3896, 0, 0, 0, 1379, 1597, 118, 1255, 3567,
|
||||
3067, 0, 3673, 1079, 0, 275, 1694, 51, 3858, 0, 353, 2263, 0, 3597, 1664, 381,
|
||||
1902, 0, 2133, 1741, 898, 0, 1995, 0, 0, 0, 0, 843, 1864, 3428, 2262, 3349,
|
||||
0, 2645, 1507, 725, 210, 258, 2887, 0, 681, 2731, 17, 948, 0, 2977, 0, 2370,
|
||||
3597, 349, 2424, 2150, 3421, 2596, 1164, 210, 2153, 53, 1962, 471, 99, 2018, 1728, 0,
|
||||
0, 2155, 2013, 595, 3828, 2895, 2329, 984, 0, 204, 453, 1341, 1667, 3773, 0, 1817,
|
||||
0, 3108, 3707, 1093, 508, 349, 578, 0, 2159, 0, 0, 974, 2466, 3540, 0, 856,
|
||||
3793, 1704, 1090, 0, 1657, 470, 0, 0, 1637, 2749, 0, 2442, 3890, 1344, 356, 0,
|
||||
63, 2310, 1212, 0, 0, 1520, 2167, 1233, 0, 0, 2035, 2484, 3569, 2255, 0, 0,
|
||||
2198, 3562, 0, 927, 1927, 1159, 0, 3827, 1770, 973, 2030, 0, 3891, 0, 0, 2649,
|
||||
354, 0, 0, 2788, 0, 2069, 0, 52, 0, 508, 0, 418, 1919, 2246, 884, 1128,
|
||||
571, 1174, 1465, 1946, 1264, 3418, 527, 0, 0, 0, 1243, 481, 0, 836, 2770, 1577,
|
||||
2660, 3473, 0, 0, 71, 3828, 1713, 0, 1228, 2355, 1192, 0, 1790, 738, 0, 3738,
|
||||
3650, 0, 73, 0, 1702, 1863, 0, 617, 0, 0, 1530, 0, 2405, 1775, 929, 0,
|
||||
0, 0, 2080, 2768, 0, 3012, 0, 935, 0, 0, 0, 1003, 0, 3536, 0, 1845,
|
||||
3873, 3629, 967, 0, 1653, 1452, 2371, 0, 0, 116, 1012, 2871, 0, 0, 855, 3097,
|
||||
0, 208, 2550, 0, 2060, 0, 0, 861, 3686, 1367, 3365, 0, 0, 0, 84, 0,
|
||||
1296, 1430, 1322, 0, 0, 0, 1698, 2567, 1659, 533, 3172, 3401, 23, 3182, 0, 1090,
|
||||
1740, 1020, 0, 0, 0, 0, 0, 1681, 427, 2766, 2834, 2909, 1449, 197, 0, 877,
|
||||
285, 3718, 162, 567, 1071, 75, 3783, 0, 635, 0, 2080, 1818, 0, 0, 2750, 0,
|
||||
255, 351, 0, 0, 1196, 0, 1084, 0, 810, 2790, 0, 2276, 0, 3083, 2887, 0,
|
||||
1301, 617, 3341, 1907, 2568, 2996, 946, 3338, 0, 1090, 898, 521, 0, 1203, 1921, 0,
|
||||
2995, 0, 2073, 0, 3755, 0, 2973, 0, 742, 3720, 1032, 493, 42, 2256, 0, 0,
|
||||
1189, 2243, 904, 0, 0, 0, 0, 532, 310, 2242, 0, 2165, 0, 3791, 0, 2406,
|
||||
0, 0, 1277, 774, 1326, 662, 0, 505, 1959, 3652, 594, 999, 1303, 0, 1756, 0,
|
||||
1077, 1337, 2229, 2158, 0, 0, 1816, 0, 348, 1764, 1873, 3387, 3181, 49, 1999, 0,
|
||||
929, 82, 0, 0, 0, 1000, 1311, 3475, 507, 1749, 798, 1128, 0, 2962, 1515, 422,
|
||||
1931, 256, 0, 0, 1089, 0, 392, 0, 190, 0, 0, 2007, 0, 2846, 2930, 1950,
|
||||
0, 940, 0, 3178, 3521, 1228, 1240, 0, 515, 746, 0, 1097, 404, 1554, 3192, 388,
|
||||
3497, 715, 1118, 3907, 2484, 1613, 786, 852, 24, 0, 1019, 0, 3664, 0, 81, 0,
|
||||
1065, 1587, 1434, 0, 1032, 3497, 1920, 2071, 251, 1394, 0, 3717, 235, 0, 0, 3880,
|
||||
323, 0, 0, 182, 0, 2350, 210, 56, 1538, 1135, 819, 2434, 423, 2662, 1661, 0,
|
||||
0, 190, 0, 2191, 0, 1829, 3781, 703, 14, 0, 0, 3759, 2941, 0, 968, 0,
|
||||
1718, 0, 2519, 3033, 1851, 797, 2103, 2602, 2372, 0, 0, 0, 0, 3672, 0, 3417,
|
||||
0, 1068, 758, 3885, 0, 3359, 157, 0, 1456, 1946, 2636, 0, 984, 3785, 3502, 2470,
|
||||
2911, 273, 361, 187, 559, 1561, 754, 1164, 0, 1829, 131, 0, 2173, 0, 0, 429,
|
||||
1648, 3554, 0, 0, 0, 0, 0, 2723, 1456, 2893, 0, 3325, 920, 0, 1278, 1415,
|
||||
870, 0, 1202, 301, 0, 0, 2119, 0, 2843, 0, 865, 1455, 3408, 1013, 0, 3761,
|
||||
2880, 1846, 0, 1986, 1336, 0, 0, 0, 3325, 679, 2137, 0, 747, 61, 0, 3632,
|
||||
724, 1253, 1210, 0, 1026, 543, 1075, 2140, 1769, 1444, 898, 728, 3618, 3121, 1167, 0,
|
||||
0, 1207, 0, 832, 3100, 2689, 0, 0, 0, 0, 0, 1148, 1496, 0, 1068, 379,
|
||||
2170, 1804, 3492, 462, 3818, 0, 1488, 1143, 1894, 1053, 0, 2106, 2699, 986, 0, 1591,
|
||||
3767, 1635, 420, 2928, 0, 0, 0, 0, 0, 194, 0, 553, 0, 1270, 0, 1388,
|
||||
1274, 2357, 159, 1175, 0, 2959, 2994, 0, 1557, 0, 398, 3809, 946, 1030, 0, 1274,
|
||||
0, 870, 0, 2234, 3167, 0, 2329, 0, 1596, 0, 0, 57, 1748, 1362, 3827, 1303,
|
||||
0, 0, 0, 3452, 0, 1579, 2160, 1638, 3335, 451, 1783, 1139, 2761, 463, 602, 0,
|
||||
1461, 0, 1261, 146, 0, 612, 0, 0, 1987, 846, 3795, 211, 598, 0, 0, 979,
|
||||
0, 0, 2009, 2219, 53, 2346, 3000, 658, 624, 698, 0, 3845, 2293, 0, 0, 0,
|
||||
1642, 0, 0, 711, 2977, 2381, 470, 2439, 14, 1300, 0, 3020, 654, 0, 1307, 541,
|
||||
467, 322, 966, 0, 3758, 3079, 0, 0, 646, 594, 2445, 0, 0, 282, 0, 1600,
|
||||
0, 660, 430, 1050, 2570, 2336, 1306, 0, 0, 2560, 227, 0, 3467, 1714, 1026, 3810,
|
||||
0, 2372, 0, 0, 1855, 0, 0, 1725, 3572, 3321, 0, 0, 0, 72, 448, 0,
|
||||
1816, 0, 1048, 3814, 2844, 0, 0, 1786, 2735, 1808, 2014, 703, 0, 0, 0, 0,
|
||||
499, 687, 3740, 0, 803, 3524, 447, 747, 456, 3216, 1880, 2958, 0, 103, 341, 812,
|
||||
3732, 0, 216, 441, 1629, 1804, 1117, 0, 2048, 0, 0, 253, 1574, 177, 1932, 648,
|
||||
1705, 0, 0, 1780, 3640, 236, 0, 3881, 2044, 1761, 552, 983, 465, 3346, 1482, 1918,
|
||||
633, 1984, 2185, 2179, 996, 580, 1853, 387, 2568, 0, 1221, 0, 1881, 3433, 962, 3650,
|
||||
1942, 0, 351, 0, 0, 0, 0, 2090, 0, 1138, 0, 1539, 1706, 127, 0, 958,
|
||||
1263, 3282, 1796, 280, 0, 692, 0, 1164, 463, 2582, 0, 722, 0, 0, 0, 3517,
|
||||
0, 0, 311, 1146, 2765, 0, 353, 252, 0, 0, 0, 0, 580, 0, 0, 3907,
|
||||
420, 2946, 0, 2534, 1985, 596, 74, 10, 0, 0, 0, 0, 0, 1914, 0, 3602,
|
||||
2121, 0, 0, 3874, 0, 1719, 507, 1037, 0, 0, 532, 0, 1720, 958, 700, 2964,
|
||||
405, 0, 0, 0, 1373, 576, 204, 1618, 0, 0, 0, 0, 478, 2877, 104, 966,
|
||||
0, 3745, 839, 526, 0, 66, 1675, 0, 1136, 3165, 1399, 2593, 0, 41, 783, 0,
|
||||
0, 1271, 636, 0, 1738, 1800, 0, 2813, 530, 1144, 692, 1594, 797, 1260, 2077, 0,
|
||||
0, 0, 0, 0, 2201, 2617, 1101, 29, 0, 3363, 474, 0, 0, 833, 980, 0,
|
||||
623, 1926, 2010, 602, 0, 373, 1501, 784, 1252, 601, 1760, 0, 1921, 0, 0, 1690,
|
||||
0, 549, 321, 0, 0, 1382, 1924, 869, 1, 717, 1573, 1272, 840, 67, 1776, 827,
|
||||
246, 397, 1012, 206, 3230, 0, 557, 0, 1454, 0, 2327, 3180, 3134, 2236, 3342, 1649,
|
||||
1942, 3752, 0, 0, 238, 510, 1887, 2231, 3144, 309, 1591, 0, 3625, 0, 1143, 0,
|
||||
794, 0, 0, 0, 0, 0, 514, 0, 0, 0, 1699, 1158, 1604, 226, 0, 3901,
|
||||
0, 1753, 3618, 1600, 2160, 719, 658, 0, 0, 2870, 1425, 555, 0, 321, 0, 0,
|
||||
1282, 1168, 0, 0, 0, 0, 3295, 1959, 0, 3542, 825, 3888, 0, 2118, 0, 0,
|
||||
513, 3796, 944, 1189, 2590, 0, 0, 3440, 0, 99, 0, 1078, 2205, 0, 0, 560,
|
||||
3491, 562, 864, 0, 851, 3573, 1087, 0, 1405, 0, 1024, 1590, 0, 75, 3130, 0,
|
||||
1195, 0, 784, 0, 0, 0};
|
||||
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
|
||||
0, 0, 0, 0, 0, 236, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
|
||||
0, 0, 0, 0, 4415, 0, 0, 1691, 0, 0, 0, 0, 0, 0, 4425, 0,
|
||||
0, 0, 0, 0, 0, 0, 4035, 1669, 0, 0, 0, 0, 2801, 0, 0, 0,
|
||||
0, 2968, 0, 294, 0, 3469, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
|
||||
0, 909, 0, 0, 0, 0, 0, 0, 2401, 0, 2142, 0, 0, 0, 0, 0,
|
||||
0, 0, 0, 0, 294, 0, 0, 0, 0, 0, 858, 0, 0, 0, 0, 0,
|
||||
0, 1663, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
|
||||
1876, 0, 0, 0, 0, 224, 0, 0, 0, 0, 0, 640, 811, 0, 3417, 0,
|
||||
0, 3687, 0, 0, 3802, 4331, 0, 0, 2261, 0, 0, 0, 1718, 0, 0, 0,
|
||||
0, 0, 1387, 0, 1507, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
|
||||
0, 0, 0, 357, 0, 0, 0, 0, 0, 0, 431, 0, 0, 0, 1199, 0,
|
||||
0, 0, 0, 0, 2446, 0, 0, 218, 0, 0, 3861, 0, 0, 0, 0, 0,
|
||||
0, 0, 0, 0, 3600, 919, 0, 0, 0, 0, 0, 0, 1694, 0, 0, 0,
|
||||
0, 0, 1161, 0, 0, 0, 0, 0, 381, 0, 221, 0, 3810, 0, 1467, 3945,
|
||||
0, 3178, 0, 0, 331, 61, 0, 0, 0, 606, 680, 0, 3568, 0, 0, 0,
|
||||
437, 0, 3806, 0, 0, 0, 1330, 0, 0, 0, 945, 0, 0, 0, 3384, 2674,
|
||||
0, 0, 0, 4287, 4141, 454, 0, 4099, 0, 0, 0, 0, 0, 0, 684, 1247,
|
||||
4248, 0, 0, 0, 0, 0, 0, 0, 0, 1705, 0, 0, 0, 0, 204, 0,
|
||||
0, 3605, 1783, 889, 0, 0, 0, 533, 841, 0, 0, 0, 722, 2641, 0, 0,
|
||||
0, 3827, 1320, 701, 4165, 0, 2297, 1239, 0, 2147, 0, 0, 0, 0, 0, 74,
|
||||
0, 0, 0, 2019, 0, 0, 0, 0, 0, 1982, 0, 0, 0, 0, 75, 0,
|
||||
0, 0, 578, 1658, 0, 0, 0, 0, 2822, 240, 0, 0, 27, 0, 0, 1251,
|
||||
0, 2305, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1199, 3986, 0, 0, 0,
|
||||
0, 0, 1984, 0, 0, 0, 1930, 3656, 0, 0, 0, 0, 1516, 0, 0, 593,
|
||||
0, 0, 0, 0, 0, 0, 0, 0, 478, 0, 882, 0, 0, 0, 0, 0,
|
||||
1844, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1101, 0, 0, 0, 0,
|
||||
3866, 559, 0, 0, 0, 0, 4302, 0, 0, 0, 0, 780, 0, 0, 1982, 0,
|
||||
0, 0, 4234, 0, 0, 0, 0, 0, 0, 0, 2297, 0, 0, 0, 659, 0,
|
||||
0, 3233, 0, 0, 0, 0, 0, 0, 0, 321, 393, 4385, 1088, 520, 0, 1157,
|
||||
1939, 0, 0, 0, 662, 865, 3747, 0, 959, 1862, 0, 408, 0, 0, 0, 1528,
|
||||
0, 0, 0, 0, 0, 0, 0, 3562, 0, 210, 0, 604, 3749, 869, 0, 859,
|
||||
787, 0, 0, 3851, 0, 0, 0, 0, 2430, 4363, 1549, 1784, 0, 0, 0, 0,
|
||||
0, 208, 0, 4183, 4422, 0, 0, 0, 0, 1393, 0, 0, 0, 1002, 0, 0,
|
||||
0, 0, 0, 0, 1081, 0, 0, 0, 0, 0, 0, 3531, 0, 0, 0, 0,
|
||||
507, 2505, 0, 0, 0, 0, 0, 0, 0, 1709, 806, 1352, 209, 0, 813, 0,
|
||||
0, 0, 0, 0, 0, 0, 0, 0, 653, 0, 0, 0, 0, 0, 0, 4320,
|
||||
0, 0, 111, 655, 0, 256, 0, 0, 315, 4069, 3518, 0, 0, 0, 0, 0,
|
||||
0, 0, 0, 3080, 968, 1823, 1486, 0, 432, 0, 0, 3856, 0, 0, 4251, 2293,
|
||||
0, 0, 0, 0, 0, 0, 1118, 0, 0, 1023, 0, 2048, 4190, 0, 3663, 0,
|
||||
0, 0, 802, 0, 0, 0, 0, 0, 0, 0, 2511, 0, 0, 0, 0, 70,
|
||||
359, 0, 872, 0, 0, 0, 0, 1357, 4197, 0, 0, 0, 2161, 509, 0, 1160,
|
||||
0, 0, 0, 0, 0, 1966, 57, 0, 0, 4399, 0, 3118, 0, 0, 3220, 0,
|
||||
35, 0, 1408, 0, 0, 0, 693, 0, 0, 1501, 0, 0, 4442, 0, 1162, 0,
|
||||
660, 0, 0, 0, 0, 0, 1589, 0, 0, 0, 0, 0, 0, 847, 0, 0,
|
||||
0, 536, 0, 1852, 0, 0, 0, 0, 3950, 4010, 0, 0, 1443, 0, 0, 0,
|
||||
235, 0, 0, 1930, 2636, 0, 1948, 2125, 0, 631, 0, 0, 1626, 0, 0, 4130,
|
||||
0, 0, 2700, 1002, 0, 0, 948, 2542, 1493, 0, 4345, 0, 0, 151, 0, 0,
|
||||
2828, 0, 0, 0, 0, 0, 0, 278, 4191, 756, 0, 3986, 0, 0, 380, 0,
|
||||
1810, 0, 3423, 0, 0, 0, 183, 0, 0, 0, 813, 0, 304, 4453, 0, 647,
|
||||
0, 0, 96, 0, 0, 1125, 0, 0, 0, 0, 0, 3813, 0, 0, 2261, 0,
|
||||
0, 0, 0, 0, 0, 0, 0, 0, 0, 3774, 0, 0, 2771, 0, 0, 0,
|
||||
784, 3419, 0, 4000, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 986, 0,
|
||||
3, 4422, 0, 0, 0, 0, 1085, 0, 2105, 0, 0, 0, 0, 0, 0, 1935,
|
||||
0, 0, 1532, 536, 0, 0, 0, 0, 0, 0, 1204, 3610, 0, 0, 0, 0,
|
||||
0, 1032, 0, 0, 2706, 0, 4084, 0, 3679, 0, 0, 0, 515, 0, 4210, 0,
|
||||
0, 357, 0, 0, 0, 0, 1868, 0, 2116, 0, 0, 0, 0, 2537, 0, 4146,
|
||||
0, 0, 0, 0, 0, 1774, 1202, 4192, 0, 38, 0, 0, 4239, 1431, 0, 0,
|
||||
0, 2086, 3359, 313, 1257, 3045, 1014, 0, 0, 0, 2549, 0, 938, 0, 0, 0,
|
||||
0, 4095, 0, 0, 0, 2625, 1961, 0, 0, 0, 3687, 3390, 0, 0, 325, 0,
|
||||
0, 0, 0, 1933, 0, 667, 0, 338, 0, 0, 0, 0, 1111, 0, 0, 0,
|
||||
0, 1483, 0, 320, 0, 1248, 0, 925, 0, 0, 0, 0, 1074, 0, 0, 0,
|
||||
0, 4239, 3207, 0, 396, 0, 0, 0, 85, 0, 1418, 127, 0, 1372, 0, 0,
|
||||
0, 0, 0, 710, 0, 2599, 2053, 4316, 0, 2708, 570, 0, 0, 1248, 0, 0,
|
||||
1187, 0, 0, 3899, 1895, 0, 0, 0, 1498, 594, 2018, 553, 2649, 911, 0, 2538,
|
||||
0, 0, 0, 3433, 0, 0, 0, 0, 2340, 0, 0, 461, 0, 0, 0, 0,
|
||||
0, 4014, 0, 3287, 647, 0, 0, 0, 466, 229, 0, 1544, 0, 1576, 0, 0,
|
||||
0, 3251, 0, 0, 698, 0, 0, 3516, 0, 0, 0, 0, 0, 653, 0, 2703,
|
||||
0, 0, 0, 2212, 0, 2015, 0, 0, 0, 0, 0, 0, 0, 0, 1307, 663,
|
||||
0, 179, 0, 0, 0, 0, 2717, 929, 358, 0, 4142, 1092, 3578, 0, 3160, 0,
|
||||
0, 0, 0, 932, 590, 85, 3483, 1580, 3628, 0, 0, 0, 0, 0, 0, 3354,
|
||||
0, 0, 166, 0, 0, 3413, 1430, 0, 0, 4427, 0, 0, 0, 0, 328, 0,
|
||||
0, 0, 0, 0, 856, 0, 0, 4415, 0, 0, 4389, 446, 0, 0, 1645, 0,
|
||||
0, 0, 0, 0, 0, 0, 3077, 0, 0, 1571, 472, 1588, 0, 0, 0, 17,
|
||||
0, 653, 815, 3015, 400, 0, 0, 0, 0, 0, 0, 4004, 0, 0, 1981, 2016,
|
||||
0, 935, 0, 0, 0, 0, 0, 0, 4100, 644, 1623, 0, 0, 91, 2507, 0,
|
||||
1311, 0, 2364, 0, 0, 327, 0, 0, 0, 264, 0, 3167, 3276, 4162, 1591, 0,
|
||||
0, 736, 0, 0, 0, 4089, 0, 3221, 1136, 0, 0, 0, 0, 867, 2968, 1781,
|
||||
0, 0, 4040, 2958, 0, 3499, 0, 3382, 1149, 2819, 266, 802, 133, 0, 0, 0,
|
||||
3176, 0, 1650, 3802, 0, 0, 0, 0, 0, 2732, 0, 0, 0, 151, 0, 0,
|
||||
1117, 3687, 0, 696, 2046, 0, 814, 0, 0, 0, 0, 3982, 0, 0, 0, 0,
|
||||
0, 0, 0, 0, 0, 0, 279, 2735, 0, 689, 853, 349, 0, 574, 2143, 0,
|
||||
0, 0, 3275, 0, 3086, 0, 0, 0, 0, 562, 1960, 0, 0, 0, 4129, 312,
|
||||
2687, 4370, 347, 1881, 1648, 1442, 0, 4226, 1609, 0, 0, 386, 2767, 0, 956, 0,
|
||||
0, 3301, 2280, 812, 0, 0, 66, 0, 0, 0, 0, 0, 0, 3085, 203, 0,
|
||||
709, 0, 235, 177, 0, 0, 0, 0, 2512, 1450, 0, 3215, 0, 0, 0, 1514,
|
||||
1008, 1860, 0, 3610, 908, 0, 0, 0, 158, 0, 153, 719, 0, 1184, 397, 256,
|
||||
0, 0, 517, 4241, 2402, 2208, 0, 4057, 0, 0, 1261, 0, 0, 0, 701, 604,
|
||||
0, 0, 135, 0, 0, 2102, 3714, 0, 826, 2268, 344, 0, 0, 4015, 0, 3958,
|
||||
1357, 0, 354, 0, 0, 598, 0, 0, 0, 0, 294, 3554, 0, 1277, 0, 0,
|
||||
0, 0, 141, 0, 0, 4115, 0, 0, 0, 1945, 0, 3230, 0, 972, 101, 1382,
|
||||
0, 0, 1014, 3534, 4383, 1312, 125, 2647, 0, 2014, 0, 1866, 0, 0, 3715, 99,
|
||||
515, 0, 0, 167, 2621, 0, 0, 0, 0, 3900, 3592, 0, 0, 0, 0, 0,
|
||||
0, 0, 1972, 0, 1653, 4378, 1975, 0, 950, 0, 0, 1553, 0, 0, 0, 0,
|
||||
145, 1093, 1404, 314, 0, 0, 0, 0, 1668, 0, 1042, 0, 2900, 1355, 0, 0,
|
||||
0, 0, 0, 858, 0, 0, 0, 958, 1889, 0, 0, 0, 0, 3924, 0, 0,
|
||||
2819, 0, 2638, 0, 0, 2585, 0, 0, 807, 1852, 0, 0, 0, 4051, 0, 3570,
|
||||
0, 0, 0, 0, 0, 0, 0, 0, 883, 0, 1526, 0, 847, 0, 532, 0,
|
||||
1214, 3981, 1205, 1023, 664, 1264, 2773, 0, 0, 73, 0, 1555, 0, 0, 0, 0,
|
||||
0, 0, 0, 0, 0, 0, 0, 2701, 2088, 811, 339, 0, 2050, 3888, 4133, 73,
|
||||
0, 0, 0, 1749, 1278, 232, 1113, 0, 0, 0, 0, 1423, 369, 589, 0, 0,
|
||||
0, 0, 0, 3947, 0, 192, 0, 1500, 2058, 0, 3093, 0, 0, 253, 686, 0,
|
||||
0, 0, 1847, 0, 0, 0, 0, 1531, 0, 222, 0, 0, 1291, 1154, 0, 0,
|
||||
0, 1422, 0, 0, 92, 1761, 0, 3482, 175, 3016, 0, 0, 0, 2091, 0, 1083,
|
||||
0, 1331, 2074, 573, 1650, 1903, 0, 0, 358, 3934, 1000, 0, 0, 0, 0, 135,
|
||||
4136, 0, 0, 0, 288, 0, 0, 0, 464, 0, 890, 408, 2370, 979, 0, 2494,
|
||||
3640, 0, 0, 0, 0, 1013, 1172, 1937, 2471, 0, 0, 0, 84, 519, 0, 1452,
|
||||
1596, 0, 1521, 0, 3417, 0, 1555, 0, 1997, 4116, 1537, 3657, 0, 0, 445, 451,
|
||||
2039, 835, 3931, 0, 4100, 1128, 0, 501, 0, 0, 0, 248, 0, 0, 4088, 2388,
|
||||
629, 0, 801, 0, 0, 1568, 771, 0, 949, 0, 140, 0, 0, 1806, 1568, 0,
|
||||
0, 2030, 1755, 0, 0, 2075, 0, 2829, 0, 0, 0, 0, 854, 1779, 0, 1022,
|
||||
2947, 0, 2714, 0, 668, 1835, 106, 0, 0, 111, 1656, 1230, 0, 0, 0, 0,
|
||||
3187, 406, 0, 752, 972, 0, 2872, 73, 0, 4400, 2630, 0, 1194, 399, 0, 948,
|
||||
0, 429, 0, 4344, 2988, 0, 1482, 3078, 0, 3811, 0, 0, 0, 453, 0, 1268,
|
||||
0, 0, 0, 1643, 1883, 0, 391, 1478, 1476, 0, 0, 907, 432, 0, 556, 0,
|
||||
0, 3783, 0, 2575, 2017, 4024, 0, 0, 0, 570, 2698, 1749, 0, 0, 0, 2650,
|
||||
1490, 0, 0, 0, 0, 906, 0, 0, 488, 1274, 0, 310, 436, 4202, 3961, 0,
|
||||
255, 2232, 2841, 0, 0, 0, 1666, 262, 1320, 0, 2744, 4376, 0, 0, 1651, 0,
|
||||
110, 0, 0, 0, 0, 775, 0, 0, 2425, 4122, 0, 1814, 0, 1951, 0, 0,
|
||||
0, 924, 3999, 0, 1109, 202, 0, 1719, 1045, 230, 0, 1359, 102, 0, 0, 0,
|
||||
542, 0, 872, 676, 0, 1685, 0, 0, 44, 0, 798, 553, 0, 239, 0, 0,
|
||||
0, 0, 881, 2692, 0, 4224, 0, 3537, 0, 0, 2051, 0, 0, 0, 0, 4291,
|
||||
0, 1617, 126, 4440, 1170, 491, 0, 0, 3101, 0, 0, 1044, 1499, 1290, 0, 0,
|
||||
0, 278, 0, 0, 1600, 0, 0, 0, 0, 0, 0, 0, 2903, 0, 0, 0,
|
||||
0, 684, 472, 0, 742, 3004, 0, 0, 1851, 1386, 1160, 1494, 1859, 0, 3500, 4048,
|
||||
581, 0, 0, 226, 1737, 0, 0, 0, 354, 0, 3818, 0, 4092, 0, 0, 1895,
|
||||
0, 1866, 1629, 0, 696, 0, 0, 1811, 0, 0, 0, 0, 0, 0, 0, 3865,
|
||||
753, 0, 0, 1902, 0, 0, 403, 831, 0, 1269, 0, 0, 0, 0, 2689, 0,
|
||||
0, 0, 0, 0, 0, 1275, 0, 0, 1799, 968, 0, 0, 0, 471, 466, 109,
|
||||
0, 0, 4410, 0, 2886, 3928, 725, 0, 0, 0, 1271, 2067, 2790, 1810, 0, 0,
|
||||
0, 0, 98, 0, 867, 1424, 1558, 1665, 1393, 0, 940, 692, 0, 0, 290, 803,
|
||||
0, 0, 1839, 0, 3825, 0, 1040, 0, 0, 0, 0, 0, 0, 0, 0, 3660,
|
||||
1943, 0, 0, 959, 1505, 4212, 238, 0, 0, 0, 119, 0, 0, 0, 407, 0,
|
||||
0, 0, 0, 3009, 1974, 1309, 0, 775, 0, 3398, 0, 532, 0, 0, 0, 0,
|
||||
0, 0, 0, 0, 0, 785, 0, 0, 2087, 0, 0, 0, 1647, 0, 0, 840,
|
||||
3232, 1827, 0, 336, 3195, 0, 12, 0, 778, 0, 1004, 1148, 0, 513, 3952, 0,
|
||||
0, 155, 567, 0, 0, 0, 1905, 0, 0, 950, 1021, 0, 2350, 1140, 0, 870,
|
||||
218, 291, 0, 1859, 3042, 708, 1500, 4199, 2385, 0, 0, 2040, 0, 276, 710, 3508,
|
||||
0, 0, 3049, 0, 0, 183, 219, 1025, 0, 4272, 3738, 0, 2222, 0, 1224, 1984,
|
||||
4319, 374, 0, 0, 0, 0, 0, 945, 2352, 496, 0, 1759, 0, 0, 0, 425,
|
||||
2723, 0, 0, 0, 771, 0, 0, 1185, 961, 3977, 0, 0, 0, 0, 0, 0,
|
||||
934, 0, 1340, 2162, 1199, 0, 0, 0, 0, 110, 851, 0, 0, 0, 0, 540,
|
||||
2149, 415, 0, 3873, 208, 0, 1655, 495, 1902, 0, 0, 2135, 0, 0, 0, 639,
|
||||
3197, 0, 0, 0, 3487, 0, 234, 0, 0, 0, 1378, 0, 0, 723, 107, 955,
|
||||
0, 0, 3313, 0, 3589, 419, 0, 4015, 1633, 2623, 0, 1129, 0, 1347, 2147, 0,
|
||||
0, 3079, 2172, 1649, 0, 0, 505, 0, 0, 2215, 0, 3567, 1279, 3671, 526, 1356,
|
||||
0, 1078, 507, 347, 0, 695, 0, 162, 0, 1867, 1923, 0, 530, 0, 0, 555,
|
||||
0, 0, 0, 0, 2208, 0, 0, 1838, 0, 0, 0, 0, 0, 1924, 1492, 0,
|
||||
1738, 1337, 0, 3595, 0, 690, 1269, 0, 1946, 0, 395, 0, 0, 13, 0, 0,
|
||||
866, 2298, 1771, 0, 0, 0, 728, 2447, 3227, 3237, 667, 0, 0, 0, 1279, 2780,
|
||||
0, 0, 0, 435, 4301, 2397, 4103, 672, 1657, 0, 0, 4024, 0, 0, 0, 0,
|
||||
3357, 0, 0, 1010, 0, 0, 0, 0, 1660, 3424, 0, 0, 0, 616, 371, 0,
|
||||
1705, 4365, 999, 275, 0, 0, 963, 0, 0, 794, 4047, 1749, 1406, 0, 55, 1751,
|
||||
0, 0, 0, 0, 0, 0, 0, 0, 739, 0, 649, 0, 0, 0, 3989, 0,
|
||||
3272, 0, 0, 0, 0, 0, 0, 0, 3295, 0, 1427, 0, 0, 811, 0, 351,
|
||||
0, 3834, 0, 1564, 0, 0, 1059, 2743, 3304, 1938, 0, 923, 378, 3177, 0, 0,
|
||||
1470, 0, 286, 0, 3065, 1371, 0, 675, 1708, 0, 0, 1203, 0, 0, 0, 0,
|
||||
376, 0, 345, 983, 2009, 0, 3788, 27, 247, 822, 0, 835, 1903, 575, 561, 1806,
|
||||
0, 107, 0, 1466, 0, 0, 1155, 85, 0, 2077, 0, 0, 838, 731, 289, 0,
|
||||
0, 0, 2114, 3728, 1067, 2248, 1546, 1000, 0, 0, 550, 3066, 1987, 0, 0, 0,
|
||||
0, 202, 0, 1788, 0, 981, 0, 3628, 882, 3969, 1795, 639, 4323, 0, 0, 0,
|
||||
614, 751, 0, 0, 3917, 326, 4035, 452, 1688, 4105, 4053, 0, 0, 797, 755, 3429,
|
||||
0, 4058, 0, 0, 0, 512, 3446, 0, 0, 0, 2624, 0, 3564, 1335, 0, 1245,
|
||||
2282, 301, 0, 0, 945, 0, 0, 0, 3408, 0, 0, 0, 4298, 0, 0, 1612,
|
||||
312, 1740, 0, 491, 3070, 0, 222, 3974, 1172, 898, 0, 1213, 0, 0, 1076, 2750,
|
||||
582, 0, 4030, 297, 0, 0, 3209, 0, 2012, 0, 409, 459, 102, 0, 0, 0,
|
||||
0, 318, 3156, 4381, 0, 243, 0, 1066, 3613, 3654, 2871, 3545, 0, 0, 585, 904,
|
||||
274, 0, 1457, 0, 0, 4058, 693, 15, 0, 1009, 4195, 0, 0, 0, 524, 0,
|
||||
0, 0, 0, 844, 203, 1782, 2118, 0, 672, 2269, 0, 0, 1905, 0, 0, 4417,
|
||||
0, 3797, 454, 0, 195, 0, 930, 4168, 480, 743, 4217, 0, 0, 3706, 2915, 2273,
|
||||
1063, 677, 0, 4420, 2326, 0, 0, 0, 1179, 1725, 0, 0, 3730, 0, 39, 4270,
|
||||
1585, 0, 1925, 3912, 0, 0, 0, 0, 0, 0, 4274, 0, 824, 0, 971, 0,
|
||||
0, 0, 0, 1928, 298, 0, 734, 0, 0, 10, 2811, 850, 0, 2731, 1322, 4050,
|
||||
2774, 0, 4322, 786, 346, 2108, 0, 0, 1920, 0, 0, 1660, 280, 174, 518, 3704,
|
||||
3169, 0, 0, 3434, 3345, 3828, 3865, 0, 196, 1421, 0, 0, 2368, 483, 1716, 0,
|
||||
0, 0, 0, 0, 0, 0, 593, 420, 0, 829, 0, 248, 1450, 4228, 0, 190,
|
||||
0, 3538, 4358, 3070, 0, 1222, 33, 0, 0, 16, 355, 0, 364, 606, 297, 0,
|
||||
1159, 1532, 0, 486, 0, 0, 0, 60, 749, 463, 861, 0, 4408, 463, 0, 0,
|
||||
849, 218, 0, 0, 0, 1062, 1411, 0, 1276, 45, 0, 0, 0, 87, 669, 861,
|
||||
570, 1206, 0, 0, 0, 0, 1367, 163, 353, 2631, 688, 1288, 0, 383, 0, 0,
|
||||
0, 0, 1901, 1817, 532, 1743, 438, 0, 3196, 0, 1135, 3962, 0, 0, 0, 1458,
|
||||
500, 253, 1314, 3690, 519, 0, 1729, 0, 1513, 692, 1127, 257, 0, 534, 0, 302,
|
||||
0, 0, 0, 0, 0, 1193, 50, 0, 314, 0, 0, 332, 4102, 265, 0, 1208,
|
||||
0, 2236, 0, 0, 0, 917, 0, 0, 2083, 2924, 543, 2492, 3603, 762, 423, 0,
|
||||
1293, 3452, 0, 2499, 0, 1700, 0, 0, 812, 1928, 1280, 2631, 436, 1422, 0, 0,
|
||||
1201, 0, 0, 1339, 68, 1872, 4153, 4268, 4238, 0, 1704, 0, 0, 0, 523, 0,
|
||||
0, 2026, 987, 292, 177, 1381, 1034, 518, 0, 0, 1611, 4312, 3213, 0, 0, 952,
|
||||
0, 0, 541, 818, 0, 0, 1349, 0, 0, 525, 0, 1459, 0, 1408, 3696, 823,
|
||||
0, 1883, 109, 4102, 1011, 700, 1049, 1167, 840, 0, 3919, 1405, 0, 2137, 1293, 0,
|
||||
0, 0, 698, 1169, 45, 0, 578, 0, 3507, 0, 4197, 379, 0, 0, 228, 519,
|
||||
0, 0, 4270, 0, 28, 0, 581, 1071, 1434, 0, 267, 0, 0, 408, 2883, 64,
|
||||
1411, 730, 1394, 0, 0, 2112, 1307, 0, 0, 236, 0, 0, 3601, 4029, 0, 0,
|
||||
716, 0, 2456, 0, 3915, 4440, 2555, 3643, 0, 628, 1357, 1373, 1008, 0, 0, 3022,
|
||||
1346, 230, 0, 0, 1991, 432, 101, 0, 0, 0, 0, 1767, 0, 0, 3903, 0,
|
||||
236, 3881, 0, 1921, 0, 2200, 0, 4411, 0, 1007, 3900, 0, 0, 282, 0, 1362,
|
||||
1018, 0, 0, 1191, 4441, 0, 0, 1280, 741, 2106, 1910, 0, 0, 394, 1720, 0,
|
||||
970, 0, 0, 0, 0, 4025, 0, 4150, 95, 3451, 132, 2737, 1448, 0, 230, 3911,
|
||||
0, 0, 713, 0, 0, 2156, 314, 382, 3165, 158, 1849, 0, 3498, 4204, 179, 0,
|
||||
0, 0, 913, 0, 0, 0, 3279, 1766, 2680, 4279, 591, 0, 4045, 3673, 3881, 0,
|
||||
1562, 421, 1387, 4121, 4154, 4200, 0, 3912, 97, 3476, 242, 0, 0, 258, 1299, 460,
|
||||
0, 0, 0, 0, 0, 4257, 0, 0, 440, 0, 0, 1967, 736, 2881, 0, 164,
|
||||
0, 2813, 3015, 2070, 0, 0, 0, 0, 294, 1999, 1933, 4131, 1509, 2148, 0, 0,
|
||||
1969, 1583, 2383, 2596, 986, 1628, 0, 49, 0, 0, 0, 0, 9, 0, 1127, 49,
|
||||
0, 0, 52, 0, 1012, 0, 1351, 0, 2061, 2487, 1716, 1424, 0, 3255, 967, 1752,
|
||||
0, 4326, 0, 639, 0, 1348, 2053, 3758, 1296, 1818, 1805, 0, 0, 0, 4321, 2091,
|
||||
0, 0, 2320, 0, 0, 3821, 193, 3423, 0, 2160, 0, 1107, 1631, 25, 0, 0,
|
||||
0, 0, 1436, 3024, 1003, 0, 2325, 0, 0, 683, 1023, 1760, 0, 1894, 16, 780,
|
||||
1558, 244, 1005, 0, 492, 2069, 1020, 1315, 3756, 764, 0, 0, 30, 0, 467, 1511,
|
||||
414, 0, 0, 0, 570, 0, 0, 0, 2072, 1627, 0, 0, 2037, 0, 539, 832,
|
||||
899, 0, 0, 638, 651, 901, 462, 1216, 0, 1074, 0, 0, 1006, 0, 0, 0,
|
||||
0, 3390, 1987, 0, 831, 1710, 0, 0, 3856, 2599, 960, 3988, 0, 4209, 0, 771,
|
||||
0, 0, 4415, 2729, 0, 0, 2165, 772, 0, 0, 2181, 431, 4130, 1508, 48, 790,
|
||||
3068, 0, 4306, 1596, 0, 0, 859, 0, 823, 3596, 2052, 3141, 0, 4377, 0, 194,
|
||||
414, 0, 0, 1051, 964, 1532, 0, 0, 1266, 3492, 0, 0, 0, 829, 1504, 0,
|
||||
1895, 0, 648, 831, 2964, 37, 3224, 1426, 3699, 1203, 1929, 1302, 2167, 0, 993, 1771,
|
||||
106, 0, 842, 0, 1152, 0, 0, 0, 1605, 0, 1533, 0, 709, 96, 658, 2045,
|
||||
2865, 618, 0, 3439, 0, 4312, 2084, 371, 0, 1961, 142, 0, 0, 0, 1552, 0,
|
||||
0, 0, 3070, 0, 1381, 1099, 1423, 0, 2743, 0, 46, 3081, 62, 3152, 0, 1067,
|
||||
3948, 2254, 808, 0, 0, 1791, 0, 2956, 1336, 153, 0, 1695, 2180, 335, 0, 502,
|
||||
896, 3491, 0, 925, 441, 464, 0, 0, 3206, 3577, 408, 2565, 2166, 4007, 734, 1520,
|
||||
766, 0, 0, 586, 0, 1025, 0, 1346, 2, 0, 140, 1355, 1884, 4337, 916, 1411,
|
||||
0, 0, 0, 76, 0, 1202, 4196, 1720, 1176, 0, 3222, 1724, 785, 0, 0, 45,
|
||||
0, 1286, 0, 144, 0, 4040, 0, 0, 0, 910, 0, 0, 277, 1484, 1494, 3994,
|
||||
0, 0, 364, 953, 582, 623, 1748, 952, 0, 0, 799, 0, 0, 3675, 7, 884,
|
||||
2132, 0, 497, 703, 0, 0, 0, 1527, 0, 0, 0, 558, 3175, 0, 2886, 20,
|
||||
0, 863, 0, 1542, 1194, 0, 0, 0, 1530, 0, 1426, 3370, 1184, 1888, 0, 0,
|
||||
0, 1879, 0, 0, 0, 0, 1373, 0, 0, 3925, 0, 0, 609, 3556, 886, 512,
|
||||
0, 1443, 1158, 0, 1601, 0, 496, 0, 0, 0, 0, 3980, 316, 0, 3999, 608,
|
||||
1375, 4451, 2447, 334, 0, 614, 1540, 3033, 3997, 0, 4215, 1469, 0, 1137, 925, 1312,
|
||||
0, 1765, 0, 2335, 645, 0, 943, 0, 2472, 0, 1214, 1635, 0, 0, 83, 4375,
|
||||
1993, 207, 291, 1175, 0, 2020, 0, 1194, 0, 540, 0, 641, 0, 0, 0, 1652,
|
||||
4302, 4210, 1077, 0, 4000, 0, 700, 3918, 3319, 3820, 750, 2117, 3307, 0, 3891, 1427,
|
||||
3662, 2483, 0, 14, 0, 0, 0, 2064, 0, 0, 0, 0, 1040, 0, 2024, 857,
|
||||
0, 1671, 879, 684, 682, 0, 846, 0, 1964, 3883, 0, 2651, 0, 0, 0, 3344,
|
||||
3567, 1574, 0, 1079, 1181, 1637, 482, 0, 2037, 265, 0, 1412, 0, 2269, 1227, 0,
|
||||
315, 297, 0, 2, 512, 0, 1097, 1347, 0, 4166, 0, 0, 0, 0, 0, 0,
|
||||
1372, 368, 1293, 0, 0, 0, 2843, 571, 1965, 4451, 1207, 1894, 1973, 2267, 0, 1274,
|
||||
0, 1584, 1144, 0, 2289, 1717, 3714, 1001, 0, 0, 1008, 834, 346, 1993, 1330, 4271,
|
||||
2874, 2332, 0, 0, 951, 0, 0, 0, 0, 3962, 1194, 1830, 1537, 3864, 807, 1958,
|
||||
0, 0, 4321, 0, 0, 0, 2290, 1033, 1590, 0, 340, 444, 3595, 3436, 425, 1916,
|
||||
0, 12, 182, 1544, 2176, 0, 1535, 1624, 0, 0, 1212, 0, 0, 4223, 0, 0,
|
||||
614, 2131, 0, 430, 1003, 667, 2642, 2027, 0, 1845, 631, 1056, 1252, 0, 468, 4019,
|
||||
0, 0, 0, 0, 1481, 1951, 3403, 1374, 0, 0, 0, 4294, 1220, 114, 0, 418,
|
||||
651, 98, 1015, 4403, 0, 1295, 0, 1338, 3941, 0, 542, 3496, 75, 916, 404, 329,
|
||||
0, 1438, 300, 957, 0, 0, 602, 373, 0, 2540, 2585, 23, 1959, 293, 3627, 1485,
|
||||
1242, 0, 0, 0, 1108, 0, 533, 0, 1842, 772, 0, 879, 1240, 0, 1545, 0,
|
||||
0, 0, 159, 111, 731, 0, 0, 0, 1284, 127, 2538, 2422, 0, 1077, 657, 862,
|
||||
3393, 3538, 398, 859, 1477, 0, 3066, 0, 0, 1873, 0, 1188, 39, 3293, 397, 0,
|
||||
0, 1098, 1549, 0, 0, 0, 6, 4275, 3349, 1906, 518, 1259, 1310, 167, 754, 329,
|
||||
0, 2196, 778, 3061, 0, 1447, 811, 0, 984, 0, 0, 1386, 1267, 0, 0, 0,
|
||||
1429, 1565, 1976, 3102, 0, 0, 0, 3727, 0, 2404, 0, 0, 3510, 2113, 0, 1147,
|
||||
0, 1704, 0, 0, 75, 0, 3848, 0, 0, 0, 0, 822, 3353, 4291, 978, 1393,
|
||||
1631, 0, 4272, 1276, 0, 0, 0, 2093, 774, 0, 3925, 901, 0, 3714, 0, 0,
|
||||
1582, 0, 1742, 4026, 748, 2962, 1209, 0, 0, 1440, 940, 2826, 0, 797, 2567, 4275,
|
||||
252, 2842, 3771, 0, 1223, 0, 0, 1900, 0, 3580, 1282, 1112, 0, 1261, 123, 117,
|
||||
381, 537, 1615, 2429, 1559, 1102, 2475, 1722, 0, 903, 0, 3890, 466, 3629, 338, 0,
|
||||
887, 4365, 676, 1438, 837, 120, 0, 941, 0, 1869, 353, 1742, 0, 1479, 0, 3562,
|
||||
0, 1483, 3730, 0, 3009, 0, 0, 0, 1887, 161, 635, 0, 3014, 0, 4170, 0,
|
||||
0, 947, 0, 119, 1617, 0, 0, 2562, 169, 458, 0, 1047, 1108, 1879, 504, 0,
|
||||
2102, 0, 1144, 2339, 364, 0, 0, 0, 40, 0, 2062, 283, 0, 745, 4330, 0,
|
||||
99, 1996, 0, 2711, 1765, 0, 1424, 3705, 0, 0, 0, 0, 1358, 4383, 3326, 0,
|
||||
0, 3030, 499, 2276, 0, 3230, 0, 923, 0, 0, 4362, 4025, 871, 0, 0, 0,
|
||||
1529, 0, 2906, 916, 0, 0, 4269, 1211, 0, 1802, 0, 0, 2895, 1825, 873, 1053,
|
||||
1322, 1833, 360, 0, 1586, 1730, 0, 1072, 0, 0, 0, 943, 1379, 0, 3869, 4429,
|
||||
3154, 1312, 2013, 0, 4232, 1317, 336, 637, 2071, 16, 4384, 0, 832, 0, 3, 0,
|
||||
0, 0, 1650, 4308, 0, 1869, 0, 0, 4115, 1017, 316, 0, 0, 1843, 0, 1378,
|
||||
577, 0, 0, 4440, 81, 3849, 0, 1644, 4385, 3917, 1747, 0, 1664, 0, 1217, 367,
|
||||
0, 0, 2700, 0, 208, 2033, 0, 413, 656, 632, 433, 0, 0, 934, 0, 37,
|
||||
4004, 0, 0, 1536, 342, 0, 0, 666, 363, 118, 4353, 0, 0, 0, 249, 105,
|
||||
1553, 1547, 19, 0, 493, 1350, 1917, 1691, 0, 1349, 0, 380, 756, 0, 0, 0,
|
||||
0, 0, 1415, 0, 1643, 0, 0, 241, 3884, 2489, 1276, 0, 0, 717, 0, 1468,
|
||||
0, 146, 1965, 0, 1116, 0, 2624, 0, 878, 2182, 1566, 1770, 850, 699, 0, 0,
|
||||
1846, 535, 0, 584, 0, 2002, 244, 0, 3769, 1094, 2006, 0, 0, 0, 4207, 3761,
|
||||
4353, 1046, 310, 3707, 0, 1253, 1284, 0, 0, 3085, 337, 2234, 162, 4231, 0, 422,
|
||||
5, 694, 1721, 0, 1853, 1474, 191, 1298, 0, 0, 2918, 4065, 0, 0, 1089, 0,
|
||||
0, 1310, 2035, 4324, 34, 0, 0, 1853, 0, 4390, 1251, 0, 1095, 1677, 1126, 1035,
|
||||
1048, 773, 2534, 767, 16, 343, 3632, 768, 538, 0, 1909, 672, 0, 461, 1732, 0,
|
||||
4193, 0, 1434, 1387, 2036, 0, 0, 2293, 0, 0, 920, 0, 1138, 1125, 0, 0,
|
||||
0, 1453, 0, 1990, 0, 1289, 76};
|
||||
|
||||
int MangledHashG(const char *key, const int *T)
|
||||
{
|
||||
|
@ -288,46 +322,45 @@ int MangledHashG(const char *key, const int *T)
|
|||
for (int i = 0; key[i] != '\0'; i++)
|
||||
{
|
||||
sum += T[i] * key[i];
|
||||
sum %= 3910;
|
||||
sum %= 4455;
|
||||
}
|
||||
return mangledkG[sum];
|
||||
}
|
||||
|
||||
int MangledPerfectHash(const char *key)
|
||||
{
|
||||
if (strlen(key) > 40)
|
||||
if (strlen(key) > 37)
|
||||
return 0;
|
||||
|
||||
return (MangledHashG(key, mangledkT1) + MangledHashG(key, mangledkT2)) % 3910;
|
||||
return (MangledHashG(key, mangledkT1) + MangledHashG(key, mangledkT2)) % 4455;
|
||||
}
|
||||
|
||||
constexpr int unmangledkT1[] = {361, 84, 287, 107, 189, 235, 216, 268, 315, 73, 365, 67, 31,
|
||||
103, 108, 1, 206, 276, 63, 133, 161, 27, 70, 359, 69, 354};
|
||||
constexpr int unmangledkT2[] = {116, 270, 65, 391, 92, 345, 246, 10, 306, 20, 206, 346, 291,
|
||||
195, 244, 398, 269, 237, 25, 394, 247, 248, 315, 180, 233, 167};
|
||||
constexpr int unmangledkT1[] = {152, 85, 131, 46, 141, 140, 355, 227, 157, 95, 193, 274, 113,
|
||||
293, 338, 312, 38, 56, 305, 7, 299, 103, 63, 14, 147, 26};
|
||||
constexpr int unmangledkT2[] = {16, 254, 132, 341, 351, 23, 144, 38, 280, 327, 291, 81, 145,
|
||||
376, 164, 258, 319, 373, 246, 29, 53, 104, 148, 299, 8, 288};
|
||||
constexpr int unmangledkG[] = {
|
||||
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 82, 0, 0, 34, 0, 0, 0, 0,
|
||||
0, 0, 0, 0, 0, 0, 0, 42, 391, 0, 0, 0, 0, 7, 0, 187, 0, 64, 237,
|
||||
350, 377, 112, 192, 0, 217, 0, 133, 0, 0, 0, 0, 0, 384, 0, 0, 0, 0, 0,
|
||||
122, 0, 107, 0, 283, 276, 9, 317, 215, 0, 147, 167, 232, 169, 15, 0, 0, 247, 25,
|
||||
348, 0, 364, 68, 195, 0, 345, 0, 0, 154, 31, 0, 0, 180, 0, 0, 342, 321, 0,
|
||||
0, 0, 0, 2, 244, 73, 61, 0, 0, 259, 0, 51, 178, 0, 0, 12, 28, 202, 0,
|
||||
113, 144, 0, 0, 0, 196, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0,
|
||||
0, 309, 0, 232, 56, 0, 315, 358, 0, 0, 0, 341, 21, 360, 0, 0, 0, 0, 0,
|
||||
46, 0, 325, 17, 11, 272, 0, 0, 126, 401, 0, 85, 40, 305, 0, 0, 0, 0, 0,
|
||||
0, 0, 7, 201, 56, 142, 405, 0, 0, 0, 339, 164, 0, 192, 0, 109, 206, 60, 40,
|
||||
0, 0, 243, 17, 0, 145, 0, 163, 88, 0, 0, 0, 128, 0, 117, 0, 0, 0, 257,
|
||||
285, 0, 16, 0, 191, 0, 0, 12, 0, 339, 71, 323, 21, 99, 0, 0, 187, 0, 22,
|
||||
167, 274, 0, 258, 0, 0, 0, 17, 30, 0, 0, 0, 181, 218, 0, 0, 109, 0, 212,
|
||||
154, 332, 54, 259, 0, 0, 0, 319, 14, 149, 82, 50, 0, 0, 15, 218, 0, 0, 0,
|
||||
0, 123, 0, 218, 162, 0, 50, 226, 219, 0, 86, 120, 310, 197, 101, 0, 0, 0, 0,
|
||||
127, 1, 207, 86, 0, 0, 0, 377, 0, 8, 75, 0, 0, 395, 106, 374, 0, 197, 0,
|
||||
356, 179, 297, 0, 3, 70, 0, 164, 7, 0, 0, 136, 0, 250, 193, 0, 52, 319, 248,
|
||||
0, 357, 112, 0, 77, 0, 0, 0, 230, 136, 81, 101, 0, 217, 0, 0, 0, 37, 0,
|
||||
172, 0, 0, 0, 14, 175, 0, 53, 361, 0, 134, 191, 304, 43, 0, 0, 198, 0, 82,
|
||||
0, 336, 0, 0, 0, 338, 280, 0, 386, 360, 8, 139, 87, 30, 281, 0, 0, 0, 11,
|
||||
262, 389, 301, 236, 36, 190, 150, 0, 0, 0, 325, 0, 388, 0, 155, 33, 379, 6, 4,
|
||||
0, 165, 129, 214, 369, 0, 0, 17};
|
||||
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 340, 0, 0, 207, 0, 0, 0, 0, 155,
|
||||
106, 0, 305, 0, 0, 8, 0, 0, 0, 0, 0, 195, 0, 252, 0, 0, 0, 84, 0,
|
||||
0, 0, 179, 24, 0, 0, 0, 0, 0, 54, 317, 0, 288, 264, 8, 0, 0, 342, 0,
|
||||
0, 0, 122, 0, 0, 365, 135, 361, 0, 0, 0, 0, 0, 0, 0, 0, 46, 0, 0,
|
||||
212, 0, 0, 152, 0, 25, 0, 134, 0, 167, 0, 0, 0, 355, 92, 0, 265, 374, 0,
|
||||
92, 0, 102, 0, 158, 152, 0, 0, 0, 0, 0, 288, 32, 0, 139, 0, 103, 365, 296,
|
||||
0, 66, 0, 370, 122, 149, 0, 0, 0, 0, 0, 349, 148, 191, 281, 172, 0, 374, 0,
|
||||
0, 0, 148, 0, 357, 272, 0, 115, 50, 0, 142, 11, 0, 0, 367, 49, 223, 54, 0,
|
||||
0, 0, 171, 84, 130, 0, 252, 0, 0, 85, 0, 116, 0, 0, 0, 0, 119, 270, 296,
|
||||
23, 71, 180, 59, 216, 284, 73, 0, 0, 0, 63, 0, 236, 115, 71, 171, 4, 0, 369,
|
||||
0, 0, 0, 267, 330, 90, 133, 81, 39, 0, 378, 190, 23, 346, 0, 0, 176, 0, 119,
|
||||
0, 0, 0, 0, 0, 0, 12, 298, 248, 97, 0, 34, 0, 53, 80, 247, 150, 387, 88,
|
||||
21, 0, 183, 341, 23, 363, 0, 14, 143, 111, 26, 0, 40, 28, 46, 0, 0, 165, 182,
|
||||
0, 0, 19, 0, 0, 0, 0, 235, 209, 305, 74, 339, 198, 14, 0, 200, 250, 35, 190,
|
||||
22, 194, 0, 122, 66, 167, 0, 0, 135, 0, 0, 201, 0, 157, 0, 255, 163, 339, 73,
|
||||
0, 271, 0, 0, 0, 101, 0, 0, 182, 0, 27, 364, 0, 87, 20, 0, 385, 383, 33,
|
||||
0, 0, 128, 0, 213, 232, 74, 150, 8, 16, 244, 0, 0, 55, 5, 72, 189, 186, 0,
|
||||
17, 116, 378, 55, 352, 148, 0, 285, 0, 123, 0, 43, 0, 0, 0, 305, 240, 0, 131,
|
||||
0, 69, 185, 174, 0, 34, 70, 378, 170, 104, 208, 281, 118, 0, 260, 173, 0, 0, 166,
|
||||
6, 30, 0, 254, 214, 204, 0, 0, 153, 0, 67, 368, 121, 2, 0, 139, 193, 0, 0,
|
||||
285, 325, 0, 0, 0, 0, 0, 96};
|
||||
|
||||
int UnmangledHashG(const char *key, const int *T)
|
||||
{
|
||||
|
@ -336,7 +369,7 @@ int UnmangledHashG(const char *key, const int *T)
|
|||
for (int i = 0; key[i] != '\0'; i++)
|
||||
{
|
||||
sum += T[i] * key[i];
|
||||
sum %= 407;
|
||||
sum %= 388;
|
||||
}
|
||||
return unmangledkG[sum];
|
||||
}
|
||||
|
@ -346,7 +379,7 @@ int UnmangledPerfectHash(const char *key)
|
|||
if (strlen(key) > 26)
|
||||
return 0;
|
||||
|
||||
return (UnmangledHashG(key, unmangledkT1) + UnmangledHashG(key, unmangledkT2)) % 407;
|
||||
return (UnmangledHashG(key, unmangledkT1) + UnmangledHashG(key, unmangledkT2)) % 388;
|
||||
}
|
||||
|
||||
} // namespace
|
||||
|
|
|
@ -9,7 +9,6 @@
|
|||
|
||||
#include <math.h>
|
||||
#include <stdlib.h>
|
||||
#include "GLSLANG/ShaderLang.h"
|
||||
#include "compiler/translator/Common.h"
|
||||
#include "compiler/translator/Severity.h"
|
||||
|
||||
|
@ -104,39 +103,17 @@ class TInfoSinkBase
|
|||
return *this;
|
||||
}
|
||||
|
||||
void erase()
|
||||
{
|
||||
sink.clear();
|
||||
binarySink.clear();
|
||||
}
|
||||
int size() { return static_cast<int>(isBinary() ? binarySink.size() : sink.size()); }
|
||||
void erase() { sink.clear(); }
|
||||
int size() { return static_cast<int>(sink.size()); }
|
||||
|
||||
const TPersistString &str() const
|
||||
{
|
||||
ASSERT(!isBinary());
|
||||
return sink;
|
||||
}
|
||||
const char *c_str() const
|
||||
{
|
||||
ASSERT(!isBinary());
|
||||
return sink.c_str();
|
||||
}
|
||||
const TPersistString &str() const { return sink; }
|
||||
const char *c_str() const { return sink.c_str(); }
|
||||
|
||||
void prefix(Severity severity);
|
||||
void location(int file, int line);
|
||||
|
||||
bool isBinary() const { return !binarySink.empty(); }
|
||||
void setBinary(BinaryBlob &&binary) { binarySink = std::move(binary); }
|
||||
const BinaryBlob &getBinary() const
|
||||
{
|
||||
ASSERT(isBinary());
|
||||
return binarySink;
|
||||
}
|
||||
|
||||
private:
|
||||
// The data in the info sink is either in human readable form (|sink|) or binary (|binarySink|).
|
||||
TPersistString sink;
|
||||
BinaryBlob binarySink;
|
||||
};
|
||||
|
||||
class TInfoSink
|
||||
|
|
|
@ -53,10 +53,6 @@ void InitExtensionBehavior(const ShBuiltInResources &resources, TExtensionBehavi
|
|||
{
|
||||
extBehavior[TExtension::EXT_shader_framebuffer_fetch] = EBhUndefined;
|
||||
}
|
||||
if (resources.EXT_shader_framebuffer_fetch_non_coherent)
|
||||
{
|
||||
extBehavior[TExtension::EXT_shader_framebuffer_fetch_non_coherent] = EBhUndefined;
|
||||
}
|
||||
if (resources.NV_shader_framebuffer_fetch)
|
||||
{
|
||||
extBehavior[TExtension::NV_shader_framebuffer_fetch] = EBhUndefined;
|
||||
|
@ -85,14 +81,6 @@ void InitExtensionBehavior(const ShBuiltInResources &resources, TExtensionBehavi
|
|||
{
|
||||
extBehavior[TExtension::EXT_geometry_shader] = EBhUndefined;
|
||||
}
|
||||
if (resources.OES_shader_io_blocks)
|
||||
{
|
||||
extBehavior[TExtension::OES_shader_io_blocks] = EBhUndefined;
|
||||
}
|
||||
if (resources.EXT_shader_io_blocks)
|
||||
{
|
||||
extBehavior[TExtension::EXT_shader_io_blocks] = EBhUndefined;
|
||||
}
|
||||
if (resources.EXT_gpu_shader5)
|
||||
{
|
||||
extBehavior[TExtension::EXT_gpu_shader5] = EBhUndefined;
|
||||
|
@ -149,10 +137,6 @@ void InitExtensionBehavior(const ShBuiltInResources &resources, TExtensionBehavi
|
|||
{
|
||||
extBehavior[TExtension::OES_shader_image_atomic] = EBhUndefined;
|
||||
}
|
||||
if (resources.EXT_tessellation_shader)
|
||||
{
|
||||
extBehavior[TExtension::EXT_tessellation_shader] = EBhUndefined;
|
||||
}
|
||||
if (resources.OES_texture_buffer)
|
||||
{
|
||||
extBehavior[TExtension::OES_texture_buffer] = EBhUndefined;
|
||||
|
@ -161,14 +145,6 @@ void InitExtensionBehavior(const ShBuiltInResources &resources, TExtensionBehavi
|
|||
{
|
||||
extBehavior[TExtension::EXT_texture_buffer] = EBhUndefined;
|
||||
}
|
||||
if (resources.OES_sample_variables)
|
||||
{
|
||||
extBehavior[TExtension::OES_sample_variables] = EBhUndefined;
|
||||
}
|
||||
if (resources.EXT_clip_cull_distance)
|
||||
{
|
||||
extBehavior[TExtension::EXT_clip_cull_distance] = EBhUndefined;
|
||||
}
|
||||
}
|
||||
|
||||
void ResetExtensionBehavior(const ShBuiltInResources &resources,
|
||||
|
@ -181,7 +157,7 @@ void ResetExtensionBehavior(const ShBuiltInResources &resources,
|
|||
}
|
||||
if (resources.ARB_texture_rectangle)
|
||||
{
|
||||
if ((compileOptions & SH_DISABLE_ARB_TEXTURE_RECTANGLE) != 0)
|
||||
if (compileOptions & SH_DISABLE_ARB_TEXTURE_RECTANGLE)
|
||||
{
|
||||
// Remove ARB_texture_rectangle so it can't be enabled by extension directives.
|
||||
extBehavior.erase(TExtension::ARB_texture_rectangle);
|
||||
|
|
|
@ -413,9 +413,6 @@ TIntermBlock::TIntermBlock(const TIntermBlock &node)
|
|||
{
|
||||
mStatements.push_back(node->deepCopy());
|
||||
}
|
||||
|
||||
ASSERT(!node.mIsTreeRoot);
|
||||
mIsTreeRoot = false;
|
||||
}
|
||||
|
||||
size_t TIntermBlock::getChildCount() const
|
||||
|
@ -433,12 +430,6 @@ bool TIntermBlock::replaceChildNode(TIntermNode *original, TIntermNode *replacem
|
|||
return replaceChildNodeInternal(original, replacement);
|
||||
}
|
||||
|
||||
void TIntermBlock::replaceAllChildren(const TIntermSequence &newStatements)
|
||||
{
|
||||
mStatements.clear();
|
||||
mStatements.insert(mStatements.begin(), newStatements.begin(), newStatements.end());
|
||||
}
|
||||
|
||||
size_t TIntermFunctionPrototype::getChildCount() const
|
||||
{
|
||||
return 0;
|
||||
|
@ -470,14 +461,6 @@ bool TIntermDeclaration::replaceChildNode(TIntermNode *original, TIntermNode *re
|
|||
return replaceChildNodeInternal(original, replacement);
|
||||
}
|
||||
|
||||
TIntermDeclaration::TIntermDeclaration(const TIntermDeclaration &node)
|
||||
{
|
||||
for (TIntermNode *node : node.mDeclarators)
|
||||
{
|
||||
mDeclarators.push_back(node->deepCopy());
|
||||
}
|
||||
}
|
||||
|
||||
bool TIntermAggregateBase::replaceChildNodeInternal(TIntermNode *original, TIntermNode *replacement)
|
||||
{
|
||||
for (size_t ii = 0; ii < getSequence()->size(); ++ii)
|
||||
|
@ -1057,9 +1040,9 @@ TIntermAggregate::TIntermAggregate(const TIntermAggregate &node)
|
|||
|
||||
TIntermAggregate *TIntermAggregate::shallowCopy() const
|
||||
{
|
||||
TIntermSequence copySeq;
|
||||
copySeq.insert(copySeq.begin(), getSequence()->begin(), getSequence()->end());
|
||||
TIntermAggregate *copyNode = new TIntermAggregate(mFunction, mType, mOp, ©Seq);
|
||||
TIntermSequence *copySeq = new TIntermSequence();
|
||||
copySeq->insert(copySeq->begin(), getSequence()->begin(), getSequence()->end());
|
||||
TIntermAggregate *copyNode = new TIntermAggregate(mFunction, mType, mOp, copySeq);
|
||||
copyNode->setLine(mLine);
|
||||
return copyNode;
|
||||
}
|
||||
|
|
|
@ -673,7 +673,7 @@ class TIntermAggregate : public TIntermOperator, public TIntermAggregateBase
|
|||
class TIntermBlock : public TIntermNode, public TIntermAggregateBase
|
||||
{
|
||||
public:
|
||||
TIntermBlock() : TIntermNode(), mIsTreeRoot(false) {}
|
||||
TIntermBlock() : TIntermNode() {}
|
||||
~TIntermBlock() override {}
|
||||
|
||||
TIntermBlock *getAsBlock() override { return this; }
|
||||
|
@ -683,7 +683,6 @@ class TIntermBlock : public TIntermNode, public TIntermAggregateBase
|
|||
size_t getChildCount() const final;
|
||||
TIntermNode *getChildNode(size_t index) const final;
|
||||
bool replaceChildNode(TIntermNode *original, TIntermNode *replacement) override;
|
||||
void replaceAllChildren(const TIntermSequence &newStatements);
|
||||
|
||||
// Only intended for initially building the block.
|
||||
void appendStatement(TIntermNode *statement);
|
||||
|
@ -694,16 +693,9 @@ class TIntermBlock : public TIntermNode, public TIntermAggregateBase
|
|||
|
||||
TIntermBlock *deepCopy() const override { return new TIntermBlock(*this); }
|
||||
|
||||
void setIsTreeRoot() { mIsTreeRoot = true; }
|
||||
bool isTreeRoot() const { return mIsTreeRoot; }
|
||||
|
||||
protected:
|
||||
TIntermSequence mStatements;
|
||||
|
||||
// Used to distinguish the tree root from the other blocks. When validating the AST, some
|
||||
// validations are not applicable if not run on the entire tree and are thus skipped.
|
||||
bool mIsTreeRoot;
|
||||
|
||||
private:
|
||||
TIntermBlock(const TIntermBlock &);
|
||||
};
|
||||
|
@ -801,23 +793,13 @@ class TIntermDeclaration : public TIntermNode, public TIntermAggregateBase
|
|||
TIntermSequence *getSequence() override { return &mDeclarators; }
|
||||
const TIntermSequence *getSequence() const override { return &mDeclarators; }
|
||||
|
||||
TIntermDeclaration *deepCopy() const override
|
||||
TIntermNode *deepCopy() const override
|
||||
{
|
||||
// Note: This is only useful as support for deepCopy of TIntermBlock and TIntermLoop, but is
|
||||
// not sufficient as it will be redeclaring the same TVariable. If a function body is
|
||||
// duplicated for example, it means that both functions reference the same TVariable pointer
|
||||
// which works, but is technically not correct. In particular, maps with TVariable * as key
|
||||
// can get confused.
|
||||
//
|
||||
// After deepCopy() is issued, ReplaceVariables must be used to replace every declared
|
||||
// variable with a duplicate. This is NOT automatically done when deepCopy-ing TIntermBlock
|
||||
// and TIntermLoop nodes.
|
||||
return new TIntermDeclaration(*this);
|
||||
UNREACHABLE();
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
protected:
|
||||
TIntermDeclaration(const TIntermDeclaration &node);
|
||||
|
||||
TIntermSequence mDeclarators;
|
||||
};
|
||||
|
||||
|
|
|
@ -258,7 +258,8 @@ void TOutputGLSLBase::writeLayoutQualifier(TIntermTyped *variable)
|
|||
|
||||
if (type.getBasicType() == EbtInterfaceBlock)
|
||||
{
|
||||
declareInterfaceBlockLayout(type);
|
||||
const TInterfaceBlock *interfaceBlock = type.getInterfaceBlock();
|
||||
declareInterfaceBlockLayout(interfaceBlock);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -395,8 +396,8 @@ void TOutputGLSLBase::writeVariableType(const TType &type,
|
|||
out << getMemoryQualifiers(type);
|
||||
}
|
||||
|
||||
// Declare the struct.
|
||||
if (type.isStructSpecifier())
|
||||
// Declare the struct if we have not done so already.
|
||||
if (type.getBasicType() == EbtStruct && !structDeclared(type.getStruct()))
|
||||
{
|
||||
const TStructure *structure = type.getStruct();
|
||||
|
||||
|
@ -404,7 +405,8 @@ void TOutputGLSLBase::writeVariableType(const TType &type,
|
|||
}
|
||||
else if (type.getBasicType() == EbtInterfaceBlock)
|
||||
{
|
||||
declareInterfaceBlock(type);
|
||||
const TInterfaceBlock *interfaceBlock = type.getInterfaceBlock();
|
||||
declareInterfaceBlock(interfaceBlock);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -1089,10 +1091,9 @@ bool TOutputGLSLBase::visitDeclaration(Visit visit, TIntermDeclaration *node)
|
|||
const TIntermSequence &sequence = *(node->getSequence());
|
||||
TIntermTyped *variable = sequence.front()->getAsTyped();
|
||||
TIntermSymbol *symbolNode = variable->getAsSymbolNode();
|
||||
if (!symbolNode || (symbolNode->getName() != "gl_ClipDistance" &&
|
||||
symbolNode->getName() != "gl_CullDistance"))
|
||||
if (!symbolNode || symbolNode->getName() != "gl_ClipDistance")
|
||||
{
|
||||
// gl_Clip/CullDistance re-declaration doesn't need layout.
|
||||
// gl_ClipDistance re-declaration doesn't need layout.
|
||||
writeLayoutQualifier(variable);
|
||||
}
|
||||
writeVariableType(variable->getType(), symbolNode ? &symbolNode->variable() : nullptr,
|
||||
|
@ -1279,6 +1280,17 @@ ImmutableString TOutputGLSLBase::hashFunctionNameIfNeeded(const TFunction *func)
|
|||
}
|
||||
}
|
||||
|
||||
bool TOutputGLSLBase::structDeclared(const TStructure *structure) const
|
||||
{
|
||||
ASSERT(structure);
|
||||
if (structure->symbolType() == SymbolType::Empty)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
return (mDeclaredStructs.count(structure->uniqueId().get()) > 0);
|
||||
}
|
||||
|
||||
void TOutputGLSLBase::declareStruct(const TStructure *structure)
|
||||
{
|
||||
TInfoSinkBase &out = objSink();
|
||||
|
@ -1302,20 +1314,16 @@ void TOutputGLSLBase::declareStruct(const TStructure *structure)
|
|||
out << ";\n";
|
||||
}
|
||||
out << "}";
|
||||
|
||||
if (structure->symbolType() != SymbolType::Empty)
|
||||
{
|
||||
mDeclaredStructs.insert(structure->uniqueId().get());
|
||||
}
|
||||
}
|
||||
|
||||
void TOutputGLSLBase::declareInterfaceBlockLayout(const TType &type)
|
||||
void TOutputGLSLBase::declareInterfaceBlockLayout(const TInterfaceBlock *interfaceBlock)
|
||||
{
|
||||
// 4.4.5 Uniform and Shader Storage Block Layout Qualifiers in GLSL 4.5 spec.
|
||||
// Layout qualifiers can be used for uniform and shader storage blocks,
|
||||
// but not for non-block uniform declarations.
|
||||
if (IsShaderIoBlock(type.getQualifier()))
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
const TInterfaceBlock *interfaceBlock = type.getInterfaceBlock();
|
||||
TInfoSinkBase &out = objSink();
|
||||
TInfoSinkBase &out = objSink();
|
||||
|
||||
out << "layout(";
|
||||
|
||||
|
@ -1353,56 +1361,20 @@ void TOutputGLSLBase::declareInterfaceBlockLayout(const TType &type)
|
|||
out << ") ";
|
||||
}
|
||||
|
||||
const char *getVariableInterpolation(TQualifier qualifier)
|
||||
void TOutputGLSLBase::declareInterfaceBlock(const TInterfaceBlock *interfaceBlock)
|
||||
{
|
||||
switch (qualifier)
|
||||
{
|
||||
case EvqSmoothOut:
|
||||
return "smooth out ";
|
||||
case EvqFlatOut:
|
||||
return "flat out ";
|
||||
case EvqNoPerspectiveOut:
|
||||
return "noperspective out ";
|
||||
case EvqCentroidOut:
|
||||
return "centroid out ";
|
||||
case EvqSmoothIn:
|
||||
return "smooth in ";
|
||||
case EvqFlatIn:
|
||||
return "flat in ";
|
||||
case EvqNoPerspectiveIn:
|
||||
return "noperspective in ";
|
||||
case EvqCentroidIn:
|
||||
return "centroid in ";
|
||||
default:
|
||||
break;
|
||||
}
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
void TOutputGLSLBase::declareInterfaceBlock(const TType &type)
|
||||
{
|
||||
const TInterfaceBlock *interfaceBlock = type.getInterfaceBlock();
|
||||
TInfoSinkBase &out = objSink();
|
||||
TInfoSinkBase &out = objSink();
|
||||
|
||||
out << hashName(interfaceBlock) << "{\n";
|
||||
const TFieldList &fields = interfaceBlock->fields();
|
||||
for (const TField *field : fields)
|
||||
{
|
||||
if (!IsShaderIoBlock(type.getQualifier()) && type.getQualifier() != EvqPatchIn &&
|
||||
type.getQualifier() != EvqPatchOut)
|
||||
{
|
||||
writeFieldLayoutQualifier(field);
|
||||
}
|
||||
writeFieldLayoutQualifier(field);
|
||||
out << getMemoryQualifiers(*field->type());
|
||||
|
||||
if (writeVariablePrecision(field->type()->getPrecision()))
|
||||
out << " ";
|
||||
|
||||
const char *qualifier = getVariableInterpolation(field->type()->getQualifier());
|
||||
if (qualifier != nullptr)
|
||||
out << qualifier;
|
||||
|
||||
out << getTypeName(*field->type()) << " " << hashFieldName(field);
|
||||
|
||||
if (field->type()->isArray())
|
||||
out << ArrayString(*field->type());
|
||||
out << ";\n";
|
||||
|
@ -1458,40 +1430,6 @@ void WriteGeometryShaderLayoutQualifiers(TInfoSinkBase &out,
|
|||
}
|
||||
}
|
||||
|
||||
void WriteTessControlShaderLayoutQualifiers(TInfoSinkBase &out, int inputVertices)
|
||||
{
|
||||
if (inputVertices != 0)
|
||||
{
|
||||
out << "layout (vertices = " << inputVertices << ") out;\n";
|
||||
}
|
||||
}
|
||||
|
||||
void WriteTessEvaluationShaderLayoutQualifiers(TInfoSinkBase &out,
|
||||
sh::TLayoutTessEvaluationType inputPrimitive,
|
||||
sh::TLayoutTessEvaluationType inputVertexSpacing,
|
||||
sh::TLayoutTessEvaluationType inputOrdering,
|
||||
sh::TLayoutTessEvaluationType inputPoint)
|
||||
{
|
||||
if (inputPrimitive != EtetUndefined)
|
||||
{
|
||||
out << "layout (";
|
||||
out << getTessEvaluationShaderTypeString(inputPrimitive);
|
||||
if (inputVertexSpacing != EtetUndefined)
|
||||
{
|
||||
out << ", " << getTessEvaluationShaderTypeString(inputVertexSpacing);
|
||||
}
|
||||
if (inputOrdering != EtetUndefined)
|
||||
{
|
||||
out << ", " << getTessEvaluationShaderTypeString(inputOrdering);
|
||||
}
|
||||
if (inputPoint != EtetUndefined)
|
||||
{
|
||||
out << ", " << getTessEvaluationShaderTypeString(inputPoint);
|
||||
}
|
||||
out << ") in;\n";
|
||||
}
|
||||
}
|
||||
|
||||
// If SH_SCALARIZE_VEC_AND_MAT_CONSTRUCTOR_ARGS is enabled, layout qualifiers are spilled whenever
|
||||
// variables with specified layout qualifiers are copied. Additional checks are needed against the
|
||||
// type and storage qualifier of the variable to verify that layout qualifiers have to be outputted.
|
||||
|
|
|
@ -89,20 +89,24 @@ class TOutputGLSLBase : public TIntermTraverser
|
|||
|
||||
void declareStruct(const TStructure *structure);
|
||||
void writeQualifier(TQualifier qualifier, const TType &type, const TSymbol *symbol);
|
||||
bool structDeclared(const TStructure *structure) const;
|
||||
|
||||
const char *mapQualifierToString(TQualifier qualifier);
|
||||
|
||||
sh::GLenum getShaderType() { return mShaderType; }
|
||||
|
||||
private:
|
||||
void declareInterfaceBlockLayout(const TType &type);
|
||||
void declareInterfaceBlock(const TType &type);
|
||||
void declareInterfaceBlockLayout(const TInterfaceBlock *interfaceBlock);
|
||||
void declareInterfaceBlock(const TInterfaceBlock *interfaceBlock);
|
||||
|
||||
void writeBuiltInFunctionTriplet(Visit visit, TOperator op, bool useEmulatedFunction);
|
||||
|
||||
TInfoSinkBase &mObjSink;
|
||||
bool mDeclaringVariable;
|
||||
|
||||
// This set contains all the ids of the structs from every scope.
|
||||
std::set<int> mDeclaredStructs;
|
||||
|
||||
ShArrayIndexClampingStrategy mClampingStrategy;
|
||||
|
||||
// name hashing.
|
||||
|
@ -125,14 +129,6 @@ void WriteGeometryShaderLayoutQualifiers(TInfoSinkBase &out,
|
|||
sh::TLayoutPrimitiveType outputPrimitive,
|
||||
int maxVertices);
|
||||
|
||||
void WriteTessControlShaderLayoutQualifiers(TInfoSinkBase &out, int inputVertices);
|
||||
|
||||
void WriteTessEvaluationShaderLayoutQualifiers(TInfoSinkBase &out,
|
||||
sh::TLayoutTessEvaluationType inputPrimitive,
|
||||
sh::TLayoutTessEvaluationType inputVertexSpacing,
|
||||
sh::TLayoutTessEvaluationType inputOrdering,
|
||||
sh::TLayoutTessEvaluationType inputPoint);
|
||||
|
||||
bool NeedsToWriteLayoutQualifier(const TType &type);
|
||||
|
||||
} // namespace sh
|
||||
|
|
|
@ -24,7 +24,7 @@
|
|||
#include "compiler/translator/TranslatorHLSL.h"
|
||||
#include "compiler/translator/UtilsHLSL.h"
|
||||
#include "compiler/translator/blocklayout.h"
|
||||
#include "compiler/translator/tree_ops/d3d/RemoveSwitchFallThrough.h"
|
||||
#include "compiler/translator/tree_ops/RemoveSwitchFallThrough.h"
|
||||
#include "compiler/translator/tree_util/FindSymbolNode.h"
|
||||
#include "compiler/translator/tree_util/NodeSearch.h"
|
||||
#include "compiler/translator/util.h"
|
||||
|
@ -297,21 +297,22 @@ const TConstantUnion *OutputHLSL::writeConstantUnionArray(TInfoSinkBase &out,
|
|||
return constUnionIterated;
|
||||
}
|
||||
|
||||
OutputHLSL::OutputHLSL(sh::GLenum shaderType,
|
||||
ShShaderSpec shaderSpec,
|
||||
int shaderVersion,
|
||||
const TExtensionBehavior &extensionBehavior,
|
||||
const char *sourcePath,
|
||||
ShShaderOutput outputType,
|
||||
int numRenderTargets,
|
||||
int maxDualSourceDrawBuffers,
|
||||
const std::vector<ShaderVariable> &uniforms,
|
||||
ShCompileOptions compileOptions,
|
||||
sh::WorkGroupSize workGroupSize,
|
||||
TSymbolTable *symbolTable,
|
||||
PerformanceDiagnostics *perfDiagnostics,
|
||||
const std::map<int, const TInterfaceBlock *> &uniformBlockOptimizedMap,
|
||||
const std::vector<InterfaceBlock> &shaderStorageBlocks)
|
||||
OutputHLSL::OutputHLSL(
|
||||
sh::GLenum shaderType,
|
||||
ShShaderSpec shaderSpec,
|
||||
int shaderVersion,
|
||||
const TExtensionBehavior &extensionBehavior,
|
||||
const char *sourcePath,
|
||||
ShShaderOutput outputType,
|
||||
int numRenderTargets,
|
||||
int maxDualSourceDrawBuffers,
|
||||
const std::vector<ShaderVariable> &uniforms,
|
||||
ShCompileOptions compileOptions,
|
||||
sh::WorkGroupSize workGroupSize,
|
||||
TSymbolTable *symbolTable,
|
||||
PerformanceDiagnostics *perfDiagnostics,
|
||||
const std::map<int, const TInterfaceBlock *> &uniformBlocksTranslatedToStructuredBuffers,
|
||||
const std::vector<InterfaceBlock> &shaderStorageBlocks)
|
||||
: TIntermTraverser(true, true, true, symbolTable),
|
||||
mShaderType(shaderType),
|
||||
mShaderSpec(shaderSpec),
|
||||
|
@ -322,7 +323,7 @@ OutputHLSL::OutputHLSL(sh::GLenum shaderType,
|
|||
mCompileOptions(compileOptions),
|
||||
mInsideFunction(false),
|
||||
mInsideMain(false),
|
||||
mUniformBlockOptimizedMap(uniformBlockOptimizedMap),
|
||||
mUniformBlocksTranslatedToStructuredBuffers(uniformBlocksTranslatedToStructuredBuffers),
|
||||
mNumRenderTargets(numRenderTargets),
|
||||
mMaxDualSourceDrawBuffers(maxDualSourceDrawBuffers),
|
||||
mCurrentFunctionMetadata(nullptr),
|
||||
|
@ -372,7 +373,7 @@ OutputHLSL::OutputHLSL(sh::GLenum shaderType,
|
|||
new AtomicCounterFunctionHLSL((compileOptions & SH_FORCE_ATOMIC_VALUE_RESOLUTION) != 0);
|
||||
|
||||
unsigned int firstUniformRegister =
|
||||
(compileOptions & SH_SKIP_D3D_CONSTANT_REGISTER_ZERO) != 0 ? 1u : 0u;
|
||||
((compileOptions & SH_SKIP_D3D_CONSTANT_REGISTER_ZERO) != 0) ? 1u : 0u;
|
||||
mResourcesHLSL = new ResourcesHLSL(mStructureHLSL, outputType, uniforms, firstUniformRegister);
|
||||
|
||||
if (mOutputType == SH_HLSL_3_0_OUTPUT)
|
||||
|
@ -387,7 +388,8 @@ OutputHLSL::OutputHLSL(sh::GLenum shaderType,
|
|||
// Reserve registers for the default uniform block and driver constants
|
||||
mResourcesHLSL->reserveUniformBlockRegisters(2);
|
||||
|
||||
mSSBOOutputHLSL = new ShaderStorageBlockOutputHLSL(this, mResourcesHLSL, shaderStorageBlocks);
|
||||
mSSBOOutputHLSL =
|
||||
new ShaderStorageBlockOutputHLSL(this, symbolTable, mResourcesHLSL, shaderStorageBlocks);
|
||||
}
|
||||
|
||||
OutputHLSL::~OutputHLSL()
|
||||
|
@ -659,7 +661,8 @@ void OutputHLSL::header(TInfoSinkBase &out,
|
|||
out << mStructureHLSL->structsHeader();
|
||||
|
||||
mResourcesHLSL->uniformsHeader(out, mOutputType, mReferencedUniforms, mSymbolTable);
|
||||
out << mResourcesHLSL->uniformBlocksHeader(mReferencedUniformBlocks, mUniformBlockOptimizedMap);
|
||||
out << mResourcesHLSL->uniformBlocksHeader(mReferencedUniformBlocks,
|
||||
mUniformBlocksTranslatedToStructuredBuffers);
|
||||
mSSBOOutputHLSL->writeShaderStorageBlocksHeader(out);
|
||||
|
||||
if (!mEqualityFunctions.empty())
|
||||
|
@ -1647,8 +1650,8 @@ bool OutputHLSL::visitBinary(Visit visit, TIntermBinary *node)
|
|||
{
|
||||
const TInterfaceBlock *interfaceBlock =
|
||||
GetInterfaceBlockOfUniformBlockNearestIndexOperator(node->getLeft());
|
||||
if (interfaceBlock &&
|
||||
mUniformBlockOptimizedMap.count(interfaceBlock->uniqueId().get()) != 0)
|
||||
if (interfaceBlock && mUniformBlocksTranslatedToStructuredBuffers.count(
|
||||
interfaceBlock->uniqueId().get()) != 0)
|
||||
{
|
||||
// If the uniform block member's type is not structure, we had explicitly
|
||||
// packed the member into a structure, so need to add an operator of field
|
||||
|
@ -1682,8 +1685,8 @@ bool OutputHLSL::visitBinary(Visit visit, TIntermBinary *node)
|
|||
{
|
||||
const TInterfaceBlock *interfaceBlock =
|
||||
GetInterfaceBlockOfUniformBlockNearestIndexOperator(node->getLeft());
|
||||
if (interfaceBlock &&
|
||||
mUniformBlockOptimizedMap.count(interfaceBlock->uniqueId().get()) != 0)
|
||||
if (interfaceBlock && mUniformBlocksTranslatedToStructuredBuffers.count(
|
||||
interfaceBlock->uniqueId().get()) != 0)
|
||||
{
|
||||
// If the uniform block member's type is not structure, we had explicitly
|
||||
// packed the member into a structure, so need to add an operator of field
|
||||
|
@ -1754,8 +1757,8 @@ bool OutputHLSL::visitBinary(Visit visit, TIntermBinary *node)
|
|||
node->getLeft()->getType().getInterfaceBlock();
|
||||
const TIntermConstantUnion *index = node->getRight()->getAsConstantUnion();
|
||||
const TField *field = interfaceBlock->fields()[index->getIConst(0)];
|
||||
if (structInStd140UniformBlock ||
|
||||
mUniformBlockOptimizedMap.count(interfaceBlock->uniqueId().get()) != 0)
|
||||
if (structInStd140UniformBlock || mUniformBlocksTranslatedToStructuredBuffers.count(
|
||||
interfaceBlock->uniqueId().get()) != 0)
|
||||
{
|
||||
out << "_";
|
||||
}
|
||||
|
@ -3203,7 +3206,7 @@ void OutputHLSL::outputTriplet(TInfoSinkBase &out,
|
|||
|
||||
void OutputHLSL::outputLineDirective(TInfoSinkBase &out, int line)
|
||||
{
|
||||
if ((mCompileOptions & SH_LINE_DIRECTIVES) != 0 && line > 0)
|
||||
if ((mCompileOptions & SH_LINE_DIRECTIVES) && (line > 0))
|
||||
{
|
||||
out << "\n";
|
||||
out << "#line " << line;
|
||||
|
|
|
@ -37,21 +37,22 @@ using ReferencedVariables = std::map<int, const TVariable *>;
|
|||
class OutputHLSL : public TIntermTraverser
|
||||
{
|
||||
public:
|
||||
OutputHLSL(sh::GLenum shaderType,
|
||||
ShShaderSpec shaderSpec,
|
||||
int shaderVersion,
|
||||
const TExtensionBehavior &extensionBehavior,
|
||||
const char *sourcePath,
|
||||
ShShaderOutput outputType,
|
||||
int numRenderTargets,
|
||||
int maxDualSourceDrawBuffers,
|
||||
const std::vector<ShaderVariable> &uniforms,
|
||||
ShCompileOptions compileOptions,
|
||||
sh::WorkGroupSize workGroupSize,
|
||||
TSymbolTable *symbolTable,
|
||||
PerformanceDiagnostics *perfDiagnostics,
|
||||
const std::map<int, const TInterfaceBlock *> &uniformBlockOptimizedMap,
|
||||
const std::vector<InterfaceBlock> &shaderStorageBlocks);
|
||||
OutputHLSL(
|
||||
sh::GLenum shaderType,
|
||||
ShShaderSpec shaderSpec,
|
||||
int shaderVersion,
|
||||
const TExtensionBehavior &extensionBehavior,
|
||||
const char *sourcePath,
|
||||
ShShaderOutput outputType,
|
||||
int numRenderTargets,
|
||||
int maxDualSourceDrawBuffers,
|
||||
const std::vector<ShaderVariable> &uniforms,
|
||||
ShCompileOptions compileOptions,
|
||||
sh::WorkGroupSize workGroupSize,
|
||||
TSymbolTable *symbolTable,
|
||||
PerformanceDiagnostics *perfDiagnostics,
|
||||
const std::map<int, const TInterfaceBlock *> &uniformBlocksTranslatedToStructuredBuffers,
|
||||
const std::vector<InterfaceBlock> &shaderStorageBlocks);
|
||||
|
||||
~OutputHLSL() override;
|
||||
|
||||
|
@ -180,7 +181,7 @@ class OutputHLSL : public TIntermTraverser
|
|||
// Indexed by block id, not instance id.
|
||||
ReferencedInterfaceBlocks mReferencedUniformBlocks;
|
||||
|
||||
std::map<int, const TInterfaceBlock *> mUniformBlockOptimizedMap;
|
||||
std::map<int, const TInterfaceBlock *> mUniformBlocksTranslatedToStructuredBuffers;
|
||||
|
||||
ReferencedVariables mReferencedAttributes;
|
||||
ReferencedVariables mReferencedVaryings;
|
||||
|
|
Разница между файлами не показана из-за своего большого размера
Загрузить разницу
|
@ -64,7 +64,7 @@ class TParseContext : angle::NonCopyable
|
|||
const char *token);
|
||||
|
||||
TIntermBlock *getTreeRoot() const { return mTreeRoot; }
|
||||
void setTreeRoot(TIntermBlock *treeRoot);
|
||||
void setTreeRoot(TIntermBlock *treeRoot) { mTreeRoot = treeRoot; }
|
||||
|
||||
bool getFragmentPrecisionHigh() const
|
||||
{
|
||||
|
@ -177,8 +177,7 @@ class TParseContext : angle::NonCopyable
|
|||
// Done only for empty declarations.
|
||||
void emptyDeclarationErrorCheck(const TType &type, const TSourceLoc &location);
|
||||
|
||||
void checkCanUseLayoutQualifier(const TSourceLoc &location);
|
||||
bool checkLayoutQualifierSupported(const TSourceLoc &location,
|
||||
void checkLayoutQualifierSupported(const TSourceLoc &location,
|
||||
const ImmutableString &layoutQualifierName,
|
||||
int versionRequired);
|
||||
bool checkWorkGroupSizeIsNotSpecified(const TSourceLoc &location,
|
||||
|
@ -191,7 +190,6 @@ class TParseContext : angle::NonCopyable
|
|||
const TPublicType &type,
|
||||
const TSourceLoc &qualifierLocation);
|
||||
void checkLocalVariableConstStorageQualifier(const TQualifierWrapperBase &qualifier);
|
||||
void checkTCSOutVarIndexIsValid(TIntermBinary *binaryExpression, const TSourceLoc &location);
|
||||
const TPragma &pragma() const { return mDirectiveHandler.pragma(); }
|
||||
const TExtensionBehavior &extensionBehavior() const
|
||||
{
|
||||
|
@ -360,8 +358,8 @@ class TParseContext : angle::NonCopyable
|
|||
TFieldList *fieldList,
|
||||
const ImmutableString &instanceName,
|
||||
const TSourceLoc &instanceLine,
|
||||
const TVector<unsigned int> *arraySizes,
|
||||
const TSourceLoc &arraySizesLine);
|
||||
TIntermTyped *arrayIndex,
|
||||
const TSourceLoc &arrayIndexLine);
|
||||
|
||||
void parseLocalSize(const ImmutableString &qualifierType,
|
||||
const TSourceLoc &qualifierTypeLine,
|
||||
|
@ -382,10 +380,6 @@ class TParseContext : angle::NonCopyable
|
|||
const TSourceLoc &intValueLine,
|
||||
const std::string &intValueString,
|
||||
int *numMaxVertices);
|
||||
void parseVertices(int intValue,
|
||||
const TSourceLoc &intValueLine,
|
||||
const std::string &intValueString,
|
||||
int *numVertices);
|
||||
void parseIndexLayoutQualifier(int intValue,
|
||||
const TSourceLoc &intValueLine,
|
||||
const std::string &intValueString,
|
||||
|
@ -471,23 +465,6 @@ class TParseContext : angle::NonCopyable
|
|||
{
|
||||
return mGeometryShaderOutputPrimitiveType;
|
||||
}
|
||||
int getTessControlShaderOutputVertices() const { return mTessControlShaderOutputVertices; }
|
||||
TLayoutTessEvaluationType getTessEvaluationShaderInputPrimitiveType() const
|
||||
{
|
||||
return mTessEvaluationShaderInputPrimitiveType;
|
||||
}
|
||||
TLayoutTessEvaluationType getTessEvaluationShaderInputVertexSpacingType() const
|
||||
{
|
||||
return mTessEvaluationShaderInputVertexSpacingType;
|
||||
}
|
||||
TLayoutTessEvaluationType getTessEvaluationShaderInputOrderingType() const
|
||||
{
|
||||
return mTessEvaluationShaderInputOrderingType;
|
||||
}
|
||||
TLayoutTessEvaluationType getTessEvaluationShaderInputPointType() const
|
||||
{
|
||||
return mTessEvaluationShaderInputPointType;
|
||||
}
|
||||
|
||||
ShShaderOutput getOutputType() const { return mOutputType; }
|
||||
|
||||
|
@ -577,18 +554,9 @@ class TParseContext : angle::NonCopyable
|
|||
|
||||
void checkEarlyFragmentTestsIsNotSpecified(const TSourceLoc &location, bool earlyFragmentTests);
|
||||
|
||||
void checkNoncoherentIsSpecified(const TSourceLoc &location, bool noncoherent);
|
||||
|
||||
void checkNoncoherentIsNotSpecified(const TSourceLoc &location, bool noncoherent);
|
||||
|
||||
bool checkUnsizedArrayConstructorArgumentDimensionality(const TIntermSequence &arguments,
|
||||
TType type,
|
||||
const TSourceLoc &line);
|
||||
|
||||
void checkCombinedClipCullDistanceIsValid(const TSourceLoc &line,
|
||||
const ImmutableString &identifier,
|
||||
const int arraySize);
|
||||
|
||||
// Check texture offset is within range.
|
||||
void checkSingleTextureOffset(const TSourceLoc &line,
|
||||
const TConstantUnion *values,
|
||||
|
@ -601,11 +569,6 @@ class TParseContext : angle::NonCopyable
|
|||
const ImmutableString &token,
|
||||
TType *type);
|
||||
|
||||
// Similar, for tessellation shaders.
|
||||
void checkTessellationShaderUnsizedArraysAndSetSize(const TSourceLoc &location,
|
||||
const ImmutableString &token,
|
||||
TType *type);
|
||||
|
||||
// Will size any unsized array type so unsized arrays won't need to be taken into account
|
||||
// further along the line in parsing.
|
||||
void checkIsNotUnsizedArray(const TSourceLoc &line,
|
||||
|
@ -648,16 +611,13 @@ class TParseContext : angle::NonCopyable
|
|||
bool parseGeometryShaderOutputLayoutQualifier(const TTypeQualifier &typeQualifier);
|
||||
void setGeometryShaderInputArraySize(unsigned int inputArraySize, const TSourceLoc &line);
|
||||
|
||||
bool parseTessControlShaderOutputLayoutQualifier(const TTypeQualifier &typeQualifier);
|
||||
bool parseTessEvaluationShaderInputLayoutQualifier(const TTypeQualifier &typeQualifier);
|
||||
|
||||
// Set to true when the last/current declarator list was started with an empty declaration. The
|
||||
// non-empty declaration error check will need to be performed if the empty declaration is
|
||||
// followed by a declarator.
|
||||
bool mDeferredNonEmptyDeclarationErrorCheck;
|
||||
|
||||
sh::GLenum mShaderType; // vertex/fragment/geometry/etc shader
|
||||
ShShaderSpec mShaderSpec; // The language specification compiler conforms to - GLES/WebGL/etc.
|
||||
sh::GLenum mShaderType; // vertex or fragment language (future: pack or unpack)
|
||||
ShShaderSpec mShaderSpec; // The language specification compiler conforms to - GLES2 or WebGL.
|
||||
ShCompileOptions mCompileOptions; // Options passed to TCompiler
|
||||
int mShaderVersion;
|
||||
TIntermBlock *mTreeRoot; // root of parse tree being created
|
||||
|
@ -714,14 +674,6 @@ class TParseContext : angle::NonCopyable
|
|||
int mGeometryShaderMaxVertices;
|
||||
int mMaxGeometryShaderInvocations;
|
||||
int mMaxGeometryShaderMaxVertices;
|
||||
unsigned int mGeometryInputArraySize;
|
||||
|
||||
int mMaxPatchVertices;
|
||||
int mTessControlShaderOutputVertices;
|
||||
TLayoutTessEvaluationType mTessEvaluationShaderInputPrimitiveType;
|
||||
TLayoutTessEvaluationType mTessEvaluationShaderInputVertexSpacingType;
|
||||
TLayoutTessEvaluationType mTessEvaluationShaderInputOrderingType;
|
||||
TLayoutTessEvaluationType mTessEvaluationShaderInputPointType;
|
||||
|
||||
// Track when we add new scope for func body in ESSL 1.00 spec
|
||||
bool mFunctionBodyNewScope;
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
// Generated by gen_builtin_symbols.py using data from builtin_variables.json and
|
||||
// builtin_function_declarations.txt.
|
||||
//
|
||||
// Copyright 2020 The ANGLE Project Authors. All rights reserved.
|
||||
// Copyright 2021 The ANGLE Project Authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
//
|
||||
|
@ -21,77 +21,77 @@ namespace BuiltInGroup
|
|||
bool isTextureOffsetNoBias(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 3792 && id <= 3861;
|
||||
return id >= 3680 && id <= 3749;
|
||||
}
|
||||
bool isTextureOffsetBias(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 3862 && id <= 3881;
|
||||
}
|
||||
bool isTextureGatherOffsetNoComp(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 3919 && id <= 3926;
|
||||
}
|
||||
bool isTextureGatherOffsetComp(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 3927 && id <= 3932;
|
||||
}
|
||||
bool isTextureGatherOffset(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 3919 && id <= 3932;
|
||||
}
|
||||
bool isTextureGatherOffsetsNoComp(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 3933 && id <= 3949;
|
||||
return id >= 3750 && id <= 3769;
|
||||
}
|
||||
bool isTextureGatherOffsetsComp(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 3950 && id <= 3961;
|
||||
return id >= 3807 && id <= 3819;
|
||||
}
|
||||
bool isTextureGatherOffsetsNoComp(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 3820 && id <= 3835;
|
||||
}
|
||||
bool isTextureGatherOffsets(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 3933 && id <= 3961;
|
||||
return id >= 3807 && id <= 3835;
|
||||
}
|
||||
bool isTextureGatherOffsetComp(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 3836 && id <= 3841;
|
||||
}
|
||||
bool isTextureGatherOffsetNoComp(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 3842 && id <= 3849;
|
||||
}
|
||||
bool isTextureGatherOffset(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 3836 && id <= 3849;
|
||||
}
|
||||
bool isTextureGather(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 3895 && id <= 3961;
|
||||
return id >= 3783 && id <= 3849;
|
||||
}
|
||||
bool isInterpolationFS(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 3974 && id <= 3997;
|
||||
return id >= 3862 && id <= 3885;
|
||||
}
|
||||
bool isAtomicMemory(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 4002 && id <= 4019;
|
||||
}
|
||||
bool isImageStore(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 4056 && id <= 4073;
|
||||
return id >= 3890 && id <= 3907;
|
||||
}
|
||||
bool isImageLoad(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 4074 && id <= 4091;
|
||||
return id >= 3944 && id <= 3961;
|
||||
}
|
||||
bool isImageAtomic(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 4092 && id <= 4667;
|
||||
return id >= 3962 && id <= 4537;
|
||||
}
|
||||
bool isImageStore(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 4538 && id <= 4555;
|
||||
}
|
||||
bool isImage(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 4020 && id <= 4667;
|
||||
return id >= 3908 && id <= 4555;
|
||||
}
|
||||
|
||||
} // namespace BuiltInGroup
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
// Generated by gen_builtin_symbols.py using data from builtin_variables.json and
|
||||
// builtin_function_declarations.txt.
|
||||
//
|
||||
// Copyright 2020 The ANGLE Project Authors. All rights reserved.
|
||||
// Copyright 2021 The ANGLE Project Authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
//
|
||||
|
@ -28,35 +28,35 @@ bool isTextureOffsetBias(const TFunction *func)
|
|||
int id = func->uniqueId().get();
|
||||
return id >= 1279 && id <= 1313;
|
||||
}
|
||||
bool isTextureGatherOffsetNoComp(const TFunction *func)
|
||||
bool isTextureGatherOffsetsComp(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 1358 && id <= 1369;
|
||||
}
|
||||
bool isTextureGatherOffsetComp(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 1370 && id <= 1378;
|
||||
}
|
||||
bool isTextureGatherOffset(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 1358 && id <= 1378;
|
||||
return id >= 1358 && id <= 1373;
|
||||
}
|
||||
bool isTextureGatherOffsetsNoComp(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 1379 && id <= 1399;
|
||||
}
|
||||
bool isTextureGatherOffsetsComp(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 1400 && id <= 1414;
|
||||
return id >= 1374 && id <= 1393;
|
||||
}
|
||||
bool isTextureGatherOffsets(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 1379 && id <= 1414;
|
||||
return id >= 1358 && id <= 1393;
|
||||
}
|
||||
bool isTextureGatherOffsetComp(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 1394 && id <= 1402;
|
||||
}
|
||||
bool isTextureGatherOffsetNoComp(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 1403 && id <= 1414;
|
||||
}
|
||||
bool isTextureGatherOffset(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 1394 && id <= 1414;
|
||||
}
|
||||
bool isTextureGather(const TFunction *func)
|
||||
{
|
||||
|
@ -73,25 +73,25 @@ bool isAtomicMemory(const TFunction *func)
|
|||
int id = func->uniqueId().get();
|
||||
return id >= 1488 && id <= 1505;
|
||||
}
|
||||
bool isImageStore(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 1578 && id <= 1610;
|
||||
}
|
||||
bool isImageLoad(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 1611 && id <= 1643;
|
||||
return id >= 1578 && id <= 1613;
|
||||
}
|
||||
bool isImageAtomic(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 1644 && id <= 2765;
|
||||
return id >= 1614 && id <= 2735;
|
||||
}
|
||||
bool isImageStore(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 2736 && id <= 2768;
|
||||
}
|
||||
bool isImage(const TFunction *func)
|
||||
{
|
||||
int id = func->uniqueId().get();
|
||||
return id >= 1506 && id <= 2765;
|
||||
return id >= 1506 && id <= 2768;
|
||||
}
|
||||
|
||||
} // namespace BuiltInGroup
|
||||
|
|
|
@ -177,8 +177,7 @@ bool HasRepeatingQualifiers(const TTypeQualifierBuilder::QualifierSequence &qual
|
|||
// repetitions.
|
||||
TQualifier currentQualifier =
|
||||
static_cast<const TStorageQualifierWrapper *>(qualifiers[i])->getQualifier();
|
||||
if (currentQualifier == EvqVertexOut || currentQualifier == EvqFragmentOut ||
|
||||
currentQualifier == EvqFragmentInOut)
|
||||
if (currentQualifier == EvqVertexOut || currentQualifier == EvqFragmentOut)
|
||||
{
|
||||
isOut = true;
|
||||
}
|
||||
|
@ -373,14 +372,10 @@ bool JoinVariableStorageQualifier(TQualifier *joinedQualifier, TQualifier storag
|
|||
break;
|
||||
case EvqVertexOut:
|
||||
case EvqGeometryOut:
|
||||
case EvqTessControlOut:
|
||||
case EvqTessEvaluationOut:
|
||||
*joinedQualifier = EvqSmoothOut;
|
||||
break;
|
||||
case EvqFragmentIn:
|
||||
case EvqGeometryIn:
|
||||
case EvqTessControlIn:
|
||||
case EvqTessEvaluationIn:
|
||||
*joinedQualifier = EvqSmoothIn;
|
||||
break;
|
||||
default:
|
||||
|
@ -397,14 +392,10 @@ bool JoinVariableStorageQualifier(TQualifier *joinedQualifier, TQualifier storag
|
|||
break;
|
||||
case EvqVertexOut:
|
||||
case EvqGeometryOut:
|
||||
case EvqTessControlOut:
|
||||
case EvqTessEvaluationOut:
|
||||
*joinedQualifier = EvqFlatOut;
|
||||
break;
|
||||
case EvqFragmentIn:
|
||||
case EvqGeometryIn:
|
||||
case EvqTessControlIn:
|
||||
case EvqTessEvaluationIn:
|
||||
*joinedQualifier = EvqFlatIn;
|
||||
break;
|
||||
default:
|
||||
|
@ -421,14 +412,10 @@ bool JoinVariableStorageQualifier(TQualifier *joinedQualifier, TQualifier storag
|
|||
break;
|
||||
case EvqVertexOut:
|
||||
case EvqGeometryOut:
|
||||
case EvqTessControlOut:
|
||||
case EvqTessEvaluationOut:
|
||||
*joinedQualifier = EvqNoPerspectiveOut;
|
||||
break;
|
||||
case EvqFragmentIn:
|
||||
case EvqGeometryIn:
|
||||
case EvqTessControlIn:
|
||||
case EvqTessEvaluationIn:
|
||||
*joinedQualifier = EvqNoPerspectiveIn;
|
||||
break;
|
||||
default:
|
||||
|
@ -442,14 +429,10 @@ bool JoinVariableStorageQualifier(TQualifier *joinedQualifier, TQualifier storag
|
|||
{
|
||||
case EvqVertexOut:
|
||||
case EvqGeometryOut:
|
||||
case EvqTessControlOut:
|
||||
case EvqTessEvaluationOut:
|
||||
*joinedQualifier = EvqCentroidOut;
|
||||
break;
|
||||
case EvqFragmentIn:
|
||||
case EvqGeometryIn:
|
||||
case EvqTessControlIn:
|
||||
case EvqTessEvaluationIn:
|
||||
*joinedQualifier = EvqCentroidIn;
|
||||
break;
|
||||
default:
|
||||
|
@ -463,14 +446,10 @@ bool JoinVariableStorageQualifier(TQualifier *joinedQualifier, TQualifier storag
|
|||
{
|
||||
case EvqVertexOut:
|
||||
case EvqGeometryOut:
|
||||
case EvqTessControlOut:
|
||||
case EvqTessEvaluationOut:
|
||||
*joinedQualifier = EvqSampleOut;
|
||||
break;
|
||||
case EvqFragmentIn:
|
||||
case EvqGeometryIn:
|
||||
case EvqTessControlIn:
|
||||
case EvqTessEvaluationIn:
|
||||
*joinedQualifier = EvqSampleIn;
|
||||
break;
|
||||
default:
|
||||
|
@ -478,21 +457,6 @@ bool JoinVariableStorageQualifier(TQualifier *joinedQualifier, TQualifier storag
|
|||
}
|
||||
break;
|
||||
}
|
||||
case EvqPatch:
|
||||
{
|
||||
switch (storageQualifier)
|
||||
{
|
||||
case EvqTessControlOut:
|
||||
*joinedQualifier = EvqPatchOut;
|
||||
break;
|
||||
case EvqTessEvaluationIn:
|
||||
*joinedQualifier = EvqPatchIn;
|
||||
break;
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
break;
|
||||
}
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
|
@ -731,10 +695,6 @@ TLayoutQualifier JoinLayoutQualifiers(TLayoutQualifier leftQualifier,
|
|||
{
|
||||
joinedQualifier.blockStorage = rightQualifier.blockStorage;
|
||||
}
|
||||
if (rightQualifier.noncoherent != false)
|
||||
{
|
||||
joinedQualifier.noncoherent = rightQualifier.noncoherent;
|
||||
}
|
||||
|
||||
for (size_t i = 0u; i < rightQualifier.localSize.size(); ++i)
|
||||
{
|
||||
|
@ -797,48 +757,6 @@ TLayoutQualifier JoinLayoutQualifiers(TLayoutQualifier leftQualifier,
|
|||
joinedQualifier.maxVertices = rightQualifier.maxVertices;
|
||||
}
|
||||
|
||||
if (rightQualifier.tesPrimitiveType != EtetUndefined)
|
||||
{
|
||||
if (joinedQualifier.tesPrimitiveType == EtetUndefined)
|
||||
{
|
||||
joinedQualifier.tesPrimitiveType = rightQualifier.tesPrimitiveType;
|
||||
}
|
||||
}
|
||||
|
||||
if (rightQualifier.tesVertexSpacingType != EtetUndefined)
|
||||
{
|
||||
if (joinedQualifier.tesVertexSpacingType == EtetUndefined)
|
||||
{
|
||||
joinedQualifier.tesVertexSpacingType = rightQualifier.tesVertexSpacingType;
|
||||
}
|
||||
}
|
||||
|
||||
if (rightQualifier.tesOrderingType != EtetUndefined)
|
||||
{
|
||||
if (joinedQualifier.tesOrderingType == EtetUndefined)
|
||||
{
|
||||
joinedQualifier.tesOrderingType = rightQualifier.tesOrderingType;
|
||||
}
|
||||
}
|
||||
|
||||
if (rightQualifier.tesPointType != EtetUndefined)
|
||||
{
|
||||
if (joinedQualifier.tesPointType == EtetUndefined)
|
||||
{
|
||||
joinedQualifier.tesPointType = rightQualifier.tesPointType;
|
||||
}
|
||||
}
|
||||
|
||||
if (rightQualifier.vertices != 0)
|
||||
{
|
||||
if (joinedQualifier.vertices != 0 && joinedQualifier.vertices != rightQualifier.vertices)
|
||||
{
|
||||
diagnostics->error(rightQualifierLocation,
|
||||
"Cannot have multiple different vertices specifiers", "vertices");
|
||||
}
|
||||
joinedQualifier.vertices = rightQualifier.vertices;
|
||||
}
|
||||
|
||||
if (rightQualifier.index != -1)
|
||||
{
|
||||
if (joinedQualifier.index != -1)
|
||||
|
|
|
@ -697,7 +697,7 @@ void ResourcesHLSL::imageMetadataUniforms(TInfoSinkBase &out, unsigned int regIn
|
|||
|
||||
TString ResourcesHLSL::uniformBlocksHeader(
|
||||
const ReferencedInterfaceBlocks &referencedInterfaceBlocks,
|
||||
const std::map<int, const TInterfaceBlock *> &uniformBlockOptimizedMap)
|
||||
const std::map<int, const TInterfaceBlock *> &uniformBlockTranslatedToStructuredBuffer)
|
||||
{
|
||||
TString interfaceBlocks;
|
||||
|
||||
|
@ -712,7 +712,7 @@ TString ResourcesHLSL::uniformBlocksHeader(
|
|||
|
||||
// In order to avoid compile performance issue, translate uniform block to structured
|
||||
// buffer. anglebug.com/3682.
|
||||
if (uniformBlockOptimizedMap.count(interfaceBlock.uniqueId().get()) != 0)
|
||||
if (uniformBlockTranslatedToStructuredBuffer.count(interfaceBlock.uniqueId().get()) != 0)
|
||||
{
|
||||
unsigned int structuredBufferRegister = mSRVRegister;
|
||||
if (instanceVariable != nullptr && instanceVariable->getType().isArray())
|
||||
|
@ -915,8 +915,7 @@ TString ResourcesHLSL::uniformBlockMembersString(const TInterfaceBlock &interfac
|
|||
|
||||
Std140PaddingHelper padHelper = mStructureHLSL->getPaddingHelper();
|
||||
|
||||
const unsigned int fieldCount = static_cast<unsigned int>(interfaceBlock.fields().size());
|
||||
for (unsigned int typeIndex = 0; typeIndex < fieldCount; typeIndex++)
|
||||
for (unsigned int typeIndex = 0; typeIndex < interfaceBlock.fields().size(); typeIndex++)
|
||||
{
|
||||
const TField &field = *interfaceBlock.fields()[typeIndex];
|
||||
const TType &fieldType = *field.type();
|
||||
|
@ -936,8 +935,7 @@ TString ResourcesHLSL::uniformBlockMembersString(const TInterfaceBlock &interfac
|
|||
{
|
||||
const bool useHLSLRowMajorPacking =
|
||||
(fieldType.getLayoutQualifier().matrixPacking == EmpColumnMajor);
|
||||
hlsl += padHelper.postPaddingString(fieldType, useHLSLRowMajorPacking,
|
||||
typeIndex == fieldCount - 1, false);
|
||||
hlsl += padHelper.postPaddingString(fieldType, useHLSLRowMajorPacking, false);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -40,7 +40,7 @@ class ResourcesHLSL : angle::NonCopyable
|
|||
void imageMetadataUniforms(TInfoSinkBase &out, unsigned int regIndex);
|
||||
TString uniformBlocksHeader(
|
||||
const ReferencedInterfaceBlocks &referencedInterfaceBlocks,
|
||||
const std::map<int, const TInterfaceBlock *> &uniformBlockOptimizedMap);
|
||||
const std::map<int, const TInterfaceBlock *> &uniformBlockTranslatedToStructuredBuffer);
|
||||
TString shaderStorageBlocksHeader(const ReferencedInterfaceBlocks &referencedInterfaceBlocks);
|
||||
|
||||
// Used for direct index references
|
||||
|
|
|
@ -13,7 +13,6 @@
|
|||
|
||||
#include "compiler/translator/Compiler.h"
|
||||
#include "compiler/translator/InitializeDll.h"
|
||||
#include "compiler/translator/glslang_wrapper.h"
|
||||
#include "compiler/translator/length_limits.h"
|
||||
#ifdef ANGLE_ENABLE_HLSL
|
||||
# include "compiler/translator/TranslatorHLSL.h"
|
||||
|
@ -27,8 +26,7 @@ namespace sh
|
|||
namespace
|
||||
{
|
||||
|
||||
bool isInitialized = false;
|
||||
bool isGlslangInitialized = false;
|
||||
bool isInitialized = false;
|
||||
|
||||
//
|
||||
// This is the platform independent interface between an OGL driver
|
||||
|
@ -104,36 +102,6 @@ GLenum GetGeometryShaderPrimitiveTypeEnum(sh::TLayoutPrimitiveType primitiveType
|
|||
}
|
||||
}
|
||||
|
||||
GLenum GetTessellationShaderTypeEnum(sh::TLayoutTessEvaluationType type)
|
||||
{
|
||||
switch (type)
|
||||
{
|
||||
case EtetTriangles:
|
||||
return GL_TRIANGLES;
|
||||
case EtetQuads:
|
||||
return GL_QUADS;
|
||||
case EtetIsolines:
|
||||
return GL_ISOLINES;
|
||||
case EtetEqualSpacing:
|
||||
return GL_EQUAL;
|
||||
case EtetFractionalEvenSpacing:
|
||||
return GL_FRACTIONAL_EVEN;
|
||||
case EtetFractionalOddSpacing:
|
||||
return GL_FRACTIONAL_ODD;
|
||||
case EtetCw:
|
||||
return GL_CW;
|
||||
case EtetCcw:
|
||||
return GL_CCW;
|
||||
case EtetPointMode:
|
||||
return GL_TESS_GEN_POINT_MODE;
|
||||
|
||||
case EtetUndefined:
|
||||
default:
|
||||
UNREACHABLE();
|
||||
return GL_INVALID_VALUE;
|
||||
}
|
||||
}
|
||||
|
||||
} // anonymous namespace
|
||||
|
||||
//
|
||||
|
@ -192,7 +160,6 @@ void InitBuiltInResources(ShBuiltInResources *resources)
|
|||
resources->EXT_shader_texture_lod = 0;
|
||||
resources->WEBGL_debug_shader_precision = 0;
|
||||
resources->EXT_shader_framebuffer_fetch = 0;
|
||||
resources->EXT_shader_framebuffer_fetch_non_coherent = 0;
|
||||
resources->NV_shader_framebuffer_fetch = 0;
|
||||
resources->ARM_shader_framebuffer_fetch = 0;
|
||||
resources->OVR_multiview = 0;
|
||||
|
@ -200,8 +167,6 @@ void InitBuiltInResources(ShBuiltInResources *resources)
|
|||
resources->EXT_YUV_target = 0;
|
||||
resources->EXT_geometry_shader = 0;
|
||||
resources->EXT_gpu_shader5 = 0;
|
||||
resources->OES_shader_io_blocks = 0;
|
||||
resources->EXT_shader_io_blocks = 0;
|
||||
resources->EXT_shader_non_constant_global_initializers = 0;
|
||||
resources->NV_shader_noperspective_interpolation = 0;
|
||||
resources->OES_texture_storage_multisample_2d_array = 0;
|
||||
|
@ -217,15 +182,10 @@ void InitBuiltInResources(ShBuiltInResources *resources)
|
|||
resources->OES_shader_multisample_interpolation = 0;
|
||||
resources->NV_draw_buffers = 0;
|
||||
resources->OES_shader_image_atomic = 0;
|
||||
resources->EXT_tessellation_shader = 0;
|
||||
resources->OES_texture_buffer = 0;
|
||||
resources->EXT_texture_buffer = 0;
|
||||
resources->OES_sample_variables = 0;
|
||||
resources->EXT_clip_cull_distance = 0;
|
||||
|
||||
resources->MaxClipDistances = 8;
|
||||
resources->MaxCullDistances = 8;
|
||||
resources->MaxCombinedClipAndCullDistances = 8;
|
||||
resources->MaxClipDistances = 0;
|
||||
|
||||
// Disable highp precision in fragment shader by default.
|
||||
resources->FragmentPrecisionHigh = 0;
|
||||
|
@ -307,30 +267,7 @@ void InitBuiltInResources(ShBuiltInResources *resources)
|
|||
resources->MaxGeometryShaderInvocations = 32;
|
||||
resources->MaxGeometryImageUniforms = 0;
|
||||
|
||||
resources->MaxTessControlInputComponents = 64;
|
||||
resources->MaxTessControlOutputComponents = 64;
|
||||
resources->MaxTessControlTextureImageUnits = 16;
|
||||
resources->MaxTessControlUniformComponents = 1024;
|
||||
resources->MaxTessControlTotalOutputComponents = 2048;
|
||||
resources->MaxTessControlImageUniforms = 0;
|
||||
resources->MaxTessControlAtomicCounters = 0;
|
||||
resources->MaxTessControlAtomicCounterBuffers = 0;
|
||||
|
||||
resources->MaxTessPatchComponents = 120;
|
||||
resources->MaxPatchVertices = 32;
|
||||
resources->MaxTessGenLevel = 64;
|
||||
|
||||
resources->MaxTessEvaluationInputComponents = 64;
|
||||
resources->MaxTessEvaluationOutputComponents = 64;
|
||||
resources->MaxTessEvaluationTextureImageUnits = 16;
|
||||
resources->MaxTessEvaluationUniformComponents = 1024;
|
||||
resources->MaxTessEvaluationImageUniforms = 0;
|
||||
resources->MaxTessEvaluationAtomicCounters = 0;
|
||||
resources->MaxTessEvaluationAtomicCounterBuffers = 0;
|
||||
|
||||
resources->SubPixelBits = 8;
|
||||
|
||||
resources->MaxSamples = 4;
|
||||
}
|
||||
|
||||
//
|
||||
|
@ -444,18 +381,6 @@ const std::string &GetObjectCode(const ShHandle handle)
|
|||
return infoSink.obj.str();
|
||||
}
|
||||
|
||||
//
|
||||
// Return any object binary code.
|
||||
//
|
||||
const BinaryBlob &GetObjectBinaryBlob(const ShHandle handle)
|
||||
{
|
||||
TCompiler *compiler = GetCompilerFromHandle(handle);
|
||||
ASSERT(compiler);
|
||||
|
||||
TInfoSink &infoSink = compiler->getInfoSink();
|
||||
return infoSink.obj.getBinary();
|
||||
}
|
||||
|
||||
const std::map<std::string, std::string> *GetNameHashingMap(const ShHandle handle)
|
||||
{
|
||||
TCompiler *compiler = GetCompilerFromHandle(handle);
|
||||
|
@ -593,16 +518,6 @@ bool HasEarlyFragmentTestsOptimization(const ShHandle handle)
|
|||
return compiler->isEarlyFragmentTestsOptimized();
|
||||
}
|
||||
|
||||
uint32_t GetShaderSpecConstUsageBits(const ShHandle handle)
|
||||
{
|
||||
TCompiler *compiler = GetCompilerFromHandle(handle);
|
||||
if (compiler == nullptr)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
return compiler->getSpecConstUsageBits().bits();
|
||||
}
|
||||
|
||||
bool CheckVariablesWithinPackingLimits(int maxVectors, const std::vector<ShaderVariable> &variables)
|
||||
{
|
||||
return CheckVariablesInPackingLimits(maxVectors, variables);
|
||||
|
@ -677,18 +592,6 @@ const std::map<std::string, unsigned int> *GetUniformRegisterMap(const ShHandle
|
|||
#endif // ANGLE_ENABLE_HLSL
|
||||
}
|
||||
|
||||
const std::set<std::string> *GetSlowCompilingUniformBlockSet(const ShHandle handle)
|
||||
{
|
||||
#ifdef ANGLE_ENABLE_HLSL
|
||||
TranslatorHLSL *translator = GetTranslatorHLSLFromHandle(handle);
|
||||
ASSERT(translator);
|
||||
|
||||
return translator->getSlowCompilingUniformBlockSet();
|
||||
#else
|
||||
return nullptr;
|
||||
#endif // ANGLE_ENABLE_HLSL
|
||||
}
|
||||
|
||||
unsigned int GetReadonlyImage2DRegisterIndex(const ShHandle handle)
|
||||
{
|
||||
#ifdef ANGLE_ENABLE_HLSL
|
||||
|
@ -758,50 +661,6 @@ bool HasValidGeometryShaderMaxVertices(const ShHandle handle)
|
|||
return compiler->getGeometryShaderMaxVertices() >= 0;
|
||||
}
|
||||
|
||||
bool HasValidTessGenMode(const ShHandle handle)
|
||||
{
|
||||
ASSERT(handle);
|
||||
|
||||
TShHandleBase *base = static_cast<TShHandleBase *>(handle);
|
||||
TCompiler *compiler = base->getAsCompiler();
|
||||
ASSERT(compiler);
|
||||
|
||||
return compiler->getTessEvaluationShaderInputPrimitiveType() != EtetUndefined;
|
||||
}
|
||||
|
||||
bool HasValidTessGenSpacing(const ShHandle handle)
|
||||
{
|
||||
ASSERT(handle);
|
||||
|
||||
TShHandleBase *base = static_cast<TShHandleBase *>(handle);
|
||||
TCompiler *compiler = base->getAsCompiler();
|
||||
ASSERT(compiler);
|
||||
|
||||
return compiler->getTessEvaluationShaderInputVertexSpacingType() != EtetUndefined;
|
||||
}
|
||||
|
||||
bool HasValidTessGenVertexOrder(const ShHandle handle)
|
||||
{
|
||||
ASSERT(handle);
|
||||
|
||||
TShHandleBase *base = static_cast<TShHandleBase *>(handle);
|
||||
TCompiler *compiler = base->getAsCompiler();
|
||||
ASSERT(compiler);
|
||||
|
||||
return compiler->getTessEvaluationShaderInputOrderingType() != EtetUndefined;
|
||||
}
|
||||
|
||||
bool HasValidTessGenPointMode(const ShHandle handle)
|
||||
{
|
||||
ASSERT(handle);
|
||||
|
||||
TShHandleBase *base = static_cast<TShHandleBase *>(handle);
|
||||
TCompiler *compiler = base->getAsCompiler();
|
||||
ASSERT(compiler);
|
||||
|
||||
return compiler->getTessEvaluationShaderInputPointType() != EtetUndefined;
|
||||
}
|
||||
|
||||
GLenum GetGeometryShaderInputPrimitiveType(const ShHandle handle)
|
||||
{
|
||||
ASSERT(handle);
|
||||
|
@ -848,62 +707,6 @@ int GetGeometryShaderMaxVertices(const ShHandle handle)
|
|||
return maxVertices;
|
||||
}
|
||||
|
||||
int GetTessControlShaderVertices(const ShHandle handle)
|
||||
{
|
||||
ASSERT(handle);
|
||||
|
||||
TShHandleBase *base = static_cast<TShHandleBase *>(handle);
|
||||
TCompiler *compiler = base->getAsCompiler();
|
||||
ASSERT(compiler);
|
||||
|
||||
int vertices = compiler->getTessControlShaderOutputVertices();
|
||||
return vertices;
|
||||
}
|
||||
|
||||
GLenum GetTessGenMode(const ShHandle handle)
|
||||
{
|
||||
ASSERT(handle);
|
||||
|
||||
TShHandleBase *base = static_cast<TShHandleBase *>(handle);
|
||||
TCompiler *compiler = base->getAsCompiler();
|
||||
ASSERT(compiler);
|
||||
|
||||
return GetTessellationShaderTypeEnum(compiler->getTessEvaluationShaderInputPrimitiveType());
|
||||
}
|
||||
|
||||
GLenum GetTessGenSpacing(const ShHandle handle)
|
||||
{
|
||||
ASSERT(handle);
|
||||
|
||||
TShHandleBase *base = static_cast<TShHandleBase *>(handle);
|
||||
TCompiler *compiler = base->getAsCompiler();
|
||||
ASSERT(compiler);
|
||||
|
||||
return GetTessellationShaderTypeEnum(compiler->getTessEvaluationShaderInputVertexSpacingType());
|
||||
}
|
||||
|
||||
GLenum GetTessGenVertexOrder(const ShHandle handle)
|
||||
{
|
||||
ASSERT(handle);
|
||||
|
||||
TShHandleBase *base = static_cast<TShHandleBase *>(handle);
|
||||
TCompiler *compiler = base->getAsCompiler();
|
||||
ASSERT(compiler);
|
||||
|
||||
return GetTessellationShaderTypeEnum(compiler->getTessEvaluationShaderInputOrderingType());
|
||||
}
|
||||
|
||||
GLenum GetTessGenPointMode(const ShHandle handle)
|
||||
{
|
||||
ASSERT(handle);
|
||||
|
||||
TShHandleBase *base = static_cast<TShHandleBase *>(handle);
|
||||
TCompiler *compiler = base->getAsCompiler();
|
||||
ASSERT(compiler);
|
||||
|
||||
return GetTessellationShaderTypeEnum(compiler->getTessEvaluationShaderInputPointType());
|
||||
}
|
||||
|
||||
unsigned int GetShaderSharedMemorySize(const ShHandle handle)
|
||||
{
|
||||
ASSERT(handle);
|
||||
|
@ -916,24 +719,6 @@ unsigned int GetShaderSharedMemorySize(const ShHandle handle)
|
|||
return sharedMemorySize;
|
||||
}
|
||||
|
||||
void InitializeGlslang()
|
||||
{
|
||||
if (!isGlslangInitialized)
|
||||
{
|
||||
GlslangInitialize();
|
||||
}
|
||||
isGlslangInitialized = true;
|
||||
}
|
||||
|
||||
void FinalizeGlslang()
|
||||
{
|
||||
if (isGlslangInitialized)
|
||||
{
|
||||
GlslangFinalize();
|
||||
}
|
||||
isGlslangInitialized = false;
|
||||
}
|
||||
|
||||
// Can't prefix with just _ because then we might introduce a double underscore, which is not safe
|
||||
// in GLSL (ESSL 3.00.6 section 3.8: All identifiers containing a double underscore are reserved for
|
||||
// use by the underlying implementation). u is short for user-defined.
|
||||
|
@ -958,17 +743,6 @@ const char kAtomicCountersBlockName[] = "ANGLEAtomicCounters";
|
|||
|
||||
const char kLineRasterEmulationPosition[] = "ANGLEPosition";
|
||||
|
||||
const char kXfbEmulationGetOffsetsFunctionName[] = "ANGLEGetXfbOffsets";
|
||||
const char kXfbEmulationCaptureFunctionName[] = "ANGLECaptureXfb";
|
||||
const char kXfbEmulationBufferBlockName[] = "ANGLEXfbBuffer";
|
||||
const char kXfbEmulationBufferName[] = "ANGLEXfb";
|
||||
const char kXfbEmulationBufferFieldName[] = "xfbOut";
|
||||
|
||||
const char kXfbExtensionPositionOutName[] = "ANGLEXfbPosition";
|
||||
|
||||
// EXT_shader_framebuffer_fetch / EXT_shader_framebuffer_fetch_non_coherent
|
||||
const char kInputAttachmentName[] = "ANGLEInputAttachment";
|
||||
|
||||
} // namespace vk
|
||||
|
||||
} // namespace sh
|
||||
|
|
|
@ -27,7 +27,6 @@
|
|||
|
||||
#include "compiler/translator/ResourcesHLSL.h"
|
||||
#include "compiler/translator/blocklayoutHLSL.h"
|
||||
#include "compiler/translator/tree_util/IntermNode_util.h"
|
||||
#include "compiler/translator/util.h"
|
||||
|
||||
namespace sh
|
||||
|
@ -289,23 +288,31 @@ void GetShaderStorageBlockMembersInfo(const TInterfaceBlock *interfaceBlock,
|
|||
TraverseShaderVariables(block->fields, false, &visitor);
|
||||
}
|
||||
|
||||
TIntermTyped *Mul(TIntermTyped *left, TIntermTyped *right)
|
||||
bool IsInArrayOfArraysChain(TIntermTyped *node)
|
||||
{
|
||||
return left && right ? new TIntermBinary(EOpMul, left, right) : nullptr;
|
||||
}
|
||||
if (node->getType().isArrayOfArrays())
|
||||
return true;
|
||||
TIntermBinary *binaryNode = node->getAsBinaryNode();
|
||||
if (binaryNode)
|
||||
{
|
||||
if (binaryNode->getLeft()->getType().isArrayOfArrays())
|
||||
return true;
|
||||
}
|
||||
|
||||
TIntermTyped *Add(TIntermTyped *left, TIntermTyped *right)
|
||||
{
|
||||
return left ? right ? new TIntermBinary(EOpAdd, left, right) : left : right;
|
||||
return false;
|
||||
}
|
||||
|
||||
} // anonymous namespace
|
||||
|
||||
ShaderStorageBlockOutputHLSL::ShaderStorageBlockOutputHLSL(
|
||||
OutputHLSL *outputHLSL,
|
||||
TSymbolTable *symbolTable,
|
||||
ResourcesHLSL *resourcesHLSL,
|
||||
const std::vector<InterfaceBlock> &shaderStorageBlocks)
|
||||
: mOutputHLSL(outputHLSL),
|
||||
: TIntermTraverser(true, true, true, symbolTable),
|
||||
mMatrixStride(0),
|
||||
mRowMajor(false),
|
||||
mLocationAsTheLastArgument(false),
|
||||
mOutputHLSL(outputHLSL),
|
||||
mResourcesHLSL(resourcesHLSL),
|
||||
mShaderStorageBlocks(shaderStorageBlocks)
|
||||
{
|
||||
|
@ -319,24 +326,27 @@ ShaderStorageBlockOutputHLSL::~ShaderStorageBlockOutputHLSL()
|
|||
|
||||
void ShaderStorageBlockOutputHLSL::outputStoreFunctionCallPrefix(TIntermTyped *node)
|
||||
{
|
||||
mLocationAsTheLastArgument = false;
|
||||
traverseSSBOAccess(node, SSBOMethod::STORE);
|
||||
}
|
||||
|
||||
void ShaderStorageBlockOutputHLSL::outputLoadFunctionCall(TIntermTyped *node)
|
||||
{
|
||||
mLocationAsTheLastArgument = true;
|
||||
traverseSSBOAccess(node, SSBOMethod::LOAD);
|
||||
mOutputHLSL->getInfoSink() << ")";
|
||||
}
|
||||
|
||||
void ShaderStorageBlockOutputHLSL::outputLengthFunctionCall(TIntermTyped *node)
|
||||
{
|
||||
mLocationAsTheLastArgument = true;
|
||||
traverseSSBOAccess(node, SSBOMethod::LENGTH);
|
||||
mOutputHLSL->getInfoSink() << ")";
|
||||
}
|
||||
|
||||
void ShaderStorageBlockOutputHLSL::outputAtomicMemoryFunctionCallPrefix(TIntermTyped *node,
|
||||
TOperator op)
|
||||
{
|
||||
mLocationAsTheLastArgument = false;
|
||||
|
||||
switch (op)
|
||||
{
|
||||
case EOpAtomicAdd:
|
||||
|
@ -372,15 +382,15 @@ void ShaderStorageBlockOutputHLSL::outputAtomicMemoryFunctionCallPrefix(TIntermT
|
|||
// Note that we must calculate the matrix stride here instead of ShaderStorageBlockFunctionHLSL.
|
||||
// It's because that if the current node's type is a vector which comes from a matrix, we will
|
||||
// lose the matrix type info once we enter ShaderStorageBlockFunctionHLSL.
|
||||
int ShaderStorageBlockOutputHLSL::getMatrixStride(TIntermTyped *node,
|
||||
TLayoutBlockStorage storage,
|
||||
bool rowMajor,
|
||||
bool *isRowMajorMatrix) const
|
||||
void ShaderStorageBlockOutputHLSL::setMatrixStride(TIntermTyped *node,
|
||||
TLayoutBlockStorage storage,
|
||||
bool rowMajor)
|
||||
{
|
||||
if (node->getType().isMatrix())
|
||||
{
|
||||
*isRowMajorMatrix = rowMajor;
|
||||
return GetBlockMemberInfoByType(node->getType(), storage, rowMajor).matrixStride;
|
||||
mMatrixStride = GetBlockMemberInfoByType(node->getType(), storage, rowMajor).matrixStride;
|
||||
mRowMajor = rowMajor;
|
||||
return;
|
||||
}
|
||||
|
||||
if (node->getType().isVector())
|
||||
|
@ -388,70 +398,23 @@ int ShaderStorageBlockOutputHLSL::getMatrixStride(TIntermTyped *node,
|
|||
TIntermBinary *binaryNode = node->getAsBinaryNode();
|
||||
if (binaryNode)
|
||||
{
|
||||
return getMatrixStride(binaryNode->getLeft(), storage, rowMajor, isRowMajorMatrix);
|
||||
return setMatrixStride(binaryNode->getLeft(), storage, rowMajor);
|
||||
}
|
||||
else
|
||||
{
|
||||
TIntermSwizzle *swizzleNode = node->getAsSwizzleNode();
|
||||
if (swizzleNode)
|
||||
{
|
||||
return getMatrixStride(swizzleNode->getOperand(), storage, rowMajor,
|
||||
isRowMajorMatrix);
|
||||
return setMatrixStride(swizzleNode->getOperand(), storage, rowMajor);
|
||||
}
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
void ShaderStorageBlockOutputHLSL::collectShaderStorageBlocks(TIntermTyped *node)
|
||||
{
|
||||
TIntermSwizzle *swizzleNode = node->getAsSwizzleNode();
|
||||
if (swizzleNode)
|
||||
{
|
||||
return collectShaderStorageBlocks(swizzleNode->getOperand());
|
||||
}
|
||||
|
||||
TIntermBinary *binaryNode = node->getAsBinaryNode();
|
||||
if (binaryNode)
|
||||
{
|
||||
switch (binaryNode->getOp())
|
||||
{
|
||||
case EOpIndexDirectInterfaceBlock:
|
||||
case EOpIndexIndirect:
|
||||
case EOpIndexDirect:
|
||||
case EOpIndexDirectStruct:
|
||||
return collectShaderStorageBlocks(binaryNode->getLeft());
|
||||
default:
|
||||
UNREACHABLE();
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
const TIntermSymbol *symbolNode = node->getAsSymbolNode();
|
||||
const TType &type = symbolNode->getType();
|
||||
ASSERT(type.getQualifier() == EvqBuffer);
|
||||
const TVariable &variable = symbolNode->variable();
|
||||
|
||||
const TInterfaceBlock *interfaceBlock = type.getInterfaceBlock();
|
||||
ASSERT(interfaceBlock);
|
||||
if (mReferencedShaderStorageBlocks.count(interfaceBlock->uniqueId().get()) == 0)
|
||||
{
|
||||
const TVariable *instanceVariable = nullptr;
|
||||
if (type.isInterfaceBlock())
|
||||
{
|
||||
instanceVariable = &variable;
|
||||
}
|
||||
mReferencedShaderStorageBlocks[interfaceBlock->uniqueId().get()] =
|
||||
new TReferencedBlock(interfaceBlock, instanceVariable);
|
||||
GetShaderStorageBlockMembersInfo(interfaceBlock, mShaderStorageBlocks,
|
||||
&mBlockMemberInfoMap);
|
||||
}
|
||||
}
|
||||
|
||||
void ShaderStorageBlockOutputHLSL::traverseSSBOAccess(TIntermTyped *node, SSBOMethod method)
|
||||
{
|
||||
// TODO: Merge collectShaderStorageBlocks and GetBlockLayoutInfo to simplify the code.
|
||||
collectShaderStorageBlocks(node);
|
||||
mMatrixStride = 0;
|
||||
mRowMajor = false;
|
||||
|
||||
// Note that we don't have correct BlockMemberInfo from mBlockMemberInfoMap at the current
|
||||
// point. But we must use those information to generate the right function name. So here we have
|
||||
|
@ -462,45 +425,18 @@ void ShaderStorageBlockOutputHLSL::traverseSSBOAccess(TIntermTyped *node, SSBOMe
|
|||
int unsizedArrayStride = 0;
|
||||
if (node->getType().isUnsizedArray())
|
||||
{
|
||||
// The unsized array member must be the last member of a shader storage block.
|
||||
TIntermBinary *binaryNode = node->getAsBinaryNode();
|
||||
if (binaryNode)
|
||||
{
|
||||
const TInterfaceBlock *interfaceBlock =
|
||||
binaryNode->getLeft()->getType().getInterfaceBlock();
|
||||
ASSERT(interfaceBlock);
|
||||
const TIntermConstantUnion *index = binaryNode->getRight()->getAsConstantUnion();
|
||||
const TField *field = interfaceBlock->fields()[index->getIConst(0)];
|
||||
auto fieldInfoIter = mBlockMemberInfoMap.find(field);
|
||||
ASSERT(fieldInfoIter != mBlockMemberInfoMap.end());
|
||||
unsizedArrayStride = fieldInfoIter->second.arrayStride;
|
||||
}
|
||||
else
|
||||
{
|
||||
const TIntermSymbol *symbolNode = node->getAsSymbolNode();
|
||||
const TVariable &variable = symbolNode->variable();
|
||||
const TInterfaceBlock *interfaceBlock = symbolNode->getType().getInterfaceBlock();
|
||||
ASSERT(interfaceBlock);
|
||||
const TField *field =
|
||||
GetFieldMemberInShaderStorageBlock(interfaceBlock, variable.name());
|
||||
auto fieldInfoIter = mBlockMemberInfoMap.find(field);
|
||||
ASSERT(fieldInfoIter != mBlockMemberInfoMap.end());
|
||||
unsizedArrayStride = fieldInfoIter->second.arrayStride;
|
||||
}
|
||||
unsizedArrayStride =
|
||||
GetBlockMemberInfoByType(node->getType(), storage, rowMajor).arrayStride;
|
||||
}
|
||||
bool isRowMajorMatrix = false;
|
||||
int matrixStride = getMatrixStride(node, storage, rowMajor, &isRowMajorMatrix);
|
||||
setMatrixStride(node, storage, rowMajor);
|
||||
|
||||
const TString &functionName = mSSBOFunctionHLSL->registerShaderStorageBlockFunction(
|
||||
node->getType(), method, storage, isRowMajorMatrix, matrixStride, unsizedArrayStride,
|
||||
node->getType(), method, storage, mRowMajor, mMatrixStride, unsizedArrayStride,
|
||||
node->getAsSwizzleNode());
|
||||
TInfoSinkBase &out = mOutputHLSL->getInfoSink();
|
||||
out << functionName;
|
||||
out << "(";
|
||||
BlockMemberInfo blockMemberInfo;
|
||||
TIntermNode *loc = traverseNode(out, node, &blockMemberInfo);
|
||||
out << ", ";
|
||||
loc->traverse(mOutputHLSL);
|
||||
node->traverse(this);
|
||||
}
|
||||
|
||||
void ShaderStorageBlockOutputHLSL::writeShaderStorageBlocksHeader(TInfoSinkBase &out) const
|
||||
|
@ -509,144 +445,318 @@ void ShaderStorageBlockOutputHLSL::writeShaderStorageBlocksHeader(TInfoSinkBase
|
|||
mSSBOFunctionHLSL->shaderStorageBlockFunctionHeader(out);
|
||||
}
|
||||
|
||||
TIntermTyped *ShaderStorageBlockOutputHLSL::traverseNode(TInfoSinkBase &out,
|
||||
TIntermTyped *node,
|
||||
BlockMemberInfo *blockMemberInfo)
|
||||
// Check if the current node is the end of the SSBO access chain. If true, we should output ')' for
|
||||
// Load method.
|
||||
bool ShaderStorageBlockOutputHLSL::isEndOfSSBOAccessChain()
|
||||
{
|
||||
if (TIntermSymbol *symbolNode = node->getAsSymbolNode())
|
||||
TIntermNode *parent = getParentNode();
|
||||
if (parent)
|
||||
{
|
||||
const TVariable &variable = symbolNode->variable();
|
||||
const TType &type = variable.getType();
|
||||
if (type.isInterfaceBlock())
|
||||
TIntermBinary *parentBinary = parent->getAsBinaryNode();
|
||||
if (parentBinary != nullptr)
|
||||
{
|
||||
switch (parentBinary->getOp())
|
||||
{
|
||||
case EOpIndexDirectStruct:
|
||||
case EOpIndexDirect:
|
||||
case EOpIndexIndirect:
|
||||
{
|
||||
return false;
|
||||
}
|
||||
default:
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
const TIntermSwizzle *parentSwizzle = parent->getAsSwizzleNode();
|
||||
if (parentSwizzle)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
void ShaderStorageBlockOutputHLSL::visitSymbol(TIntermSymbol *node)
|
||||
{
|
||||
TInfoSinkBase &out = mOutputHLSL->getInfoSink();
|
||||
const TVariable &variable = node->variable();
|
||||
TQualifier qualifier = variable.getType().getQualifier();
|
||||
|
||||
if (qualifier == EvqBuffer)
|
||||
{
|
||||
const TType &variableType = variable.getType();
|
||||
const TInterfaceBlock *interfaceBlock = variableType.getInterfaceBlock();
|
||||
ASSERT(interfaceBlock);
|
||||
if (mReferencedShaderStorageBlocks.count(interfaceBlock->uniqueId().get()) == 0)
|
||||
{
|
||||
const TVariable *instanceVariable = nullptr;
|
||||
if (variableType.isInterfaceBlock())
|
||||
{
|
||||
instanceVariable = &variable;
|
||||
}
|
||||
mReferencedShaderStorageBlocks[interfaceBlock->uniqueId().get()] =
|
||||
new TReferencedBlock(interfaceBlock, instanceVariable);
|
||||
GetShaderStorageBlockMembersInfo(interfaceBlock, mShaderStorageBlocks,
|
||||
&mBlockMemberInfoMap);
|
||||
}
|
||||
if (variableType.isInterfaceBlock())
|
||||
{
|
||||
out << DecorateVariableIfNeeded(variable);
|
||||
}
|
||||
else
|
||||
{
|
||||
const TInterfaceBlock *interfaceBlock = type.getInterfaceBlock();
|
||||
out << Decorate(interfaceBlock->name());
|
||||
out << ", ";
|
||||
|
||||
const TField *field =
|
||||
GetFieldMemberInShaderStorageBlock(interfaceBlock, variable.name());
|
||||
return createFieldOffset(field, blockMemberInfo);
|
||||
writeDotOperatorOutput(out, field);
|
||||
}
|
||||
}
|
||||
else if (TIntermSwizzle *swizzleNode = node->getAsSwizzleNode())
|
||||
else
|
||||
{
|
||||
return traverseNode(out, swizzleNode->getOperand(), blockMemberInfo);
|
||||
return mOutputHLSL->visitSymbol(node);
|
||||
}
|
||||
else if (TIntermBinary *binaryNode = node->getAsBinaryNode())
|
||||
}
|
||||
|
||||
void ShaderStorageBlockOutputHLSL::visitConstantUnion(TIntermConstantUnion *node)
|
||||
{
|
||||
mOutputHLSL->visitConstantUnion(node);
|
||||
}
|
||||
|
||||
bool ShaderStorageBlockOutputHLSL::visitAggregate(Visit visit, TIntermAggregate *node)
|
||||
{
|
||||
return mOutputHLSL->visitAggregate(visit, node);
|
||||
}
|
||||
|
||||
bool ShaderStorageBlockOutputHLSL::visitTernary(Visit visit, TIntermTernary *node)
|
||||
{
|
||||
return mOutputHLSL->visitTernary(visit, node);
|
||||
}
|
||||
|
||||
bool ShaderStorageBlockOutputHLSL::visitUnary(Visit visit, TIntermUnary *node)
|
||||
{
|
||||
return mOutputHLSL->visitUnary(visit, node);
|
||||
}
|
||||
|
||||
bool ShaderStorageBlockOutputHLSL::visitSwizzle(Visit visit, TIntermSwizzle *node)
|
||||
{
|
||||
if (visit == PostVisit)
|
||||
{
|
||||
switch (binaryNode->getOp())
|
||||
if (!IsInShaderStorageBlock(node))
|
||||
{
|
||||
case EOpIndexDirect:
|
||||
return mOutputHLSL->visitSwizzle(visit, node);
|
||||
}
|
||||
|
||||
TInfoSinkBase &out = mOutputHLSL->getInfoSink();
|
||||
// TODO(jiajia.qin@intel.com): add swizzle process if the swizzle node is not the last node
|
||||
// of ssbo access chain. Such as, data.xy[0]
|
||||
if (mLocationAsTheLastArgument && isEndOfSSBOAccessChain())
|
||||
{
|
||||
out << ")";
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
bool ShaderStorageBlockOutputHLSL::visitBinary(Visit visit, TIntermBinary *node)
|
||||
{
|
||||
TInfoSinkBase &out = mOutputHLSL->getInfoSink();
|
||||
|
||||
switch (node->getOp())
|
||||
{
|
||||
case EOpIndexDirect:
|
||||
{
|
||||
if (!IsInShaderStorageBlock(node->getLeft()))
|
||||
{
|
||||
const TType &leftType = binaryNode->getLeft()->getType();
|
||||
if (leftType.isInterfaceBlock())
|
||||
return mOutputHLSL->visitBinary(visit, node);
|
||||
}
|
||||
|
||||
const TType &leftType = node->getLeft()->getType();
|
||||
if (leftType.isInterfaceBlock())
|
||||
{
|
||||
if (visit == PreVisit)
|
||||
{
|
||||
ASSERT(leftType.getQualifier() == EvqBuffer);
|
||||
TIntermSymbol *instanceArraySymbol = binaryNode->getLeft()->getAsSymbolNode();
|
||||
TIntermSymbol *instanceArraySymbol = node->getLeft()->getAsSymbolNode();
|
||||
const TInterfaceBlock *interfaceBlock = leftType.getInterfaceBlock();
|
||||
|
||||
const int arrayIndex =
|
||||
binaryNode->getRight()->getAsConstantUnion()->getIConst(0);
|
||||
if (mReferencedShaderStorageBlocks.count(interfaceBlock->uniqueId().get()) == 0)
|
||||
{
|
||||
mReferencedShaderStorageBlocks[interfaceBlock->uniqueId().get()] =
|
||||
new TReferencedBlock(interfaceBlock, &instanceArraySymbol->variable());
|
||||
GetShaderStorageBlockMembersInfo(interfaceBlock, mShaderStorageBlocks,
|
||||
&mBlockMemberInfoMap);
|
||||
}
|
||||
|
||||
const int arrayIndex = node->getRight()->getAsConstantUnion()->getIConst(0);
|
||||
out << mResourcesHLSL->InterfaceBlockInstanceString(
|
||||
instanceArraySymbol->getName(), arrayIndex);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
writeEOpIndexDirectOrIndirectOutput(out, visit, node);
|
||||
}
|
||||
break;
|
||||
}
|
||||
case EOpIndexIndirect:
|
||||
{
|
||||
if (!IsInShaderStorageBlock(node->getLeft()))
|
||||
{
|
||||
return mOutputHLSL->visitBinary(visit, node);
|
||||
}
|
||||
|
||||
// We do not currently support indirect references to interface blocks
|
||||
ASSERT(node->getLeft()->getBasicType() != EbtInterfaceBlock);
|
||||
writeEOpIndexDirectOrIndirectOutput(out, visit, node);
|
||||
break;
|
||||
}
|
||||
case EOpIndexDirectStruct:
|
||||
{
|
||||
if (!IsInShaderStorageBlock(node->getLeft()))
|
||||
{
|
||||
return mOutputHLSL->visitBinary(visit, node);
|
||||
}
|
||||
|
||||
if (visit == InVisit)
|
||||
{
|
||||
ASSERT(IsInShaderStorageBlock(node->getLeft()));
|
||||
const TStructure *structure = node->getLeft()->getType().getStruct();
|
||||
const TIntermConstantUnion *index = node->getRight()->getAsConstantUnion();
|
||||
const TField *field = structure->fields()[index->getIConst(0)];
|
||||
out << " + ";
|
||||
writeDotOperatorOutput(out, field);
|
||||
return false;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case EOpIndexDirectInterfaceBlock:
|
||||
if (!IsInShaderStorageBlock(node->getLeft()))
|
||||
{
|
||||
return mOutputHLSL->visitBinary(visit, node);
|
||||
}
|
||||
|
||||
if (visit == InVisit)
|
||||
{
|
||||
ASSERT(IsInShaderStorageBlock(node->getLeft()));
|
||||
out << ", ";
|
||||
const TInterfaceBlock *interfaceBlock =
|
||||
node->getLeft()->getType().getInterfaceBlock();
|
||||
const TIntermConstantUnion *index = node->getRight()->getAsConstantUnion();
|
||||
const TField *field = interfaceBlock->fields()[index->getIConst(0)];
|
||||
writeDotOperatorOutput(out, field);
|
||||
return false;
|
||||
}
|
||||
break;
|
||||
default:
|
||||
// It may have other operators in EOpIndexIndirect. Such as buffer.attribs[(y * gridSize
|
||||
// + x) * 6u + 0u]
|
||||
return mOutputHLSL->visitBinary(visit, node);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void ShaderStorageBlockOutputHLSL::writeEOpIndexDirectOrIndirectOutput(TInfoSinkBase &out,
|
||||
Visit visit,
|
||||
TIntermBinary *node)
|
||||
{
|
||||
ASSERT(IsInShaderStorageBlock(node->getLeft()));
|
||||
if (visit == InVisit)
|
||||
{
|
||||
const TType &type = node->getLeft()->getType();
|
||||
// For array of arrays, we calculate the offset using the formula below:
|
||||
// elementStride * (a3 * a2 * a1 * i0 + a3 * a2 * i1 + a3 * i2 + i3)
|
||||
// Note: assume that there are 4 dimensions.
|
||||
// a0, a1, a2, a3 is the size of the array in each dimension. (S s[a0][a1][a2][a3])
|
||||
// i0, i1, i2, i3 is the index of the array in each dimension. (s[i0][i1][i2][i3])
|
||||
if (IsInArrayOfArraysChain(node->getLeft()))
|
||||
{
|
||||
if (type.isArrayOfArrays())
|
||||
{
|
||||
const TSpan<const unsigned int> &arraySizes = type.getArraySizes();
|
||||
// Don't need to concern the tail comma which will be used to multiply the index.
|
||||
for (unsigned int i = 0; i < (arraySizes.size() - 1); i++)
|
||||
{
|
||||
out << arraySizes[i];
|
||||
out << " * ";
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (node->getType().isVector() && type.isMatrix())
|
||||
{
|
||||
if (mRowMajor)
|
||||
{
|
||||
out << " + " << str(BlockLayoutEncoder::kBytesPerComponent);
|
||||
}
|
||||
else
|
||||
{
|
||||
return writeEOpIndexDirectOrIndirectOutput(out, binaryNode, blockMemberInfo);
|
||||
out << " + " << str(mMatrixStride);
|
||||
}
|
||||
break;
|
||||
}
|
||||
case EOpIndexIndirect:
|
||||
else if (node->getType().isScalar() && !type.isArray())
|
||||
{
|
||||
// We do not currently support indirect references to interface blocks
|
||||
ASSERT(binaryNode->getLeft()->getBasicType() != EbtInterfaceBlock);
|
||||
return writeEOpIndexDirectOrIndirectOutput(out, binaryNode, blockMemberInfo);
|
||||
break;
|
||||
if (mRowMajor)
|
||||
{
|
||||
out << " + " << str(mMatrixStride);
|
||||
}
|
||||
else
|
||||
{
|
||||
out << " + " << str(BlockLayoutEncoder::kBytesPerComponent);
|
||||
}
|
||||
}
|
||||
case EOpIndexDirectStruct:
|
||||
{
|
||||
// We do not currently support direct references to interface blocks
|
||||
ASSERT(binaryNode->getLeft()->getBasicType() != EbtInterfaceBlock);
|
||||
TIntermTyped *left = traverseNode(out, binaryNode->getLeft(), blockMemberInfo);
|
||||
const TStructure *structure = binaryNode->getLeft()->getType().getStruct();
|
||||
const TIntermConstantUnion *index = binaryNode->getRight()->getAsConstantUnion();
|
||||
const TField *field = structure->fields()[index->getIConst(0)];
|
||||
return Add(createFieldOffset(field, blockMemberInfo), left);
|
||||
break;
|
||||
}
|
||||
case EOpIndexDirectInterfaceBlock:
|
||||
{
|
||||
ASSERT(IsInShaderStorageBlock(binaryNode->getLeft()));
|
||||
traverseNode(out, binaryNode->getLeft(), blockMemberInfo);
|
||||
const TInterfaceBlock *interfaceBlock =
|
||||
binaryNode->getLeft()->getType().getInterfaceBlock();
|
||||
const TIntermConstantUnion *index = binaryNode->getRight()->getAsConstantUnion();
|
||||
const TField *field = interfaceBlock->fields()[index->getIConst(0)];
|
||||
return createFieldOffset(field, blockMemberInfo);
|
||||
break;
|
||||
}
|
||||
default:
|
||||
return nullptr;
|
||||
|
||||
out << " * ";
|
||||
}
|
||||
}
|
||||
else if (visit == PostVisit)
|
||||
{
|
||||
// This is used to output the '+' in the array of arrays formula in above.
|
||||
if (node->getType().isArray() && !isEndOfSSBOAccessChain())
|
||||
{
|
||||
out << " + ";
|
||||
}
|
||||
// This corresponds to '(' in writeDotOperatorOutput when fieldType.isArrayOfArrays() is
|
||||
// true.
|
||||
if (IsInArrayOfArraysChain(node->getLeft()) && !node->getType().isArray())
|
||||
{
|
||||
out << ")";
|
||||
}
|
||||
if (mLocationAsTheLastArgument && isEndOfSSBOAccessChain())
|
||||
{
|
||||
out << ")";
|
||||
}
|
||||
}
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
TIntermTyped *ShaderStorageBlockOutputHLSL::writeEOpIndexDirectOrIndirectOutput(
|
||||
TInfoSinkBase &out,
|
||||
TIntermBinary *node,
|
||||
BlockMemberInfo *blockMemberInfo)
|
||||
{
|
||||
ASSERT(IsInShaderStorageBlock(node->getLeft()));
|
||||
TIntermTyped *left = traverseNode(out, node->getLeft(), blockMemberInfo);
|
||||
TIntermTyped *right = node->getRight()->deepCopy();
|
||||
const TType &type = node->getLeft()->getType();
|
||||
TLayoutBlockStorage storage;
|
||||
bool rowMajor;
|
||||
GetBlockLayoutInfo(node, false, &storage, &rowMajor);
|
||||
|
||||
if (type.isArray())
|
||||
{
|
||||
const TSpan<const unsigned int> &arraySizes = type.getArraySizes();
|
||||
for (unsigned int i = 0; i < arraySizes.size() - 1; i++)
|
||||
{
|
||||
right = Mul(CreateUIntNode(arraySizes[i]), right);
|
||||
}
|
||||
right = Mul(CreateUIntNode(blockMemberInfo->arrayStride), right);
|
||||
}
|
||||
else if (type.isMatrix())
|
||||
{
|
||||
if (rowMajor)
|
||||
{
|
||||
right = Mul(CreateUIntNode(BlockLayoutEncoder::kBytesPerComponent), right);
|
||||
}
|
||||
else
|
||||
{
|
||||
right = Mul(CreateUIntNode(blockMemberInfo->matrixStride), right);
|
||||
}
|
||||
}
|
||||
else if (type.isVector())
|
||||
{
|
||||
if (blockMemberInfo->isRowMajorMatrix)
|
||||
{
|
||||
right = Mul(CreateUIntNode(blockMemberInfo->matrixStride), right);
|
||||
}
|
||||
else
|
||||
{
|
||||
right = Mul(CreateUIntNode(BlockLayoutEncoder::kBytesPerComponent), right);
|
||||
}
|
||||
}
|
||||
return Add(left, right);
|
||||
}
|
||||
|
||||
TIntermTyped *ShaderStorageBlockOutputHLSL::createFieldOffset(const TField *field,
|
||||
BlockMemberInfo *blockMemberInfo)
|
||||
void ShaderStorageBlockOutputHLSL::writeDotOperatorOutput(TInfoSinkBase &out, const TField *field)
|
||||
{
|
||||
auto fieldInfoIter = mBlockMemberInfoMap.find(field);
|
||||
ASSERT(fieldInfoIter != mBlockMemberInfoMap.end());
|
||||
*blockMemberInfo = fieldInfoIter->second;
|
||||
return CreateUIntNode(blockMemberInfo->offset);
|
||||
const BlockMemberInfo &memberInfo = fieldInfoIter->second;
|
||||
mMatrixStride = memberInfo.matrixStride;
|
||||
mRowMajor = memberInfo.isRowMajorMatrix;
|
||||
out << memberInfo.offset;
|
||||
|
||||
const TType &fieldType = *field->type();
|
||||
if (fieldType.isArray() && !isEndOfSSBOAccessChain())
|
||||
{
|
||||
out << " + ";
|
||||
out << memberInfo.arrayStride;
|
||||
if (fieldType.isArrayOfArrays())
|
||||
{
|
||||
out << " * (";
|
||||
}
|
||||
}
|
||||
if (mLocationAsTheLastArgument && isEndOfSSBOAccessChain())
|
||||
{
|
||||
out << ")";
|
||||
}
|
||||
}
|
||||
|
||||
} // namespace sh
|
||||
|
|
|
@ -10,9 +10,9 @@
|
|||
#ifndef COMPILER_TRANSLATOR_SHADERSTORAGEBLOCKOUTPUTHLSL_H_
|
||||
#define COMPILER_TRANSLATOR_SHADERSTORAGEBLOCKOUTPUTHLSL_H_
|
||||
|
||||
#include "compiler/translator/IntermNode.h"
|
||||
#include "compiler/translator/ShaderStorageBlockFunctionHLSL.h"
|
||||
#include "compiler/translator/blocklayout.h"
|
||||
#include "compiler/translator/tree_util/IntermTraverse.h"
|
||||
|
||||
namespace sh
|
||||
{
|
||||
|
@ -36,14 +36,15 @@ using BlockMemberInfoMap = std::map<const TField *, BlockMemberInfo>;
|
|||
|
||||
using ShaderVarToFieldMap = std::map<std::string, const TField *>;
|
||||
|
||||
class ShaderStorageBlockOutputHLSL
|
||||
class ShaderStorageBlockOutputHLSL : public TIntermTraverser
|
||||
{
|
||||
public:
|
||||
ShaderStorageBlockOutputHLSL(OutputHLSL *outputHLSL,
|
||||
TSymbolTable *symbolTable,
|
||||
ResourcesHLSL *resourcesHLSL,
|
||||
const std::vector<InterfaceBlock> &shaderStorageBlocks);
|
||||
|
||||
~ShaderStorageBlockOutputHLSL();
|
||||
~ShaderStorageBlockOutputHLSL() override;
|
||||
|
||||
// This writes part of the function call to store a value to a SSBO to the output stream. After
|
||||
// calling this, ", <stored value>)" should be written to the output stream to complete the
|
||||
|
@ -58,21 +59,26 @@ class ShaderStorageBlockOutputHLSL
|
|||
|
||||
void writeShaderStorageBlocksHeader(TInfoSinkBase &out) const;
|
||||
|
||||
protected:
|
||||
void visitSymbol(TIntermSymbol *) override;
|
||||
void visitConstantUnion(TIntermConstantUnion *) override;
|
||||
bool visitSwizzle(Visit visit, TIntermSwizzle *node) override;
|
||||
bool visitBinary(Visit visit, TIntermBinary *) override;
|
||||
bool visitAggregate(Visit visit, TIntermAggregate *node) override;
|
||||
bool visitTernary(Visit visit, TIntermTernary *) override;
|
||||
bool visitUnary(Visit visit, TIntermUnary *) override;
|
||||
|
||||
private:
|
||||
void traverseSSBOAccess(TIntermTyped *node, SSBOMethod method);
|
||||
TIntermTyped *traverseNode(TInfoSinkBase &out,
|
||||
TIntermTyped *node,
|
||||
BlockMemberInfo *blockMemberInfo);
|
||||
int getMatrixStride(TIntermTyped *node,
|
||||
TLayoutBlockStorage storage,
|
||||
bool rowMajor,
|
||||
bool *isRowMajor) const;
|
||||
TIntermTyped *writeEOpIndexDirectOrIndirectOutput(TInfoSinkBase &out,
|
||||
TIntermBinary *node,
|
||||
BlockMemberInfo *blockMemberInfo);
|
||||
void setMatrixStride(TIntermTyped *node, TLayoutBlockStorage storage, bool rowMajor);
|
||||
bool isEndOfSSBOAccessChain();
|
||||
void writeEOpIndexDirectOrIndirectOutput(TInfoSinkBase &out, Visit visit, TIntermBinary *node);
|
||||
// Common part in dot operations.
|
||||
TIntermTyped *createFieldOffset(const TField *field, BlockMemberInfo *blockMemberInfo);
|
||||
void collectShaderStorageBlocks(TIntermTyped *node);
|
||||
void writeDotOperatorOutput(TInfoSinkBase &out, const TField *field);
|
||||
|
||||
int mMatrixStride;
|
||||
bool mRowMajor;
|
||||
bool mLocationAsTheLastArgument;
|
||||
OutputHLSL *mOutputHLSL;
|
||||
ShaderStorageBlockFunctionHLSL *mSSBOFunctionHLSL;
|
||||
ResourcesHLSL *mResourcesHLSL;
|
||||
|
|
|
@ -40,19 +40,14 @@ ShaderVariable::ShaderVariable(GLenum typeIn)
|
|||
active(false),
|
||||
isRowMajorLayout(false),
|
||||
location(-1),
|
||||
hasImplicitLocation(false),
|
||||
binding(-1),
|
||||
imageUnitFormat(GL_NONE),
|
||||
offset(-1),
|
||||
readonly(false),
|
||||
writeonly(false),
|
||||
isFragmentInOut(false),
|
||||
index(-1),
|
||||
yuv(false),
|
||||
interpolation(INTERPOLATION_SMOOTH),
|
||||
isInvariant(false),
|
||||
isShaderIOBlock(false),
|
||||
isPatch(false),
|
||||
texelFetchStaticUse(false),
|
||||
flattenedOffsetInParentArrays(-1)
|
||||
{}
|
||||
|
@ -74,23 +69,17 @@ ShaderVariable::ShaderVariable(const ShaderVariable &other)
|
|||
staticUse(other.staticUse),
|
||||
active(other.active),
|
||||
fields(other.fields),
|
||||
structOrBlockName(other.structOrBlockName),
|
||||
mappedStructOrBlockName(other.mappedStructOrBlockName),
|
||||
structName(other.structName),
|
||||
isRowMajorLayout(other.isRowMajorLayout),
|
||||
location(other.location),
|
||||
hasImplicitLocation(other.hasImplicitLocation),
|
||||
binding(other.binding),
|
||||
imageUnitFormat(other.imageUnitFormat),
|
||||
offset(other.offset),
|
||||
readonly(other.readonly),
|
||||
writeonly(other.writeonly),
|
||||
isFragmentInOut(other.isFragmentInOut),
|
||||
index(other.index),
|
||||
yuv(other.yuv),
|
||||
interpolation(other.interpolation),
|
||||
isInvariant(other.isInvariant),
|
||||
isShaderIOBlock(other.isShaderIOBlock),
|
||||
isPatch(other.isPatch),
|
||||
texelFetchStaticUse(other.texelFetchStaticUse),
|
||||
flattenedOffsetInParentArrays(other.flattenedOffsetInParentArrays)
|
||||
{}
|
||||
|
@ -105,24 +94,18 @@ ShaderVariable &ShaderVariable::operator=(const ShaderVariable &other)
|
|||
staticUse = other.staticUse;
|
||||
active = other.active;
|
||||
fields = other.fields;
|
||||
structOrBlockName = other.structOrBlockName;
|
||||
mappedStructOrBlockName = other.mappedStructOrBlockName;
|
||||
structName = other.structName;
|
||||
isRowMajorLayout = other.isRowMajorLayout;
|
||||
flattenedOffsetInParentArrays = other.flattenedOffsetInParentArrays;
|
||||
location = other.location;
|
||||
hasImplicitLocation = other.hasImplicitLocation;
|
||||
binding = other.binding;
|
||||
imageUnitFormat = other.imageUnitFormat;
|
||||
offset = other.offset;
|
||||
readonly = other.readonly;
|
||||
writeonly = other.writeonly;
|
||||
isFragmentInOut = other.isFragmentInOut;
|
||||
index = other.index;
|
||||
yuv = other.yuv;
|
||||
interpolation = other.interpolation;
|
||||
isInvariant = other.isInvariant;
|
||||
isShaderIOBlock = other.isShaderIOBlock;
|
||||
isPatch = other.isPatch;
|
||||
texelFetchStaticUse = other.texelFetchStaticUse;
|
||||
return *this;
|
||||
}
|
||||
|
@ -132,16 +115,12 @@ bool ShaderVariable::operator==(const ShaderVariable &other) const
|
|||
if (type != other.type || precision != other.precision || name != other.name ||
|
||||
mappedName != other.mappedName || arraySizes != other.arraySizes ||
|
||||
staticUse != other.staticUse || active != other.active ||
|
||||
fields.size() != other.fields.size() || structOrBlockName != other.structOrBlockName ||
|
||||
mappedStructOrBlockName != other.mappedStructOrBlockName ||
|
||||
fields.size() != other.fields.size() || structName != other.structName ||
|
||||
isRowMajorLayout != other.isRowMajorLayout || location != other.location ||
|
||||
hasImplicitLocation != other.hasImplicitLocation || binding != other.binding ||
|
||||
imageUnitFormat != other.imageUnitFormat || offset != other.offset ||
|
||||
readonly != other.readonly || writeonly != other.writeonly || index != other.index ||
|
||||
yuv != other.yuv || interpolation != other.interpolation ||
|
||||
isInvariant != other.isInvariant || isShaderIOBlock != other.isShaderIOBlock ||
|
||||
isPatch != other.isPatch || texelFetchStaticUse != other.texelFetchStaticUse ||
|
||||
isFragmentInOut != other.isFragmentInOut)
|
||||
binding != other.binding || imageUnitFormat != other.imageUnitFormat ||
|
||||
offset != other.offset || readonly != other.readonly || writeonly != other.writeonly ||
|
||||
index != other.index || interpolation != other.interpolation ||
|
||||
isInvariant != other.isInvariant || texelFetchStaticUse != other.texelFetchStaticUse)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
@ -314,28 +293,16 @@ const sh::ShaderVariable *ShaderVariable::findField(const std::string &fullName,
|
|||
return nullptr;
|
||||
}
|
||||
size_t pos = fullName.find_first_of(".");
|
||||
std::string topName, fieldName;
|
||||
if (pos == std::string::npos)
|
||||
{
|
||||
// If this is a shader I/O block without an instance name, return the field given only the
|
||||
// field name.
|
||||
if (!isShaderIOBlock || !name.empty())
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
fieldName = fullName;
|
||||
return nullptr;
|
||||
}
|
||||
else
|
||||
std::string topName = fullName.substr(0, pos);
|
||||
if (topName != name)
|
||||
{
|
||||
std::string baseName = isShaderIOBlock ? structOrBlockName : name;
|
||||
topName = fullName.substr(0, pos);
|
||||
if (topName != baseName)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
fieldName = fullName.substr(pos + 1);
|
||||
return nullptr;
|
||||
}
|
||||
std::string fieldName = fullName.substr(pos + 1);
|
||||
if (fieldName.empty())
|
||||
{
|
||||
return nullptr;
|
||||
|
@ -353,7 +320,7 @@ const sh::ShaderVariable *ShaderVariable::findField(const std::string &fullName,
|
|||
|
||||
bool ShaderVariable::isBuiltIn() const
|
||||
{
|
||||
return gl::IsBuiltInName(name);
|
||||
return (name.size() >= 4 && name[0] == 'g' && name[1] == 'l' && name[2] == '_');
|
||||
}
|
||||
|
||||
bool ShaderVariable::isEmulatedBuiltIn() const
|
||||
|
@ -389,28 +356,11 @@ bool ShaderVariable::isSameVariableAtLinkTime(const ShaderVariable &other,
|
|||
return false;
|
||||
}
|
||||
}
|
||||
if (structOrBlockName != other.structOrBlockName ||
|
||||
mappedStructOrBlockName != other.mappedStructOrBlockName)
|
||||
if (structName != other.structName)
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
void ShaderVariable::updateEffectiveLocation(const sh::ShaderVariable &parent)
|
||||
{
|
||||
if ((location < 0 || hasImplicitLocation) && !parent.hasImplicitLocation)
|
||||
{
|
||||
location = parent.location;
|
||||
}
|
||||
}
|
||||
|
||||
void ShaderVariable::resetEffectiveLocation()
|
||||
{
|
||||
if (hasImplicitLocation)
|
||||
{
|
||||
location = -1;
|
||||
}
|
||||
}
|
||||
|
||||
bool ShaderVariable::isSameUniformAtLinkTime(const ShaderVariable &other) const
|
||||
{
|
||||
// Enforce a consistent match.
|
||||
|
@ -450,28 +400,11 @@ bool ShaderVariable::isSameVaryingAtLinkTime(const ShaderVariable &other) const
|
|||
|
||||
bool ShaderVariable::isSameVaryingAtLinkTime(const ShaderVariable &other, int shaderVersion) const
|
||||
{
|
||||
return ShaderVariable::isSameVariableAtLinkTime(other, false, false) &&
|
||||
InterpolationTypesMatch(interpolation, other.interpolation) &&
|
||||
(shaderVersion >= 300 || isInvariant == other.isInvariant) &&
|
||||
(isPatch == other.isPatch) && location == other.location &&
|
||||
(isSameNameAtLinkTime(other) || (shaderVersion >= 310 && location >= 0));
|
||||
}
|
||||
|
||||
bool ShaderVariable::isSameNameAtLinkTime(const ShaderVariable &other) const
|
||||
{
|
||||
if (isShaderIOBlock != other.isShaderIOBlock)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
if (isShaderIOBlock)
|
||||
{
|
||||
// Shader I/O blocks match by block name.
|
||||
return structOrBlockName == other.structOrBlockName;
|
||||
}
|
||||
|
||||
// Otherwise match by name.
|
||||
return name == other.name;
|
||||
return (ShaderVariable::isSameVariableAtLinkTime(other, false, false) &&
|
||||
InterpolationTypesMatch(interpolation, other.interpolation) &&
|
||||
(shaderVersion >= 300 || isInvariant == other.isInvariant) &&
|
||||
(location == other.location) &&
|
||||
(name == other.name || (shaderVersion >= 310 && location >= 0)));
|
||||
}
|
||||
|
||||
InterfaceBlock::InterfaceBlock()
|
||||
|
@ -549,7 +482,7 @@ bool InterfaceBlock::isSameInterfaceBlockAtLinkTime(const InterfaceBlock &other)
|
|||
|
||||
bool InterfaceBlock::isBuiltIn() const
|
||||
{
|
||||
return gl::IsBuiltInName(name);
|
||||
return (name.size() >= 4 && name[0] == 'g' && name[1] == 'l' && name[2] == '_');
|
||||
}
|
||||
|
||||
void WorkGroupSize::fill(int fillValue)
|
||||
|
|
|
@ -62,7 +62,7 @@ TString Define(const TStructure &structure,
|
|||
if (padHelper)
|
||||
{
|
||||
string += padHelper->postPaddingString(fieldType, useHLSLRowMajorPacking,
|
||||
memberSize == 0, forcePadding);
|
||||
memberSize == 0 && forcePadding);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -92,12 +92,6 @@ TString WriteParameterList(const std::vector<TType> ¶meters)
|
|||
return parameterList;
|
||||
}
|
||||
|
||||
int GetElementPadding(int elementIndex, int alignment)
|
||||
{
|
||||
const int paddingOffset = elementIndex % alignment;
|
||||
return paddingOffset != 0 ? (alignment - paddingOffset) : 0;
|
||||
}
|
||||
|
||||
} // anonymous namespace
|
||||
|
||||
Std140PaddingHelper::Std140PaddingHelper(const std::map<TString, int> &structElementIndexes,
|
||||
|
@ -129,19 +123,9 @@ int Std140PaddingHelper::prePadding(const TType &type, bool forcePadding)
|
|||
{
|
||||
if (type.getBasicType() == EbtStruct || type.isMatrix() || type.isArray())
|
||||
{
|
||||
if (forcePadding)
|
||||
{
|
||||
// Add padding between the structure's members to follow the std140 rules manually.
|
||||
const int forcePaddingCount = GetElementPadding(mElementIndex, 4);
|
||||
mElementIndex = 0;
|
||||
return forcePaddingCount;
|
||||
}
|
||||
else
|
||||
{
|
||||
// no padding needed, HLSL will align the field to a new register
|
||||
mElementIndex = 0;
|
||||
return 0;
|
||||
}
|
||||
// no padding needed, HLSL will align the field to a new register
|
||||
mElementIndex = 0;
|
||||
return 0;
|
||||
}
|
||||
|
||||
const GLenum glType = GLVariableType(type);
|
||||
|
@ -149,27 +133,18 @@ int Std140PaddingHelper::prePadding(const TType &type, bool forcePadding)
|
|||
|
||||
if (numComponents >= 4)
|
||||
{
|
||||
if (forcePadding)
|
||||
{
|
||||
// Add padding between the structure's members to follow the std140 rules manually.
|
||||
const int forcePaddingCount = GetElementPadding(mElementIndex, 4);
|
||||
mElementIndex = numComponents % 4;
|
||||
return forcePaddingCount;
|
||||
}
|
||||
else
|
||||
{
|
||||
// no padding needed, HLSL will align the field to a new register
|
||||
mElementIndex = 0;
|
||||
return 0;
|
||||
}
|
||||
// no padding needed, HLSL will align the field to a new register
|
||||
mElementIndex = 0;
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (mElementIndex + numComponents > 4)
|
||||
{
|
||||
if (forcePadding)
|
||||
{
|
||||
// Add padding between the structure's members to follow the std140 rules manually.
|
||||
const int forcePaddingCount = GetElementPadding(mElementIndex, 4);
|
||||
// If this structure will be used as HLSL StructuredBuffer member's type, we should add
|
||||
// padding between the structure's members to follow the std140 rules manually.
|
||||
const int forcePaddingCount = 4 - mElementIndex;
|
||||
mElementIndex = numComponents;
|
||||
return forcePaddingCount;
|
||||
}
|
||||
|
@ -181,8 +156,9 @@ int Std140PaddingHelper::prePadding(const TType &type, bool forcePadding)
|
|||
}
|
||||
}
|
||||
|
||||
const int alignment = numComponents == 3 ? 4 : numComponents;
|
||||
const int paddingCount = GetElementPadding(mElementIndex, alignment);
|
||||
const int alignment = numComponents == 3 ? 4 : numComponents;
|
||||
const int paddingOffset = (mElementIndex % alignment);
|
||||
const int paddingCount = (paddingOffset != 0 ? (alignment - paddingOffset) : 0);
|
||||
|
||||
mElementIndex += paddingCount;
|
||||
mElementIndex += numComponents;
|
||||
|
@ -207,33 +183,23 @@ TString Std140PaddingHelper::prePaddingString(const TType &type, bool forcePaddi
|
|||
|
||||
TString Std140PaddingHelper::postPaddingString(const TType &type,
|
||||
bool useHLSLRowMajorPacking,
|
||||
bool isLastElement,
|
||||
bool forcePadding)
|
||||
{
|
||||
if (!type.isMatrix() && !type.isArray() && type.getBasicType() != EbtStruct)
|
||||
{
|
||||
if (forcePadding)
|
||||
{
|
||||
const GLenum glType = GLVariableType(type);
|
||||
const int numComponents = gl::VariableComponentCount(glType);
|
||||
if (isLastElement || (numComponents >= 4))
|
||||
// If this structure will be used as HLSL StructuredBuffer member's type, we
|
||||
// should force to pad the end of the structure to follow the std140 rules.
|
||||
TString forcePaddingStr;
|
||||
const int paddingOffset = mElementIndex % 4;
|
||||
const int paddingCount = paddingOffset != 0 ? (4 - paddingOffset) : 0;
|
||||
for (int paddingIndex = 0; paddingIndex < paddingCount; paddingIndex++)
|
||||
{
|
||||
// If this structure will be used as HLSL StructuredBuffer member's type, in
|
||||
// order to follow the std140 rules, add padding at the end of the structure
|
||||
// if necessary. Or if the current element straddles a vec4 boundary, add
|
||||
// padding to round up the base offset of the next element to the base
|
||||
// alignment of a vec4.
|
||||
TString forcePaddingStr;
|
||||
const int paddingCount = GetElementPadding(mElementIndex, 4);
|
||||
for (int paddingIndex = 0; paddingIndex < paddingCount; paddingIndex++)
|
||||
{
|
||||
forcePaddingStr += " float pad_" + next() + ";\n";
|
||||
}
|
||||
mElementIndex = 0;
|
||||
return forcePaddingStr;
|
||||
forcePaddingStr += " float pad_" + next() + ";\n";
|
||||
}
|
||||
return forcePaddingStr;
|
||||
}
|
||||
|
||||
return "";
|
||||
}
|
||||
|
||||
|
|
|
@ -34,10 +34,7 @@ class Std140PaddingHelper
|
|||
int elementIndex() const { return mElementIndex; }
|
||||
int prePadding(const TType &type, bool forcePadding);
|
||||
TString prePaddingString(const TType &type, bool forcePadding);
|
||||
TString postPaddingString(const TType &type,
|
||||
bool useHLSLRowMajorPacking,
|
||||
bool isLastElement,
|
||||
bool forcePadding);
|
||||
TString postPaddingString(const TType &type, bool useHLSLRowMajorPacking, bool forcePadding);
|
||||
|
||||
private:
|
||||
TString next();
|
||||
|
|
|
@ -25,7 +25,6 @@ constexpr const ImmutableString kMainName("main");
|
|||
constexpr const ImmutableString kImageLoadName("imageLoad");
|
||||
constexpr const ImmutableString kImageStoreName("imageStore");
|
||||
constexpr const ImmutableString kImageSizeName("imageSize");
|
||||
constexpr const ImmutableString kImageAtomicExchangeName("imageAtomicExchange");
|
||||
constexpr const ImmutableString kAtomicCounterName("atomicCounter");
|
||||
|
||||
static const char kFunctionMangledNameSeparator = '(';
|
||||
|
@ -215,8 +214,7 @@ bool TFunction::isMain() const
|
|||
bool TFunction::isImageFunction() const
|
||||
{
|
||||
return symbolType() == SymbolType::BuiltIn &&
|
||||
(name() == kImageSizeName || name() == kImageLoadName || name() == kImageStoreName ||
|
||||
name() == kImageAtomicExchangeName);
|
||||
(name() == kImageSizeName || name() == kImageLoadName || name() == kImageStoreName);
|
||||
}
|
||||
|
||||
bool TFunction::isAtomicCounterFunction() const
|
||||
|
|
|
@ -138,7 +138,7 @@ class TStructure : public TSymbol, public TFieldListCollection
|
|||
// TODO(zmo): Find a way to get rid of the const_cast in function
|
||||
// setName(). At the moment keep this function private so only
|
||||
// friend class RegenerateStructNames may call it.
|
||||
friend class RegenerateStructNamesTraverser;
|
||||
friend class RegenerateStructNames;
|
||||
void setName(const ImmutableString &name);
|
||||
|
||||
bool mAtGlobalScope;
|
||||
|
|
|
@ -39,10 +39,6 @@ bool CheckShaderType(Shader expected, GLenum actual)
|
|||
return actual == GL_GEOMETRY_SHADER;
|
||||
case Shader::GEOMETRY_EXT:
|
||||
return actual == GL_GEOMETRY_SHADER_EXT;
|
||||
case Shader::TESS_CONTROL_EXT:
|
||||
return actual == GL_TESS_CONTROL_SHADER_EXT;
|
||||
case Shader::TESS_EVALUATION_EXT:
|
||||
return actual == GL_TESS_EVALUATION_SHADER_EXT;
|
||||
case Shader::NOT_COMPUTE:
|
||||
return actual != GL_COMPUTE_SHADER;
|
||||
default:
|
||||
|
@ -415,8 +411,6 @@ void TSymbolTable::initializeBuiltIns(sh::GLenum type,
|
|||
case GL_VERTEX_SHADER:
|
||||
case GL_COMPUTE_SHADER:
|
||||
case GL_GEOMETRY_SHADER_EXT:
|
||||
case GL_TESS_CONTROL_SHADER_EXT:
|
||||
case GL_TESS_EVALUATION_SHADER_EXT:
|
||||
setDefaultPrecision(EbtInt, EbpHigh);
|
||||
setDefaultPrecision(EbtFloat, EbpHigh);
|
||||
break;
|
||||
|
|
|
@ -45,13 +45,11 @@
|
|||
enum class Shader : uint8_t
|
||||
{
|
||||
ALL,
|
||||
FRAGMENT, // GL_FRAGMENT_SHADER
|
||||
VERTEX, // GL_VERTEX_SHADER
|
||||
COMPUTE, // GL_COMPUTE_SHADER
|
||||
GEOMETRY, // GL_GEOMETRY_SHADER
|
||||
GEOMETRY_EXT, // GL_GEOMETRY_SHADER_EXT
|
||||
TESS_CONTROL_EXT, // GL_TESS_CONTROL_SHADER_EXT
|
||||
TESS_EVALUATION_EXT, // GL_TESS_EVALUATION_SHADER_EXT
|
||||
FRAGMENT, // GL_FRAGMENT_SHADER
|
||||
VERTEX, // GL_VERTEX_SHADER
|
||||
COMPUTE, // GL_COMPUTE_SHADER
|
||||
GEOMETRY, // GL_GEOMETRY_SHADER
|
||||
GEOMETRY_EXT, // GL_GEOMETRY_SHADER_EXT
|
||||
NOT_COMPUTE
|
||||
};
|
||||
|
||||
|
|
Разница между файлами не показана из-за своего большого размера
Загрузить разницу
Разница между файлами не показана из-за своего большого размера
Загрузить разницу
|
@ -2,7 +2,7 @@
|
|||
// Generated by gen_builtin_symbols.py using data from builtin_variables.json and
|
||||
// builtin_function_declarations.txt.
|
||||
//
|
||||
// Copyright 2020 The ANGLE Project Authors. All rights reserved.
|
||||
// Copyright 2021 The ANGLE Project Authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
//
|
||||
|
@ -18,145 +18,61 @@ namespace sh
|
|||
class TSymbolTableBase
|
||||
{
|
||||
public:
|
||||
TSymbolTableBase() = default;
|
||||
TSymbol *m_gl_DepthRangeParameters = nullptr;
|
||||
TSymbol *m_gl_DepthRange = nullptr;
|
||||
TSymbol *m_gl_MaxVertexAttribs = nullptr;
|
||||
TSymbol *m_gl_MaxVertexUniformVectors = nullptr;
|
||||
TSymbol *m_gl_MaxVertexTextureImageUnits = nullptr;
|
||||
TSymbol *m_gl_MaxCombinedTextureImageUnits = nullptr;
|
||||
TSymbol *m_gl_MaxTextureImageUnits = nullptr;
|
||||
TSymbol *m_gl_MaxFragmentUniformVectors = nullptr;
|
||||
TSymbol *m_gl_MaxVaryingVectors = nullptr;
|
||||
TSymbol *m_gl_MaxDrawBuffers = nullptr;
|
||||
TSymbol *m_gl_MaxDualSourceDrawBuffersEXT = nullptr;
|
||||
TSymbol *m_gl_MaxVertexOutputVectors = nullptr;
|
||||
TSymbol *m_gl_MaxFragmentInputVectors = nullptr;
|
||||
TSymbol *m_gl_MinProgramTexelOffset = nullptr;
|
||||
TSymbol *m_gl_MaxProgramTexelOffset = nullptr;
|
||||
TSymbol *m_gl_MaxImageUnits = nullptr;
|
||||
TSymbol *m_gl_MaxVertexImageUniforms = nullptr;
|
||||
TSymbol *m_gl_MaxFragmentImageUniforms = nullptr;
|
||||
TSymbol *m_gl_MaxComputeImageUniforms = nullptr;
|
||||
TSymbol *m_gl_MaxCombinedImageUniforms = nullptr;
|
||||
TSymbol *m_gl_MaxCombinedShaderOutputResources = nullptr;
|
||||
TSymbol *m_gl_MaxComputeWorkGroupCount = nullptr;
|
||||
TSymbol *m_gl_MaxComputeWorkGroupSize = nullptr;
|
||||
TSymbol *m_gl_MaxComputeUniformComponents = nullptr;
|
||||
TSymbol *m_gl_MaxComputeTextureImageUnits = nullptr;
|
||||
TSymbol *m_gl_MaxComputeAtomicCounters = nullptr;
|
||||
TSymbol *m_gl_MaxComputeAtomicCounterBuffers = nullptr;
|
||||
TSymbol *m_gl_MaxVertexAtomicCounters = nullptr;
|
||||
TSymbol *m_gl_MaxFragmentAtomicCounters = nullptr;
|
||||
TSymbol *m_gl_MaxCombinedAtomicCounters = nullptr;
|
||||
TSymbol *m_gl_MaxAtomicCounterBindings = nullptr;
|
||||
TSymbol *m_gl_MaxVertexAtomicCounterBuffers = nullptr;
|
||||
TSymbol *m_gl_MaxFragmentAtomicCounterBuffers = nullptr;
|
||||
TSymbol *m_gl_MaxCombinedAtomicCounterBuffers = nullptr;
|
||||
TSymbol *m_gl_MaxAtomicCounterBufferSize = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryInputComponents = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryInputComponentsES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryOutputComponents = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryOutputComponentsES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryImageUniforms = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryImageUniformsES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryTextureImageUnits = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryTextureImageUnitsES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryOutputVertices = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryOutputVerticesES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryTotalOutputComponents = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryTotalOutputComponentsES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryUniformComponents = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryUniformComponentsES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryAtomicCounters = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryAtomicCountersES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryAtomicCounterBuffers = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryAtomicCounterBuffersES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxTessControlInputComponents = nullptr;
|
||||
TSymbol *m_gl_MaxTessControlInputComponentsES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxTessControlOutputComponents = nullptr;
|
||||
TSymbol *m_gl_MaxTessControlOutputComponentsES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxTessControlTextureImageUnits = nullptr;
|
||||
TSymbol *m_gl_MaxTessControlTextureImageUnitsES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxTessControlUniformComponents = nullptr;
|
||||
TSymbol *m_gl_MaxTessControlUniformComponentsES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxTessControlTotalOutputComponents = nullptr;
|
||||
TSymbol *m_gl_MaxTessControlTotalOutputComponentsES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxTessControlImageUniforms = nullptr;
|
||||
TSymbol *m_gl_MaxTessControlImageUniformsES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxTessControlAtomicCounters = nullptr;
|
||||
TSymbol *m_gl_MaxTessControlAtomicCountersES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxTessControlAtomicCounterBuffers = nullptr;
|
||||
TSymbol *m_gl_MaxTessControlAtomicCounterBuffersES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxTessPatchComponents = nullptr;
|
||||
TSymbol *m_gl_MaxTessPatchComponentsES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxPatchVertices = nullptr;
|
||||
TSymbol *m_gl_MaxPatchVerticesES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxTessGenLevel = nullptr;
|
||||
TSymbol *m_gl_MaxTessGenLevelES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxTessEvaluationInputComponents = nullptr;
|
||||
TSymbol *m_gl_MaxTessEvaluationInputComponentsES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxTessEvaluationOutputComponents = nullptr;
|
||||
TSymbol *m_gl_MaxTessEvaluationOutputComponentsES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxTessEvaluationTextureImageUnits = nullptr;
|
||||
TSymbol *m_gl_MaxTessEvaluationTextureImageUnitsES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxTessEvaluationUniformComponents = nullptr;
|
||||
TSymbol *m_gl_MaxTessEvaluationUniformComponentsES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxTessEvaluationImageUniforms = nullptr;
|
||||
TSymbol *m_gl_MaxTessEvaluationImageUniformsES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxTessEvaluationAtomicCounters = nullptr;
|
||||
TSymbol *m_gl_MaxTessEvaluationAtomicCountersES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxTessEvaluationAtomicCounterBuffers = nullptr;
|
||||
TSymbol *m_gl_MaxTessEvaluationAtomicCounterBuffersES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxSamples = nullptr;
|
||||
TSymbol *m_gl_MaxSamplesES3_2 = nullptr;
|
||||
TSymbol *m_gl_MaxClipDistancesAPPLE = nullptr;
|
||||
TSymbol *m_gl_MaxCullDistancesEXT = nullptr;
|
||||
TSymbol *m_gl_MaxCombinedClipAndCullDistancesEXT = nullptr;
|
||||
TSymbol *m_gl_FragData = nullptr;
|
||||
TSymbol *m_gl_SecondaryFragDataEXT = nullptr;
|
||||
TSymbol *m_gl_FragDepthEXT = nullptr;
|
||||
TSymbol *m_gl_LastFragData = nullptr;
|
||||
TSymbol *m_gl_LastFragDataNonCoherent = nullptr;
|
||||
TSymbol *m_gl_LastFragDataNV = nullptr;
|
||||
TSymbol *m_gl_SampleMaskIn = nullptr;
|
||||
TSymbol *m_gl_SampleMaskInES3_2 = nullptr;
|
||||
TSymbol *m_gl_SampleMask = nullptr;
|
||||
TSymbol *m_gl_SampleMaskES3_2 = nullptr;
|
||||
TSymbol *m_gl_CullDistance = nullptr;
|
||||
TSymbol *m_gl_ClipDistance = nullptr;
|
||||
TSymbol *m_gl_ClipDistanceAPPLE = nullptr;
|
||||
TSymbol *m_gl_CullDistanceEXT = nullptr;
|
||||
TSymbol *m_gl_PerVertex = nullptr;
|
||||
TSymbol *m_gl_PerVertexES3_2 = nullptr;
|
||||
TSymbol *m_gl_in = nullptr;
|
||||
TSymbol *m_gl_inES3_2 = nullptr;
|
||||
TSymbol *m_gl_PositionGS = nullptr;
|
||||
TSymbol *m_gl_PositionGSES3_2 = nullptr;
|
||||
TSymbol *m_gl_TessLevelOuterTCS = nullptr;
|
||||
TSymbol *m_gl_TessLevelOuterTCSES3_2 = nullptr;
|
||||
TSymbol *m_gl_TessLevelInnerTCS = nullptr;
|
||||
TSymbol *m_gl_TessLevelInnerTCSES3_2 = nullptr;
|
||||
TSymbol *m_gl_PerVertexTCS = nullptr;
|
||||
TSymbol *m_gl_PerVertexTCSES3_2 = nullptr;
|
||||
TSymbol *m_gl_inTCS = nullptr;
|
||||
TSymbol *m_gl_inTCSES3_2 = nullptr;
|
||||
TSymbol *m_gl_outTCS = nullptr;
|
||||
TSymbol *m_gl_outTCSES3_2 = nullptr;
|
||||
TSymbol *m_gl_PositionTCS = nullptr;
|
||||
TSymbol *m_gl_PositionTCSES3_2 = nullptr;
|
||||
TSymbol *m_gl_TessLevelOuterTES = nullptr;
|
||||
TSymbol *m_gl_TessLevelOuterTESES3_2 = nullptr;
|
||||
TSymbol *m_gl_TessLevelInnerTES = nullptr;
|
||||
TSymbol *m_gl_TessLevelInnerTESES3_2 = nullptr;
|
||||
TSymbol *m_gl_PerVertexTES = nullptr;
|
||||
TSymbol *m_gl_PerVertexTESES3_2 = nullptr;
|
||||
TSymbol *m_gl_inTES = nullptr;
|
||||
TSymbol *m_gl_inTESES3_2 = nullptr;
|
||||
TSymbol *m_gl_outTES = nullptr;
|
||||
TSymbol *m_gl_outTESES3_2 = nullptr;
|
||||
TSymbol *m_gl_PositionTES = nullptr;
|
||||
TSymbol *m_gl_PositionTESES3_2 = nullptr;
|
||||
TSymbolTableBase() = default;
|
||||
TSymbol *m_gl_DepthRangeParameters = nullptr;
|
||||
TSymbol *m_gl_DepthRange = nullptr;
|
||||
TSymbol *m_gl_MaxVertexAttribs = nullptr;
|
||||
TSymbol *m_gl_MaxVertexUniformVectors = nullptr;
|
||||
TSymbol *m_gl_MaxVertexTextureImageUnits = nullptr;
|
||||
TSymbol *m_gl_MaxCombinedTextureImageUnits = nullptr;
|
||||
TSymbol *m_gl_MaxTextureImageUnits = nullptr;
|
||||
TSymbol *m_gl_MaxFragmentUniformVectors = nullptr;
|
||||
TSymbol *m_gl_MaxVaryingVectors = nullptr;
|
||||
TSymbol *m_gl_MaxDrawBuffers = nullptr;
|
||||
TSymbol *m_gl_MaxDualSourceDrawBuffersEXT = nullptr;
|
||||
TSymbol *m_gl_MaxVertexOutputVectors = nullptr;
|
||||
TSymbol *m_gl_MaxFragmentInputVectors = nullptr;
|
||||
TSymbol *m_gl_MinProgramTexelOffset = nullptr;
|
||||
TSymbol *m_gl_MaxProgramTexelOffset = nullptr;
|
||||
TSymbol *m_gl_MaxImageUnits = nullptr;
|
||||
TSymbol *m_gl_MaxVertexImageUniforms = nullptr;
|
||||
TSymbol *m_gl_MaxFragmentImageUniforms = nullptr;
|
||||
TSymbol *m_gl_MaxComputeImageUniforms = nullptr;
|
||||
TSymbol *m_gl_MaxCombinedImageUniforms = nullptr;
|
||||
TSymbol *m_gl_MaxCombinedShaderOutputResources = nullptr;
|
||||
TSymbol *m_gl_MaxComputeWorkGroupCount = nullptr;
|
||||
TSymbol *m_gl_MaxComputeWorkGroupSize = nullptr;
|
||||
TSymbol *m_gl_MaxComputeUniformComponents = nullptr;
|
||||
TSymbol *m_gl_MaxComputeTextureImageUnits = nullptr;
|
||||
TSymbol *m_gl_MaxComputeAtomicCounters = nullptr;
|
||||
TSymbol *m_gl_MaxComputeAtomicCounterBuffers = nullptr;
|
||||
TSymbol *m_gl_MaxVertexAtomicCounters = nullptr;
|
||||
TSymbol *m_gl_MaxFragmentAtomicCounters = nullptr;
|
||||
TSymbol *m_gl_MaxCombinedAtomicCounters = nullptr;
|
||||
TSymbol *m_gl_MaxAtomicCounterBindings = nullptr;
|
||||
TSymbol *m_gl_MaxVertexAtomicCounterBuffers = nullptr;
|
||||
TSymbol *m_gl_MaxFragmentAtomicCounterBuffers = nullptr;
|
||||
TSymbol *m_gl_MaxCombinedAtomicCounterBuffers = nullptr;
|
||||
TSymbol *m_gl_MaxAtomicCounterBufferSize = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryInputComponents = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryOutputComponents = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryImageUniforms = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryTextureImageUnits = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryOutputVertices = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryTotalOutputComponents = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryUniformComponents = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryAtomicCounters = nullptr;
|
||||
TSymbol *m_gl_MaxGeometryAtomicCounterBuffers = nullptr;
|
||||
TSymbol *m_gl_FragData = nullptr;
|
||||
TSymbol *m_gl_SecondaryFragDataEXT = nullptr;
|
||||
TSymbol *m_gl_FragDepthEXT = nullptr;
|
||||
TSymbol *m_gl_LastFragData = nullptr;
|
||||
TSymbol *m_gl_LastFragDataNV = nullptr;
|
||||
TSymbol *m_gl_ClipDistance = nullptr;
|
||||
TSymbol *m_gl_MaxClipDistances = nullptr;
|
||||
TSymbol *m_gl_PerVertex = nullptr;
|
||||
TSymbol *m_gl_in = nullptr;
|
||||
TSymbol *m_gl_PositionGS = nullptr;
|
||||
};
|
||||
|
||||
} // namespace sh
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
#include "angle_gl.h"
|
||||
#include "compiler/translator/BuiltInFunctionEmulatorGLSL.h"
|
||||
#include "compiler/translator/OutputESSL.h"
|
||||
#include "compiler/translator/tree_ops/gl/RecordConstantPrecision.h"
|
||||
#include "compiler/translator/tree_ops/RecordConstantPrecision.h"
|
||||
|
||||
namespace sh
|
||||
{
|
||||
|
@ -21,7 +21,7 @@ TranslatorESSL::TranslatorESSL(sh::GLenum type, ShShaderSpec spec)
|
|||
void TranslatorESSL::initBuiltInFunctionEmulator(BuiltInFunctionEmulator *emu,
|
||||
ShCompileOptions compileOptions)
|
||||
{
|
||||
if ((compileOptions & SH_EMULATE_ATAN2_FLOAT_FUNCTION) != 0)
|
||||
if (compileOptions & SH_EMULATE_ATAN2_FLOAT_FUNCTION)
|
||||
{
|
||||
InitBuiltInAtanFunctionEmulatorForGLSLWorkarounds(emu);
|
||||
}
|
||||
|
|
|
@ -11,9 +11,9 @@
|
|||
#include "compiler/translator/ExtensionGLSL.h"
|
||||
#include "compiler/translator/OutputGLSL.h"
|
||||
#include "compiler/translator/VersionGLSL.h"
|
||||
#include "compiler/translator/tree_ops/RewriteRowMajorMatrices.h"
|
||||
#include "compiler/translator/tree_ops/RewriteTexelFetchOffset.h"
|
||||
#include "compiler/translator/tree_ops/gl/mac/RewriteRowMajorMatrices.h"
|
||||
#include "compiler/translator/tree_ops/gl/mac/RewriteUnaryMinusOperatorFloat.h"
|
||||
#include "compiler/translator/tree_ops/RewriteUnaryMinusOperatorFloat.h"
|
||||
|
||||
namespace sh
|
||||
{
|
||||
|
@ -25,17 +25,17 @@ TranslatorGLSL::TranslatorGLSL(sh::GLenum type, ShShaderSpec spec, ShShaderOutpu
|
|||
void TranslatorGLSL::initBuiltInFunctionEmulator(BuiltInFunctionEmulator *emu,
|
||||
ShCompileOptions compileOptions)
|
||||
{
|
||||
if ((compileOptions & SH_EMULATE_ABS_INT_FUNCTION) != 0)
|
||||
if (compileOptions & SH_EMULATE_ABS_INT_FUNCTION)
|
||||
{
|
||||
InitBuiltInAbsFunctionEmulatorForGLSLWorkarounds(emu, getShaderType());
|
||||
}
|
||||
|
||||
if ((compileOptions & SH_EMULATE_ISNAN_FLOAT_FUNCTION) != 0)
|
||||
if (compileOptions & SH_EMULATE_ISNAN_FLOAT_FUNCTION)
|
||||
{
|
||||
InitBuiltInIsnanFunctionEmulatorForGLSLWorkarounds(emu, getShaderVersion());
|
||||
}
|
||||
|
||||
if ((compileOptions & SH_EMULATE_ATAN2_FLOAT_FUNCTION) != 0)
|
||||
if (compileOptions & SH_EMULATE_ATAN2_FLOAT_FUNCTION)
|
||||
{
|
||||
InitBuiltInAtanFunctionEmulatorForGLSLWorkarounds(emu);
|
||||
}
|
||||
|
@ -234,7 +234,7 @@ bool TranslatorGLSL::shouldFlattenPragmaStdglInvariantAll()
|
|||
|
||||
bool TranslatorGLSL::shouldCollectVariables(ShCompileOptions compileOptions)
|
||||
{
|
||||
return (compileOptions & SH_FLATTEN_PRAGMA_STDGL_INVARIANT_ALL) != 0 ||
|
||||
return (compileOptions & SH_FLATTEN_PRAGMA_STDGL_INVARIANT_ALL) ||
|
||||
TCompiler::shouldCollectVariables(compileOptions);
|
||||
}
|
||||
|
||||
|
|
|
@ -7,24 +7,26 @@
|
|||
#include "compiler/translator/TranslatorHLSL.h"
|
||||
|
||||
#include "compiler/translator/OutputHLSL.h"
|
||||
#include "compiler/translator/tree_ops/AddDefaultReturnStatements.h"
|
||||
#include "compiler/translator/tree_ops/ArrayReturnValueToOutParameter.h"
|
||||
#include "compiler/translator/tree_ops/BreakVariableAliasingInInnerLoops.h"
|
||||
#include "compiler/translator/tree_ops/ExpandIntegerPowExpressions.h"
|
||||
#include "compiler/translator/tree_ops/PruneEmptyCases.h"
|
||||
#include "compiler/translator/tree_ops/RecordUniformBlocksTranslatedToStructuredBuffers.h"
|
||||
#include "compiler/translator/tree_ops/RemoveDynamicIndexing.h"
|
||||
#include "compiler/translator/tree_ops/RewriteAtomicFunctionExpressions.h"
|
||||
#include "compiler/translator/tree_ops/RewriteElseBlocks.h"
|
||||
#include "compiler/translator/tree_ops/RewriteExpressionsWithShaderStorageBlock.h"
|
||||
#include "compiler/translator/tree_ops/RewriteTexelFetchOffset.h"
|
||||
#include "compiler/translator/tree_ops/RewriteUnaryMinusOperatorInt.h"
|
||||
#include "compiler/translator/tree_ops/SeparateArrayConstructorStatements.h"
|
||||
#include "compiler/translator/tree_ops/SeparateArrayInitialization.h"
|
||||
#include "compiler/translator/tree_ops/SeparateDeclarations.h"
|
||||
#include "compiler/translator/tree_ops/SeparateExpressionsReturningArrays.h"
|
||||
#include "compiler/translator/tree_ops/SimplifyLoopConditions.h"
|
||||
#include "compiler/translator/tree_ops/SplitSequenceOperator.h"
|
||||
#include "compiler/translator/tree_ops/d3d/AddDefaultReturnStatements.h"
|
||||
#include "compiler/translator/tree_ops/d3d/ArrayReturnValueToOutParameter.h"
|
||||
#include "compiler/translator/tree_ops/d3d/BreakVariableAliasingInInnerLoops.h"
|
||||
#include "compiler/translator/tree_ops/d3d/ExpandIntegerPowExpressions.h"
|
||||
#include "compiler/translator/tree_ops/d3d/RecordUniformBlocksWithLargeArrayMember.h"
|
||||
#include "compiler/translator/tree_ops/d3d/RewriteAtomicFunctionExpressions.h"
|
||||
#include "compiler/translator/tree_ops/d3d/RewriteElseBlocks.h"
|
||||
#include "compiler/translator/tree_ops/d3d/RewriteExpressionsWithShaderStorageBlock.h"
|
||||
#include "compiler/translator/tree_ops/d3d/RewriteUnaryMinusOperatorInt.h"
|
||||
#include "compiler/translator/tree_ops/d3d/SeparateArrayConstructorStatements.h"
|
||||
#include "compiler/translator/tree_ops/d3d/SeparateArrayInitialization.h"
|
||||
#include "compiler/translator/tree_ops/d3d/SeparateExpressionsReturningArrays.h"
|
||||
#include "compiler/translator/tree_ops/d3d/UnfoldShortCircuitToIf.h"
|
||||
#include "compiler/translator/tree_ops/d3d/WrapSwitchStatementsInBlocks.h"
|
||||
#include "compiler/translator/tree_ops/UnfoldShortCircuitToIf.h"
|
||||
#include "compiler/translator/tree_ops/WrapSwitchStatementsInBlocks.h"
|
||||
#include "compiler/translator/tree_util/IntermNodePatternMatcher.h"
|
||||
|
||||
namespace sh
|
||||
|
@ -182,26 +184,25 @@ bool TranslatorHLSL::translate(TIntermBlock *root,
|
|||
}
|
||||
}
|
||||
|
||||
mUniformBlockOptimizedMap.clear();
|
||||
mSlowCompilingUniformBlockSet.clear();
|
||||
mUniformBlocksTranslatedToStructuredBuffers.clear();
|
||||
// In order to get the exact maximum of slots are available for shader resources, which would
|
||||
// been bound with StructuredBuffer, we only translate uniform block with a large array member
|
||||
// into StructuredBuffer when shader version is 300.
|
||||
if (getShaderVersion() == 300 &&
|
||||
(compileOptions & SH_ALLOW_TRANSLATE_UNIFORM_BLOCK_TO_STRUCTUREDBUFFER) != 0)
|
||||
{
|
||||
if (!sh::RecordUniformBlocksWithLargeArrayMember(root, mUniformBlockOptimizedMap,
|
||||
mSlowCompilingUniformBlockSet))
|
||||
if (!sh::RecordUniformBlocksTranslatedToStructuredBuffers(
|
||||
root, mUniformBlocksTranslatedToStructuredBuffers))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
sh::OutputHLSL outputHLSL(getShaderType(), getShaderSpec(), getShaderVersion(),
|
||||
getExtensionBehavior(), getSourcePath(), getOutputType(),
|
||||
numRenderTargets, maxDualSourceDrawBuffers, getUniforms(),
|
||||
compileOptions, getComputeShaderLocalSize(), &getSymbolTable(),
|
||||
perfDiagnostics, mUniformBlockOptimizedMap, mShaderStorageBlocks);
|
||||
sh::OutputHLSL outputHLSL(
|
||||
getShaderType(), getShaderSpec(), getShaderVersion(), getExtensionBehavior(),
|
||||
getSourcePath(), getOutputType(), numRenderTargets, maxDualSourceDrawBuffers, getUniforms(),
|
||||
compileOptions, getComputeShaderLocalSize(), &getSymbolTable(), perfDiagnostics,
|
||||
mUniformBlocksTranslatedToStructuredBuffers, mShaderStorageBlocks);
|
||||
|
||||
outputHLSL.output(root, getInfoSink().obj);
|
||||
|
||||
|
@ -250,11 +251,6 @@ const std::map<std::string, unsigned int> *TranslatorHLSL::getUniformRegisterMap
|
|||
return &mUniformRegisterMap;
|
||||
}
|
||||
|
||||
const std::set<std::string> *TranslatorHLSL::getSlowCompilingUniformBlockSet() const
|
||||
{
|
||||
return &mSlowCompilingUniformBlockSet;
|
||||
}
|
||||
|
||||
unsigned int TranslatorHLSL::getReadonlyImage2DRegisterIndex() const
|
||||
{
|
||||
return mReadonlyImage2DRegisterIndex;
|
||||
|
|
|
@ -24,7 +24,6 @@ class TranslatorHLSL : public TCompiler
|
|||
bool hasUniformBlock(const std::string &interfaceBlockName) const;
|
||||
unsigned int getUniformBlockRegister(const std::string &interfaceBlockName) const;
|
||||
bool shouldUniformBlockUseStructuredBuffer(const std::string &uniformBlockName) const;
|
||||
const std::set<std::string> *getSlowCompilingUniformBlockSet() const;
|
||||
|
||||
const std::map<std::string, unsigned int> *getUniformRegisterMap() const;
|
||||
unsigned int getReadonlyImage2DRegisterIndex() const;
|
||||
|
@ -47,8 +46,7 @@ class TranslatorHLSL : public TCompiler
|
|||
unsigned int mReadonlyImage2DRegisterIndex;
|
||||
unsigned int mImage2DRegisterIndex;
|
||||
std::set<std::string> mUsedImage2DFunctionNames;
|
||||
std::map<int, const TInterfaceBlock *> mUniformBlockOptimizedMap;
|
||||
std::set<std::string> mSlowCompilingUniformBlockSet;
|
||||
std::map<int, const TInterfaceBlock *> mUniformBlocksTranslatedToStructuredBuffers;
|
||||
};
|
||||
|
||||
} // namespace sh
|
||||
|
|
Некоторые файлы не были показаны из-за слишком большого количества измененных файлов Показать больше
Загрузка…
Ссылка в новой задаче