-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.cpp
47 lines (31 loc) · 839 Bytes
/
main.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
#include <QCoreApplication>
#include <stdio.h>
#include <iostream>
#include <QThread>
#include <opengev.h>
#include "app.h"
#include <string.h>
#include <stdlib.h>
//#include <X11/Xlib.h>
using namespace std;
int main(int argc, char *argv[])
{
QCoreApplication a(argc, argv);
OpenGEV::configure();
/*
App* myObj = new App(); // 0 = no parent
QThread* thread = new QThread;
myObj->moveToThread(thread);
QObject::connect(thread, SIGNAL(started()), myObj, SLOT(run()));
thread->start();
*/
//XInitThreads();
std::cout<<argv[1]<<std::endl;
char* p;
int channels = strtol(argv[1], &p, 10);
int packetSize = strtol(argv[2], &p, 10);
int packetDelay = strtol(argv[3], &p, 10);
App myObj (channels, packetSize, packetDelay);
myObj.start();
return a.exec();
}