Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

something like this:

float kdata[] = { -1, -1, -1, -1, -1,
                  -1, 2, 2, 2, -1,
                  -1, 2, 2, 2, -1,
                  -1, 2, 2, 2, -1,
                  -1, -1, -1, -1, -1};

Mat kernel(5, 5, CV_32F, kdata);

kernel /= 8;