From: Kostya Shishkov Date: Thu, 18 Nov 2021 13:07:21 +0000 (+0100) Subject: flacenc: set output packet PTS X-Git-Url: https://git.nihav.org/?a=commitdiff_plain;h=3fae33bd60f5575e63cfb1beec82a56a036e47fb;p=nihav.git flacenc: set output packet PTS --- diff --git a/nihav-llaudio/src/codecs/flacenc.rs b/nihav-llaudio/src/codecs/flacenc.rs index ccfe807..f9adc24 100644 --- a/nihav-llaudio/src/codecs/flacenc.rs +++ b/nihav-llaudio/src/codecs/flacenc.rs @@ -299,7 +299,7 @@ impl FLACEncoder { let mut dbuf = bw.end(); calc_header_crc(&mut dbuf[..hdr_crc_pos]); calc_frame_crc(&mut dbuf); - let ts = NATimeInfo::new(None, None, Some(nsamples as u64), 1, self.srate); + let ts = NATimeInfo::new(Some(self.cur_pos as u64), None, Some(nsamples as u64), 1, self.srate); for samp in self.samples.iter_mut() { samp.drain(..nsamples);