Filters#

Detailed Description#

Classes#

Name

Description

class cv::ximgproc::AdaptiveManifoldFilter

Interface for Adaptive Manifold Filter realizations. View details

class cv::ximgproc::DisparityFilter

Main interface for all disparity map filters. View details

class cv::ximgproc::DisparityWLSFilter

Disparity map filter based on Weighted Least Squares filter (in form of Fast Global Smoother that is a lot faster than traditional Weighted Least Squares filter implementations) and optional use of left-right-consistency-based confidence to refine the results in half-occlusions and uniform areas. View details

class cv::ximgproc::DTFilter

Interface for realizations of Domain Transform filter. View details

class cv::ximgproc::EdgeAwareInterpolator

Sparse match interpolation algorithm based on modified locally-weighted affine estimator from [250] and Fast Global Smoother as post-processing filter. View details

class cv::ximgproc::FastBilateralSolverFilter

Interface for implementations of Fast Bilateral Solver. View details

class cv::ximgproc::FastGlobalSmootherFilter

Interface for implementations of Fast Global Smoother filter. View details

class cv::ximgproc::GuidedFilter

Interface for realizations of (Fast) Guided Filter. View details

class cv::ximgproc::RICInterpolator

Sparse match interpolation algorithm based on modified piecewise locally-weighted affine estimator called Robust Interpolation method of Correspondences or RIC from [148] and Variational and Fast Global Smoother as post-processing filter. The RICInterpolator is a extension of the EdgeAwareInterpolator. Main concept of this extension is an piece-wise affine model based on over-segmentation via SLIC superpixel estimation. The method contains an efficient propagation mechanism to estimate among the pieces-wise models. View details

class cv::ximgproc::RidgeDetectionFilter

Applies Ridge Detection Filter to an input image. Implements Ridge detection similar to the one in Mathematica using the eigen values from the Hessian Matrix of the input image using Sobel Derivatives. Additional refinement can be done using Skeletonization and Binarization. Adapted from segleafvein and [208]. View details

class cv::ximgproc::SparseMatchInterpolator

Main interface for all filters, that take sparse matches as an input and produce a dense per-pixel matching (optical flow) as an output. View details

Enumerations#

View details

Enumeration Type Documentation#

EdgeAwareFiltersList#

enum cv::ximgproc::EdgeAwareFiltersList

#include <opencv2/ximgproc/edge_filter.hpp>

Enumerator:

DTF_NC

DTF_IC

DTF_RF

GUIDED_FILTER

AM_FILTER

Function Documentation#

amFilter()#

void cv::ximgproc::amFilter(
InputArray joint,
InputArray src,
OutputArray dst,
double sigma_s,
double sigma_r,
bool adjust_outliers = false )

#include <opencv2/ximgproc/edge_filter.hpp>

Simple one-line Adaptive Manifold Filter call.

Note

Joint images with CV_8U and CV_16U depth converted to images with CV_32F depth and [0; 1] color range before processing. Hence color space sigma sigma_r must be in [0; 1] range, unlike same sigmas in bilateralFilter and dtFilter functions.

Parameters

  • joint — joint (also called as guided) image or array of images with any numbers of channels.

  • src — filtering image with any numbers of channels.

  • dst — output image.

  • sigma_s — spatial standard deviation.

  • sigma_r — color space standard deviation, it is similar to the sigma in the color space into bilateralFilter.

  • adjust_outliers — optional, specify perform outliers adjust operation or not, (Eq. 9) in the original paper.

bilateralTextureFilter()#

void cv::ximgproc::bilateralTextureFilter(
InputArray src,
OutputArray dst,
int fr = 3,
int numIter = 1,
double sigmaAlpha = -1.,
double sigmaAvg = -1. )

#include <opencv2/ximgproc/edge_filter.hpp>

Applies the bilateral texture filter to an image. It performs structure-preserving texture filter. For more details about this filter see [64].

Parameters

  • src — Source image whose depth is 8-bit UINT or 32-bit FLOAT

  • dst — Destination image of the same size and type as src.

  • fr — Radius of kernel to be used for filtering. It should be positive integer

  • numIter — Number of iterations of algorithm, It should be positive integer

  • sigmaAlpha — Controls the sharpness of the weight transition from edges to smooth/texture regions, where a bigger value means sharper transition. When the value is negative, it is automatically calculated.

  • sigmaAvgRange blur parameter for texture blurring. Larger value makes result to be more blurred. When the value is negative, it is automatically calculated as described in the paper.

colorMatchTemplate()#

void cv::ximgproc::colorMatchTemplate(
InputArray img,
InputArray templ,
OutputArray result )

#include <opencv2/ximgproc/color_match.hpp>

Compares a color template against overlapped color image regions.

Parameters

  • img — Image where the search is running. It must be 3 channels image

  • templ — Searched template. It must be not greater than the source image and have 3 channels

  • result — Map of comparison results. It must be single-channel 64-bit floating-point

computeBadPixelPercent()#

double cv::ximgproc::computeBadPixelPercent(
InputArray GT,
InputArray src,
Rect ROI,
int thresh = 24 )

#include <opencv2/ximgproc/disparity_filter.hpp>

Function for computing the percent of “bad” pixels in the disparity map (pixels where error is higher than a specified threshold)

Parameters

  • GT — ground truth disparity map

  • src — disparity map to evaluate

  • ROI — region of interest

  • thresh — threshold used to determine “bad” pixels

Returns

returns mean square error between GT and src

computeMSE()#

double cv::ximgproc::computeMSE(
InputArray GT,
InputArray src,
Rect ROI )

#include <opencv2/ximgproc/disparity_filter.hpp>

Function for computing mean square error for disparity maps.

Parameters

  • GT — ground truth disparity map

  • src — disparity map to evaluate

  • ROI — region of interest

Returns

returns mean square error between GT and src

createAMFilter()#

Ptr< AdaptiveManifoldFilter > cv::ximgproc::createAMFilter(
double sigma_s,
double sigma_r,
bool adjust_outliers = false )

#include <opencv2/ximgproc/edge_filter.hpp>

Factory method, create instance of AdaptiveManifoldFilter and produce some initialization routines.

For more details about Adaptive Manifold Filter parameters, see the original article [114] .

Note

Joint images with CV_8U and CV_16U depth converted to images with CV_32F depth and [0; 1] color range before processing. Hence color space sigma sigma_r must be in [0; 1] range, unlike same sigmas in bilateralFilter and dtFilter functions.

Parameters

  • sigma_s — spatial standard deviation.

  • sigma_r — color space standard deviation, it is similar to the sigma in the color space into bilateralFilter.

  • adjust_outliers — optional, specify perform outliers adjust operation or not, (Eq. 9) in the original paper.

createDisparityWLSFilter()#

Ptr< DisparityWLSFilter > cv::ximgproc::createDisparityWLSFilter(Ptr< StereoMatcher > matcher_left)

#include <opencv2/ximgproc/disparity_filter.hpp>

Convenience factory method that creates an instance of DisparityWLSFilter and sets up all the relevant filter parameters automatically based on the matcher instance. Currently supports only StereoBM and StereoSGBM.

Parameters

  • matcher_left — stereo matcher instance that will be used with the filter

createDisparityWLSFilterGeneric()#

Ptr< DisparityWLSFilter > cv::ximgproc::createDisparityWLSFilterGeneric(bool use_confidence)

#include <opencv2/ximgproc/disparity_filter.hpp>

More generic factory method, create instance of DisparityWLSFilter and execute basic initialization routines. When using this method you will need to set-up the ROI, matchers and other parameters by yourself.

Parameters

  • use_confidence — filtering with confidence requires two disparity maps (for the left and right views) and is approximately two times slower. However, quality is typically significantly better.

createDTFilter()#

Ptr< DTFilter > cv::ximgproc::createDTFilter(
InputArray guide,
double sigmaSpatial,
double sigmaColor,
int mode = DTF_NC,
int numIters = 3 )

#include <opencv2/ximgproc/edge_filter.hpp>

Factory method, create instance of DTFilter and produce initialization routines.

For more details about Domain Transform filter parameters, see the original article [113] and Domain Transform filter homepage.

Parameters

  • guide — guided image (used to build transformed distance, which describes edge structure of guided image).

  • sigmaSpatial\({\sigma}_H\) parameter in the original article, it’s similar to the sigma in the coordinate space into bilateralFilter.

  • sigmaColor\({\sigma}_r\) parameter in the original article, it’s similar to the sigma in the color space into bilateralFilter.

  • mode — one form three modes DTF_NC, DTF_RF and DTF_IC which corresponds to three modes for filtering 2D signals in the article.

  • numIters — optional number of iterations used for filtering, 3 is quite enough.

createEdgeAwareInterpolator()#

Ptr< EdgeAwareInterpolator > cv::ximgproc::createEdgeAwareInterpolator()

#include <opencv2/ximgproc/sparse_match_interpolator.hpp>

Factory method that creates an instance of the EdgeAwareInterpolator.

createFastBilateralSolverFilter()#

Ptr< FastBilateralSolverFilter > cv::ximgproc::createFastBilateralSolverFilter(
InputArray guide,
double sigma_spatial,
double sigma_luma,
double sigma_chroma,
double lambda = 128.0,
int num_iter = 25,
double max_tol = 1e-5 )

#include <opencv2/ximgproc/edge_filter.hpp>

Factory method, create instance of FastBilateralSolverFilter and execute the initialization routines.

For more details about the Fast Bilateral Solver parameters, see the original paper [22].

Parameters

  • guide — image serving as guide for filtering. It should have 8-bit depth and either 1 or 3 channels.

  • sigma_spatial — parameter, that is similar to spatial space sigma (bandwidth) in bilateralFilter.

  • sigma_luma — parameter, that is similar to luma space sigma (bandwidth) in bilateralFilter.

  • sigma_chroma — parameter, that is similar to chroma space sigma (bandwidth) in bilateralFilter.

  • lambda — smoothness strength parameter for solver.

  • num_iter — number of iterations used for solver, 25 is usually enough.

  • max_tol — convergence tolerance used for solver.

createFastGlobalSmootherFilter()#

Ptr< FastGlobalSmootherFilter > cv::ximgproc::createFastGlobalSmootherFilter(
InputArray guide,
double lambda,
double sigma_color,
double lambda_attenuation = 0.25,
int num_iter = 3 )

#include <opencv2/ximgproc/edge_filter.hpp>

Factory method, create instance of FastGlobalSmootherFilter and execute the initialization routines.

For more details about Fast Global Smoother parameters, see the original paper [215]. However, please note that there are several differences. Lambda attenuation described in the paper is implemented a bit differently so do not expect the results to be identical to those from the paper; sigma_color values from the paper should be multiplied by 255.0 to achieve the same effect. Also, in case of image filtering where source and guide image are the same, authors propose to dynamically update the guide image after each iteration. To maximize the performance this feature was not implemented here.

Parameters

  • guide — image serving as guide for filtering. It should have 8-bit depth and either 1 or 3 channels.

  • lambda — parameter defining the amount of regularization

  • sigma_color — parameter, that is similar to color space sigma in bilateralFilter.

  • lambda_attenuation — internal parameter, defining how much lambda decreases after each iteration. Normally, it should be 0.25. Setting it to 1.0 may lead to streaking artifacts.

  • num_iter — number of iterations used for filtering, 3 is usually enough.

createGuidedFilter()#

Ptr< GuidedFilter > cv::ximgproc::createGuidedFilter(
InputArray guide,
int radius,
double eps,
double scale = 1.0 )

#include <opencv2/ximgproc/edge_filter.hpp>

Factory method, create instance of GuidedFilter and produce initialization routines.

For more details about (Fast) Guided Filter parameters, see the original articles [134] [136] .

Parameters

  • guide — guided image (or array of images) with up to 3 channels, if it have more then 3 channels then only first 3 channels will be used.

  • radius — radius of Guided Filter.

  • eps — regularization term of Guided Filter. \({eps}^2\) is similar to the sigma in the color space into bilateralFilter.

  • scale — subsample factor of Fast Guided Filter, use a scale less than 1 to speeds up computation with almost no visible degradation. (e.g. scale==0.5 shrinks the image by 2x inside the filter)

createQuaternionImage()#

void cv::ximgproc::createQuaternionImage(
InputArray img,
OutputArray qimg )

#include <opencv2/ximgproc/color_match.hpp>

creates a quaternion image.

Parameters

  • img — Source 8-bit, 32-bit or 64-bit image, with 3-channel image.

  • qimg — result CV_64FC4 a quaternion image( 4 chanels zero channel and B,G,R).

createRICInterpolator()#

Ptr< RICInterpolator > cv::ximgproc::createRICInterpolator()

#include <opencv2/ximgproc/sparse_match_interpolator.hpp>

Factory method that creates an instance of the RICInterpolator.

createRightMatcher()#

Ptr< StereoMatcher > cv::ximgproc::createRightMatcher(Ptr< StereoMatcher > matcher_left)

#include <opencv2/ximgproc/disparity_filter.hpp>

Convenience method to set up the matcher for computing the right-view disparity map that is required in case of filtering with confidence.

Parameters

  • matcher_left — main stereo matcher instance that will be used with the filter

dtFilter()#

void cv::ximgproc::dtFilter(
InputArray guide,
InputArray src,
OutputArray dst,
double sigmaSpatial,
double sigmaColor,
int mode = DTF_NC,
int numIters = 3 )

#include <opencv2/ximgproc/edge_filter.hpp>

Simple one-line Domain Transform filter call. If you have multiple images to filter with the same guided image then use DTFilter interface to avoid extra computations on initialization stage.

Parameters

  • guide — guided image (also called as joint image) with unsigned 8-bit or floating-point 32-bit depth and up to 4 channels.

  • src — filtering image with unsigned 8-bit or floating-point 32-bit depth and up to 4 channels.

  • dst — destination image

  • sigmaSpatial\({\sigma}_H\) parameter in the original article, it’s similar to the sigma in the coordinate space into bilateralFilter.

  • sigmaColor\({\sigma}_r\) parameter in the original article, it’s similar to the sigma in the color space into bilateralFilter.

  • mode — one form three modes DTF_NC, DTF_RF and DTF_IC which corresponds to three modes for filtering 2D signals in the article.

  • numIters — optional number of iterations used for filtering, 3 is quite enough.

fastBilateralSolverFilter()#

void cv::ximgproc::fastBilateralSolverFilter(
InputArray guide,
InputArray src,
InputArray confidence,
OutputArray dst,
double sigma_spatial = 8,
double sigma_luma = 8,
double sigma_chroma = 8,
double lambda = 128.0,
int num_iter = 25,
double max_tol = 1e-5 )

#include <opencv2/ximgproc/edge_filter.hpp>

Simple one-line Fast Bilateral Solver filter call. If you have multiple images to filter with the same guide then use FastBilateralSolverFilter interface to avoid extra computations.

For more details about the Fast Bilateral Solver parameters, see the original paper [22].

Note

Confidence images with CV_8U depth are expected to in [0, 255] and CV_32F in [0, 1] range.

Parameters

  • guide — image serving as guide for filtering. It should have 8-bit depth and either 1 or 3 channels.

  • src — source image for filtering with unsigned 8-bit or signed 16-bit or floating-point 32-bit depth and up to 4 channels.

  • confidence — confidence image with unsigned 8-bit or floating-point 32-bit confidence and 1 channel.

  • dst — destination image.

  • sigma_spatial — parameter, that is similar to spatial space sigma (bandwidth) in bilateralFilter.

  • sigma_luma — parameter, that is similar to luma space sigma (bandwidth) in bilateralFilter.

  • sigma_chroma — parameter, that is similar to chroma space sigma (bandwidth) in bilateralFilter.

  • lambda — smoothness strength parameter for solver.

  • num_iter — number of iterations used for solver, 25 is usually enough.

  • max_tol — convergence tolerance used for solver.

fastGlobalSmootherFilter()#

void cv::ximgproc::fastGlobalSmootherFilter(
InputArray guide,
InputArray src,
OutputArray dst,
double lambda,
double sigma_color,
double lambda_attenuation = 0.25,
int num_iter = 3 )

#include <opencv2/ximgproc/edge_filter.hpp>

Simple one-line Fast Global Smoother filter call. If you have multiple images to filter with the same guide then use FastGlobalSmootherFilter interface to avoid extra computations.

Parameters

  • guide — image serving as guide for filtering. It should have 8-bit depth and either 1 or 3 channels.

  • src — source image for filtering with unsigned 8-bit or signed 16-bit or floating-point 32-bit depth and up to 4 channels.

  • dst — destination image.

  • lambda — parameter defining the amount of regularization

  • sigma_color — parameter, that is similar to color space sigma in bilateralFilter.

  • lambda_attenuation — internal parameter, defining how much lambda decreases after each iteration. Normally, it should be 0.25. Setting it to 1.0 may lead to streaking artifacts.

  • num_iter — number of iterations used for filtering, 3 is usually enough.

getDisparityVis()#

void cv::ximgproc::getDisparityVis(
InputArray src,
OutputArray dst,
double scale = 1.0 )

#include <opencv2/ximgproc/disparity_filter.hpp>

Function for creating a disparity map visualization (clamped CV_8U image)

Parameters

  • src — input disparity map (CV_16S depth)

  • dst — output visualization

  • scale — disparity map will be multiplied by this value for visualization

GradientDericheX()#

void cv::ximgproc::GradientDericheX(
InputArray op,
OutputArray dst,
double alpha,
double omega )

#include <opencv2/ximgproc/deriche_filter.hpp>

Applies X Deriche filter to an image.

For more details about this implementation, please see http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.476.5736&rep=rep1&type=pdf

Parameters

  • op — Source 8-bit or 16bit image, 1-channel or 3-channel image.

  • dst — result CV_32FC image with same number of channel than _op.

  • alpha — double see paper

  • omega — double see paper

GradientDericheY()#

void cv::ximgproc::GradientDericheY(
InputArray op,
OutputArray dst,
double alpha,
double omega )

#include <opencv2/ximgproc/deriche_filter.hpp>

Applies Y Deriche filter to an image.

For more details about this implementation, please see http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.476.5736&rep=rep1&type=pdf

Parameters

  • op — Source 8-bit or 16bit image, 1-channel or 3-channel image.

  • dst — result CV_32FC image with same number of channel than _op.

  • alpha — double see paper

  • omega — double see paper

GradientPaillouX()#

void cv::ximgproc::GradientPaillouX(
InputArray op,
OutputArray _dst,
double alpha,
double omega )

#include <opencv2/ximgproc/paillou_filter.hpp>

GradientPaillouY()#

void cv::ximgproc::GradientPaillouY(
InputArray op,
OutputArray _dst,
double alpha,
double omega )

#include <opencv2/ximgproc/paillou_filter.hpp>

Applies Paillou filter to an image.

For more details about this implementation, please see [236]

Parameters

  • op — Source CV_8U(S) or CV_16U(S), 1-channel or 3-channels image.

  • _dst — result CV_32F image with same number of channel than op.

  • omega — double see paper

  • alpha — double see paper

guidedFilter()#

void cv::ximgproc::guidedFilter(
InputArray guide,
InputArray src,
OutputArray dst,
int radius,
double eps,
int dDepth = -1,
double scale = 1.0 )

#include <opencv2/ximgproc/edge_filter.hpp>

Simple one-line (Fast) Guided Filter call.

If you have multiple images to filter with the same guided image then use GuidedFilter interface to avoid extra computations on initialization stage.

Parameters

  • guide — guided image (or array of images) with up to 3 channels, if it have more then 3 channels then only first 3 channels will be used.

  • src — filtering image with any numbers of channels.

  • dst — output image.

  • radius — radius of Guided Filter.

  • eps — regularization term of Guided Filter. \({eps}^2\) is similar to the sigma in the color space into bilateralFilter.

  • dDepth — optional depth of the output image.

  • scale — subsample factor of Fast Guided Filter, use a scale less than 1 to speeds up computation with almost no visible degradation. (e.g. scale==0.5 shrinks the image by 2x inside the filter)

jointBilateralFilter()#

void cv::ximgproc::jointBilateralFilter(
InputArray joint,
InputArray src,
OutputArray dst,
int d,
double sigmaColor,
double sigmaSpace,
int borderType = BORDER_DEFAULT )

#include <opencv2/ximgproc/edge_filter.hpp>

Applies the joint bilateral filter to an image.

Note

bilateralFilter and jointBilateralFilter use L1 norm to compute difference between colors.

Parameters

  • joint — Joint 8-bit or floating-point, 1-channel or 3-channel image.

  • src — Source 8-bit or floating-point, 1-channel or 3-channel image with the same depth as joint image.

  • dst — Destination image of the same size and type as src .

  • d — Diameter of each pixel neighborhood that is used during filtering. If it is non-positive, it is computed from sigmaSpace .

  • sigmaColor — Filter sigma in the color space. A larger value of the parameter means that farther colors within the pixel neighborhood (see sigmaSpace ) will be mixed together, resulting in larger areas of semi-equal color.

  • sigmaSpace — Filter sigma in the coordinate space. A larger value of the parameter means that farther pixels will influence each other as long as their colors are close enough (see sigmaColor ). When d>0 , it specifies the neighborhood size regardless of sigmaSpace . Otherwise, d is proportional to sigmaSpace .

  • borderType

l0Smooth()#

void cv::ximgproc::l0Smooth(
InputArray src,
OutputArray dst,
double lambda = 0.02,
double kappa = 2.0 )

#include <opencv2/ximgproc/edge_filter.hpp>

Global image smoothing via L0 gradient minimization.

For more details about L0 Smoother, see the original paper [343].

Parameters

  • src — source image for filtering with unsigned 8-bit or signed 16-bit or floating-point depth.

  • dst — destination image.

  • lambda — parameter defining the smooth term weight.

  • kappa — parameter defining the increasing factor of the weight of the gradient data term.

qconj()#

void cv::ximgproc::qconj(
InputArray qimg,
OutputArray qcimg )

#include <opencv2/ximgproc/color_match.hpp>

calculates conjugate of a quaternion image.

Parameters

  • qimg — quaternion image.

  • qcimg — conjugate of qimg

qdft()#

void cv::ximgproc::qdft(
InputArray img,
OutputArray qimg,
int flags,
bool sideLeft )

#include <opencv2/ximgproc/color_match.hpp>

Performs a forward or inverse Discrete quaternion Fourier transform of a 2D quaternion array.

Parameters

  • img — quaternion image.

  • qimg — quaternion image in dual space.

  • flags — quaternion image in dual space. only DFT_INVERSE flags is supported

  • sideLeft — true the hypercomplex exponential is to be multiplied on the left (false on the right ).

qmultiply()#

void cv::ximgproc::qmultiply(
InputArray src1,
InputArray src2,
OutputArray dst )

#include <opencv2/ximgproc/color_match.hpp>

Calculates the per-element quaternion product of two arrays.

Parameters

  • src1 — quaternion image.

  • src2 — quaternion image.

  • dst — product dst(I)=src1(I) . src2(I)

qunitary()#

void cv::ximgproc::qunitary(
InputArray qimg,
OutputArray qnimg )

#include <opencv2/ximgproc/color_match.hpp>

divides each element by its modulus.

Parameters

  • qimg — quaternion image.

  • qnimg — conjugate of qimg

readGT()#

int cv::ximgproc::readGT(
String src_path,
OutputArray dst )

#include <opencv2/ximgproc/disparity_filter.hpp>

Function for reading ground truth disparity maps. Supports basic Middlebury and MPI-Sintel formats. Note that the resulting disparity map is scaled by 16.

Parameters

  • src_path — path to the image, containing ground-truth disparity map

  • dst — output disparity map, CV_16S depth

Returns

returns zero if successfully read the ground truth

rollingGuidanceFilter()#

void cv::ximgproc::rollingGuidanceFilter(
InputArray src,
OutputArray dst,
int d = -1,
double sigmaColor = 25,
double sigmaSpace = 3,
int numOfIter = 4,
int borderType = BORDER_DEFAULT )

#include <opencv2/ximgproc/edge_filter.hpp>

Applies the rolling guidance filter to an image.

For more details, please see [356]

Note

rollingGuidanceFilter uses jointBilateralFilter as the edge-preserving filter.

Parameters

  • src — Source 8-bit or floating-point, 1-channel or 3-channel image.

  • dst — Destination image of the same size and type as src.

  • d — Diameter of each pixel neighborhood that is used during filtering. If it is non-positive, it is computed from sigmaSpace .

  • sigmaColor — Filter sigma in the color space. A larger value of the parameter means that farther colors within the pixel neighborhood (see sigmaSpace ) will be mixed together, resulting in larger areas of semi-equal color.

  • sigmaSpace — Filter sigma in the coordinate space. A larger value of the parameter means that farther pixels will influence each other as long as their colors are close enough (see sigmaColor ). When d>0 , it specifies the neighborhood size regardless of sigmaSpace . Otherwise, d is proportional to sigmaSpace .

  • numOfIter — Number of iterations of joint edge-preserving filtering applied on the source image.

  • borderType