#[non_exhaustive]pub enum PrefilterMode {
None,
External,
Bilateral {
sigma_s: f32,
sigma_r: f32,
},
NlmSpatial {
strength_scale: f32,
},
}Expand description
How the reference image for each frame is produced.
NLM compares patches to decide how much two pixels look alike. Doing that on a noisy image means comparing noise as well as content, so a cleaner reference image can give better weights.
The pixels being averaged always come from the original input. Only the weights change.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
None
No reference image, so patches are compared on the noisy input. This costs nothing extra.
External
The caller supplies the reference frame through
[super::NlmDenoiser::push_frame_with_reference].
Bilateral
A quick bilateral blur run on the GPU at push time.
NlmSpatial
A spatial NLM pilot pass.
Each frame is denoised with the windowed spatial kernel at push time and the result is kept as the reference image.
Trait Implementations§
Source§impl Clone for PrefilterMode
impl Clone for PrefilterMode
Source§fn clone(&self) -> PrefilterMode
fn clone(&self) -> PrefilterMode
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for PrefilterMode
Source§impl Debug for PrefilterMode
impl Debug for PrefilterMode
Source§impl Default for PrefilterMode
impl Default for PrefilterMode
Source§fn default() -> PrefilterMode
fn default() -> PrefilterMode
Returns the “default value” for a type. Read more
Source§impl PartialEq for PrefilterMode
impl PartialEq for PrefilterMode
impl StructuralPartialEq for PrefilterMode
Auto Trait Implementations§
impl Freeze for PrefilterMode
impl RefUnwindSafe for PrefilterMode
impl Send for PrefilterMode
impl Sync for PrefilterMode
impl Unpin for PrefilterMode
impl UnsafeUnpin for PrefilterMode
impl UnwindSafe for PrefilterMode
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