format/stream: add stream metadata
This commit is contained in:
parent
991bbc24e8
commit
206ccd4e5a
@ -1,7 +1,7 @@
|
||||
use libc::c_int;
|
||||
use ffi::*;
|
||||
use ::codec::{self, packet};
|
||||
use ::{Rational, Discard};
|
||||
use ::{Rational, Discard, DictionaryRef};
|
||||
use super::Disposition;
|
||||
use format::context::common::Context;
|
||||
|
||||
@ -90,6 +90,12 @@ impl<'a> Stream<'a> {
|
||||
Rational::from((*self.as_ptr()).avg_frame_rate)
|
||||
}
|
||||
}
|
||||
|
||||
pub fn metadata(&self) -> DictionaryRef {
|
||||
unsafe {
|
||||
DictionaryRef::wrap((*self.as_ptr()).metadata)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
impl<'a> PartialEq for Stream<'a> {
|
||||
|
Loading…
x
Reference in New Issue
Block a user