- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Enric,
You can use the following functons to data from RCPack format
Code:
/* ///////////////////////////////////////////////////////////////////////////// // Name: ippiPackToCplxExtend // // Purpose: Converts an image in RCPack2D format to a complex data image. // // Returns: // ippStsNoErr No errors // ippStsNullPtrErr pSrc == NULL, or pDst == NULL // ippStsStepErr One of the step values is less zero or negative // ippStsSizeErr The srcSize has a field with zero or negative value // // Parameters: // pSrc Pointer to the source image data (point to pixel (0,0)) // srcSize Size of the source image // srcStep Step through the source image // pDst Pointer to the destination image // dstStep Step through the destination image // Notes: */ IPPAPI (IppStatus, ippiPackToCplxExtend_32s32sc_C1R, (const Ipp32s* pSrc, IppiSize srcSize, int srcStep, Ipp32sc* pDst, int dstStep )) IPPAPI (IppStatus, ippiPackToCplxExtend_32f32fc_C1R, (const Ipp32f* pSrc, IppiSize srcSize, int srcStep, Ipp32fc* pDst, int dstStep ))
Regards,
Vladimir
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
IplImage* SRC = cvLoadImage("INTENT_4.JPG",0); //Gray image
cvSaveImage("SRC.JPG",SRC);
IplImage* INTENT_GRAY32= cvCreateImage( cvGetSize(SRC),IPL_DEPTH_32F,1); cvConvertScale(SRC,INTENT_GRAY32, 1 , 0 ); cvSaveImage("INTENT_FRAME_GRAY32.JPG",INTENT_GRAY32);IppiSize INTENTSIZE = {INTENT_GRAY32->width,INTENT_GRAY32->height};
CvSize EXTEND ={2*SRC->width, 2*SRC->width};
IplImage* INTENTFFT=cvCreateImage(cvGetSize(SRC),IPL_DEPTH_32F,1);
IplImage* INTENTResult=cvCreateImage(cvGetSize(SRC),IPL_DEPTH_8U,1);
IplImage* INTENTIFFT=cvCreateImage(cvGetSize(SRC),IPL_DEPTH_32F,1);
iplRealFft2D(INTENT_GRAY32,INTENTFFT,IPL_FFT_Forw);
IplImage* INT_M=cvCreateImage(EXTEND,IPL_DEPTH_32F,1);
ippiPackToCplxExtend_32f32fc_C1R((Ipp32f*)INTENTFFT->imageData,
INTENTSIZE,INTENTFFT->width*
sizeof(Ipp32f),(Ipp32fc*)INT_M->imageData,INT_M->width*
sizeof(Ipp32fc));IplImage* INTENTFFT_8=cvCreateImage(cvGetSize(INT_M),IPL_DEPTH_8U,1);
cvConvert(INT_M,INTENTFFT_8);
cvSaveImage("INTENTFFT_8.JPG",INTENTFFT_8);
IplImage* INTENTFFT_MAG=cvCreateImage(cvGetSize(INT_M),IPL_DEPTH_32F,1);
IplImage* INTENTFFT_MAG_8=cvCreateImage(cvGetSize(INT_M),IPL_DEPTH_8U,1);
ippiMagnitudePack_32f_C1R((Ipp32f*)INTENTFFT->imageData,
INTENTFFT->width*
sizeof(Ipp32f), (Ipp32f*)INTENTFFT_MAG->imageData,INTENTFFT_MAG->width*
sizeof(Ipp32f), INTENTSIZE);cvConvert(INTENTFFT_MAG,INTENTFFT_MAG_8);
cvSaveImage("INTENTFFT_MAG_8.JPG",INTENTFFT_MAG_8);
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Enric,
You may find the thread link below to be of interest
http://softwareforums.intel.com/ids/board/message?board.id=IPP&message.id=1156&query.id=5983#M1156

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page