Table of Contents

Method CalcOpticalFlowSF

Namespace
OpenCvSharp
Assembly
OpenCvSharp.dll

CalcOpticalFlowSF(InputArray, InputArray, OutputArray, int, int, int)

computes dense optical flow using Simple Flow algorithm

public static void CalcOpticalFlowSF(InputArray from, InputArray to, OutputArray flow, int layers, int averagingBlockSize, int maxFlow)

Parameters

from InputArray

First 8-bit 3-channel image.

to InputArray

Second 8-bit 3-channel image

flow OutputArray

Estimated flow

layers int

Number of layers

averagingBlockSize int

Size of block through which we sum up when calculate cost function for pixel

maxFlow int

maximal flow that we search at each level

CalcOpticalFlowSF(InputArray, InputArray, OutputArray, int, int, int, double, double, int, double, double, double, int, double, double, double)

computes dense optical flow using Simple Flow algorithm

public static void CalcOpticalFlowSF(InputArray from, InputArray to, OutputArray flow, int layers, int averagingBlockSize, int maxFlow, double sigmaDist, double sigmaColor, int postprocessWindow, double sigmaDistFix, double sigmaColorFix, double occThr, int upscaleAveragingRadius, double upscaleSigmaDist, double upscaleSigmaColor, double speedUpThr)

Parameters

from InputArray

First 8-bit 3-channel image.

to InputArray

Second 8-bit 3-channel image

flow OutputArray

Estimated flow

layers int

Number of layers

averagingBlockSize int

Size of block through which we sum up when calculate cost function for pixel

maxFlow int

maximal flow that we search at each level

sigmaDist double

vector smooth spatial sigma parameter

sigmaColor double

vector smooth color sigma parameter

postprocessWindow int

window size for postprocess cross bilateral filter

sigmaDistFix double

spatial sigma for postprocess cross bilateralf filter

sigmaColorFix double

color sigma for postprocess cross bilateral filter

occThr double

threshold for detecting occlusions

upscaleAveragingRadius int

window size for bilateral upscale operation

upscaleSigmaDist double

spatial sigma for bilateral upscale operation

upscaleSigmaColor double

color sigma for bilateral upscale operation

speedUpThr double

threshold to detect point with irregular flow - where flow should be recalculated after upscale