- void (*pl1th_handler)(void) = pl1th_isr_fixed;
- void (*pl2th_handler)(void) = pl2th_isr_fixed;
- void (*vsync_handler)(void) = vsync_isr_nop;
-
- if (g.stream_enable_to) {
- switch (g.inc_mode) {
- case INC_MODE_VSYNC:
- pl1th_handler = pl1th_isr_do_to;
- pl2th_handler = pl2th_isr_do_to_p1d;
- vsync_handler = vsync_isr_frameinc;
- break;
- case INC_MODE_SHARED_PL1:
- pl1th_handler = pl1th_isr_do_to_inc;
- pl2th_handler = pl2th_isr_do_to_p1d;
- break;
- case INC_MODE_SHARED_PL2:
- pl1th_handler = pl1th_isr_do_to;
- pl2th_handler = pl2th_isr_do_to_inc_pl1;
- break;
- case INC_MODE_SEPARATE:
- pl1th_handler = pl1th_isr_do_to_inc;
- pl2th_handler = pl2th_isr_do_to_inc;
- break;
- }
- }
- else if (g.stream_enable_from) {
- g.use_pending = 1;
- switch (g.inc_mode) {
- case INC_MODE_VSYNC:
- vsync_handler = vsync_isr_frameinc_do_from;
- break;
- case INC_MODE_SHARED_PL1:
- pl1th_handler = pl1th_isr_fixed_do_from;
- break;
- case INC_MODE_SHARED_PL2:
- case INC_MODE_SEPARATE:
- /* TODO */
- break;
- }
- }