This project has moved and is read-only. For the latest updates, please go here.

Possible bug in BC6/BC7 DirectCompute conversion code

Jan 22, 2014 at 1:37 PM

I think I found a bug in BCDirectCompute.cpp.

Five of the seven calls to RunComputeShader calculate a reduced value for X with the code:
  • std::max<UINT>(uThreadGroupCount / 2, 1) or:
  • std::max<UINT>(uThreadGroupCount / 4, 1)
I believe that the logic should round up instead, e.g:
  • (uThreadGroupCount+1)/2 or:
  • (uThreadGroupCount+3)/4.
When converting a 92x92 image (23x23 = 529 blocks) I found that the last block was set all black. Making the suggested change did fix the problem.

Thanks, it's great to have a project like this open-sourced!
Jan 22, 2014 at 7:08 PM
Edited Jan 24, 2014 at 10:16 PM
Thanks for the report.

Fixed in changelist 33785 and is included in the January 2014 release.
Marked as answer by walbourn on 1/24/2014 at 2:16 PM