diff options
author | Kostya Shishkov <kostya.shishkov@gmail.com> | 2021-11-22 18:39:52 +0100 |
---|---|---|
committer | Kostya Shishkov <kostya.shishkov@gmail.com> | 2021-11-22 18:39:52 +0100 |
commit | dbca8a6d522fde14d236bb09e09d199259288267 (patch) | |
tree | b93ae25089230a4f1a170b47e2f4577483776c3e | |
parent | 3ab5378796abde0cd9930804c07b36d52d8c3182 (diff) | |
download | nihav-player-dbca8a6d522fde14d236bb09e09d199259288267.tar.gz |
use raw stream duration
-rw-r--r-- | sndplay/src/demux.rs | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/sndplay/src/demux.rs b/sndplay/src/demux.rs index f2e8870..ac483da 100644 --- a/sndplay/src/demux.rs +++ b/sndplay/src/demux.rs @@ -159,6 +159,9 @@ impl<'a> DemuxerObject<'a> { match *self { DemuxerObject::Normal(ref dmx) => dmx.get_duration(), DemuxerObject::Raw(ref dmx, _, _) => dmx.get_duration(), + DemuxerObject::RawStream(ref ctx) => { + NATimeInfo::ts_to_time(ctx.stream.duration, 1000, ctx.stream.tb_num, ctx.stream.tb_den) + }, _ => 0, } } |