pub struct RoiEncoder { /* private fields */ }Expand description
The ROI encoder optimizer generates per-CTU QP delta maps from ROI regions.
Implementations§
Source§impl RoiEncoder
impl RoiEncoder
Sourcepub fn new(config: RoiEncoderConfig) -> Self
pub fn new(config: RoiEncoderConfig) -> Self
Creates a new ROI encoder with the given configuration.
Sourcepub fn add_region(&mut self, region: RoiRegion)
pub fn add_region(&mut self, region: RoiRegion)
Adds a region of interest.
Sourcepub fn clear_regions(&mut self)
pub fn clear_regions(&mut self)
Clears all ROI regions.
Sourcepub fn region_count(&self) -> usize
pub fn region_count(&self) -> usize
Returns the number of configured regions.
Sourcepub fn config(&self) -> &RoiEncoderConfig
pub fn config(&self) -> &RoiEncoderConfig
Returns the encoder configuration.
Sourcepub fn generate_qp_map(&self) -> QpDeltaMap
pub fn generate_qp_map(&self) -> QpDeltaMap
Generates a QP delta map for the current set of regions.
Sourcepub fn optimize_frame(&self) -> RoiOptimizeResult
pub fn optimize_frame(&self) -> RoiOptimizeResult
Generates an RoiOptimizeResult for pipeline integration with the main Optimizer.
This produces a result that includes both the QP delta map and per-block quality weights that the Optimizer uses to adjust AQ decisions.
Sourcepub fn estimate_bitrate_impact(&self) -> f64
pub fn estimate_bitrate_impact(&self) -> f64
Estimates the bitrate savings/cost relative to uniform encoding.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for RoiEncoder
impl RefUnwindSafe for RoiEncoder
impl Send for RoiEncoder
impl Sync for RoiEncoder
impl Unpin for RoiEncoder
impl UnsafeUnpin for RoiEncoder
impl UnwindSafe for RoiEncoder
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
Mutably borrows from an owned value. Read more
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>
Converts
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>
Converts
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 more