typedef pstatus_t (*__shiftC_16s_t)(const INT16* pSrc, INT32 val, INT16* pSrcDst, UINT32 len);
typedef pstatus_t (*__shiftC_16u_t)(const UINT16* pSrc, INT32 val, UINT16* pSrcDst, UINT32 len);
typedef pstatus_t (*__sign_16s_t)(const INT16* pSrc, INT16* pDst, UINT32 len);
-typedef pstatus_t (*__yCbCrToRGB_16s8u_P3AC4R_t)(const INT16* pSrc[3], UINT32 srcStep, BYTE* pDst,
- UINT32 dstStep, UINT32 DstFormat,
+typedef pstatus_t (*__yCbCrToRGB_16s8u_P3AC4R_t)(const INT16* const 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, INT16* pDst[3],
- INT32 dstStep, const prim_size_t* roi);
-typedef pstatus_t (*__RGBToYCbCr_16s16s_P3P3_t)(const INT16* pSrc[3], INT32 srcStep, INT16* pDst[3],
- INT32 dstStep, const prim_size_t* roi);
+typedef pstatus_t (*__yCbCrToRGB_16s16s_P3P3_t)(const INT16* const pSrc[3], INT32 srcStep,
+ INT16* pDst[3], INT32 dstStep,
+ const prim_size_t* roi);
+typedef pstatus_t (*__RGBToYCbCr_16s16s_P3P3_t)(const INT16* const pSrc[3], INT32 srcStep,
+ INT16* pDst[3], INT32 dstStep,
+ const prim_size_t* roi);
typedef pstatus_t (*__RGBToRGB_16s8u_P3AC4R_t)(const INT16* const pSrc[3], UINT32 srcStep,
BYTE* pDst, UINT32 dstStep, UINT32 DstFormat,
const prim_size_t* roi);
typedef pstatus_t (*__RGB565ToARGB_16u32u_C3C4_t)(const UINT16* pSrc, INT32 srcStep, UINT32* pDst,
INT32 dstStep, UINT32 width, UINT32 height,
UINT32 format);
-typedef pstatus_t (*__YUV420ToRGB_8u_P3AC4R_t)(const BYTE* pSrc[3], const UINT32 srcStep[3],
+typedef pstatus_t (*__YUV420ToRGB_8u_P3AC4R_t)(const BYTE* const pSrc[3], const UINT32 srcStep[3],
BYTE* pDst, UINT32 dstStep, UINT32 DstFormat,
const prim_size_t* roi);
-typedef pstatus_t (*__YUV444ToRGB_8u_P3AC4R_t)(const BYTE* pSrc[3], const UINT32 srcStep[3],
+typedef pstatus_t (*__YUV444ToRGB_8u_P3AC4R_t)(const BYTE* const pSrc[3], const UINT32 srcStep[3],
BYTE* pDst, UINT32 dstStep, UINT32 DstFormat,
const prim_size_t* roi);
typedef pstatus_t (*__RGBToYUV420_8u_P3AC4R_t)(const BYTE* pSrc, UINT32 SrcFormat, UINT32 srcStep,
typedef pstatus_t (*__RGBToYUV444_8u_P3AC4R_t)(const BYTE* pSrc, UINT32 SrcFormat, UINT32 srcStep,
BYTE* pDst[3], UINT32 dstStep[3],
const prim_size_t* roi);
-typedef pstatus_t (*__YUV420CombineToYUV444_t)(avc444_frame_type type, const BYTE* pSrc[3],
+typedef pstatus_t (*__YUV420CombineToYUV444_t)(avc444_frame_type type, const BYTE* const pSrc[3],
const UINT32 srcStep[3], UINT32 nWidth,
UINT32 nHeight, BYTE* pDst[3],
const UINT32 dstStep[3], const RECTANGLE_16* roi);
-typedef pstatus_t (*__YUV444SplitToYUV420_t)(const BYTE* pSrc[3], const UINT32 srcStep[3],
+typedef pstatus_t (*__YUV444SplitToYUV420_t)(const BYTE* const pSrc[3], const UINT32 srcStep[3],
BYTE* pMainDst[3], const UINT32 dstMainStep[3],
BYTE* pAuxDst[3], const UINT32 srcAuxStep[3],
const prim_size_t* roi);
UINT32* piDstStride = h264->iYUV444Stride;
BYTE** ppYUVDstData = h264->pYUV444Data;
const UINT32* piStride = h264->iStride;
- const BYTE** ppYUVData = (const BYTE**)h264->pYUVData;
+ const BYTE* const* ppYUVData = (const BYTE* const*)h264->pYUVData;
if (h264->subsystem->Decompress(h264, pSrcData, SrcSize) < 0)
return FALSE;
#include <freerdp/codec/color.h>
#include "prim_internal.h"
-static pstatus_t general_LumaToYUV444(const BYTE* pSrcRaw[3], const UINT32 srcStep[3],
+static pstatus_t general_LumaToYUV444(const BYTE* const pSrcRaw[3], const UINT32 srcStep[3],
BYTE* pDstRaw[3], const UINT32 dstStep[3],
const RECTANGLE_16* roi)
{
return PRIMITIVES_SUCCESS;
}
-static pstatus_t general_ChromaV1ToYUV444(const BYTE* pSrcRaw[3], const UINT32 srcStep[3],
+static pstatus_t general_ChromaV1ToYUV444(const BYTE* const pSrcRaw[3], const UINT32 srcStep[3],
BYTE* pDstRaw[3], const UINT32 dstStep[3],
const RECTANGLE_16* roi)
{
return general_ChromaFilter(pDst, dstStep, roi);
}
-static pstatus_t general_ChromaV2ToYUV444(const BYTE* pSrc[3], const UINT32 srcStep[3],
+static pstatus_t general_ChromaV2ToYUV444(const BYTE* const pSrc[3], const UINT32 srcStep[3],
UINT32 nTotalWidth, UINT32 nTotalHeight, BYTE* pDst[3],
const UINT32 dstStep[3], const RECTANGLE_16* roi)
{
return general_ChromaFilter(pDst, dstStep, roi);
}
-static pstatus_t general_YUV420CombineToYUV444(avc444_frame_type type, const BYTE* pSrc[3],
+static pstatus_t general_YUV420CombineToYUV444(avc444_frame_type type, const BYTE* const pSrc[3],
const UINT32 srcStep[3], UINT32 nWidth,
UINT32 nHeight, BYTE* pDst[3],
const UINT32 dstStep[3], const RECTANGLE_16* roi)
}
}
-static pstatus_t general_YUV444SplitToYUV420(const BYTE* pSrc[3], const UINT32 srcStep[3],
+static pstatus_t general_YUV444SplitToYUV420(const BYTE* const pSrc[3], const UINT32 srcStep[3],
BYTE* pMainDst[3], const UINT32 dstMainStep[3],
BYTE* pAuxDst[3], const UINT32 dstAuxStep[3],
const prim_size_t* roi)
return PRIMITIVES_SUCCESS;
}
-static pstatus_t general_YUV444ToRGB_8u_P3AC4R_general(const BYTE* pSrc[3], const UINT32 srcStep[3],
- BYTE* pDst, UINT32 dstStep, UINT32 DstFormat,
+static pstatus_t general_YUV444ToRGB_8u_P3AC4R_general(const BYTE* const pSrc[3],
+ const UINT32 srcStep[3], BYTE* pDst,
+ UINT32 dstStep, UINT32 DstFormat,
const prim_size_t* roi)
{
UINT32 x, y;
return PRIMITIVES_SUCCESS;
}
-static pstatus_t general_YUV444ToRGB_8u_P3AC4R_BGRX(const BYTE* pSrc[3], const UINT32 srcStep[3],
- BYTE* pDst, UINT32 dstStep, UINT32 DstFormat,
+static pstatus_t general_YUV444ToRGB_8u_P3AC4R_BGRX(const BYTE* const pSrc[3],
+ const UINT32 srcStep[3], BYTE* pDst,
+ UINT32 dstStep, UINT32 DstFormat,
const prim_size_t* roi)
{
UINT32 x, y;
return PRIMITIVES_SUCCESS;
}
-static pstatus_t general_YUV444ToRGB_8u_P3AC4R(const BYTE* pSrc[3], const UINT32 srcStep[3],
+static pstatus_t general_YUV444ToRGB_8u_P3AC4R(const BYTE* const pSrc[3], const UINT32 srcStep[3],
BYTE* pDst, UINT32 dstStep, UINT32 DstFormat,
const prim_size_t* roi)
{
* | G | = ( | 256 -48 -120 | | U - 128 | ) >> 8
* | B | ( | 256 475 0 | | V - 128 | )
*/
-static pstatus_t general_YUV420ToRGB_8u_P3AC4R(const BYTE* pSrc[3], const UINT32 srcStep[3],
+static pstatus_t general_YUV420ToRGB_8u_P3AC4R(const BYTE* const pSrc[3], const UINT32 srcStep[3],
BYTE* pDst, UINT32 dstStep, UINT32 DstFormat,
const prim_size_t* roi)
{
return pRGB;
}
-static INLINE pstatus_t neon_YUV420ToX(const BYTE* pSrc[3], const UINT32 srcStep[3], BYTE* pDst,
- UINT32 dstStep, const prim_size_t* roi, const uint8_t rPos,
- const uint8_t gPos, const uint8_t bPos, const uint8_t aPos)
+static INLINE pstatus_t neon_YUV420ToX(const BYTE* const pSrc[3], const UINT32 srcStep[3],
+ BYTE* pDst, UINT32 dstStep, const prim_size_t* roi,
+ const uint8_t rPos, const uint8_t gPos, const uint8_t bPos,
+ const uint8_t aPos)
{
UINT32 y;
const UINT32 nWidth = roi->width;
return PRIMITIVES_SUCCESS;
}
-static pstatus_t neon_YUV420ToRGB_8u_P3AC4R(const BYTE* pSrc[3], const UINT32 srcStep[3],
+static pstatus_t neon_YUV420ToRGB_8u_P3AC4R(const BYTE* const pSrc[3], const UINT32 srcStep[3],
BYTE* pDst, UINT32 dstStep, UINT32 DstFormat,
const prim_size_t* roi)
{
}
}
-static INLINE pstatus_t neon_YUV444ToX(const BYTE* pSrc[3], const UINT32 srcStep[3], BYTE* pDst,
- UINT32 dstStep, const prim_size_t* roi, const uint8_t rPos,
- const uint8_t gPos, const uint8_t bPos, const uint8_t aPos)
+static INLINE pstatus_t neon_YUV444ToX(const BYTE* const pSrc[3], const UINT32 srcStep[3],
+ BYTE* pDst, UINT32 dstStep, const prim_size_t* roi,
+ const uint8_t rPos, const uint8_t gPos, const uint8_t bPos,
+ const uint8_t aPos)
{
UINT32 y;
const UINT32 nWidth = roi->width;
return PRIMITIVES_SUCCESS;
}
-static pstatus_t neon_YUV444ToRGB_8u_P3AC4R(const BYTE* pSrc[3], const UINT32 srcStep[3],
+static pstatus_t neon_YUV444ToRGB_8u_P3AC4R(const BYTE* const pSrc[3], const UINT32 srcStep[3],
BYTE* pDst, UINT32 dstStep, UINT32 DstFormat,
const prim_size_t* roi)
{
}
}
-static pstatus_t neon_LumaToYUV444(const BYTE* pSrcRaw[3], const UINT32 srcStep[3],
+static pstatus_t neon_LumaToYUV444(const BYTE* const pSrcRaw[3], const UINT32 srcStep[3],
BYTE* pDstRaw[3], const UINT32 dstStep[3],
const RECTANGLE_16* roi)
{
return PRIMITIVES_SUCCESS;
}
-static pstatus_t neon_ChromaV1ToYUV444(const BYTE* pSrcRaw[3], const UINT32 srcStep[3],
+static pstatus_t neon_ChromaV1ToYUV444(const BYTE* const pSrcRaw[3], const UINT32 srcStep[3],
BYTE* pDstRaw[3], const UINT32 dstStep[3],
const RECTANGLE_16* roi)
{
return neon_ChromaFilter(pDst, dstStep, roi);
}
-static pstatus_t neon_ChromaV2ToYUV444(const BYTE* pSrc[3], const UINT32 srcStep[3],
+static pstatus_t neon_ChromaV2ToYUV444(const BYTE* const pSrc[3], const UINT32 srcStep[3],
UINT32 nTotalWidth, UINT32 nTotalHeight, BYTE* pDst[3],
const UINT32 dstStep[3], const RECTANGLE_16* roi)
{
return neon_ChromaFilter(pDst, dstStep, roi);
}
-static pstatus_t neon_YUV420CombineToYUV444(avc444_frame_type type, const BYTE* pSrc[3],
+static pstatus_t neon_YUV420CombineToYUV444(avc444_frame_type type, const BYTE* const pSrc[3],
const UINT32 srcStep[3], UINT32 nWidth, UINT32 nHeight,
BYTE* pDst[3], const UINT32 dstStep[3],
const RECTANGLE_16* roi)
return dst;
}
-static pstatus_t ssse3_YUV420ToRGB_BGRX(const BYTE** pSrc, const UINT32* srcStep, BYTE* pDst,
+static pstatus_t ssse3_YUV420ToRGB_BGRX(const BYTE* const* pSrc, const UINT32* srcStep, BYTE* pDst,
UINT32 dstStep, const prim_size_t* roi)
{
const UINT32 nWidth = roi->width;
return PRIMITIVES_SUCCESS;
}
-static pstatus_t ssse3_YUV420ToRGB(const BYTE** pSrc, const UINT32* srcStep, BYTE* pDst,
+static pstatus_t ssse3_YUV420ToRGB(const BYTE* const* pSrc, const UINT32* srcStep, BYTE* pDst,
UINT32 dstStep, UINT32 DstFormat, const prim_size_t* roi)
{
switch (DstFormat)
}
}
-static pstatus_t ssse3_YUV444ToRGB_8u_P3AC4R_BGRX(const BYTE** pSrc, const UINT32* srcStep,
+static pstatus_t ssse3_YUV444ToRGB_8u_P3AC4R_BGRX(const BYTE* const* pSrc, const UINT32* srcStep,
BYTE* pDst, UINT32 dstStep,
const prim_size_t* roi)
{
return PRIMITIVES_SUCCESS;
}
-static pstatus_t ssse3_YUV444ToRGB_8u_P3AC4R(const BYTE** pSrc, const UINT32* srcStep, BYTE* pDst,
- UINT32 dstStep, UINT32 DstFormat,
+static pstatus_t ssse3_YUV444ToRGB_8u_P3AC4R(const BYTE* const* pSrc, const UINT32* srcStep,
+ BYTE* pDst, UINT32 dstStep, UINT32 DstFormat,
const prim_size_t* roi)
{
if ((unsigned long)pSrc[0] % 16 || (unsigned long)pSrc[1] % 16 || (unsigned long)pSrc[2] % 16 ||
}
}
-static pstatus_t ssse3_LumaToYUV444(const BYTE* pSrcRaw[3], const UINT32 srcStep[3],
+static pstatus_t ssse3_LumaToYUV444(const BYTE* const pSrcRaw[3], const UINT32 srcStep[3],
BYTE* pDstRaw[3], const UINT32 dstStep[3],
const RECTANGLE_16* roi)
{
return PRIMITIVES_SUCCESS;
}
-static pstatus_t ssse3_ChromaV1ToYUV444(const BYTE* pSrcRaw[3], const UINT32 srcStep[3],
+static pstatus_t ssse3_ChromaV1ToYUV444(const BYTE* const pSrcRaw[3], const UINT32 srcStep[3],
BYTE* pDstRaw[3], const UINT32 dstStep[3],
const RECTANGLE_16* roi)
{
return ssse3_ChromaFilter(pDst, dstStep, roi);
}
-static pstatus_t ssse3_ChromaV2ToYUV444(const BYTE* pSrc[3], const UINT32 srcStep[3],
+static pstatus_t ssse3_ChromaV2ToYUV444(const BYTE* const pSrc[3], const UINT32 srcStep[3],
UINT32 nTotalWidth, UINT32 nTotalHeight, BYTE* pDst[3],
const UINT32 dstStep[3], const RECTANGLE_16* roi)
{
return ssse3_ChromaFilter(pDst, dstStep, roi);
}
-static pstatus_t ssse3_YUV420CombineToYUV444(avc444_frame_type type, const BYTE* pSrc[3],
+static pstatus_t ssse3_YUV420CombineToYUV444(avc444_frame_type type, const BYTE* const pSrc[3],
const UINT32 srcStep[3], UINT32 nWidth, UINT32 nHeight,
BYTE* pDst[3], const UINT32 dstStep[3],
const RECTANGLE_16* roi)
#define MINMAX(_v_, _l_, _h_) ((_v_) < (_l_) ? (_l_) : ((_v_) > (_h_) ? (_h_) : (_v_)))
#endif /* !MINMAX */
/* ------------------------------------------------------------------------- */
-static pstatus_t general_yCbCrToRGB_16s8u_P3AC4R_BGRX(const INT16* pSrc[3], UINT32 srcStep,
+static pstatus_t general_yCbCrToRGB_16s8u_P3AC4R_BGRX(const INT16* const pSrc[3], UINT32 srcStep,
BYTE* pDst, UINT32 dstStep, UINT32 DstFormat,
const prim_size_t* roi)
{
return PRIMITIVES_SUCCESS;
}
-static pstatus_t general_yCbCrToRGB_16s8u_P3AC4R_general(const INT16* pSrc[3], UINT32 srcStep,
+static pstatus_t general_yCbCrToRGB_16s8u_P3AC4R_general(const INT16* const pSrc[3], UINT32 srcStep,
BYTE* pDst, UINT32 dstStep,
UINT32 DstFormat, const prim_size_t* roi)
{
return PRIMITIVES_SUCCESS;
}
-static pstatus_t general_yCbCrToRGB_16s8u_P3AC4R(const INT16* pSrc[3], UINT32 srcStep, BYTE* pDst,
- UINT32 dstStep, UINT32 DstFormat,
+static pstatus_t general_yCbCrToRGB_16s8u_P3AC4R(const INT16* const pSrc[3], UINT32 srcStep,
+ BYTE* pDst, UINT32 dstStep, UINT32 DstFormat,
const prim_size_t* roi)
{
switch (DstFormat)
/* ------------------------------------------------------------------------- */
-static pstatus_t general_yCbCrToRGB_16s16s_P3P3(const INT16* pSrc[3], INT32 srcStep, INT16* pDst[3],
- INT32 dstStep,
+static pstatus_t general_yCbCrToRGB_16s16s_P3P3(const INT16* const pSrc[3], INT32 srcStep,
+ INT16* pDst[3], INT32 dstStep,
const prim_size_t* roi) /* region of interest */
{
/**
}
/* ------------------------------------------------------------------------- */
-static pstatus_t general_RGBToYCbCr_16s16s_P3P3(const INT16* pSrc[3], INT32 srcStep, INT16* pDst[3],
- INT32 dstStep,
+static pstatus_t general_RGBToYCbCr_16s16s_P3P3(const INT16* const pSrc[3], INT32 srcStep,
+ INT16* pDst[3], INT32 dstStep,
const prim_size_t* roi) /* region of interest */
{
/* The encoded YCbCr coefficients are represented as 11.5 fixed-point
#endif /* DO_PREFETCH */
/*---------------------------------------------------------------------------*/
-static pstatus_t sse2_yCbCrToRGB_16s16s_P3P3(const INT16* pSrc[3], int srcStep, INT16* pDst[3],
- int dstStep,
+static pstatus_t sse2_yCbCrToRGB_16s16s_P3P3(const INT16* const pSrc[3], int srcStep,
+ INT16* pDst[3], int dstStep,
const prim_size_t* roi) /* region of interest */
{
__m128i zero, max, r_cr, g_cb, g_cr, b_cb, c4096;
}
/*---------------------------------------------------------------------------*/
-static pstatus_t sse2_yCbCrToRGB_16s8u_P3AC4R_BGRX(const INT16* pSrc[3], UINT32 srcStep, BYTE* pDst,
- UINT32 dstStep,
+static pstatus_t sse2_yCbCrToRGB_16s8u_P3AC4R_BGRX(const INT16* const pSrc[3], UINT32 srcStep,
+ BYTE* pDst, UINT32 dstStep,
const prim_size_t* roi) /* region of interest */
{
const __m128i zero = _mm_setzero_si128();
}
/*---------------------------------------------------------------------------*/
-static pstatus_t sse2_yCbCrToRGB_16s8u_P3AC4R_RGBX(const INT16* pSrc[3], UINT32 srcStep, BYTE* pDst,
- UINT32 dstStep,
+static pstatus_t sse2_yCbCrToRGB_16s8u_P3AC4R_RGBX(const INT16* const pSrc[3], UINT32 srcStep,
+ BYTE* pDst, UINT32 dstStep,
const prim_size_t* roi) /* region of interest */
{
const __m128i zero = _mm_setzero_si128();
return PRIMITIVES_SUCCESS;
}
-static pstatus_t sse2_yCbCrToRGB_16s8u_P3AC4R(const INT16* pSrc[3], UINT32 srcStep, BYTE* pDst,
- UINT32 dstStep, UINT32 DstFormat,
+static pstatus_t sse2_yCbCrToRGB_16s8u_P3AC4R(const INT16* const pSrc[3], UINT32 srcStep,
+ BYTE* pDst, UINT32 dstStep, UINT32 DstFormat,
const prim_size_t* roi) /* region of interest */
{
if (((ULONG_PTR)(pSrc[0]) & 0x0f) || ((ULONG_PTR)(pSrc[1]) & 0x0f) ||
/* The encodec YCbCr coeffectients are represented as 11.5 fixed-point
* numbers. See the general code above.
*/
-static pstatus_t sse2_RGBToYCbCr_16s16s_P3P3(const INT16* pSrc[3], int srcStep, INT16* pDst[3],
- int dstStep,
+static pstatus_t sse2_RGBToYCbCr_16s16s_P3P3(const INT16* const pSrc[3], int srcStep,
+ INT16* pDst[3], int dstStep,
const prim_size_t* roi) /* region of interest */
{
__m128i min, max, y_r, y_g, y_b, cb_r, cb_g, cb_b, cr_r, cr_g, cr_b;
/*---------------------------------------------------------------------------*/
#ifdef WITH_NEON
-static pstatus_t neon_yCbCrToRGB_16s16s_P3P3(const INT16* pSrc[3], INT32 srcStep, INT16* pDst[3],
- INT32 dstStep,
+static pstatus_t neon_yCbCrToRGB_16s16s_P3P3(const INT16* const pSrc[3], INT32 srcStep,
+ INT16* pDst[3], INT32 dstStep,
const prim_size_t* roi) /* region of interest */
{
/* TODO: If necessary, check alignments and call the general version. */
return PRIMITIVES_SUCCESS;
}
-static pstatus_t neon_yCbCrToRGB_16s8u_P3AC4R_X(const INT16* pSrc[3], UINT32 srcStep, BYTE* pDst,
- UINT32 dstStep, const prim_size_t* roi,
+static pstatus_t neon_yCbCrToRGB_16s8u_P3AC4R_X(const INT16* const pSrc[3], UINT32 srcStep,
+ BYTE* pDst, UINT32 dstStep, const prim_size_t* roi,
uint8_t rPos, uint8_t gPos, uint8_t bPos,
uint8_t aPos)
{
return PRIMITIVES_SUCCESS;
}
-static pstatus_t neon_yCbCrToRGB_16s8u_P3AC4R(const INT16* pSrc[3], UINT32 srcStep, BYTE* pDst,
- UINT32 dstStep, UINT32 DstFormat,
+static pstatus_t neon_yCbCrToRGB_16s8u_P3AC4R(const INT16* const pSrc[3], UINT32 srcStep,
+ BYTE* pDst, UINT32 dstStep, UINT32 DstFormat,
const prim_size_t* roi)
{
switch (DstFormat)