aboutsummaryrefslogtreecommitdiffstats
path: root/examples/pugl_embed_demo.c
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2020-04-02 17:39:54 +0200
committerDavid Robillard <d@drobilla.net>2020-04-02 17:40:56 +0200
commitffa9c8240e4d904da2154466e811302ae313034d (patch)
tree4f4618b267e91b0c575512087fa264cd923e8e3f /examples/pugl_embed_demo.c
parent6c870cb0d2cae098d7780d7aaaf1815887ef182e (diff)
downloadpugl-ffa9c8240e4d904da2154466e811302ae313034d.tar.gz
pugl-ffa9c8240e4d904da2154466e811302ae313034d.tar.bz2
pugl-ffa9c8240e4d904da2154466e811302ae313034d.zip
Strengthen warnings
Diffstat (limited to 'examples/pugl_embed_demo.c')
-rw-r--r--examples/pugl_embed_demo.c13
1 files changed, 10 insertions, 3 deletions
diff --git a/examples/pugl_embed_demo.c b/examples/pugl_embed_demo.c
index 6152648..3a7b051 100644
--- a/examples/pugl_embed_demo.c
+++ b/examples/pugl_embed_demo.c
@@ -87,7 +87,11 @@ onDisplay(PuglView* view)
app->yAngle = fmod(app->yAngle + dTime * 100.0, 360.0);
}
- displayCube(view, app->dist, app->xAngle, app->yAngle, app->mouseEntered);
+ displayCube(view,
+ app->dist,
+ (float)app->xAngle,
+ (float)app->yAngle,
+ app->mouseEntered);
app->lastDrawTime = thisTime;
}
@@ -164,7 +168,9 @@ onParentEvent(PuglView* view, const PuglEvent* event)
switch (event->type) {
case PUGL_CONFIGURE:
- reshapeCube((int)event->configure.width, (int)event->configure.height);
+ reshapeCube((float)event->configure.width,
+ (float)event->configure.height);
+
puglSetFrame(app->child, getChildFrame(parentFrame));
break;
case PUGL_UPDATE:
@@ -214,7 +220,8 @@ onEvent(PuglView* view, const PuglEvent* event)
switch (event->type) {
case PUGL_CONFIGURE:
- reshapeCube((int)event->configure.width, (int)event->configure.height);
+ reshapeCube((float)event->configure.width,
+ (float)event->configure.height);
break;
case PUGL_UPDATE:
if (app->continuous) {