Fix compile error on some clangs with non-const string literals

This commit is contained in:
baldurk
2023-09-13 16:25:09 +01:00
parent 02272f98ac
commit 92f4aeacde
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -177,7 +177,7 @@ void main()
GLuint program = MakeProgram(common + vertex, common + pixel);
GLuint whiteprogram = MakeProgram(common + vertex, whitepixel);
char *fmtNames[] = {"D24_S8", "D32F_S8", "D16_S0", "D24_S0", "D32F_S0"};
const char *fmtNames[] = {"D24_S8", "D32F_S8", "D16_S0", "D24_S0", "D32F_S0"};
GLenum fmts[] = {GL_DEPTH24_STENCIL8, GL_DEPTH32F_STENCIL8, GL_DEPTH_COMPONENT16,
GL_DEPTH_COMPONENT24, GL_DEPTH_COMPONENT32F};
const size_t countFmts = ARRAY_COUNT(fmts);
+1 -1
View File
@@ -217,7 +217,7 @@ void main()
std::vector<std::string> supportedFmtNames;
std::vector<VkFormat> supportedFmts;
{
char *possibleFmtNames[] = {"D24_S8", "D32F_S8", "D16_S0", "D24_S0", "D32F_S0"};
const char *possibleFmtNames[] = {"D24_S8", "D32F_S8", "D16_S0", "D24_S0", "D32F_S0"};
VkFormat possibleFmts[] = {VK_FORMAT_D24_UNORM_S8_UINT, VK_FORMAT_D32_SFLOAT_S8_UINT,
VK_FORMAT_D16_UNORM, VK_FORMAT_X8_D24_UNORM_PACK32,
VK_FORMAT_D32_SFLOAT};