Skip to content

Commit 2dad653

Browse files
committed
GPU: Add missing compute-writeable texture formats
1 parent 992e4c5 commit 2dad653

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/gpu/SDL_gpu.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,7 @@ static bool TextureFormatIsComputeWritable[] = {
195195
true, // R16_UNORM
196196
true, // R16G16_UNORM
197197
true, // R16G16B16A16_UNORM
198-
false, // R10G10B10A2_UNORM
198+
true, // R10G10B10A2_UNORM
199199
false, // B5G6R5_UNORM
200200
false, // B5G5R5A1_UNORM
201201
false, // B4G4R4A4_UNORM
@@ -220,7 +220,7 @@ static bool TextureFormatIsComputeWritable[] = {
220220
true, // R32_FLOAT
221221
true, // R32G32_FLOAT
222222
true, // R32G32B32A32_FLOAT
223-
false, // R11G11B10_UFLOAT
223+
true, // R11G11B10_UFLOAT
224224
true, // R8_UINT
225225
true, // R8G8_UINT
226226
true, // R8G8B8A8_UINT
@@ -839,7 +839,7 @@ bool SDL_GPUTextureSupportsFormat(
839839
CHECK_TEXTUREFORMAT_ENUM_INVALID(format, false)
840840
}
841841

842-
if ((usage & SDL_GPU_TEXTUREUSAGE_COMPUTE_STORAGE_WRITE) ||
842+
if ((usage & SDL_GPU_TEXTUREUSAGE_COMPUTE_STORAGE_WRITE) ||
843843
(usage & SDL_GPU_TEXTUREUSAGE_COMPUTE_STORAGE_SIMULTANEOUS_READ_WRITE)) {
844844
if (!TextureFormatIsComputeWritable[format]) {
845845
return false;

0 commit comments

Comments
 (0)