This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

VLIB 库函数调用的参数咨询



各位好,

VLIB_grayscale_morphology函数调用,假如我要对一个256x256 8位灰度图像做开运算,模板3x3元素均为1.

那么该如何设置下列参数?

 blk_w是256?还是图像需要加上边界,成为258

line_ofst 是256?如何理解offset between input lines这句话?

blk_h 是3?

refl_se_ptr[]是什么?Reflected structuring element data pointer有什么物理意义?

scratch1_ptrscratch2_ptr有何区别?

void VLIB_grayscale_morphology
(
uint16_t blk_w,       //width of input block, in elements (UQ16.0)
uint16_t line_ofst,  //offset between input lines, in elements (UQ16.0)
uint16_t blk_h,       //height of input block (UQ16.0)
const uint8_t data_ptr[],   //input data pointer (UQ8.0)
uint16_t se_w,                   //width of structuring element block, in elements (UQ16.0)
uint16_t se_h,                   //height of structuring element block (UQ16.0)
const uint8_t se_ptr[],      //structuring element data pointer (UQ8.0) 
const uint8_t refl_se_ptr[],   //Reflected structuring element data pointer (UQ8.0)
uint8_t scratch1_ptr[],          //scratch 1 pointer. Size of this scratch buffer should be equal to input image size (UQ8.0)
uint8_t scratch2_ptr[],         //scratch 2 pointer. This scratch buffer is for temproray data storage and it is used only when se_h =1,

                                                //and all the elements of structuring element is one and (blk_h - (se_h-1))se_h = 0. Size of this buffer should be 32*se_h (UQ8.0)
uint8_t output_ptr[],              //output data pointer (UQ8.0)
uint8_t operation                 //Operation selection 
);


忍不住说几句TI的库--“严谨有余,灵活不足,晦涩难懂”,每个函数为什么不能给个使用例子?