diff options
Diffstat (limited to 'test/pugl_test.c')
-rw-r--r-- | test/pugl_test.c | 29 |
1 files changed, 17 insertions, 12 deletions
diff --git a/test/pugl_test.c b/test/pugl_test.c index b8a0a42..b012868 100644 --- a/test/pugl_test.c +++ b/test/pugl_test.c @@ -34,16 +34,17 @@ typedef struct { - bool continuous; - int quit; - float xAngle; - float yAngle; - float dist; - double lastMouseX; - double lastMouseY; - double lastDrawTime; - unsigned framesDrawn; - bool mouseEntered; + PuglWorld* world; + bool continuous; + int quit; + float xAngle; + float yAngle; + float dist; + double lastMouseX; + double lastMouseY; + double lastDrawTime; + unsigned framesDrawn; + bool mouseEntered; } PuglTestApp; static void @@ -178,7 +179,9 @@ main(int argc, char** argv) } } - PuglView* view = puglInit(NULL, NULL); + app.world = puglNewWorld(); + + PuglView* view = puglNewView(app.world); puglInitWindowClass(view, "PuglTest"); puglInitWindowSize(view, 512, 512); puglInitWindowMinSize(view, 256, 256); @@ -224,6 +227,8 @@ main(int argc, char** argv) } } - puglDestroy(view); + puglFreeView(view); + puglFreeWorld(app.world); + return 0; } |