1Name 2 3 ANDROID_extension_pack_es31a 4 5Name Strings 6 7 GL_ANDROID_extension_pack_es31a 8 9Contact 10 11 Jesse Hall (jessehall 'at' google.com) 12 13Contributors 14 15 Jesse Hall, Google 16 17Status 18 19 Complete. 20 21Version 22 23 Last Modified Date: July 7, 2014 24 Revision: 3 25 26Number 27 28 OpenGL ES Extension #187 29 30Dependencies 31 32 OpenGL ES 3.1 and GLSL ES 3.10 are required. 33 34 The following extensions are required: 35 * KHR_debug 36 * KHR_texture_compression_astc_ldr 37 * KHR_blend_equation_advanced 38 * OES_sample_shading 39 * OES_sample_variables 40 * OES_shader_image_atomic 41 * OES_shader_multisample_interpolation 42 * OES_texture_stencil8 43 * OES_texture_storage_multisample_2d_array 44 * EXT_copy_image 45 * EXT_draw_buffers_indexed 46 * EXT_geometry_shader 47 * EXT_gpu_shader5 48 * EXT_primitive_bounding_box 49 * EXT_shader_io_blocks 50 * EXT_tessellation_shader 51 * EXT_texture_border_clamp 52 * EXT_texture_buffer 53 * EXT_texture_cube_map_array 54 * EXT_texture_sRGB_decode 55 56Overview 57 58 This extension changes little functionality directly. Instead it serves to 59 roll up the 20 extensions it requires, allowing applications to check for 60 all of them at once, and enable all of their shading language features with 61 a single #extension statement. The Android platform provides special support 62 outside of OpenGL ES to help applications target this set of extensions. 63 64 In addition, this extension ensures support for images, shader storage 65 buffers, and atomic counters in fragment shaders. In unextended OpenGL ES 66 the minimum value of the relevant implementation-defined limits is zero; 67 this extension raises these minimums to match the minimums for compute 68 shaders. 69 70New Procedures and Functions 71 72 None 73 74New Tokens 75 76 None 77 78Modifications to Chapter 20 of the OpenGL ES 3.1 Specification (State Tables) 79 80 Modify Table 20.44, Implementation Dependent Fragment Shader Limits, p. 395: 81 82 Get Value Type Get Command Minimum Value Description Sec. 83 ----------------------- ---- ----------- ------------- ------------------------- ----- 84 MAX_FRAGMENT_ATOMIC_COUNTER_BUFFERS Z+ GetIntegerv 1 No. of atomic counter 7.7 85 buffers accessed by a 86 fragment shader 87 MAX_FRAGMENT_ATOMIC_COUNTERS Z+ GetIntegerv 8 No. of atomic counters 7.7 88 accessed by a fragment 89 shader 90 MAX_FRAGMENT_IMAGE_UNIFORMS Z+ GetIntegerv 4 No. of image variables in 11.1.3 91 fragment shaders 92 MAX_FRAGMENT_SHADER_STORAGE_BLOCKS Z+ GetIntegerv 4 No. of shader storage 7.8 93 blocks accessed by a 94 fragment shader 95 [[Change minimum values]] 96 97Modifications to The OpenGL ES Shading Language Specification, Version 3.10 98(Revision 5) 99 100 Including the following line in a shader: 101 102 #extension GL_ANDROID_extension_pack_es31a : <behavior> 103 104 has the same effect as including the following lines: 105 106 #extension GL_KHR_blend_equation_advanced : <behavior> 107 #extension GL_OES_sample_variables : <behavior> 108 #extension GL_OES_shader_image_atomic : <behavior> 109 #extension GL_OES_shader_multisample_interpolation : <behavior> 110 #extension GL_OES_texture_storage_multisample_2d_array : <behavior> 111 #extension GL_EXT_geometry_shader : <behavior> 112 #extension GL_EXT_gpu_shader5 : <behavior> 113 #extension GL_EXT_primitive_bounding_box : <behavior> 114 #extension GL_EXT_shader_io_blocks : <behavior> 115 #extension GL_EXT_tessellation_shader : <behavior> 116 #extension GL_EXT_texture_buffer : <behavior> 117 #extension GL_EXT_texture_cube_map_array : <behavior> 118 119 where <behavior> is as specified in section 3.4. 120 121 A new preprocessor #define is added to the OpenGL ES Shading Language: 122 123 #define GL_ANDROID_extension_pack_es31a 1 124 125New Implementation Dependent State 126 127 None 128 129Issues 130 131 (1) Should all the extensions be enabled in all shader stages? What happens 132 if an extension is enabled in a stage that it does not modify? 133 134 RESOLVED: All extensions are enabled in all stages. 135 136 Enabling this extension in a shader has exactly the same behavior as 137 enabling each of the required extensions individually. None of the other 138 extensions limit what shader stages they can be enabled in. Generally, if 139 the modifications introduced by an extension do not apply to a shader stage, 140 then enabling it in that stage is a no-op. If an extension does introduce 141 new features to the language in a stage, a shader that doesn't use the new 142 features will behave the same whether it enables the extension or not. 143 144 145Revision History 146 147 Revision 3, 2014/7/7 (Jesse Hall) 148 - Changed status from "draft" to "complete" 149 - Corrected capitalization of EXT_texture_sRGB_decode 150 151 Revision 2, 2014/5/2 (Jesse Hall) 152 - Added dependency on EXT_primitive_bounding_box 153 - Added and resolved Issue #1 154 155 Revision 1, 2014/4/18 (Jesse Hall) 156 - Initial version 157