diff options
| author | Yong He <yonghe@outlook.com> | 2021-04-05 13:31:05 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-04-05 13:31:05 -0700 |
| commit | 086ecf41fa21138899960bb9805bc8ced91690f0 (patch) | |
| tree | c98af81ffc28371a9334e71987a85f9e88bce678 /examples/gpu-printing | |
| parent | dd662f5cda97e7a6720ef526509a772a06112d4a (diff) | |
Transient root shader object. (#1782)
Diffstat (limited to 'examples/gpu-printing')
| -rw-r--r-- | examples/gpu-printing/main.cpp | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/examples/gpu-printing/main.cpp b/examples/gpu-printing/main.cpp index a0acb8159..265b4c5ff 100644 --- a/examples/gpu-printing/main.cpp +++ b/examples/gpu-printing/main.cpp @@ -121,9 +121,7 @@ Result execute() auto queue = gDevice->createCommandQueue(queueDesc); auto commandBuffer = transientHeap->createCommandBuffer(); auto encoder = commandBuffer->encodeComputeCommands(); - auto rootShaderObject = gDevice->createRootShaderObject(gProgram); - encoder->setPipelineState(gPipelineState); - encoder->bindRootShaderObject(rootShaderObject); + auto rootShaderObject = encoder->bindPipeline(gPipelineState); encoder->dispatchCompute(1, 1, 1); encoder->endEncoding(); commandBuffer->close(); |
