diff options
| author | eiko <[email protected]> | 2018-03-30 12:07:15 -0400 |
|---|---|---|
| committer | Tom Black <[email protected]> | 2018-05-06 17:56:39 -0700 |
| commit | 36754d58e1e17c11cc243f896d63cd9e1daf95ed (patch) | |
| tree | 662336f7034eddaf52bf11b51b69e6c06e42ac8c /ext | |
| parent | 3a7f63f64159b21f4ec5c4e64aa36eafcacf567f (diff) | |
| download | ruby2d-36754d58e1e17c11cc243f896d63cd9e1daf95ed.tar.gz ruby2d-36754d58e1e17c11cc243f896d63cd9e1daf95ed.zip | |
Enable setting and getting custom fps_cap
Diffstat (limited to 'ext')
| -rw-r--r-- | ext/ruby2d/ruby2d.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/ext/ruby2d/ruby2d.c b/ext/ruby2d/ruby2d.c index 888c053..b44ba58 100644 --- a/ext/ruby2d/ruby2d.c +++ b/ext/ruby2d/ruby2d.c @@ -933,6 +933,7 @@ static R_VAL ruby2d_window_ext_show(R_VAL self) { char *title = RSTRING_PTR(r_iv_get(self, "@title")); int width = NUM2INT(r_iv_get(self, "@width")); int height = NUM2INT(r_iv_get(self, "@height")); + int fps_cap = NUM2INT(r_iv_get(self, "@fps_cap")); int flags = 0; // Get window flags @@ -965,6 +966,7 @@ static R_VAL ruby2d_window_ext_show(R_VAL self) { window->viewport.width = viewport_width; window->viewport.height = viewport_height; + window->fps_cap = fps_cap; window->on_key = on_key; window->on_mouse = on_mouse; window->on_controller = on_controller; |
