MTCopyLocalizedNameForMediaSubType is a function in the MediaToolbox framework that gets a localized value of a codec string.
Before I migrated to MTCopyLocalizedNameForMediaSubType, I created a "clever" way of getting a localized string from the "MediaAndSubtypes" strings.
A caveat if you do use MTCopyLocalizedNameForMediaSubType: If it doesn't map to a codec, it'll return the codec, converted from the fourchar into a CFString. Make sure you catch that.
A lot of video codec fourchars can be found in CoreMedia/CMFormatDescription.h, with audio codecs in CoreAudioTypes/CoreAudioBaseTypes.h (the audio codecs' header has been moved recently).
MTCopyLocalizedNameForMediaSubTypeis a function in the MediaToolbox framework that gets a localized value of a codec string.Before I migrated to
MTCopyLocalizedNameForMediaSubType, I created a "clever" way of getting a localized string from the "MediaAndSubtypes" strings.A caveat if you do use
MTCopyLocalizedNameForMediaSubType: If it doesn't map to a codec, it'll return the codec, converted from the fourchar into aCFString. Make sure you catch that.A lot of video codec fourchars can be found in
CoreMedia/CMFormatDescription.h, with audio codecs inCoreAudioTypes/CoreAudioBaseTypes.h(the audio codecs' header has been moved recently).