Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
alexbevi
GitHub Repository: alexbevi/BizHawk
Path: blob/master/libsnes/bsnes/snes/smp/timing/timing.hpp
2 views
1
template<unsigned timer_frequency>
2
class Timer {
3
public:
4
uint8 stage0_ticks;
5
uint8 stage1_ticks;
6
uint8 stage2_ticks;
7
uint4 stage3_ticks;
8
bool current_line;
9
bool enable;
10
uint8 target;
11
12
void tick();
13
void synchronize_stage1();
14
};
15
16
Timer<192> timer0;
17
Timer<192> timer1;
18
Timer< 24> timer2;
19
20
alwaysinline void add_clocks(unsigned clocks);
21
alwaysinline void cycle_edge();
22
23