Contents

canApply(outputSettings:forMediaType:)

Determines whether the output file format supports the output settings for a specific media type.

Declaration

func canApply(outputSettings: [String : Any]?, forMediaType mediaType: AVMediaType) -> Bool

Parameters

  • outputSettings:

    The output settings to validate.

  • mediaType:

    The media type to validate the output settings for.

Return Value

true if the format supports the output settings; otherwise, false.

Discussion

Use this method to determine the compatibility of output settings for a particular media type. For example, video compression settings that specify H.264 compression aren’t compatible with file formats that don’t contain H.264-compressed video.

See Also

Configuring inputs