Commit 7ceff5ba authored by Sebastian Dröge's avatar Sebastian Dröge 🍵
Browse files

Print clock times as actual time in Segment/Buffer/BufferList debug output

parent 927b1ac8
......@@ -372,9 +372,9 @@ impl ToOwned for BufferRef {
impl fmt::Debug for BufferRef {
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
f.debug_struct("Buffer")
.field("pts", &self.get_pts())
.field("dts", &self.get_dts())
.field("duration", &self.get_duration())
.field("pts", &self.get_pts().to_string())
.field("dts", &self.get_dts().to_string())
.field("duration", &self.get_duration().to_string())
.field("size", &self.get_size())
.field("offset", &self.get_offset())
.field("offset_end", &self.get_offset_end())
......
......@@ -102,8 +102,8 @@ impl fmt::Debug for BufferListRef {
f.debug_struct("BufferList")
.field("buffers", &self.len())
.field("pts", &pts)
.field("dts", &dts)
.field("pts", &pts.to_string())
.field("dts", &dts.to_string())
.field("size", &size)
.finish()
}
......
......@@ -328,16 +328,16 @@ impl fmt::Debug for Segment {
Format::Time => {
f.debug_struct("Segment")
.field("format", &Format::Time)
.field("start", &ClockTime::from(self.get_start()))
.field("offset", &ClockTime::from(self.get_offset()))
.field("stop", &ClockTime::from(self.get_stop()))
.field("start", &ClockTime::from(self.get_start()).to_string())
.field("offset", &ClockTime::from(self.get_offset()).to_string())
.field("stop", &ClockTime::from(self.get_stop()).to_string())
.field("rate", &self.get_rate())
.field("applied_rate", &self.get_applied_rate())
.field("flags", &self.get_flags())
.field("time", &ClockTime::from(self.get_time()))
.field("base", &ClockTime::from(self.get_base()))
.field("position", &ClockTime::from(self.get_position()))
.field("duration", &ClockTime::from(self.get_duration()))
.field("time", &ClockTime::from(self.get_time()).to_string())
.field("base", &ClockTime::from(self.get_base()).to_string())
.field("position", &ClockTime::from(self.get_position()).to_string())
.field("duration", &ClockTime::from(self.get_duration()).to_string())
.finish()
},
_ => {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment