Contents

makeDefaultLibrary()

Creates a Metal library instance that contains the functions from your app’s default Metal library.

Declaration

func makeDefaultLibrary() -> (any MTLLibrary)?

Return Value

A new MTLLibrary instance if the method completes successfully; otherwise nil.

Discussion

Xcode compiles all the Metal source files (ending in .metal) in an Xcode project into a single default library.

See Also

Creating shader libraries