refactor program to work with a vector of layers instead

This commit is contained in:
2024-05-05 12:05:01 +02:00
parent feec302053
commit 2f0cd19bc4
3 changed files with 71 additions and 34 deletions

View File

@@ -17,12 +17,15 @@ using namespace std;
int main() {
auto bg = new BackgroundImage("../../../../data/map_661-661.png");
auto e = new EGlyphLayer();
auto l = new LGlyphLayer();
l->spoofPoints();
auto program = new Program(bg, e, l);
Program *program = new Program();
program->addLayer(new BackgroundImage("../../../../data/map_661-661.png"));
program->addLayer(new EGlyphLayer());
program->addLayer(l);
// auto program = new Program(bg, e, l);
program->setLagrangeInteractor(l->createSpawnPointCallback());
program->render();