cmd option

This commit is contained in:
Ilya Lavrenov
2014-04-17 15:21:30 +04:00
parent 87eb1b8fcc
commit 05a47d9014
10 changed files with 72 additions and 19 deletions

View File

@@ -560,12 +560,14 @@ namespace cudev
template <typename _Tp> class GpuMat_;
}
namespace ipp
{
CV_EXPORTS void setIppStatus(int status, const char * const funcname = NULL, const char * const filename = NULL,
int line = 0);
CV_EXPORTS int getIppStatus();
CV_EXPORTS String getIppErrorLocation();
#define setIppErrorStatus() setIppStatus(-1, CV_Func, __FILE__, __LINE__)
} // ipp
} // cv
#endif //__OPENCV_CORE_BASE_HPP__

View File

@@ -218,6 +218,8 @@ CV_EXPORTS void scalarToRawData(const cv::Scalar& s, void* buf, int type, int un
# endif
# define IPP_VERSION_X100 (IPP_VERSION_MAJOR * 100 + IPP_VERSION_MINOR)
#define setIppErrorStatus() cv::ipp::setIppStatus(-1, CV_Func, __FILE__, __LINE__)
static inline IppiSize ippiSize(int width, int height)
{
IppiSize size = { width, height };

View File

@@ -1063,9 +1063,12 @@ TLSStorage::~TLSStorage()
TLSData<CoreTLSData> coreTlsData;
namespace ipp
{
static int ippStatus = 0; // 0 - all is ok, -1 - IPP functions failed
static const char * funcname, * filename;
static int linen;
static const char * funcname = NULL, * filename = NULL;
static int linen = 0;
void setIppStatus(int status, const char * const _funcname, const char * const _filename, int _line)
{
@@ -1085,6 +1088,8 @@ String getIppErrorLocation()
return format("%s:%d %s", filename ? filename : "", linen, funcname ? funcname : "");
}
} // namespace ipp
} // namespace cv
/* End of file. */