Contents

CGImageMetadataCopyTagMatchingImageProperty(_:_:_:)

Searches for the specified image property and, if found, returns the corresponding tag object.

Declaration

func CGImageMetadataCopyTagMatchingImageProperty(_ metadata: CGImageMetadata, _ dictionaryName: CFString, _ propertyName: CFString) -> CGImageMetadataTag?

Parameters

Return Value

The CGImageMetadataTag object that corresponds to the specified property, or NULL if the property wasn’t found.

Discussion

Use this function to quickly search the different metadata dictionaries for a specific tag. The returned tag object contains appropriate values for all fields, including the namespace, prefix, and XMP type.

When you request an EXIF or IPTC property, this function fills in the namespace, prefix, and XMP type information by copying information from an appropriate XMP type. For example, when you request the kCGImagePropertyExifDateTimeOriginal property, the function fills in the information using the photoshop:DateTime XMP tag. When this bridging occurs, property fields retain their XMP format, rather than the EXIF or IPTC format.

See Also

Getting the Metadata Tags