add correct media format profiles to res elements