7 OpenFile* g_CurrentFile = NULL; |
7 OpenFile* g_CurrentFile = NULL; |
8 LDForgeWindow* g_qWindow = NULL; |
8 LDForgeWindow* g_qWindow = NULL; |
9 bbox g_BBox; |
9 bbox g_BBox; |
10 |
10 |
11 int main (int argc, char** argv) { |
11 int main (int argc, char** argv) { |
12 g_CurrentFile = IO_ParseLDFile ("55966.dat"); |
|
13 g_BBox.calculate(); |
|
14 |
|
15 if (g_CurrentFile) { |
12 if (g_CurrentFile) { |
16 printf ("bbox: (%.3f, %.3f, %.3f), (%.3f, %.3f, %.3f)\n", |
13 printf ("bbox: (%.3f, %.3f, %.3f), (%.3f, %.3f, %.3f)\n", |
17 FVERTEX (g_BBox.v0), FVERTEX (g_BBox.v1)); |
14 FVERTEX (g_BBox.v0), FVERTEX (g_BBox.v1)); |
18 printf ("%u objects\n", g_CurrentFile->objects.size()); |
15 printf ("%u objects\n", g_CurrentFile->objects.size()); |
19 } |
16 } |
20 |
17 |
21 QApplication app (argc, argv); |
18 QApplication app (argc, argv); |
22 LDForgeWindow* win = new LDForgeWindow; |
19 LDForgeWindow* win = new LDForgeWindow; |
23 g_qWindow = win; |
20 g_qWindow = win; |
24 g_qWindow->buildObjList (); |
|
25 win->show (); |
21 win->show (); |
26 return app.exec (); |
22 return app.exec (); |
27 } |
23 } |
28 |
24 |
29 vertex vertex::midpoint (vertex& other) { |
25 vertex vertex::midpoint (vertex& other) { |