tumvis.cpp 912 Bytes
Newer Older
schultezub's avatar
schultezub committed
1
2
3
4
5
#include "tgt/camera.h"
#include "tgt/qt/qtapplication.h"
#include "tgt/qt/qtcanvas.h"

#include "tumvispainter.h"
schultezub's avatar
schultezub committed
6
7
#include "modules/pipelines/slicevis.h"

schultezub's avatar
schultezub committed
8

9
using namespace TUMVis;
schultezub's avatar
schultezub committed
10

schultezub's avatar
schultezub committed
11
12
13
14
15
16
17
/**
 * TUMVis main function, application entry point
 *
 * \param   argc    number of passed arguments
 * \param   argv    vector of arguments
 * \return  0 if program exited successfully
 **/
18
19
20
int main(int argc, char** argv) {  
    tgt::QtApplication* app = new tgt::QtApplication(argc, argv);
    tgt::QtCanvas* canvas = new tgt::QtCanvas("TUMVis");
schultezub's avatar
schultezub committed
21

22
    app->addCanvas(canvas);  
schultezub's avatar
schultezub committed
23
24
    app->init();
    
schultezub's avatar
schultezub committed
25

26
27
    tgt::Camera camera;  
    canvas->setCamera(&camera);  
schultezub's avatar
schultezub committed
28
29
30

    //SliceVis sliceVis(canvas);
    //canvas->setPainter(&sliceVis);  
31
32
    TumVisPainter painter(canvas);  
    canvas->setPainter(&painter);  
schultezub's avatar
schultezub committed
33

34
    app->run();  
schultezub's avatar
schultezub committed
35

36
37
    delete canvas;  
    delete app;  
schultezub's avatar
schultezub committed
38

39
    return 0;  
schultezub's avatar
schultezub committed
40
}