forked from mirrors/gstreamer-rs
Add Debug impl for Sample
This commit is contained in:
parent
d44869711a
commit
f47b30b8d1
1 changed files with 12 additions and 0 deletions
|
@ -7,6 +7,7 @@
|
||||||
// except according to those terms.
|
// except according to those terms.
|
||||||
|
|
||||||
use std::ptr;
|
use std::ptr;
|
||||||
|
use std::fmt;
|
||||||
|
|
||||||
use ffi;
|
use ffi;
|
||||||
|
|
||||||
|
@ -97,5 +98,16 @@ impl ToOwned for SampleRef {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
impl fmt::Debug for SampleRef {
|
||||||
|
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
|
||||||
|
f.debug_struct("Sample")
|
||||||
|
.field("buffer", &self.get_buffer())
|
||||||
|
.field("caps", &self.get_caps())
|
||||||
|
.field("segment", &self.get_segment())
|
||||||
|
.field("info", &self.get_info())
|
||||||
|
.finish()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
unsafe impl Sync for SampleRef {}
|
unsafe impl Sync for SampleRef {}
|
||||||
unsafe impl Send for SampleRef {}
|
unsafe impl Send for SampleRef {}
|
||||||
|
|
Loading…
Reference in a new issue