copyCommands(sourceBuffer:sourceRange:destinationBuffer:destinationIndex:)
Encodes a command that copies commands from one indirect command buffer into another.
Declaration
func copyCommands(sourceBuffer: any MTLIndirectCommandBuffer, sourceRange: Range<Int>, destinationBuffer: any MTLIndirectCommandBuffer, destinationIndex: Int)Parameters
- sourceBuffer:
An Mtlindirectcommandbuffer instance the command copies from.
- sourceRange:
The range of commands in
sourceBufferto copy. The source range needs to start at a valid execution point. - destinationBuffer:
Another Mtlindirectcommandbuffer instance the command copies to.
- destinationIndex:
An index in
destinationBufferwhere the command copies content to. The destination index needs to be a valid execution point with enough remaining space indestinationBufferto accommodatesourceRange.countcommands.