Fixed primitives misuse.

This commit is contained in:
Armin Novak 2016-07-13 15:15:41 +02:00
parent a6cef5cde7
commit 076b92dd72
3 changed files with 13 additions and 11 deletions

View File

@ -138,12 +138,12 @@ typedef pstatus_t (*__sign_16s_t)(
INT16* pDst,
UINT32 len);
typedef pstatus_t (*__yCbCrToRGB_16s8u_P3AC4R_t)(
const INT16* pSrc[3], INT32 srcStep,
BYTE* pDst, INT32 dstStep, UINT32 DstFormat,
const INT16* pSrc[3], UINT32 srcStep,
BYTE* pDst, UINT32 dstStep, UINT32 DstFormat,
const prim_size_t* roi);
typedef pstatus_t (*__yCbCrToBGR_16s8u_P3AC4R_t)(
const INT16* pSrc[3], INT32 srcStep,
BYTE* pDst, INT32 dstStep, UINT32 DstFormat,
const INT16* pSrc[3], UINT32 srcStep,
BYTE* pDst, UINT32 dstStep, UINT32 DstFormat,
const prim_size_t* roi);
typedef pstatus_t (*__yCbCrToRGB_16s16s_P3P3_t)(
const INT16* pSrc[3], INT32 srcStep,

View File

@ -42,8 +42,8 @@ static INLINE BYTE* writePixel(BYTE* dst, UINT32 format, BYTE r, BYTE g, BYTE b)
static pstatus_t general_yCbCrToRGB_16s8u_P3AC4R(
const INT16* pSrc[3], INT32 srcStep,
BYTE* pDst, INT32 dstStep, UINT32 DstFormat,
const INT16* pSrc[3], UINT32 srcStep,
BYTE* pDst, UINT32 DstFormat, UINT32 dstStep,
const prim_size_t* roi)
{
UINT32 x, y;
@ -98,8 +98,8 @@ static pstatus_t general_yCbCrToRGB_16s8u_P3AC4R(
}
static pstatus_t general_yCbCrToBGR_16s8u_P3AC4R(
const INT16* pSrc[3], INT32 srcStep,
BYTE* pDst, INT32 dstStep, UINT32 DstFormat,
const INT16* pSrc[3], UINT32 srcStep,
BYTE* pDst, UINT32 DstFormat, UINT32 dstStep,
const prim_size_t* roi)
{
UINT32 x, y;

View File

@ -2274,6 +2274,7 @@ int test_YCbCr_pixels()
int TestPrimitivesYCbCr(int argc, char* argv[])
{
pstatus_t status = PRIMITIVES_SUCCESS;
int size;
int cnt[3];
float err[3];
@ -2298,8 +2299,9 @@ int TestPrimitivesYCbCr(int argc, char* argv[])
if (1)
{
prims->yCbCrToRGB_16s8u_P3AC4R((const INT16**) pYCbCr, 64 * 2,
actual, 64 * 4, PIXEL_FORMAT_BGRA32, &roi_64x64);
status = prims->yCbCrToRGB_16s8u_P3AC4R((const INT16**) pYCbCr, 64 * 2,
actual, PIXEL_FORMAT_BGRA32,
64 * 4, &roi_64x64);
}
else
{
@ -2358,6 +2360,6 @@ int TestPrimitivesYCbCr(int argc, char* argv[])
}
_aligned_free(actual);
return 0;
return (status == PRIMITIVES_SUCCESS) ? 0 : 1;
}