Skip to main content

Level

Enum Level 

Source
pub enum Level {
Show 17 variants Level_1_0, Level_1_B, Level_1_1, Level_1_2, Level_1_3, Level_2_0, Level_2_1, Level_2_2, Level_3_0, Level_3_1, Level_3_2, Level_4_0, Level_4_1, Level_4_2, Level_5_0, Level_5_1, Level_5_2,
}
Expand description

H.264 encoding levels with their corresponding capabilities.

LevelMax Resolution (Pixels)Max Frame Rate (fps)Max Bitrate (Main Profile)Max Bitrate (High Profile)
1.0176x144 (QCIF)1564 kbps80 kbps
1.1176x144 (QCIF)30192 kbps240 kbps
1.2320x240 (QVGA)30384 kbps480 kbps
2.0352x288 (CIF)302 Mbps2.5 Mbps
3.0720x576 (SD)3010 Mbps12.5 Mbps
3.11280x720 (HD)3014 Mbps17.5 Mbps
4.01920x1080 (Full HD)3020 Mbps25 Mbps
4.11920x1080 (Full HD)6050 Mbps62.5 Mbps
5.03840x2160 (4K)30135 Mbps168.75 Mbps
5.13840x2160 (4K)60240 Mbps300 Mbps
5.24096x2160 (4K Cinema)60480 Mbps600 Mbps

Variants§

§

Level_1_0

Level 1.0: Max resolution 176x144 (QCIF), 15 fps, 64 kbps (Main), 80 kbps (High)

§

Level_1_B

Level 1.B: Specialized low-complexity baseline level.

§

Level_1_1

Level 1.1: Max resolution 176x144 (QCIF), 30 fps, 192 kbps (Main), 240 kbps (High)

§

Level_1_2

Level 1.2: Max resolution 320x240 (QVGA), 30 fps, 384 kbps (Main), 480 kbps (High)

§

Level_1_3

Level 1.3: Reserved in standard, similar to Level 2.0.

§

Level_2_0

Level 2.0: Max resolution 352x288 (CIF), 30 fps, 2 Mbps (Main), 2.5 Mbps (High)

§

Level_2_1

Level 2.1: Max resolution 352x288 (CIF), 30 fps, 4 Mbps (Main), 5 Mbps (High)

§

Level_2_2

Level 2.2: Max resolution 352x288 (CIF), 30 fps, 10 Mbps (Main), 12.5 Mbps (High)

§

Level_3_0

Level 3.0: Max resolution 720x576 (SD), 30 fps, 10 Mbps (Main), 12.5 Mbps (High)

§

Level_3_1

Level 3.1: Max resolution 1280x720 (HD), 30 fps, 14 Mbps (Main), 17.5 Mbps (High)

§

Level_3_2

Level 3.2: Max resolution 1280x720 (HD), 60 fps, 20 Mbps (Main), 25 Mbps (High)

§

Level_4_0

Level 4.0: Max resolution 1920x1080 (Full HD), 30 fps, 20 Mbps (Main), 25 Mbps (High)

§

Level_4_1

Level 4.1: Max resolution 1920x1080 (Full HD), 60 fps, 50 Mbps (Main), 62.5 Mbps (High)

§

Level_4_2

Level 4.2: Max resolution 1920x1080 (Full HD), 120 fps, 100 Mbps (Main), 125 Mbps (High)

§

Level_5_0

Level 5.0: Max resolution 3840x2160 (4K), 30 fps, 135 Mbps (Main), 168.75 Mbps (High)

§

Level_5_1

Level 5.1: Max resolution 3840x2160 (4K), 60 fps, 240 Mbps (Main), 300 Mbps (High)

§

Level_5_2

Level 5.2: Max resolution 4096x2160 (4K Cinema), 60 fps, 480 Mbps (Main), 600 Mbps (High)

Trait Implementations§

Source§

impl Clone for Level

Source§

fn clone(&self) -> Level

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Level

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Copy for Level

Auto Trait Implementations§

§

impl Freeze for Level

§

impl RefUnwindSafe for Level

§

impl Send for Level

§

impl Sync for Level

§

impl Unpin for Level

§

impl UnsafeUnpin for Level

§

impl UnwindSafe for Level

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.