- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I want to do memory copy as follows, but I can not find the related IPP functions for PXA, could you help me please?
Thanks,
David
/*
* SRC - the source buffer
* DST - the destination buffer
*
* Then the function does the 8->16 bit transfer and this serie of operations :
*
* SRC (8bit) = SRC
* DST (16bit) = SRC
*
*/
void
transfer_8to16copy_c(int16_t * const dst,
const uint8_t * const src,
uint32_t stride)
{
uint32_t i, j;
for (j = 0; j < 8; j++) {
for (i = 0; i < 8; i++) {
dst[j * 8 + i] = (int16_t) src[j * stride + i];
}
}
}
/*
* SRC - the source buffer
* DST - the destination buffer
*
* Then the function does the 8->16 bit transfer and this serie of operations :
*
* SRC (16bit) = SRC
* DST (8bit) = max(min(SRC, 255), 0)
*/
void
transfer_16to8copy_c(uint8_t * const dst,
const int16_t * const src,
uint32_t stride)
{
uint32_t i, j;
for (i = 0; i < 8; i++) {
dst[j * 8 + i] = (int16_t) src[j * stride + i];
}
}
}
/*
* SRC - the source buffer
* DST - the destination buffer
*
* Then the function does the 8->16 bit transfer and this serie of operations :
*
* SRC (16bit) = SRC
* DST (8bit) = max(min(SRC, 255), 0)
*/
void
transfer_16to8copy_c(uint8_t * const dst,
const int16_t * const src,
uint32_t stride)
{
uint32_t i, j;
for (j = 0; j < 8; j++) {
for (i = 0; i < 8; i++) {
int16_t pixel = src[j * 8 + i];
for (i = 0; i < 8; i++) {
int16_t pixel = src[j * 8 + i];
if (pixel < 0) {
pixel = 0;
} else if (pixel > 255) {
pixel = 255;
}
dst[j * stride + i] = (uint8_t) pixel;
}
}
}
pixel = 0;
} else if (pixel > 255) {
pixel = 255;
}
dst[j * stride + i] = (uint8_t) pixel;
}
}
}
Link Copied
1 Reply
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You are right, we do not have such function in IPP for PCA. Do you think it will be useful to have it? If so, please submit your request through technical support channel.
Regards,
Vladimir

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