separate input devices

This commit is contained in:
2018-09-27 00:00:38 +07:00
parent aabd9bc618
commit 56fd426ca7
5 changed files with 405 additions and 276 deletions

View File

@@ -21,7 +21,8 @@ int main() {
.trace("SAMPLE: window virtual size: %0", w.virtual_size())
.trace("SAMPLE: window framebuffer size: %0", w.framebuffer_size());
while ( !w.should_close() && !i.is_keyboard_key_just_released(keyboard_key::escape) ) {
const keyboard& k = i.keyboard();
while ( !w.should_close() && !k.is_key_just_released(keyboard_key::escape) ) {
i.frame_tick();
w.swap_buffers();
window::frame_tick();