pub trait DISOpticalFlowTraitConst: DenseOpticalFlowTraitConst {
// Required method
fn as_raw_DISOpticalFlow(&self) -> *const c_void;
// Provided methods
fn get_finest_scale(&self) -> Result<i32> { ... }
fn get_patch_size(&self) -> Result<i32> { ... }
fn get_patch_stride(&self) -> Result<i32> { ... }
fn get_gradient_descent_iterations(&self) -> Result<i32> { ... }
fn get_variational_refinement_iterations(&self) -> Result<i32> { ... }
fn get_variational_refinement_alpha(&self) -> Result<f32> { ... }
fn get_variational_refinement_delta(&self) -> Result<f32> { ... }
fn get_variational_refinement_gamma(&self) -> Result<f32> { ... }
fn get_variational_refinement_epsilon(&self) -> Result<f32> { ... }
fn get_use_mean_normalization(&self) -> Result<bool> { ... }
fn get_use_spatial_propagation(&self) -> Result<bool> { ... }
}
Expand description
Constant methods for crate::video::DISOpticalFlow
Required Methods§
fn as_raw_DISOpticalFlow(&self) -> *const c_void
Provided Methods§
Sourcefn get_finest_scale(&self) -> Result<i32>
fn get_finest_scale(&self) -> Result<i32>
Finest level of the Gaussian pyramid on which the flow is computed (zero level corresponds to the original image resolution). The final flow is obtained by bilinear upscaling.
§See also
setFinestScale
Sourcefn get_patch_size(&self) -> Result<i32>
fn get_patch_size(&self) -> Result<i32>
Size of an image patch for matching (in pixels). Normally, default 8x8 patches work well enough in most cases.
§See also
setPatchSize
Sourcefn get_patch_stride(&self) -> Result<i32>
fn get_patch_stride(&self) -> Result<i32>
Stride between neighbor patches. Must be less than patch size. Lower values correspond to higher flow quality.
§See also
setPatchStride
Sourcefn get_gradient_descent_iterations(&self) -> Result<i32>
fn get_gradient_descent_iterations(&self) -> Result<i32>
Maximum number of gradient descent iterations in the patch inverse search stage. Higher values may improve quality in some cases.
§See also
setGradientDescentIterations
Sourcefn get_variational_refinement_iterations(&self) -> Result<i32>
fn get_variational_refinement_iterations(&self) -> Result<i32>
Number of fixed point iterations of variational refinement per scale. Set to zero to disable variational refinement completely. Higher values will typically result in more smooth and high-quality flow.
§See also
setGradientDescentIterations
Sourcefn get_variational_refinement_alpha(&self) -> Result<f32>
fn get_variational_refinement_alpha(&self) -> Result<f32>
Sourcefn get_variational_refinement_delta(&self) -> Result<f32>
fn get_variational_refinement_delta(&self) -> Result<f32>
Sourcefn get_variational_refinement_gamma(&self) -> Result<f32>
fn get_variational_refinement_gamma(&self) -> Result<f32>
Sourcefn get_variational_refinement_epsilon(&self) -> Result<f32>
fn get_variational_refinement_epsilon(&self) -> Result<f32>
Sourcefn get_use_mean_normalization(&self) -> Result<bool>
fn get_use_mean_normalization(&self) -> Result<bool>
Whether to use mean-normalization of patches when computing patch distance. It is turned on by default as it typically provides a noticeable quality boost because of increased robustness to illumination variations. Turn it off if you are certain that your sequence doesn’t contain any changes in illumination.
§See also
setUseMeanNormalization
Sourcefn get_use_spatial_propagation(&self) -> Result<bool>
fn get_use_spatial_propagation(&self) -> Result<bool>
Whether to use spatial propagation of good optical flow vectors. This option is turned on by default, as it tends to work better on average and can sometimes help recover from major errors introduced by the coarse-to-fine scheme employed by the DIS optical flow algorithm. Turning this option off can make the output flow field a bit smoother, however.
§See also
setUseSpatialPropagation
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.