aac: clear M/S flags
[nihav.git] / nihav-registry / src / register.rs
index 5e06224a7c42431d06c1e6a5633e2ede079048a7..15a3f65b8ed52c8d979446260fd416a459580e5c 100644 (file)
@@ -147,12 +147,7 @@ macro_rules! desc {
 
 /// Returns codec description for the provided codec short name if it is found.
 pub fn get_codec_description(name: &str) -> Option<&'static CodecDescription> {
-    for reg in CODEC_REGISTER {
-        if reg.name == name {
-            return Some(reg);
-        }
-    }
-    None
+    CODEC_REGISTER.iter().find(|&reg| reg.name == name)
 }
 
 static CODEC_REGISTER: &[CodecDescription] = &[
@@ -165,6 +160,7 @@ static CODEC_REGISTER: &[CodecDescription] = &[
     desc!(video;    "indeo3", "Intel Indeo 3"),
     desc!(video;    "indeo4", "Intel Indeo 4", CODEC_CAP_REORDER | CODEC_CAP_SCALABLE),
     desc!(video;    "indeo5", "Intel Indeo 5", CODEC_CAP_REORDER | CODEC_CAP_SCALABLE),
+    desc!(video;    "indeo5s", "Intel Indeo 5 Scalable", CODEC_CAP_SCALABLE),
     desc!(video;    "intel263", "Intel I263", CODEC_CAP_REORDER),
     desc!(audio;    "iac",    "Intel Indeo audio"),
     desc!(audio;    "imc",    "Intel Music Coder"),
@@ -185,6 +181,10 @@ static CODEC_REGISTER: &[CodecDescription] = &[
     desc!(audio;    "atrac3",     "Sony Atrac3"),
     desc!(audio;    "sipro",      "Sipro Labs ADPCM"),
 
+
+    desc!(video-ll; "rawvideo",   "Raw video data"),
+    desc!(video-ll; "rawvideo-ms", "Raw video data"),
+
     desc!(video;    "cinepak",    "Cinepak"),
 
     desc!(video-llp; "zmbv",      "Zip Motion Blocks Video"),
@@ -199,6 +199,7 @@ static CODEC_REGISTER: &[CodecDescription] = &[
     desc!(video;    "apple-video",          "Apple video"),
     desc!(video;    "sorenson-video",       "Sorenson Video"),
     desc!(video;    "sorenson-video3",      "Sorenson Video 3", CODEC_CAP_REORDER),
+    desc!(audio-ll; "alac",                 "Apple Lossless Audio Codec"),
     desc!(audio;    "mace-3",               "MACE 3:1"),
     desc!(audio;    "mace-6",               "MACE 6:1"),
     desc!(audio;    "ima-adpcm-qt",         "IMA ADPCM (Apple variant)"),
@@ -206,6 +207,20 @@ static CODEC_REGISTER: &[CodecDescription] = &[
     desc!(audio;    "qdesign-music2",       "QDesign Music v2"),
     desc!(audio;    "qualcomm-purevoice",   "Qualcomm PureVoice"),
 
+    desc!(video-ll; "arm_rawvideo",         "Acorn Replay Movie raw video formats"),
+    desc!(audio;    "arm_rawaudio",         "Acorn Replay Movie raw audio formats"),
+    desc!(video;    "movinglines",          "Acorn Moving Lines"),
+    desc!(video;    "movingblocks",         "Acorn Moving Blocks"),
+    desc!(video;    "movingblockshq",       "Acorn Moving Blocks HQ"),
+    desc!(video;    "supermovingblocks",    "Acorn Super Moving Blocks"),
+    desc!(video;    "linepack",             "Henrik Pedersen's LinePack"),
+    desc!(video;    "movie16_3",            "Henrik Pedersen's Movie 16:3"),
+    desc!(video;    "escape100",            "Eidos Escape 100"),
+    desc!(video;    "escape102",            "Eidos Escape 102"),
+    desc!(video;    "escape122",            "Eidos Escape 122"),
+    desc!(video;    "escape124",            "Eidos Escape 124"),
+    desc!(video;    "escape130",            "Eidos Escape 130"),
+
     desc!(video;    "truemotion1",   "TrueMotion 1"),
     desc!(video-im; "truemotionrt",  "TrueMotion RT"),
     desc!(video;    "truemotion2",   "TrueMotion 2"),
@@ -214,7 +229,8 @@ static CODEC_REGISTER: &[CodecDescription] = &[
     desc!(video;    "vp4",           "VP4"),
     desc!(video;    "vp5",           "VP5"),
     desc!(video;    "vp6",           "VP6"),
-    desc!(video;    "vp6a",          "VP6"),
+    desc!(video;    "vp6f",          "VP6 (in Flash)"),
+    desc!(video;    "vp6a",          "VP6 with alpha"),
     desc!(video;    "vp7",           "VP7"),
     desc!(video;    "vp8",           "VP8"),
     desc!(video;    "vp9",           "VP9"),
@@ -223,18 +239,41 @@ static CODEC_REGISTER: &[CodecDescription] = &[
     desc!(audio;    "on2avc-500",    "On2 AVC"),
     desc!(audio;    "on2avc-501",    "On2 AVC"),
 
+    desc!(video;     "flv263",       "Sorenson H.263"),
+    desc!(video-llp; "flashsv",      "Flash Screen Video"),
+    desc!(video-llp; "flashsv2",     "Flash Screen Video 2"),
+    desc!(audio;     "asao",         "N*llym*s*r ASAO"),
+    desc!(audio;     "flv-adpcm",    "Flash ADPCM"),
+
+    desc!(audio;     "mp1",          "MPEG Audio Layer I"),
+    desc!(audio;     "mp2",          "MPEG Audio Layer II"),
+    desc!(audio;     "mp3",          "MPEG Audio Layer III"),
+    desc!(audio;     "speex",        "Speex"),
+
     desc!(video;    "gdv-video",     "Gremlin Digital Video - video"),
     desc!(audio;    "gdv-audio",     "Gremlin Digital Video - audio"),
+    desc!(video-im; "arxel-video",   "Arxel Tribe Video"),
+    desc!(video;    "beam-fcp",      "Beam Software Animation"),
+    desc!(video;    "beam-video",    "Beam Software Video"),
     desc!(video;    "bmv-video",     "BMV video"),
     desc!(audio;    "bmv-audio",     "BMV audio"),
     desc!(video;    "bmv3-video",    "DW Noir BMV video"),
     desc!(audio;    "bmv3-audio",    "DW Noir BMV audio"),
+    desc!(video;    "dp-sga",        "Digital Pictures SGA video"),
     desc!(video;    "fable-imax",    "Fable IMAX video"),
     desc!(video;    "fst-video",     "FutureVision video"),
     desc!(audio;    "fst-audio",     "FutureVision audio"),
+    desc!(video;    "hl-fmv-video",  "Highlander FMV video"),
+    desc!(video-llp; "ipma",         "Imagination Pilots Matte Animation"),
+    desc!(video-llp; "ipma2",        "Imagination Pilots Matte Animation v2"),
+    desc!(video;    "legend-q-video", "Legend Entertainment Q video"),
     desc!(video;    "midivid",       "MidiVid"),
     desc!(video;    "midivid3",      "MidiVid 3"),
     desc!(video-ll; "midivid-ll",    "MidiVid Lossless"),
+    desc!(video;    "smushv1",       "SMUSH Video paletted"),
+    desc!(video;    "smushv2",       "SMUSH Video 16-bit"),
+    desc!(video;    "smush-iact",    "SMUSH IACT Audio"),
+    desc!(video;    "smush-vima",    "SMUSH VIMA Audio"),
     desc!(video;    "vmd-video",     "VMD video"),
     desc!(audio;    "vmd-audio",     "VMD audio"),
     desc!(video;    "vxvideo",       "Actimagine Vx"),
@@ -262,7 +301,11 @@ static CODEC_REGISTER: &[CodecDescription] = &[
     desc!(audio-ll;  "tta",          "True Audio codec"),
     desc!(audio-hyb; "wavpack",      "WavPack"),
 
+    desc!(video-ll; "gif",           "GIF"),
+    desc!(video-im; "jpeg",          "JPEG"),
     desc!(video;    "h264",          "ITU H.264", CODEC_CAP_COMPLEX_REORDER | CODEC_CAP_HYBRID),
+
+    desc!(video-im; "mwv1",          "Aware MotionWavelets"),
 ];
 
 static AVI_VIDEO_CODEC_REGISTER: &[(&[u8;4], &str)] = &[
@@ -273,6 +316,8 @@ static AVI_VIDEO_CODEC_REGISTER: &[(&[u8;4], &str)] = &[
     (b"MSVC", "msvideo1"),
     (b"WHAM", "msvideo1"),
 
+    (b"MJPG", "jpeg"),
+
     (b"IF09", "indeo1"),
     (b"RT21", "indeo2"),
     (b"IV31", "indeo3"),
@@ -285,6 +330,9 @@ static AVI_VIDEO_CODEC_REGISTER: &[(&[u8;4], &str)] = &[
     (b"cvid", "cinepak"),
     (b"ZMBV", "zmbv"),
 
+    (b"Ipma", "ipma"),
+    (b"Ip20", "ipma2"),
+
     (b"MVDV", "midivid"),
     (b"MV30", "midivid3"),
     (b"MVLZ", "midivid-ll"),
@@ -303,6 +351,8 @@ static AVI_VIDEO_CODEC_REGISTER: &[(&[u8;4], &str)] = &[
     (b"VP62", "vp6"),
     (b"VP6A", "vp6a"),
     (b"VP70", "vp7"),
+
+    (b"MWV1", "mwv1"),
 ];
 
 static WAV_CODEC_REGISTER: &[(u16, &str)] = &[
@@ -368,6 +418,8 @@ static MOV_AUDIO_CODEC_REGISTER: &[(&[u8;4], &str)] = &[
     //(b".mp3", "mpeg-layer3"),
 
     (b"mp4a", "aac"),
+
+    (b"alac", "alac"),
 ];
 
 /// Returns video codec short name for provided FOURCC (used in AVI format).