My current research work is focused in image processing and algorithms for CFA interpolation. I would like to perform some experiments with the algorithms for RGB image restoration from the grayscale CFA image, implemented in Intel IPP library - CFAToRGB and DemosaicAHD.
I am new in using this library. I have troubles with understanding the meaning of parameter “pTmp” of function DemosaicAHD.
In the function description it is written that: “The algorithm requires “the temporary image pTmp of size (srcRoi.width +6, 30)” to be defined and passed during the function call. Could someone to help me to understand:
What the purpose of the temporary image is and what determines this size for the temporary image?
How to define / create this image? Which IPP method to use for allocating memory?
Thanks in advance,
Thanks for your interest to IPP library.
Temporal image pTmp is internal memory buffer of function for speedup calculations.
This function requires temp buffer of Ipp8u data size of width = (srcRoi.width +6) and height = 30 where srcRoi is size of image to be processed. So you need just to call pTmp = ippsMalloc_8u( (srcRoi.width+6)*30). You can provide this buffer again for images with smaller width but need to allocate new buffer for images with bigger width.