File tree Expand file tree Collapse file tree 1 file changed +16
-1
lines changed Expand file tree Collapse file tree 1 file changed +16
-1
lines changed Original file line number Diff line number Diff line change @@ -585,21 +585,36 @@ uint32_t IGPUCommandBuffer::buildAccelerationStructures_common(const std::span<c
585
585
{
586
586
// valid also checks that the `ranges` are below device limits
587
587
const auto toAdd = infos[i].valid (ranges[i]);
588
- if (toAdd!=0 )
588
+ if (toAdd==0 )
589
+ {
590
+ m_logger.log (" Acceleration Structure Build Info combined with Range %d is not valid!" ,system::ILogger::ELL_ERROR,i);
589
591
return false ;
592
+ }
590
593
if (!isCompatibleDevicewise (infos[i].dstAS ))
594
+ {
595
+ m_logger.log (
596
+ " Acceleration Structure Build Info %d destination acceleration structure `%s` is not compatible with our Logical Device!" ,system::ILogger::ELL_ERROR,
597
+ i,infos[i].dstAS ? infos[i].dstAS ->getObjectDebugName ():" nullptr"
598
+ );
591
599
return false ;
600
+ }
592
601
resourcesToTrack += toAdd;
593
602
totalGeometries += infos[i].inputCount ();
594
603
}
595
604
// infos array was empty
596
605
if (resourcesToTrack==0u )
606
+ {
607
+ m_logger.log (" Acceleration Structure Build Info span was empty!" , system::ILogger::ELL_ERROR);
597
608
return false ;
609
+ }
598
610
599
611
if (indirectBuffer)
600
612
{
601
613
if (!features.accelerationStructureIndirectBuild )
614
+ {
615
+ m_logger.log (" Indirect Acceleration Structure Build Feature not enabled!" , system::ILogger::ELL_ERROR);
602
616
return false ;
617
+ }
603
618
resourcesToTrack++;
604
619
}
605
620
You can’t perform that action at this time.
0 commit comments