mirror of
https://github.com/opencv/opencv.git
synced 2025-08-06 14:36:36 +08:00
Drop commented out convertTo impl with IPP.
This commit is contained in:
parent
1b3db545a3
commit
8f74086d3f
@ -275,102 +275,6 @@ static void cvt32s(const uchar* src, size_t sstep, const uchar*, size_t, uchar*
|
||||
static void cvt64s(const uchar* src, size_t sstep, const uchar*, size_t, uchar* dst, size_t dstep, Size size, void*)
|
||||
{ CV_INSTRUMENT_REGION(); cvtCopy((const uchar*)src, sstep, (uchar*)dst, dstep, size, 8); }
|
||||
|
||||
|
||||
/* [TODO] Recover IPP calls
|
||||
#if defined(HAVE_IPP)
|
||||
#define DEF_CVT_FUNC_F(suffix, stype, dtype, ippFavor) \
|
||||
static void cvt##suffix( const stype* src, size_t sstep, const uchar*, size_t, \
|
||||
dtype* dst, size_t dstep, Size size, double*) \
|
||||
{ \
|
||||
CV_IPP_RUN(src && dst, CV_INSTRUMENT_FUN_IPP(ippiConvert_##ippFavor, src, (int)sstep, dst, (int)dstep, ippiSize(size.width, size.height)) >= 0) \
|
||||
cvt_(src, sstep, dst, dstep, size); \
|
||||
}
|
||||
|
||||
#define DEF_CVT_FUNC_F2(suffix, stype, dtype, ippFavor) \
|
||||
static void cvt##suffix( const stype* src, size_t sstep, const uchar*, size_t, \
|
||||
dtype* dst, size_t dstep, Size size, double*) \
|
||||
{ \
|
||||
CV_IPP_RUN(src && dst, CV_INSTRUMENT_FUN_IPP(ippiConvert_##ippFavor, src, (int)sstep, dst, (int)dstep, ippiSize(size.width, size.height), ippRndFinancial, 0) >= 0) \
|
||||
cvt_(src, sstep, dst, dstep, size); \
|
||||
}
|
||||
#else
|
||||
#define DEF_CVT_FUNC_F(suffix, stype, dtype, ippFavor) \
|
||||
static void cvt##suffix( const stype* src, size_t sstep, const uchar*, size_t, \
|
||||
dtype* dst, size_t dstep, Size size, double*) \
|
||||
{ \
|
||||
cvt_(src, sstep, dst, dstep, size); \
|
||||
}
|
||||
#define DEF_CVT_FUNC_F2 DEF_CVT_FUNC_F
|
||||
#endif
|
||||
|
||||
#define DEF_CVT_FUNC(suffix, stype, dtype) \
|
||||
static void cvt##suffix( const stype* src, size_t sstep, const uchar*, size_t, \
|
||||
dtype* dst, size_t dstep, Size size, double*) \
|
||||
{ \
|
||||
cvt_(src, sstep, dst, dstep, size); \
|
||||
}
|
||||
|
||||
#define DEF_CPY_FUNC(suffix, stype) \
|
||||
static void cvt##suffix( const stype* src, size_t sstep, const uchar*, size_t, \
|
||||
stype* dst, size_t dstep, Size size, double*) \
|
||||
{ \
|
||||
cpy_(src, sstep, dst, dstep, size); \
|
||||
}
|
||||
|
||||
DEF_CPY_FUNC(8u, uchar)
|
||||
DEF_CVT_FUNC_F(8s8u, schar, uchar, 8s8u_C1Rs)
|
||||
DEF_CVT_FUNC_F(16u8u, ushort, uchar, 16u8u_C1R)
|
||||
DEF_CVT_FUNC_F(16s8u, short, uchar, 16s8u_C1R)
|
||||
DEF_CVT_FUNC_F(32s8u, int, uchar, 32s8u_C1R)
|
||||
DEF_CVT_FUNC_F2(32f8u, float, uchar, 32f8u_C1RSfs)
|
||||
DEF_CVT_FUNC(64f8u, double, uchar)
|
||||
|
||||
DEF_CVT_FUNC_F2(8u8s, uchar, schar, 8u8s_C1RSfs)
|
||||
DEF_CVT_FUNC_F2(16u8s, ushort, schar, 16u8s_C1RSfs)
|
||||
DEF_CVT_FUNC_F2(16s8s, short, schar, 16s8s_C1RSfs)
|
||||
DEF_CVT_FUNC_F(32s8s, int, schar, 32s8s_C1R)
|
||||
DEF_CVT_FUNC_F2(32f8s, float, schar, 32f8s_C1RSfs)
|
||||
DEF_CVT_FUNC(64f8s, double, schar)
|
||||
|
||||
DEF_CVT_FUNC_F(8u16u, uchar, ushort, 8u16u_C1R)
|
||||
DEF_CVT_FUNC_F(8s16u, schar, ushort, 8s16u_C1Rs)
|
||||
DEF_CPY_FUNC(16u, ushort)
|
||||
DEF_CVT_FUNC_F(16s16u, short, ushort, 16s16u_C1Rs)
|
||||
DEF_CVT_FUNC_F2(32s16u, int, ushort, 32s16u_C1RSfs)
|
||||
DEF_CVT_FUNC_F2(32f16u, float, ushort, 32f16u_C1RSfs)
|
||||
DEF_CVT_FUNC(64f16u, double, ushort)
|
||||
|
||||
DEF_CVT_FUNC_F(8u16s, uchar, short, 8u16s_C1R)
|
||||
DEF_CVT_FUNC_F(8s16s, schar, short, 8s16s_C1R)
|
||||
DEF_CVT_FUNC_F2(16u16s, ushort, short, 16u16s_C1RSfs)
|
||||
DEF_CVT_FUNC_F2(32s16s, int, short, 32s16s_C1RSfs)
|
||||
DEF_CVT_FUNC(32f16s, float, short)
|
||||
DEF_CVT_FUNC(64f16s, double, short)
|
||||
|
||||
DEF_CVT_FUNC_F(8u32s, uchar, int, 8u32s_C1R)
|
||||
DEF_CVT_FUNC_F(8s32s, schar, int, 8s32s_C1R)
|
||||
DEF_CVT_FUNC_F(16u32s, ushort, int, 16u32s_C1R)
|
||||
DEF_CVT_FUNC_F(16s32s, short, int, 16s32s_C1R)
|
||||
DEF_CPY_FUNC(32s, int)
|
||||
DEF_CVT_FUNC_F2(32f32s, float, int, 32f32s_C1RSfs)
|
||||
DEF_CVT_FUNC(64f32s, double, int)
|
||||
|
||||
DEF_CVT_FUNC_F(8u32f, uchar, float, 8u32f_C1R)
|
||||
DEF_CVT_FUNC_F(8s32f, schar, float, 8s32f_C1R)
|
||||
DEF_CVT_FUNC_F(16u32f, ushort, float, 16u32f_C1R)
|
||||
DEF_CVT_FUNC_F(16s32f, short, float, 16s32f_C1R)
|
||||
DEF_CVT_FUNC_F(32s32f, int, float, 32s32f_C1R)
|
||||
DEF_CVT_FUNC(64f32f, double, float)
|
||||
|
||||
DEF_CVT_FUNC(8u64f, uchar, double)
|
||||
DEF_CVT_FUNC(8s64f, schar, double)
|
||||
DEF_CVT_FUNC(16u64f, ushort, double)
|
||||
DEF_CVT_FUNC(16s64f, short, double)
|
||||
DEF_CVT_FUNC(32s64f, int, double)
|
||||
DEF_CVT_FUNC(32f64f, float, double)
|
||||
DEF_CPY_FUNC(64s, int64)
|
||||
*/
|
||||
|
||||
BinaryFunc getConvertFunc(int sdepth, int ddepth)
|
||||
{
|
||||
static BinaryFunc cvtTab[CV_DEPTH_MAX][CV_DEPTH_MAX] =
|
||||
|
Loading…
Reference in New Issue
Block a user