#[non_exhaustive]pub enum VideoCaptionType {
Unknown,
Cea608Raw,
Cea608S3341a,
Cea708Raw,
Cea708Cdp,
}
Expand description
The various known types of Closed Caption (CC).
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Unknown
Unknown type of CC
Cea608Raw
CEA-608 as byte pairs. Note that
this format is not recommended since is does not specify to
which field the caption comes from and therefore assumes
it comes from the first field (and that there is no information
on the second field). Use Cea708Raw
if you wish to store CEA-608 from two fields and prefix each byte pair
with 0xFC for the first field and 0xFD for the second field.
Cea608S3341a
CEA-608 as byte triplets as defined in SMPTE S334-1 Annex A. The second and third byte of the byte triplet is the raw CEA608 data, the first byte is a bitfield: The top/7th bit is 0 for the second field, 1 for the first field, bit 6 and 5 are 0 and bits 4 to 0 are a 5 bit unsigned integer that represents the line offset relative to the base-line of the original image format (line 9 for 525-line field 1, line 272 for 525-line field 2, line 5 for 625-line field 1 and line 318 for 625-line field 2).
Cea708Raw
CEA-708 as cc_data byte triplets. They can also contain 608-in-708 and the first byte of each triplet has to be inspected for detecting the type.
Cea708Cdp
CEA-708 (and optionally CEA-608) in a CDP (Caption Distribution Packet) defined by SMPTE S-334-2. Contains the whole CDP (starting with 0x9669).
Implementations§
source§impl VideoCaptionType
impl VideoCaptionType
pub fn from_caps(caps: &CapsRef) -> VideoCaptionType
Trait Implementations§
source§impl Clone for VideoCaptionType
impl Clone for VideoCaptionType
source§fn clone(&self) -> VideoCaptionType
fn clone(&self) -> VideoCaptionType
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for VideoCaptionType
impl Debug for VideoCaptionType
source§impl From<VideoCaptionType> for Value
impl From<VideoCaptionType> for Value
source§fn from(v: VideoCaptionType) -> Self
fn from(v: VideoCaptionType) -> Self
source§impl<'a> FromValue<'a> for VideoCaptionType
impl<'a> FromValue<'a> for VideoCaptionType
§type Checker = GenericValueTypeChecker<VideoCaptionType>
type Checker = GenericValueTypeChecker<VideoCaptionType>
source§unsafe fn from_value(value: &'a Value) -> Self
unsafe fn from_value(value: &'a Value) -> Self
Value
. Read moresource§impl HasParamSpec for VideoCaptionType
impl HasParamSpec for VideoCaptionType
type ParamSpec = ParamSpecEnum
§type SetValue = VideoCaptionType
type SetValue = VideoCaptionType
type BuilderFn = fn(_: &str, _: VideoCaptionType) -> ParamSpecEnumBuilder<'_, VideoCaptionType>
fn param_spec_builder() -> Self::BuilderFn
source§impl Hash for VideoCaptionType
impl Hash for VideoCaptionType
source§impl Ord for VideoCaptionType
impl Ord for VideoCaptionType
source§fn cmp(&self, other: &VideoCaptionType) -> Ordering
fn cmp(&self, other: &VideoCaptionType) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
source§impl PartialEq for VideoCaptionType
impl PartialEq for VideoCaptionType
source§impl PartialOrd for VideoCaptionType
impl PartialOrd for VideoCaptionType
source§impl StaticType for VideoCaptionType
impl StaticType for VideoCaptionType
source§fn static_type() -> Type
fn static_type() -> Type
Self
.source§impl ToValue for VideoCaptionType
impl ToValue for VideoCaptionType
source§impl ValueType for VideoCaptionType
impl ValueType for VideoCaptionType
§type Type = VideoCaptionType
type Type = VideoCaptionType
Type
from. Read moreimpl Copy for VideoCaptionType
impl Eq for VideoCaptionType
impl StructuralPartialEq for VideoCaptionType
Auto Trait Implementations§
impl Freeze for VideoCaptionType
impl RefUnwindSafe for VideoCaptionType
impl Send for VideoCaptionType
impl Sync for VideoCaptionType
impl Unpin for VideoCaptionType
impl UnwindSafe for VideoCaptionType
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)source§impl<T> IntoClosureReturnValue for T
impl<T> IntoClosureReturnValue for T
fn into_closure_return_value(self) -> Option<Value>
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§impl<T> PropertyGet for Twhere
T: HasParamSpec,
impl<T> PropertyGet for Twhere
T: HasParamSpec,
source§impl<T> StaticTypeExt for Twhere
T: StaticType,
impl<T> StaticTypeExt for Twhere
T: StaticType,
source§fn ensure_type()
fn ensure_type()
source§impl<T> ToSendValue for T
impl<T> ToSendValue for T
source§fn to_send_value(&self) -> SendValue
fn to_send_value(&self) -> SendValue
SendValue
clone of self
.