diff --git a/projects/clr/rocclr/runtime/device/gpu/gslbe/src/rt/GSLDeviceGL.cpp b/projects/clr/rocclr/runtime/device/gpu/gslbe/src/rt/GSLDeviceGL.cpp index 554bf0d6c3..0d127fb77e 100644 --- a/projects/clr/rocclr/runtime/device/gpu/gslbe/src/rt/GSLDeviceGL.cpp +++ b/projects/clr/rocclr/runtime/device/gpu/gslbe/src/rt/GSLDeviceGL.cpp @@ -149,7 +149,9 @@ static const cmFormatXlateParams cmFormatXlateTable [] = { {CM_SURF_FMT_INTENSITY8UI, CM_SURF_FMT_R8I, GSL_CHANNEL_ORDER_R}, {CM_SURF_FMT_LUMINANCE8UI, CM_SURF_FMT_R8I, GSL_CHANNEL_ORDER_R}, {CM_SURF_FMT_LUMINANCE_ALPHA8UI, CM_SURF_FMT_RG8I, GSL_CHANNEL_ORDER_RG}, +#ifndef CM_SURF_FMT_sRGBA32I_EXT_HAS_BEEN_REMOVED {CM_SURF_FMT_sRGBA32I_EXT, CM_SURF_FMT_sRGBA32I, GSL_CHANNEL_ORDER_RGBA}, +#endif {CM_SURF_FMT_sRGBX32I, CM_SURF_FMT_sRGBA32I, GSL_CHANNEL_ORDER_RGBA}, {CM_SURF_FMT_sALPHA32I, CM_SURF_FMT_sR32I, GSL_CHANNEL_ORDER_R}, {CM_SURF_FMT_sINTENSITY32I, CM_SURF_FMT_sR32I, GSL_CHANNEL_ORDER_R}, @@ -370,6 +372,7 @@ dummyAssertIfCmSurfFmtChanges(void) COMPILE_TIME_ASSERT(123 == CM_SURF_FMT_INTENSITY8UI); COMPILE_TIME_ASSERT(124 == CM_SURF_FMT_LUMINANCE8UI); COMPILE_TIME_ASSERT(125 == CM_SURF_FMT_LUMINANCE_ALPHA8UI); +#ifndef CM_SURF_FMT_sRGBA32I_EXT_HAS_BEEN_REMOVED COMPILE_TIME_ASSERT(126 == CM_SURF_FMT_sRGBA32I_EXT); COMPILE_TIME_ASSERT(127 == CM_SURF_FMT_sRGBX32I); COMPILE_TIME_ASSERT(128 == CM_SURF_FMT_sALPHA32I); @@ -442,7 +445,6 @@ dummyAssertIfCmSurfFmtChanges(void) COMPILE_TIME_ASSERT(195 == CM_SURF_FMT_RGBA8_ASTC_10x10); COMPILE_TIME_ASSERT(196 == CM_SURF_FMT_RGBA8_ASTC_12x10); COMPILE_TIME_ASSERT(197 == CM_SURF_FMT_RGBA8_ASTC_12x12); - COMPILE_TIME_ASSERT(198 == CM_SURF_FMT_SRGBA8_ASTC_4x4); COMPILE_TIME_ASSERT(199 == CM_SURF_FMT_SRGBA8_ASTC_5x4); COMPILE_TIME_ASSERT(200 == CM_SURF_FMT_SRGBA8_ASTC_5x5); @@ -467,7 +469,103 @@ dummyAssertIfCmSurfFmtChanges(void) COMPILE_TIME_ASSERT(219 == CM_SURF_FMT_L8_X16_A8_SRGB); COMPILE_TIME_ASSERT(220 == CM_SURF_FMT_L8_X24_SRGB); COMPILE_TIME_ASSERT(221 == CM_SURF_FMT_STENCIL8); - +#else + COMPILE_TIME_ASSERT(126 == CM_SURF_FMT_sRGBX32I); + COMPILE_TIME_ASSERT(127 == CM_SURF_FMT_sALPHA32I); + COMPILE_TIME_ASSERT(128 == CM_SURF_FMT_sINTENSITY32I); + COMPILE_TIME_ASSERT(129 == CM_SURF_FMT_sLUMINANCE32I); + COMPILE_TIME_ASSERT(130 == CM_SURF_FMT_sLUMINANCE_ALPHA32I); + COMPILE_TIME_ASSERT(131 == CM_SURF_FMT_sRGBA16I); + COMPILE_TIME_ASSERT(132 == CM_SURF_FMT_sRGBX16I); + COMPILE_TIME_ASSERT(133 == CM_SURF_FMT_sALPHA16I); + COMPILE_TIME_ASSERT(134 == CM_SURF_FMT_sINTENSITY16I); + COMPILE_TIME_ASSERT(135 == CM_SURF_FMT_sLUMINANCE16I); + COMPILE_TIME_ASSERT(136 == CM_SURF_FMT_sLUMINANCE_ALPHA16I); + COMPILE_TIME_ASSERT(137 == CM_SURF_FMT_sRGBA8I); + COMPILE_TIME_ASSERT(138 == CM_SURF_FMT_sRGBX8I); + COMPILE_TIME_ASSERT(139 == CM_SURF_FMT_sALPHA8I); + COMPILE_TIME_ASSERT(140 == CM_SURF_FMT_sINTENSITY8I); + COMPILE_TIME_ASSERT(141 == CM_SURF_FMT_sLUMINANCE8I); + COMPILE_TIME_ASSERT(142 == CM_SURF_FMT_sLUMINANCE_ALPHA8I); + COMPILE_TIME_ASSERT(143 == CM_SURF_FMT_sDXT6); + COMPILE_TIME_ASSERT(144 == CM_SURF_FMT_DXT6); + COMPILE_TIME_ASSERT(145 == CM_SURF_FMT_DXT7); + COMPILE_TIME_ASSERT(146 == CM_SURF_FMT_LUMINANCE8_SNORM); + COMPILE_TIME_ASSERT(147 == CM_SURF_FMT_LUMINANCE16_SNORM); + COMPILE_TIME_ASSERT(148 == CM_SURF_FMT_INTENSITY8_SNORM); + COMPILE_TIME_ASSERT(149 == CM_SURF_FMT_INTENSITY16_SNORM); + COMPILE_TIME_ASSERT(150 == CM_SURF_FMT_ALPHA8_SNORM); + COMPILE_TIME_ASSERT(151 == CM_SURF_FMT_ALPHA16_SNORM); + COMPILE_TIME_ASSERT(152 == CM_SURF_FMT_LUMINANCE_ALPHA8_SNORM); + COMPILE_TIME_ASSERT(153 == CM_SURF_FMT_LUMINANCE_ALPHA16_SNORM); + COMPILE_TIME_ASSERT(154 == CM_SURF_FMT_R8_SNORM); + COMPILE_TIME_ASSERT(155 == CM_SURF_FMT_R16_SNORM); + COMPILE_TIME_ASSERT(156 == CM_SURF_FMT_RG8_SNORM); + COMPILE_TIME_ASSERT(157 == CM_SURF_FMT_RG16_SNORM); + COMPILE_TIME_ASSERT(158 == CM_SURF_FMT_RGBX8_SNORM); + COMPILE_TIME_ASSERT(159 == CM_SURF_FMT_RGBX16_SNORM); + COMPILE_TIME_ASSERT(160 == CM_SURF_FMT_RGBA8_SNORM); + COMPILE_TIME_ASSERT(161 == CM_SURF_FMT_RGBA16_SNORM); + COMPILE_TIME_ASSERT(162 == CM_SURF_FMT_RGB10_A2UI); + COMPILE_TIME_ASSERT(163 == CM_SURF_FMT_RGB32F); + COMPILE_TIME_ASSERT(164 == CM_SURF_FMT_RGB32I); + COMPILE_TIME_ASSERT(165 == CM_SURF_FMT_RGB32UI); + COMPILE_TIME_ASSERT(166 == CM_SURF_FMT_RGBX8_SRGB); + COMPILE_TIME_ASSERT(167 == CM_SURF_FMT_RGBA8_SRGB); + COMPILE_TIME_ASSERT(168 == CM_SURF_FMT_DXT1_SRGB); + COMPILE_TIME_ASSERT(169 == CM_SURF_FMT_DXT1A_SRGB); + COMPILE_TIME_ASSERT(170 == CM_SURF_FMT_DXT2_3_SRGB); + COMPILE_TIME_ASSERT(171 == CM_SURF_FMT_DXT4_5_SRGB); + COMPILE_TIME_ASSERT(172 == CM_SURF_FMT_DXT7_SRGB); + COMPILE_TIME_ASSERT(173 == CM_SURF_FMT_RGB8_ETC2); + COMPILE_TIME_ASSERT(174 == CM_SURF_FMT_SRGB8_ETC2); + COMPILE_TIME_ASSERT(175 == CM_SURF_FMT_RGB8_PT_ALPHA1_ETC2); + COMPILE_TIME_ASSERT(176 == CM_SURF_FMT_SRGB8_PT_ALPHA1_ETC2); + COMPILE_TIME_ASSERT(177 == CM_SURF_FMT_RGBA8_ETC2_EAC); + COMPILE_TIME_ASSERT(178 == CM_SURF_FMT_SRGB8_ALPHA8_ETC2_EAC); + COMPILE_TIME_ASSERT(179 == CM_SURF_FMT_R11_EAC); + COMPILE_TIME_ASSERT(180 == CM_SURF_FMT_SIGNED_R11_EAC); + COMPILE_TIME_ASSERT(181 == CM_SURF_FMT_RG11_EAC); + COMPILE_TIME_ASSERT(182 == CM_SURF_FMT_SIGNED_RG11_EAC); + COMPILE_TIME_ASSERT(183 == CM_SURF_FMT_RGBA8_ASTC_4x4); + COMPILE_TIME_ASSERT(184 == CM_SURF_FMT_RGBA8_ASTC_5x4); + COMPILE_TIME_ASSERT(185 == CM_SURF_FMT_RGBA8_ASTC_5x5); + COMPILE_TIME_ASSERT(186 == CM_SURF_FMT_RGBA8_ASTC_6x5); + COMPILE_TIME_ASSERT(187 == CM_SURF_FMT_RGBA8_ASTC_6x6); + COMPILE_TIME_ASSERT(188 == CM_SURF_FMT_RGBA8_ASTC_8x5); + COMPILE_TIME_ASSERT(189 == CM_SURF_FMT_RGBA8_ASTC_8x6); + COMPILE_TIME_ASSERT(190 == CM_SURF_FMT_RGBA8_ASTC_8x8); + COMPILE_TIME_ASSERT(191 == CM_SURF_FMT_RGBA8_ASTC_10x5); + COMPILE_TIME_ASSERT(192 == CM_SURF_FMT_RGBA8_ASTC_10x6); + COMPILE_TIME_ASSERT(193 == CM_SURF_FMT_RGBA8_ASTC_10x8); + COMPILE_TIME_ASSERT(194 == CM_SURF_FMT_RGBA8_ASTC_10x10); + COMPILE_TIME_ASSERT(195 == CM_SURF_FMT_RGBA8_ASTC_12x10); + COMPILE_TIME_ASSERT(196 == CM_SURF_FMT_RGBA8_ASTC_12x12); + COMPILE_TIME_ASSERT(197 == CM_SURF_FMT_SRGBA8_ASTC_4x4); + COMPILE_TIME_ASSERT(198 == CM_SURF_FMT_SRGBA8_ASTC_5x4); + COMPILE_TIME_ASSERT(199 == CM_SURF_FMT_SRGBA8_ASTC_5x5); + COMPILE_TIME_ASSERT(200 == CM_SURF_FMT_SRGBA8_ASTC_6x5); + COMPILE_TIME_ASSERT(201 == CM_SURF_FMT_SRGBA8_ASTC_6x6); + COMPILE_TIME_ASSERT(202 == CM_SURF_FMT_SRGBA8_ASTC_8x5); + COMPILE_TIME_ASSERT(203 == CM_SURF_FMT_SRGBA8_ASTC_8x6); + COMPILE_TIME_ASSERT(204 == CM_SURF_FMT_SRGBA8_ASTC_8x8); + COMPILE_TIME_ASSERT(205 == CM_SURF_FMT_SRGBA8_ASTC_10x5); + COMPILE_TIME_ASSERT(206 == CM_SURF_FMT_SRGBA8_ASTC_10x6); + COMPILE_TIME_ASSERT(207 == CM_SURF_FMT_SRGBA8_ASTC_10x8); + COMPILE_TIME_ASSERT(208 == CM_SURF_FMT_SRGBA8_ASTC_10x10); + COMPILE_TIME_ASSERT(209 == CM_SURF_FMT_SRGBA8_ASTC_12x10); + COMPILE_TIME_ASSERT(210 == CM_SURF_FMT_SRGBA8_ASTC_12x12); + COMPILE_TIME_ASSERT(211 == CM_SURF_FMT_BGR10_A2UI); + COMPILE_TIME_ASSERT(212 == CM_SURF_FMT_A2_BGR10UI); + COMPILE_TIME_ASSERT(213 == CM_SURF_FMT_A2_RGB10UI); + COMPILE_TIME_ASSERT(214 == CM_SURF_FMT_B5_G6_R5UI); + COMPILE_TIME_ASSERT(215 == CM_SURF_FMT_R5_G6_B5UI); + COMPILE_TIME_ASSERT(216 == CM_SURF_FMT_DEPTH32F_X24_STEN8_UNCLAMPED); + COMPILE_TIME_ASSERT(217 == CM_SURF_FMT_DEPTH32F_UNCLAMPED); + COMPILE_TIME_ASSERT(218 == CM_SURF_FMT_L8_X16_A8_SRGB); + COMPILE_TIME_ASSERT(219 == CM_SURF_FMT_L8_X24_SRGB); + COMPILE_TIME_ASSERT(220 == CM_SURF_FMT_STENCIL8); +#endif COMPILE_TIME_ASSERT(cmSurfFmt_LAST == CM_SURF_FMT_STENCIL8); COMPILE_TIME_ASSERT(cmSurfFmt_LAST < 501); }