video_info: Implement fmt::Debug

This commit is contained in:
Thibault Saunier 2017-11-06 09:20:50 -03:00 committed by Sebastian Dröge
parent 2962f186f7
commit a10532c379

View file

@ -190,6 +190,18 @@ impl ::VideoMultiviewFramePacking {
pub struct VideoInfo(pub(crate) ffi::GstVideoInfo); pub struct VideoInfo(pub(crate) ffi::GstVideoInfo);
impl fmt::Debug for VideoInfo {
fn fmt(&self, f: &mut fmt::Formatter) -> Result<(), fmt::Error> {
f.debug_struct("VideoInfo")
.field("format", &self.format())
.field("width", &self.width())
.field("height", &self.height())
.field("size", &self.size())
.finish()
}
}
pub struct VideoInfoBuilder<'a> { pub struct VideoInfoBuilder<'a> {
format: ::VideoFormat, format: ::VideoFormat,
width: u32, width: u32,