bink demuxer: save timebase in context
authorKostya Shishkov <kostya.shishkov@gmail.com>
Sun, 17 Nov 2019 07:59:10 +0000 (08:59 +0100)
committerKostya Shishkov <kostya.shishkov@gmail.com>
Sun, 17 Nov 2019 07:59:10 +0000 (08:59 +0100)
nihav-rad/src/demuxers/bink.rs

index d0ae143ac9b7d7e827a5105a95e4aa0b3723261d..8438a363d0ab315aa5548b1cf0058240cb621484 100644 (file)
@@ -66,6 +66,8 @@ impl<'a> DemuxCore<'a> for BinkDemuxer<'a> {
         let tb_num                          = src.read_u32le()?;
         validate!((width > 0) && (height > 0) && (width <= 7680) && (height <= 4800));
         validate!((self.frames > 0) && (tb_num > 0) && (tb_den > 0) && (max_size < fsize));
+        self.tb_num = tb_num;
+        self.tb_den = tb_den;
         let mut flags: [u8; 4] = [0; 4];
                                               src.read_buf(&mut flags)?;
         let mut edata: Vec<u8> = vec![0; 8];