Currently now I'm using the Gaussian blur of iplimage. like this,
# include "stdio.h"
# include "highgui.h"
# include "cv.h"
int main( int argc, char** argv ) {
IplImage* img = 0;
IplImage* out = 0;
if( argc < 2 ) {
printf( "Usage: Accepts one image as argument\n" );
exit( EXIT_SUCCESS );
}
img = cvLoadImage( argv[1] );
if( !img ) {
printf( "Error loading image file %s\n", argv[1]);
exit( EXIT_SUCCESS );
}
out = cvCreateImage( cvGetSize(img), IPL_DEPTH_8U, 3 );
cvSmooth( img, out, CV_GAUSSIAN, 3, 3 );
cvReleaseImage( &img );
cvReleaseImage( &out );
cvDestroyWindow( "Example1" );
cvDestroyWindow( "Output" );
return EXIT_SUCCESS;
}
But I don't know what coefficients are used in the Gaussian blur of iplimage.
How can I know the Gaussian blur coefficients of iplimage?
IplImage does not have any Gaussian blur coefficients. IplImage is a data structure from the Intel Processing Library for storing image data.
How can you find the coefficients that are used in your filter operation? Well you read the manual and find out...
http://docs.opencv.org/3.0-beta/modules/imgproc/doc/filtering.html#smooth
As you don't provide a sigma in your function call (or let's say in someone else's function call because I doubt you wrote that code), it defaults to 0.
cvSmooth( img, out, CV_GAUSSIAN, 3, 3 );
In the case of a Gaussian parameter this parameter may specify Gaussian sigma (standard deviation). If it is zero, it is calculated from the kernel size:
sigma = 0.3 (n/2 - 1) + 0.8
where n is your kernel size
Using standard sigma for small kernels ( 3 x 3 to 7 x 7 ) gives better speed. If sigma1 is not zero, while size1 and size2 are zeros, the kernel size is calculated from the sigma (to provide accurate enough operation).