Instance Method

newTexturesWithContentsOfURLs:options:completionHandler:

Asynchronously loads image data and creates new Metal textures from the specified list of URLs.

Declaration

- (void)newTexturesWithContentsOfURLs:(NSArray<NSURL *> *)URLs options:(NSDictionary<MTKTextureLoaderOption, id> *)options completionHandler:(MTKTextureLoaderArrayCallback)completionHandler;

Parameters

URLs

An array of URLs referencing files to load.

options

A dictionary describing any additional texture loading steps. See Texture Loading Options.

completionHandler

A block called after all URLs have been processed. See the MTKTextureLoaderArrayCallback signature to determine whether each texture has successfully loaded.

See Also

Loading Textures from URLs

- newTextureWithContentsOfURL:options:error:

Synchronously loads image data and creates a new Metal texture from a given URL.

- newTextureWithContentsOfURL:options:completionHandler:

Asynchronously loads image data and creates a new Metal texture from a given URL.

- newTexturesWithContentsOfURLs:options:error:

Synchronously loads image data and creates new Metal textures from the specified list of URLs.