1
0
mirror of https://github.com/opencv/opencv.git synced 2026-07-29 15:23:05 +04:00

trace: initial support for code trace

This commit is contained in:
Alexander Alekhin
2017-05-25 18:59:01 +03:00
parent 07aff8e85f
commit 006966e629
58 changed files with 2963 additions and 185 deletions
+12
View File
@@ -556,6 +556,8 @@ imreadmulti_(const String& filename, int flags, std::vector<Mat>& mats)
*/
Mat imread( const String& filename, int flags )
{
CV_TRACE_FUNCTION();
/// create the basic container
Mat img;
@@ -584,6 +586,8 @@ Mat imread( const String& filename, int flags )
*/
bool imreadmulti(const String& filename, std::vector<Mat>& mats, int flags)
{
CV_TRACE_FUNCTION();
return imreadmulti_(filename, flags, mats);
}
@@ -621,6 +625,8 @@ static bool imwrite_( const String& filename, const Mat& image,
bool imwrite( const String& filename, InputArray _img,
const std::vector<int>& params )
{
CV_TRACE_FUNCTION();
Mat img = _img.getMat();
return imwrite_(filename, img, params, false);
}
@@ -725,6 +731,8 @@ imdecode_( const Mat& buf, int flags, int hdrtype, Mat* mat=0 )
Mat imdecode( InputArray _buf, int flags )
{
CV_TRACE_FUNCTION();
Mat buf = _buf.getMat(), img;
imdecode_( buf, flags, LOAD_MAT, &img );
@@ -739,6 +747,8 @@ Mat imdecode( InputArray _buf, int flags )
Mat imdecode( InputArray _buf, int flags, Mat* dst )
{
CV_TRACE_FUNCTION();
Mat buf = _buf.getMat(), img;
dst = dst ? dst : &img;
imdecode_( buf, flags, LOAD_MAT, dst );
@@ -755,6 +765,8 @@ Mat imdecode( InputArray _buf, int flags, Mat* dst )
bool imencode( const String& ext, InputArray _image,
std::vector<uchar>& buf, const std::vector<int>& params )
{
CV_TRACE_FUNCTION();
Mat image = _image.getMat();
int channels = image.channels();