MetalPerformanceShaders Functions

No overview available.

Topics

Functions

func MPSFindIntegerDivisionParams(UInt16) -> MPSIntegerDivisionParams

Returns the integer division parameters for a specified divisor.

func MPSGetCustomKernelBatchedDestinationIndex(MPSCustomKernelArgumentCount) -> UInt

Returns the index of the first destination texture argument.

func MPSGetCustomKernelBatchedSourceIndex(MPSCustomKernelArgumentCount, UInt) -> UInt

Returns the index of the specified batched source texture argument.

func MPSGetCustomKernelBroadcastSourceIndex(MPSCustomKernelArgumentCount, UInt) -> UInt

Returns the index of the specified nonbatched source texture argument.

func MPSHintTemporaryMemoryHighWaterMark(MTLCommandBuffer, Int)

Triggers Metal Performance Shaders to prefetch a Metal heap of the indicated size into its internal cache.

func MPSImageBatchIncrementReadCount([MPSImage], Int) -> Int

Increments or decrements the read count of an image batch by a specified amount.

func MPSImageBatchIterate([MPSImage], (MPSImage, Int) -> Int) -> Int

Executes a callback block once for each unique image in a batch.

func MPSImageBatchResourceSize([MPSImage]) -> Int

Returns the number of bytes used to allocate the specified image batch.

func MPSImageBatchSynchronize([MPSImage], MTLCommandBuffer)

Removes any copy of the specified image batch from the device's caches, and, if needed, invalidates any CPU caches.

func MPSSetHeapCacheDuration(MTLCommandBuffer, Double)

Sets the timeout after which unused cached Metal heaps are released.

func MPSStateBatchIncrementReadCount([MPSState]?, Int) -> Int

Increments or decrements the read count of a state batch by a specified amount.

func MPSStateBatchResourceSize([MPSState]?) -> Int

Returns the number of bytes used to allocate the specified state batch.

func MPSStateBatchSynchronize([MPSState], MTLCommandBuffer)

Removes any copy of the specified state batch from the device's caches, and, if needed, invalidates any CPU caches.