]> git.nihav.org Git - nihav.git/blobdiff - nihav-codec-support/src/test/enc_video.rs
codec_support: fix or silence clippy warnings
[nihav.git] / nihav-codec-support / src / test / enc_video.rs
index 6f9e1ec2c69ffe36c0326226853bcd61d99b31a5..c27459e035e6ade504e327194b96c2f144ebe45b 100644 (file)
@@ -133,7 +133,7 @@ pub fn test_remuxing_md5(dec_config: &DecoderTestParams, muxer: &str, mux_reg: &
 
     let mux_f = mux_reg.find_muxer(muxer).unwrap();
 
-    let mut dst = Vec::with_capacity(1048576);
+    let mut dst = Vec::with_capacity(1 << 10);
     let mut gw = GrowableMemoryWriter::new_write(&mut dst);
     let mut bw = ByteWriter::new(&mut gw);
     let mut out_sm = StreamManager::new();
@@ -258,7 +258,7 @@ pub fn test_encoding_to_file(dec_config: &DecoderTestParams, enc_config: &Encode
     let mut encoder = (encfunc)();
     let out_str = encoder.init(0, enc_params).unwrap();
     out_sm.add_stream(NAStream::clone(&out_str));
-    
+
     let mux_f = enc_config.mux_reg.find_muxer(enc_config.muxer).unwrap();
     let out_name = "assets/test_out/".to_owned() + enc_config.out_name;
     let file = File::create(&out_name).unwrap();
@@ -271,7 +271,7 @@ pub fn test_encoding_to_file(dec_config: &DecoderTestParams, enc_config: &Encode
              vinfo)
         } else {
             (ScaleInfo { fmt: YUV420_FORMAT, width: 2, height: 2 },
-             NAVideoInfo { width: 2, height: 2, format: YUV420_FORMAT, flipped: false })
+             NAVideoInfo { width: 2, height: 2, format: YUV420_FORMAT, flipped: false, bits: 12 })
         };
     let ofmt = ifmt;
     let mut scaler = NAScale::new(ifmt, ofmt).unwrap();