#include "dialog.h" #include //typedef HWND(WINAPI *PROCGETCONSOLEWINDOW)(); //PROCGETCONSOLEWINDOW GetConsoleWindowAPI; //int iNum = 0; #define ISAPI_OUT_LEN 3 * 1024 * 1024 #define ISAPI_STATUS_LEN 8*1024 //时间解析宏定义 #define GET_YEAR(_time_) (((_time_)>>26) + 2000) #define GET_MONTH(_time_) (((_time_)>>22) & 15) #define GET_DAY(_time_) (((_time_)>>17) & 31) #define GET_HOUR(_time_) (((_time_)>>12) & 31) #define GET_MINUTE(_time_) (((_time_)>>6) & 63) #define GET_SECOND(_time_) (((_time_)>>0) & 63) int main(int argc, char *argv[]) { // QCoreApplication::setAttribute(Qt::AA_EnableHighDpiScaling); QApplication a(argc, argv); Dialog w; // NET_DVR_Init(); w.show(); w.startInBackground(); //--------------------------------------- // 初始化 // NET_DVR_Init(); // //设置连接时间与重连时间 // NET_DVR_SetConnectTime(2000, 1); // NET_DVR_SetReconnect(10000, true); //--------------------------------------- //设置异常消息回调函数 // NET_DVR_SetExceptionCallBack_V30(0, NULL, g_ExceptionCallBack, NULL); //--------------------------------------- // 获取控制台窗口句柄 //HMODULE hKernel32 = GetModuleHandle("kernel32"); // GetConsoleWindowAPI = (PROCGETCONSOLEWINDOW)GetProcAddress(hKernel32, "GetConsoleWindow"); return a.exec(); }