Dilate

During a dilation operation, the current pixel intensity is replaced by the maximum value of the intensity in a 3x3 neighborhood of the current pixel.



API Syntax

template void xFdilate(xF::Mat & _src_mat, xF::Mat & _dst_mat)

Parameter Descriptions

The following table describes the template and the function parameters.

Table 1.xFdilate Function Parameter Descriptions
Parameter Description
BORDER_TYPE Border Type supported is XF_BORDER_CONSTANT
SRC_T Input and output pixel type. Only 8-bit, unsigned, 1 channel is supported (XF_8UC1)
ROWS Maximum height of input and output image. (must be a multiple of 8)
COLS Maximum width of input and output image. (must be a multiple of 8)
NPC Number of pixels to be processed per cycle; possible options are XF_NPPC1 and XF_NPPC8 for 1 pixel and 8 pixel operations respectively.
_src_mat Input image
_dst_mat Output image

Resource Utilization

The following table summarizes the resource utilization of the Dilation function for 1 pixel operation and 8 pixel operation, generated usingVivado HLS 2017.1version tool for theXilinx Xczu9eg-ffvb1156-1-i-es1FPGA.

Table 2.xFdilate Function Resource Utilization Summary
Name Resource Utilization
1 pixel per clock operation 8 pixel per clock operation
300 MHz 150 MHz
BRAM_18K 3 6
DSP48E 0 0
FF 339 644
LUT 350 1325
CLB 81 245

Performance Estimate

The following table summarizes a performance estimate of the Dilation function for Normal Operation (1 pixel) and Resource Optimized (8 pixel) configurations, generated usingVivado HLS 2017.1tool forXilinx Xczu9eg-ffvb1156-1-i-es1FPGA.

Table 3.xFdilate Function Performance Estimate Summary
Operating Mode Latency Estimate
Min (ms) Max (ms)

1 pixel (300 MHz)

7.0 7.0

8 pixel (150 MHz)

1.87 1.87