codec/subtitle: add Subtitle

This commit is contained in:
meh 2015-05-12 03:46:25 +02:00
parent 42564d0d5e
commit 64c6678f04
3 changed files with 18 additions and 0 deletions

View File

@ -3,6 +3,8 @@ pub use self::id::Id;
pub mod packet;
pub mod subtitle;
use std::ffi::CStr;
use std::str::from_utf8_unchecked;

15
src/codec/subtitle.rs Normal file
View File

@ -0,0 +1,15 @@
use std::mem;
use ffi::*;
pub struct Subtitle {
pub val: AVSubtitle,
}
impl Subtitle {
pub fn new() -> Self {
unsafe {
Subtitle { val: mem::zeroed() }
}
}
}

View File

@ -16,3 +16,4 @@ pub use util::frame::{self, Frame};
pub mod codec;
pub use codec::packet::{self, Packet};
pub use codec::subtitle::Subtitle;