-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathmain.cpp
More file actions
47 lines (31 loc) · 782 Bytes
/
Copy pathmain.cpp
File metadata and controls
47 lines (31 loc) · 782 Bytes
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 <iostream>
#include <QApplication>
#include <QtCore/QThread>
#include <QAbstractEventDispatcher>
#include <Image/TrigCache.h>
#include "DepthForgeWin.h"
#include "MainWnd.h"
#include "version.h"
QApplication *app;
extern double sinTab[65536];
extern double cosTab[65536];
int main(int argc, char **argv) {
for (int i=0; i<65536; i++)
{
double th = (i/65536.0)*M_PI*2;
sinTab[i] = sin(th);
cosTab[i] = cos(th);
}
Init_JWC_PixelGfx();
int Threads = QThread::idealThreadCount();
app = new QApplication(argc, argv);
GfxInitThreadWorkers(Threads);
MainWnd *Win = new MainWnd();
Win->resize(800,800);
Win->show();
app->exec();
GfxTerminate();
delete Win;
delete app;
return 0;
}