Browse Source

Source also should be storage tex

Heedong Arkiny Lee 5 years ago
parent
commit
278ac2b1ad
1 changed files with 1 additions and 1 deletions
  1. 1
    1
      Samples/ComputeShader/ComputeShader.cpp

+ 1
- 1
Samples/ComputeShader/ComputeShader.cpp View File

228
             texDesc.mipmapLevels = 1;
228
             texDesc.mipmapLevels = 1;
229
             texDesc.sampleCount = 1;
229
             texDesc.sampleCount = 1;
230
             texDesc.arrayLength = 1;
230
             texDesc.arrayLength = 1;
231
-            texDesc.usage = DKTexture::UsageCopyDestination | DKTexture::UsageSampled;
231
+            texDesc.usage = DKTexture::UsageStorage | DKTexture::UsageShaderRead | DKTexture::UsageCopyDestination | DKTexture::UsageSampled;
232
             DKObject<DKTexture> tex = device->CreateTexture(texDesc);
232
             DKObject<DKTexture> tex = device->CreateTexture(texDesc);
233
             if (tex)
233
             if (tex)
234
             {
234
             {