#[derive(Debug, Default, Clone, Copy)]
pub struct VideoPacketExtra {
key: bool,
}
impl VideoPacketExtra {
pub const fn new(key: bool) -> Self {
Self { key }
}
pub const fn key(&self) -> bool {
self.key
}
#[must_use]
pub const fn with_key(mut self, key: bool) -> Self {
self.key = key;
self
}
pub const fn set_key(&mut self, key: bool) -> &mut Self {
self.key = key;
self
}
}
#[derive(Debug, Default, Clone, Copy)]
pub struct VideoFrameExtra {
key: bool,
}
impl VideoFrameExtra {
pub const fn new(key: bool) -> Self {
Self { key }
}
pub const fn key(&self) -> bool {
self.key
}
#[must_use]
pub const fn with_key(mut self, key: bool) -> Self {
self.key = key;
self
}
pub const fn set_key(&mut self, key: bool) -> &mut Self {
self.key = key;
self
}
}
#[derive(Debug, Default, Clone, Copy)]
pub struct AudioPacketExtra {
key: bool,
}
impl AudioPacketExtra {
pub const fn new(key: bool) -> Self {
Self { key }
}
pub const fn key(&self) -> bool {
self.key
}
#[must_use]
pub const fn with_key(mut self, key: bool) -> Self {
self.key = key;
self
}
pub const fn set_key(&mut self, key: bool) -> &mut Self {
self.key = key;
self
}
}
#[derive(Debug, Default, Clone, Copy)]
pub struct AudioFrameExtra {
key: bool,
}
impl AudioFrameExtra {
pub const fn new(key: bool) -> Self {
Self { key }
}
pub const fn key(&self) -> bool {
self.key
}
#[must_use]
pub const fn with_key(mut self, key: bool) -> Self {
self.key = key;
self
}
pub const fn set_key(&mut self, key: bool) -> &mut Self {
self.key = key;
self
}
}