-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.cpp
More file actions
32 lines (28 loc) · 812 Bytes
/
main.cpp
File metadata and controls
32 lines (28 loc) · 812 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
#include <fstream>
#include <iostream>
#include <json.hpp>
#include <prtl_vis/portal_window.h>
int main(int argc, char** argv) {
std::string filename = "debug.json";
if (argc > 1)
filename = std::string(argv[1]);
scene::json js;
std::ifstream fin(filename);
fin >> js;
fin.close();
prtl_vis::PortalsOpenglWindow window(scene::parseScene(js), 0, 0, filename);
window.showWindowAndWaitClosing();
// It also possible
// {
// std::cout << "1" << std::endl;
// prtl_vis::PortalsOpenglWindow window(scene::parseScene(js));
// window.showWindowAndWaitClosing();
// std::cout << "1e" << std::endl;
// }
// {
// std::cout << "2" << std::endl;
// prtl_vis::PortalsOpenglWindow window(scene::parseScene(js));
// window.showWindowAndWaitClosing();
// std::cout << "2e" << std::endl;
// }
}