ManagedCuda.NPP.NPPImage_8uC3.FilterMedian C# (CSharp) Method

FilterMedian() public method

Result pixel value is the median of pixel values under the rectangular mask region.
public FilterMedian ( NPPImage_8uC3 dst, NppiSize oMaskSize, NppiPoint oAnchor ) : void
dst NPPImage_8uC3 Destination-Image
oMaskSize NppiSize Width and Height of the neighborhood region for the local Median operation.
oAnchor NppiPoint X and Y offsets of the kernel origin frame of reference relative to the source pixel.
return void
        public void FilterMedian(NPPImage_8uC3 dst, NppiSize oMaskSize, NppiPoint oAnchor)
        {
            int bufferSize = FilterMedianGetBufferHostSize(oMaskSize);
            CudaDeviceVariable<byte> buffer = new CudaDeviceVariable<byte>(bufferSize);
            status = NPPNativeMethods.NPPi.ImageMedianFilter.nppiFilterMedian_8u_C3R(_devPtrRoi, _pitch, dst.DevicePointerRoi, dst.Pitch, _sizeRoi, oMaskSize, oAnchor, buffer.DevicePointer);
            Debug.WriteLine(String.Format("{0:G}, {1}: {2}", DateTime.Now, "nppiFilterMedian_8u_C3R", status));
            buffer.Dispose();
            NPPException.CheckNppStatus(status, this);
        }

Same methods

NPPImage_8uC3::FilterMedian ( NPPImage_8uC3 dst, NppiSize oMaskSize, NppiPoint oAnchor, CudaDeviceVariable buffer ) : void
NPPImage_8uC3