From 086ecf41fa21138899960bb9805bc8ced91690f0 Mon Sep 17 00:00:00 2001 From: Yong He Date: Mon, 5 Apr 2021 13:31:05 -0700 Subject: Transient root shader object. (#1782) --- examples/gpu-printing/main.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'examples/gpu-printing/main.cpp') 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(); -- cgit v1.2.3