summaryrefslogtreecommitdiffhomepage
path: root/main.cpp
blob: a4cd1487bf0cbbd1a44c74c39af0341ed09b77ba (plain)
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
#include <memory>
#include <utility>

#include <raylib.h>

#include "App.h"
#include "Snapshot.h"
#include "Globals.h"
#include "Reader.h"
#include "View.h"


App app;


int
main(int, char*[])
{
    {
        Snapshot source("sample.json");
        auto [grids, timeline] = Reader::read(source);
        auto view = std::make_unique<View>(std::move(grids), std::move(timeline));
        app.assign(std::move(view));
    }
    while (!WindowShouldClose())
        app.loop();
}