You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When adding a new track to Mp4Writer, is it better that returns track_id? so that with the track_id, a user can call write_sample conveniently. otherwise a user have to keep order of adding track, and using the sequence number as the track_id.
pub fn add_track(&mut self, config: &TrackConfig) -> Result {
let track_id = self.tracks.len() as u32 + 1;
let track = Mp4TrackWriter::new(track_id, config)?;
self.tracks.push(track);
Ok((self.tracks.len() + 1) as u32)
}
Thanks.
The text was updated successfully, but these errors were encountered:
When adding a new track to Mp4Writer, is it better that returns track_id? so that with the track_id, a user can call write_sample conveniently. otherwise a user have to keep order of adding track, and using the sequence number as the track_id.
pub fn add_track(&mut self, config: &TrackConfig) -> Result {
let track_id = self.tracks.len() as u32 + 1;
let track = Mp4TrackWriter::new(track_id, config)?;
self.tracks.push(track);
Ok((self.tracks.len() + 1) as u32)
}
Thanks.
The text was updated successfully, but these errors were encountered: