CommandBuffer.DispatchRays(RayTracingShader,string,int,int,int,Camera)

매뉴얼로 전환

파라미터

raytracingShader RayTracingShader to execute.
rayGenShaderNameName of the ray generation shader.
rayGenShaderNameIDProperty name ID. Use Shader.PropertyToID to get this ID.
widthThe width of the ray generation shader thread grid.
heightThe height of the ray generation shader thread grid.
depthThe depth of the ray generation shader thread grid.
cameraThe Camera to be used as environment to dispatch RayTracingShader.

설명

Add a command to execute a RayTracingShader.

When the command buffer executes, a RayTracingShader is dispatched and launches the threads of ray generation shader. Width, height and depth must be above zero and width*height*depth <= 2^30.