mexlog.cpp
来自「显著区域检测。求的图像中感兴趣区域的位置」· C++ 代码 · 共 59 行
CPP
59 行
/*!@file mexLog.cpp a few helpful functions for logging in mex files. */// This file is part of the SaliencyToolbox - Copyright (C) 2006-2007// by Dirk B. Walther and the California Institute of Technology.// See the enclosed LICENSE.TXT document for the license agreement. // More information about this project is available at: // http://www.saliencytoolbox.net#include "mexLog.h"#include <cstdarg>#include <cstdio>#define BUFMAXSIZE 1000// ######################################################################void mexInfo(const char *fmt,...){ char buf[BUFMAXSIZE]; va_list ap; va_start(ap,fmt); vsnprintf(buf,BUFMAXSIZE,fmt,ap); va_end(ap); mexPrintf("%s: %s\n",mexFunctionName(),buf);}// ######################################################################void mexError(const char *fmt,...){ char buf[BUFMAXSIZE]; va_list ap; va_start(ap,fmt); vsnprintf(buf,BUFMAXSIZE,fmt,ap); va_end(ap); mexPrintf("Error in %s: %s\n",mexFunctionName(),buf);}// ######################################################################void mexFatal(const char *fmt,...){ char buf[BUFMAXSIZE]; va_list ap; va_start(ap,fmt); vsnprintf(buf,BUFMAXSIZE,fmt,ap); va_end(ap); mexErrMsgTxt(buf);}// ######################################################################void mexDebug(const char *fmt,...){ char buf[BUFMAXSIZE]; va_list ap; va_start(ap,fmt); vsnprintf(buf,BUFMAXSIZE,fmt,ap); va_end(ap); mexPrintf("%s-debug: %s\n",mexFunctionName(),buf);}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?