aboutsummaryrefslogtreecommitdiff
path: root/examples/rotation.c
diff options
context:
space:
mode:
authoremersion <contact@emersion.fr>2018-01-21 22:16:55 +0100
committeremersion <contact@emersion.fr>2018-01-21 22:18:06 +0100
commit59c53e8333cae17210832fb79514c4d0110c7de8 (patch)
treea2b06676b53f4f7ca075ce728155d0d442f69759 /examples/rotation.c
parentf704c3d42b80ad28bfd096e5467a5219c0778e3b (diff)
parente5fa4d8e8e6e81b0cdac9df2dcb1f589867c98f2 (diff)
Merge remote-tracking branch 'upstream/master' into output-damage
Diffstat (limited to 'examples/rotation.c')
-rw-r--r--examples/rotation.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/examples/rotation.c b/examples/rotation.c
index 65e436f6..64de73f9 100644
--- a/examples/rotation.c
+++ b/examples/rotation.c
@@ -64,8 +64,12 @@ static void handle_output_frame(struct output_state *output, struct timespec *ts
odata->x_offs += odata->x_vel * seconds;
odata->y_offs += odata->y_vel * seconds;
- if (odata->x_offs > 128) odata->x_offs = 0;
- if (odata->y_offs > 128) odata->y_offs = 0;
+ if (odata->x_offs > 128) {
+ odata->x_offs = 0;
+ }
+ if (odata->y_offs > 128) {
+ odata->y_offs = 0;
+ }
}
static void handle_output_add(struct output_state *output) {