1/* WARNING! THIS IS A PROGRAMMATICALLY GENERATED CODE. DO NOT MODIFY THE CODE, 2 * SINCE THE CHANGES WILL BE LOST! MODIFY THE GENERATING PYTHON INSTEAD. 3 */ 4 5const char* getBooleanName (int value) 6{ 7 switch (value) 8 { 9 case EGL_TRUE: return "EGL_TRUE"; 10 case EGL_FALSE: return "EGL_FALSE"; 11 default: return DE_NULL; 12 } 13} 14 15const char* getBoolDontCareName (int value) 16{ 17 switch (value) 18 { 19 case EGL_TRUE: return "EGL_TRUE"; 20 case EGL_FALSE: return "EGL_FALSE"; 21 case EGL_DONT_CARE: return "EGL_DONT_CARE"; 22 default: return DE_NULL; 23 } 24} 25 26const char* getAPIName (int value) 27{ 28 switch (value) 29 { 30 case EGL_OPENGL_API: return "EGL_OPENGL_API"; 31 case EGL_OPENGL_ES_API: return "EGL_OPENGL_ES_API"; 32 case EGL_OPENVG_API: return "EGL_OPENVG_API"; 33 default: return DE_NULL; 34 } 35} 36 37const char* getErrorName (int value) 38{ 39 switch (value) 40 { 41 case EGL_SUCCESS: return "EGL_SUCCESS"; 42 case EGL_NOT_INITIALIZED: return "EGL_NOT_INITIALIZED"; 43 case EGL_BAD_ACCESS: return "EGL_BAD_ACCESS"; 44 case EGL_BAD_ALLOC: return "EGL_BAD_ALLOC"; 45 case EGL_BAD_ATTRIBUTE: return "EGL_BAD_ATTRIBUTE"; 46 case EGL_BAD_CONFIG: return "EGL_BAD_CONFIG"; 47 case EGL_BAD_CONTEXT: return "EGL_BAD_CONTEXT"; 48 case EGL_BAD_CURRENT_SURFACE: return "EGL_BAD_CURRENT_SURFACE"; 49 case EGL_BAD_DISPLAY: return "EGL_BAD_DISPLAY"; 50 case EGL_BAD_MATCH: return "EGL_BAD_MATCH"; 51 case EGL_BAD_NATIVE_PIXMAP: return "EGL_BAD_NATIVE_PIXMAP"; 52 case EGL_BAD_NATIVE_WINDOW: return "EGL_BAD_NATIVE_WINDOW"; 53 case EGL_BAD_PARAMETER: return "EGL_BAD_PARAMETER"; 54 case EGL_BAD_SURFACE: return "EGL_BAD_SURFACE"; 55 case EGL_CONTEXT_LOST: return "EGL_CONTEXT_LOST"; 56 default: return DE_NULL; 57 } 58} 59 60const char* getContextAttribName (int value) 61{ 62 switch (value) 63 { 64 case EGL_CONFIG_ID: return "EGL_CONFIG_ID"; 65 case EGL_CONTEXT_CLIENT_TYPE: return "EGL_CONTEXT_CLIENT_TYPE"; 66 case EGL_CONTEXT_CLIENT_VERSION: return "EGL_CONTEXT_CLIENT_VERSION"; 67 case EGL_RENDER_BUFFER: return "EGL_RENDER_BUFFER"; 68 default: return DE_NULL; 69 } 70} 71 72const char* getConfigAttribName (int value) 73{ 74 switch (value) 75 { 76 case EGL_BUFFER_SIZE: return "EGL_BUFFER_SIZE"; 77 case EGL_RED_SIZE: return "EGL_RED_SIZE"; 78 case EGL_GREEN_SIZE: return "EGL_GREEN_SIZE"; 79 case EGL_BLUE_SIZE: return "EGL_BLUE_SIZE"; 80 case EGL_LUMINANCE_SIZE: return "EGL_LUMINANCE_SIZE"; 81 case EGL_ALPHA_SIZE: return "EGL_ALPHA_SIZE"; 82 case EGL_ALPHA_MASK_SIZE: return "EGL_ALPHA_MASK_SIZE"; 83 case EGL_BIND_TO_TEXTURE_RGB: return "EGL_BIND_TO_TEXTURE_RGB"; 84 case EGL_BIND_TO_TEXTURE_RGBA: return "EGL_BIND_TO_TEXTURE_RGBA"; 85 case EGL_COLOR_BUFFER_TYPE: return "EGL_COLOR_BUFFER_TYPE"; 86 case EGL_CONFIG_CAVEAT: return "EGL_CONFIG_CAVEAT"; 87 case EGL_CONFIG_ID: return "EGL_CONFIG_ID"; 88 case EGL_CONFORMANT: return "EGL_CONFORMANT"; 89 case EGL_DEPTH_SIZE: return "EGL_DEPTH_SIZE"; 90 case EGL_LEVEL: return "EGL_LEVEL"; 91 case EGL_MATCH_NATIVE_PIXMAP: return "EGL_MATCH_NATIVE_PIXMAP"; 92 case EGL_MAX_SWAP_INTERVAL: return "EGL_MAX_SWAP_INTERVAL"; 93 case EGL_MIN_SWAP_INTERVAL: return "EGL_MIN_SWAP_INTERVAL"; 94 case EGL_NATIVE_RENDERABLE: return "EGL_NATIVE_RENDERABLE"; 95 case EGL_NATIVE_VISUAL_TYPE: return "EGL_NATIVE_VISUAL_TYPE"; 96 case EGL_RENDERABLE_TYPE: return "EGL_RENDERABLE_TYPE"; 97 case EGL_SAMPLE_BUFFERS: return "EGL_SAMPLE_BUFFERS"; 98 case EGL_SAMPLES: return "EGL_SAMPLES"; 99 case EGL_STENCIL_SIZE: return "EGL_STENCIL_SIZE"; 100 case EGL_SURFACE_TYPE: return "EGL_SURFACE_TYPE"; 101 case EGL_TRANSPARENT_TYPE: return "EGL_TRANSPARENT_TYPE"; 102 case EGL_TRANSPARENT_RED_VALUE: return "EGL_TRANSPARENT_RED_VALUE"; 103 case EGL_TRANSPARENT_GREEN_VALUE: return "EGL_TRANSPARENT_GREEN_VALUE"; 104 case EGL_TRANSPARENT_BLUE_VALUE: return "EGL_TRANSPARENT_BLUE_VALUE"; 105 default: return DE_NULL; 106 } 107} 108 109const char* getSurfaceAttribName (int value) 110{ 111 switch (value) 112 { 113 case EGL_CONFIG_ID: return "EGL_CONFIG_ID"; 114 case EGL_WIDTH: return "EGL_WIDTH"; 115 case EGL_HEIGHT: return "EGL_HEIGHT"; 116 case EGL_HORIZONTAL_RESOLUTION: return "EGL_HORIZONTAL_RESOLUTION"; 117 case EGL_VERTICAL_RESOLUTION: return "EGL_VERTICAL_RESOLUTION"; 118 case EGL_LARGEST_PBUFFER: return "EGL_LARGEST_PBUFFER"; 119 case EGL_MIPMAP_TEXTURE: return "EGL_MIPMAP_TEXTURE"; 120 case EGL_MIPMAP_LEVEL: return "EGL_MIPMAP_LEVEL"; 121 case EGL_MULTISAMPLE_RESOLVE: return "EGL_MULTISAMPLE_RESOLVE"; 122 case EGL_PIXEL_ASPECT_RATIO: return "EGL_PIXEL_ASPECT_RATIO"; 123 case EGL_RENDER_BUFFER: return "EGL_RENDER_BUFFER"; 124 case EGL_SWAP_BEHAVIOR: return "EGL_SWAP_BEHAVIOR"; 125 case EGL_TEXTURE_FORMAT: return "EGL_TEXTURE_FORMAT"; 126 case EGL_TEXTURE_TARGET: return "EGL_TEXTURE_TARGET"; 127 case EGL_VG_ALPHA_FORMAT: return "EGL_VG_ALPHA_FORMAT"; 128 case EGL_VG_COLORSPACE: return "EGL_VG_COLORSPACE"; 129 default: return DE_NULL; 130 } 131} 132 133const char* getSurfaceTargetName (int value) 134{ 135 switch (value) 136 { 137 case EGL_READ: return "EGL_READ"; 138 case EGL_DRAW: return "EGL_DRAW"; 139 default: return DE_NULL; 140 } 141} 142 143const char* getColorBufferTypeName (int value) 144{ 145 switch (value) 146 { 147 case EGL_RGB_BUFFER: return "EGL_RGB_BUFFER"; 148 case EGL_LUMINANCE_BUFFER: return "EGL_LUMINANCE_BUFFER"; 149 default: return DE_NULL; 150 } 151} 152 153const char* getConfigCaveatName (int value) 154{ 155 switch (value) 156 { 157 case EGL_NONE: return "EGL_NONE"; 158 case EGL_SLOW_CONFIG: return "EGL_SLOW_CONFIG"; 159 case EGL_NON_CONFORMANT_CONFIG: return "EGL_NON_CONFORMANT_CONFIG"; 160 default: return DE_NULL; 161 } 162} 163 164const char* getTransparentTypeName (int value) 165{ 166 switch (value) 167 { 168 case EGL_NONE: return "EGL_NONE"; 169 case EGL_TRANSPARENT_RGB: return "EGL_TRANSPARENT_RGB"; 170 default: return DE_NULL; 171 } 172} 173 174const char* getMultisampleResolveName (int value) 175{ 176 switch (value) 177 { 178 case EGL_MULTISAMPLE_RESOLVE_DEFAULT: return "EGL_MULTISAMPLE_RESOLVE_DEFAULT"; 179 case EGL_MULTISAMPLE_RESOLVE_BOX: return "EGL_MULTISAMPLE_RESOLVE_BOX"; 180 default: return DE_NULL; 181 } 182} 183 184const char* getRenderBufferName (int value) 185{ 186 switch (value) 187 { 188 case EGL_SINGLE_BUFFER: return "EGL_SINGLE_BUFFER"; 189 case EGL_BACK_BUFFER: return "EGL_BACK_BUFFER"; 190 default: return DE_NULL; 191 } 192} 193 194const char* getSwapBehaviorName (int value) 195{ 196 switch (value) 197 { 198 case EGL_BUFFER_DESTROYED: return "EGL_BUFFER_DESTROYED"; 199 case EGL_BUFFER_PRESERVED: return "EGL_BUFFER_PRESERVED"; 200 default: return DE_NULL; 201 } 202} 203 204const char* getTextureFormatName (int value) 205{ 206 switch (value) 207 { 208 case EGL_NO_TEXTURE: return "EGL_NO_TEXTURE"; 209 case EGL_TEXTURE_RGB: return "EGL_TEXTURE_RGB"; 210 case EGL_TEXTURE_RGBA: return "EGL_TEXTURE_RGBA"; 211 default: return DE_NULL; 212 } 213} 214 215const char* getTextureTargetName (int value) 216{ 217 switch (value) 218 { 219 case EGL_NO_TEXTURE: return "EGL_NO_TEXTURE"; 220 case EGL_TEXTURE_2D: return "EGL_TEXTURE_2D"; 221 default: return DE_NULL; 222 } 223} 224 225const char* getVGAlphaFormatName (int value) 226{ 227 switch (value) 228 { 229 case EGL_VG_ALPHA_FORMAT_NONPRE: return "EGL_VG_ALPHA_FORMAT_NONPRE"; 230 case EGL_VG_ALPHA_FORMAT_PRE: return "EGL_VG_ALPHA_FORMAT_PRE"; 231 default: return DE_NULL; 232 } 233} 234 235const char* getVGColorspaceName (int value) 236{ 237 switch (value) 238 { 239 case EGL_VG_COLORSPACE_sRGB: return "EGL_VG_COLORSPACE_sRGB"; 240 case EGL_VG_COLORSPACE_LINEAR: return "EGL_VG_COLORSPACE_LINEAR"; 241 default: return DE_NULL; 242 } 243} 244 245tcu::Format::Bitfield<16> getAPIBitsStr (int value) 246{ 247 static const tcu::Format::BitDesc s_desc[] = 248 { 249 tcu::Format::BitDesc(EGL_OPENGL_BIT, "EGL_OPENGL_BIT"), 250 tcu::Format::BitDesc(EGL_OPENGL_ES_BIT, "EGL_OPENGL_ES_BIT"), 251 tcu::Format::BitDesc(EGL_OPENGL_ES2_BIT, "EGL_OPENGL_ES2_BIT"), 252 tcu::Format::BitDesc(EGL_OPENGL_ES3_BIT_KHR, "EGL_OPENGL_ES3_BIT_KHR"), 253 tcu::Format::BitDesc(EGL_OPENVG_BIT, "EGL_OPENVG_BIT") 254 }; 255 return tcu::Format::Bitfield<16>(value, &s_desc[0], &s_desc[DE_LENGTH_OF_ARRAY(s_desc)]); 256} 257 258tcu::Format::Bitfield<16> getSurfaceBitsStr (int value) 259{ 260 static const tcu::Format::BitDesc s_desc[] = 261 { 262 tcu::Format::BitDesc(EGL_PBUFFER_BIT, "EGL_PBUFFER_BIT"), 263 tcu::Format::BitDesc(EGL_PIXMAP_BIT, "EGL_PIXMAP_BIT"), 264 tcu::Format::BitDesc(EGL_WINDOW_BIT, "EGL_WINDOW_BIT"), 265 tcu::Format::BitDesc(EGL_MULTISAMPLE_RESOLVE_BOX_BIT, "EGL_MULTISAMPLE_RESOLVE_BOX_BIT"), 266 tcu::Format::BitDesc(EGL_SWAP_BEHAVIOR_PRESERVED_BIT, "EGL_SWAP_BEHAVIOR_PRESERVED_BIT"), 267 tcu::Format::BitDesc(EGL_VG_ALPHA_FORMAT_PRE_BIT, "EGL_VG_ALPHA_FORMAT_PRE_BIT"), 268 tcu::Format::BitDesc(EGL_VG_COLORSPACE_LINEAR_BIT, "EGL_VG_COLORSPACE_LINEAR_BIT"), 269 tcu::Format::BitDesc(EGL_LOCK_SURFACE_BIT_KHR, "EGL_LOCK_SURFACE_BIT_KHR"), 270 tcu::Format::BitDesc(EGL_OPTIMAL_FORMAT_BIT_KHR, "EGL_OPTIMAL_FORMAT_BIT_KHR") 271 }; 272 return tcu::Format::Bitfield<16>(value, &s_desc[0], &s_desc[DE_LENGTH_OF_ARRAY(s_desc)]); 273} 274