Getting video file type formats from UTI's

Viewed 879

I'm building a video editing application that uses AVFoundation. When the user goes to import their video (via an NSOpenPanel file browser), I only want to allow them to select acceptable video formats that AVFoundation supports.

You can retrieve those accepted formats by calling audioVisualTypes() on AVURLAsset. However, these formats include a lot of gibberish / stuff I don't need, ex:

 "public.mpeg",


    "dyn.ah62d46dzqm0gw23sqf40k4pts3y1g7pbru00g55ssvw067b4gq81q4peqz1w88brrz2de7a",
        "public.dv-movie",
        "public.pls-playlist",

"dyn.ah62d46dzqm0gw23sqf40k4pts3y1g7pbru00g55ssvw067b4gq80c6durvy0g2pyrf106p50r3wc62pusb0gnpxrsbw0s7pwru",
    "public.aac-audio",

Does anyone have an idea of how to parse these into a simple array of file extensions? Thanks

1 Answers
Related