aac: clear M/S flags
[nihav.git] / nihav-duck / src / codecs / mod.rs
index 271dc5728a1aa66a287faca67f1378565aef8c12..63e899f0dc2c803038a61a7e1c5bdbedf009be5c 100644 (file)
@@ -1,11 +1,18 @@
 use nihav_core::codecs::*;
 
+#[cfg(debug_assertions)]
 macro_rules! validate {
     ($a:expr) => { if !$a { println!("check failed at {}:{}", file!(), line!()); return Err(DecoderError::InvalidData); } };
 }
+#[cfg(not(debug_assertions))]
+macro_rules! validate {
+    ($a:expr) => { if !$a { return Err(DecoderError::InvalidData); } };
+}
 
 #[cfg(feature="decoder_truemotion1")]
 mod truemotion1;
+#[cfg(any(feature="decoder_truemotion1", feature="encoder_truemotion1"))]
+mod truemotion1data;
 #[cfg(feature="decoder_truemotionrt")]
 mod truemotionrt;
 #[cfg(feature="decoder_truemotion2")]
@@ -126,6 +133,8 @@ pub fn duck_register_all_decoders(rd: &mut RegisteredDecoders) {
     }
 }
 
+#[cfg(feature="encoder_truemotion1")]
+mod truemotion1enc;
 #[cfg(feature="encoder_truemotionrt")]
 mod truemotionrtenc;
 #[cfg(feature="encoder_vp6")]
@@ -139,6 +148,8 @@ mod vp6enc;
 mod vp7enc;
 
 const DUCK_ENCODERS: &[EncoderInfo] = &[
+#[cfg(feature="encoder_truemotion1")]
+    EncoderInfo { name: "truemotion1", get_encoder: truemotion1enc::get_encoder },
 #[cfg(feature="encoder_truemotionrt")]
     EncoderInfo { name: "truemotionrt", get_encoder: truemotionrtenc::get_encoder },
 #[cfg(feature="encoder_vp6")]