38 lines
947 B
C++
38 lines
947 B
C++
#include "mainwindow.h"
|
|
#include <QApplication>
|
|
#include "cplaywidget.h"
|
|
#include <QTimer>
|
|
#include "CameraCapture.h"
|
|
#include "mainwindow.h"
|
|
|
|
void CameraDataCallback(double ts, BYTE *dat, LONG size){
|
|
qDebug()<<"reieve cnt"<<size;
|
|
}
|
|
|
|
int main(int argc, char *argv[])
|
|
{
|
|
QApplication a(argc, argv);
|
|
|
|
MainWindow main;
|
|
main.show();
|
|
/*
|
|
CPlayWidget gPlayer(nullptr);
|
|
gPlayer.SetDataType(CPlayWidget::IMG_TYPE::TYPE_RGB32);
|
|
gPlayer.SetImgSize(640,480);
|
|
gPlayer.show();
|
|
Camera *gCam;
|
|
std::vector<std::wstring> names = Camera::EnumAllCamera();
|
|
for(auto itr = names.begin();itr != names.end();itr++){
|
|
if(gCam->Open(*names.begin()) ){
|
|
Camera *gCam = new Camera(*names.begin());
|
|
gCam->SetObserver(&gPlayer);
|
|
qDebug("open success");
|
|
}else{
|
|
qDebug("open fail");
|
|
}
|
|
qDebug()<<QString::fromStdWString(*itr);
|
|
}
|
|
*/
|
|
return a.exec();
|
|
}
|