Function

CMMetadataFormatDescriptionCreateWithKeys(allocator:metadataType:keys:formatDescriptionOut:)

Creates a metadata format description object specified by the key.

Declaration

func CMMetadataFormatDescriptionCreateWithKeys(allocator: CFAllocator?, metadataType: CMMetadataFormatType, keys: CFArray?, formatDescriptionOut: UnsafeMutablePointer<CMMetadataFormatDescription?>) -> OSStatus

Parameters

allocator

CFAllocator to be used. Pass NULL or kCFAllocatorDefault to use the default allocator.

metadataType

The type of metadata (kCMMetadataFormatType_Boxed).

keys

Array of metadata keys. Each key is a dictionary of key properties. The required properties are:

  • kCMMetadataFormatDescriptionKey_Namespace

  • kCMMetadataFormatDescriptionKey_Value

  • kCMMetadataFormatDescriptionKey_LocalID

outDesc

Returns newly created metadata CMFormatDescription.

Return Value

A result code. Returns noErr if successful.

See Also

Metadata-Specific Functions

func CMSwapBigEndianMetadataDescriptionToHost(UnsafeMutablePointer<UInt8>, Int) -> OSStatus

Converts a MetadataDescription data structure from big-endian to host-endian in place.

func CMSwapHostEndianMetadataDescriptionToBig(UnsafeMutablePointer<UInt8>, Int) -> OSStatus

Converts a MetadataDescription data structure from host-endian to big-endian in place.

func CMMetadataFormatDescriptionGetIdentifiers(CMMetadataFormatDescription) -> CFArray?

Gets an array of metadata identifiers from a metadata format description.