Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

BinaryFunc type in new version of OpenCv is missing

I have some project which was wriiten in OpenCV 2.4.x and I migrated it to version 3.4.1. I am nearly at the end of my work but in the sources data type BinaryFunc is used and method CV_EXPORTS BinaryFunc getConvertFunc(int sdepth, int ddepth) too. In old version they are placed in core.hpp file. But in version 3.4.1 they are not available. I found them in another header file but it is only "internal file of OpenCv". Any idea how to rewrite the code to work with new version of OpenCV?

Old core.hpp : typedef void (BinaryFunc)(const uchar src1, size_t step1, const uchar* src2, size_t step2, uchar* dst, size_t step, Size sz, void*); CV_EXPORTS BinaryFunc getConvertFunc(int sdepth, int ddepth); CV_EXPORTS BinaryFunc getConvertScaleFunc(int sdepth, int ddepth); CV_EXPORTS BinaryFunc getCopyMaskFunc(size_t esz);

This is not present in new core.hpp.

click to hide/show revision 2
None

updated 2018-05-31 01:05:22 -0600

berak gravatar image

BinaryFunc type in new version of OpenCv is missing

I have some project which was wriiten in OpenCV 2.4.x and I migrated it to version 3.4.1. I am nearly at the end of my work but in the sources data type BinaryFunc is used and method

CV_EXPORTS BinaryFunc getConvertFunc(int sdepth, int ddepth) ddepth)

too. In old version they are placed in core.hpp file. But in version 3.4.1 they are not available. I found them in another header file but it is only "internal file of OpenCv". Any idea how to rewrite the code to work with new version of OpenCV?

Old core.hpp : :

typedef void (BinaryFunc)(const uchar (*BinaryFunc)(const uchar* src1, size_t step1,
                           const uchar* src2, size_t step2,
                           uchar* dst, size_t step, Size sz,       void*);
CV_EXPORTS BinaryFunc getConvertFunc(int sdepth, int ddepth);
CV_EXPORTS BinaryFunc getConvertScaleFunc(int sdepth, int ddepth);
CV_EXPORTS BinaryFunc getCopyMaskFunc(size_t esz);

esz);

This is not present in new core.hpp.