diff --git a/src/util/mod.rs b/src/util/mod.rs index e69de29..9a8d351 100644 --- a/src/util/mod.rs +++ b/src/util/mod.rs @@ -0,0 +1,53 @@ +use std::error::Error; +use std::fmt; + +pub struct VideoMetadata { + pub width: u32, + pub height: u32, + pub framerate: f32, + pub codec: Option, +} + +pub enum VideoCodec { + H264, +} + +pub struct AudioMetadata { + pub samplerate: u32, + pub channels: u8, + pub codec: Option, +} + +pub enum AudioCodec { + AAC, +} + +pub struct Metadata { + pub video: VideoMetadata, + pub audio: AudioMetadata, +} + +pub enum FileType { + FLV, + MPEGTS, +} + +pub enum NALUPacketType { + Audio, + Video, +} + +pub struct NALUPacket { + pub packet_type: NALUPacketType, + pub packet_data: Vec, +} + +pub enum RawMediaType { + YUV420P, + PCM16LE, +} + +pub struct RawMedia { + pub media_type: RawMediaType, + pub sample: Vec, +}