- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I'm getting some strange and unpredictable output from the IPP Filter function on the XScale-platform (I'm using the BenQ P50).
For my Master's thesis, I need to create edge images. The IPP functions seem to be a lot faster than what I could do myself. Unfortunately, the mobile platform seems to be limited to do filtering with 8u pictures and there's no extra Sobel-function. That means that I have to do the filtering using custom filters four times to get all the required information - positive and negative edges in x/y-direction.
Most of the time this works fine. However, sometimes the output of one or both of the negative sobel filters is just not correct. I attached an image to show you the effect, the negative y-edges picture is wrong. Quite often when that happens I just switch from doing a debug build to a release build (or the other way round) and everything works fine again. Without any changes in code. In fact, I don't change anything in this piece code and sometimes it can work fine for several days (at least with one build configuration), then, suddenly, it doesn't.
Calling "clean" or "rebuild all" doesn't change anything. I tried changing the order of declaring the images, the order of the calls to the filter function, anything I could think of... But there doesn't seem to be any way how I can influence the rather unpredictable output of the filter function.
Do you have any suggestions? I have no idea what I could do in this case...
Here's the code I use to create the edge images:
const Ipp32s filterSobelXPos[3][3] = {{1,0,-1},{2,0,-2},{1,0,-1}};
const Ipp32s filterSobelYPos[3][3] = {{1,2,1},{0,0,0},{-1,-2,-1}};
const Ipp32s filterSobelXNeg[3][3] = {{-1,0,1},{-2,0,2},{-1,0,1}};
const Ipp32s filterSobelYNeg[3][3] = {{-1,-2,-1},{0,0,0},{1,2,1}};
const IppiSize sobelSize = {3, 3};
const IppiPoint kernelAnchor = {1, 1};
IppStatus status;
status = ippiFilter_8u_C1R(imgY->imageData, iImgYWidthStep, edgeXPos->imageData, iEdgeWidthStep, edgeXPos->size, *filterSobelXPos, sobelSize, kernelAnchor, 1);
status = ippiFilter_8u_C1R(imgY->imageData, iImgYWidthStep, edgeYPos->imageData, iEdgeWidthStep, edgeYPos->size, *filterSobelYPos, sobelSize, kernelAnchor, 1);
status = ippiFilter_8u_C1R(imgY->imageData, iImgYWidthStep, edgeXNeg->imageData, iEdgeWidthStep, edgeXNeg->size, *filterSobelXNeg, sobelSize, kernelAnchor, 1);
status = ippiFilter_8u_C1R(imgY->imageData, iImgYWidthStep, edgeYNeg->imageData, iEdgeWidthStep, edgeYNeg->size, *filterSobelYNeg, sobelSize, kernelAnchor, 1);
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Could you also specify for version of IPP do you use and for wich processor family (IXP or PCA)?
Regards,
Vladimir
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I recommend you to submit your bug report to Technical Support. You also can consider opportunity to move your code to IPP for IXP, which also will run on your processor. Note, IPP for IXP does not provide WMMX optimization.
Regards,
Vladimir
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page