summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
f2019b6)
flip is not called when emulation gets stuck, making
impossible to return to menu.
void pl_fbdev_flip(void)
{
void pl_fbdev_flip(void)
{
- /* doing input here because the pad is polled
- * thousands of times for some reason */
- int actions[IN_BINDTYPE_COUNT] = { 0, };
-
- in_update(actions);
- if (actions[IN_BINDTYPE_EMU] & PEV_MENU)
- stop = 1;
- keystate = actions[IN_BINDTYPE_PLAYER12];
-
flip_cnt++;
print_fps();
print_cpu_usage();
flip_cnt++;
print_fps();
print_cpu_usage();
+static void update_input(void)
+{
+ int actions[IN_BINDTYPE_COUNT] = { 0, };
+
+ in_update(actions);
+ if (actions[IN_BINDTYPE_EMU] & PEV_MENU)
+ stop = 1;
+ keystate = actions[IN_BINDTYPE_PLAYER12];
+}
+
/* called on every vsync */
void pl_frame_limit(void)
{
/* called on every vsync */
void pl_frame_limit(void)
{
static int oldsec;
struct timeval tv;
static int oldsec;
struct timeval tv;
+ /* doing input here because the pad is polled
+ * thousands of times per frame for some reason */
+ update_input();
+
pcnt_end(PCNT_ALL);
gettimeofday(&tv, 0);
pcnt_end(PCNT_ALL);
gettimeofday(&tv, 0);