#include <DLMask.h>
Static Public Member Functions | |
static DLImage | dlMask (const DLImage &image, double *mask[], int length) |
Definition at line 13 of file DLMask.h.
Mask an image.
Convolves the image with a square (N x N) filter. The filter should be provided as a row-major 2-dimensional double
array. For example:
DLImage i("test.jpg"); // create masking filter: use array[][] format for ease of initialization double maskarray[3][3] = { {1, 1, 1}, {1, -8, 1}, {1, 1, 1} }; // convert double[][] into double** for input to dlMask() double ** mask = new double*[3]; for (int qq=0; qq<3; qq++) { mask[qq] = &maskarray[qq][0]; } // perform masking operation DLImage outim = DLMask::dlMask(i,mask,3);
image | DLImage to be masked | |
mask | array containing masking filter | |
length | length of filter (i.e. N) |