summaryrefslogtreecommitdiff
path: root/tools/gfx/d3d12/d3d12-command-encoder.cpp
diff options
context:
space:
mode:
authorEllie Hermaszewska <ellieh@nvidia.com>2024-11-06 01:47:26 +0800
committerGitHub <noreply@github.com>2024-11-05 09:47:26 -0800
commitb118451e301d734e3e783b3acdf871f3f6ea851c (patch)
tree277f160d31e2c442f724bc6a2d3c09fabff403ca /tools/gfx/d3d12/d3d12-command-encoder.cpp
parent53dd5928c35d5a5cb1f7d2a563348fd1fa87d672 (diff)
Move switch statement bodies to their own lines (#5493)
* Move switch statement bodies to their own lines * format --------- Co-authored-by: Yong He <yonghe@outlook.com>
Diffstat (limited to 'tools/gfx/d3d12/d3d12-command-encoder.cpp')
-rw-r--r--tools/gfx/d3d12/d3d12-command-encoder.cpp20
1 files changed, 14 insertions, 6 deletions
diff --git a/tools/gfx/d3d12/d3d12-command-encoder.cpp b/tools/gfx/d3d12/d3d12-command-encoder.cpp
index f0b4b0dfc..bed31f2f5 100644
--- a/tools/gfx/d3d12/d3d12-command-encoder.cpp
+++ b/tools/gfx/d3d12/d3d12-command-encoder.cpp
@@ -24,10 +24,15 @@ int PipelineCommandEncoder::getBindPointIndex(PipelineType type)
{
switch (type)
{
- case PipelineType::Graphics: return 0;
- case PipelineType::Compute: return 1;
- case PipelineType::RayTracing: return 2;
- default: assert(!"unknown pipeline type."); return -1;
+ case PipelineType::Graphics:
+ return 0;
+ case PipelineType::Compute:
+ return 1;
+ case PipelineType::RayTracing:
+ return 2;
+ default:
+ assert(!"unknown pipeline type.");
+ return -1;
}
}
@@ -124,7 +129,9 @@ Result PipelineCommandEncoder::_bindRenderState(
d3dheap = m_transientHeap->getCurrentSamplerHeap().getHeap();
m_commandBuffer->bindDescriptorHeaps();
break;
- default: assert(!"shouldn't be here"); return SLANG_FAIL;
+ default:
+ assert(!"shouldn't be here");
+ return SLANG_FAIL;
}
// Try again.
@@ -456,7 +463,8 @@ void ResourceCommandEncoderImpl::clearResourceView(
}
break;
}
- default: break;
+ default:
+ break;
}
}