- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
Here is what I expect to get:
I am trying to modify one of the frei0r files to make a call to ippiAlphaComp because I think it might have better performance than just frei0r itself. I want to put it within a frei0r file though because I have a gstreamer wrapper that will allow me to use the ippiAlphaComp function within a gstreamer pipeline. I realize that this is probably a strange thing to do, but I am having difficulty getting it to work correctly.
Here is what I expect to get:
Here is what I actually get:
Does anyone have any ideas on what might cause this? I've tried every possible value for and none of them work, so I don't think it's that.
EDIT: One thing that might cause this is...:
ippiAlphaComp_32u_AC4R((const Ipp32u *) inframe1, w, (const Ipp32u *) inframe2, w, (Ipp32u *) outframe, w, sz, ippAlphaOver);
That is my function call. Is it okay to be typecasting to Ipp32u *?
1 Solution
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes, that's right, modifier specify how many bits per color channel, and number of color channels specified separately by C4 (or C1 or C3) symbols.
There is another very popular trouble for new IPP users, it is what is step parameter in image processing functions. It should be number of bytes per image row (not number of pixels).
Regards,
Vladimir
There is another very popular trouble for new IPP users, it is what is step parameter in image processing functions. It should be number of bytes per image row (not number of pixels).
Regards,
Vladimir
Link Copied
4 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You may misinterpret IPP functions data type and function descriptor notation.According naming convention accepted in IPP,"32u_AC4R"stands for 4-channel image where each channel is Ipp32u data type, so whole pixel will consist from four Ipp32uvalues.
In case you work with traditional 8-bits per color channel images you need to use ippiAlphaComp_8u_ function.
Regards,
Vladimir
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Oh, ok. So if I have an image with 32 pits per pixel, I shouldn't use the modifier "32u_AC4R"? I should use 8u_AC4R? The modifier isn't referring to how many pixels are in the image as whole, but how many pixels are in each channel?
I think I get it. However, when I try using the 8u_AC4R function instead of the 32, I get a seg fault. I am calling it from a frei0r function that takes a const uint32_t* though and I am just type casting it to (Ipp8u *), which would probably cause problems..
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes, that's right, modifier specify how many bits per color channel, and number of color channels specified separately by C4 (or C1 or C3) symbols.
There is another very popular trouble for new IPP users, it is what is step parameter in image processing functions. It should be number of bytes per image row (not number of pixels).
Regards,
Vladimir
There is another very popular trouble for new IPP users, it is what is step parameter in image processing functions. It should be number of bytes per image row (not number of pixels).
Regards,
Vladimir
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
D'oh! That's what got me. I was using pixels instead of bytes per image row. It works fine now, thanks!
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page