mirror of
https://github.com/TomHarte/CLK.git
synced 2024-11-23 03:32:32 +00:00
Merge pull request #835 from TomHarte/ErrantScan
Allows for permitted 1/32nd timing error in `time_multiplier_`.
This commit is contained in:
commit
7bb74af478
@ -27,7 +27,7 @@ void CRT::set_new_timing(int cycles_per_line, int height_of_display, Outputs::Di
|
|||||||
// 7 microseconds for horizontal retrace and 500 to 750 microseconds for vertical retrace
|
// 7 microseconds for horizontal retrace and 500 to 750 microseconds for vertical retrace
|
||||||
// in NTSC and PAL TV."
|
// in NTSC and PAL TV."
|
||||||
|
|
||||||
time_multiplier_ = 65535 / cycles_per_line;
|
time_multiplier_ = 63487 / cycles_per_line; // 63475 = 65535 * 31/32, i.e. the same 1/32 error as below is permitted.
|
||||||
phase_denominator_ = int64_t(cycles_per_line) * int64_t(colour_cycle_denominator) * int64_t(time_multiplier_);
|
phase_denominator_ = int64_t(cycles_per_line) * int64_t(colour_cycle_denominator) * int64_t(time_multiplier_);
|
||||||
phase_numerator_ = 0;
|
phase_numerator_ = 0;
|
||||||
colour_cycle_numerator_ = int64_t(colour_cycle_numerator);
|
colour_cycle_numerator_ = int64_t(colour_cycle_numerator);
|
||||||
|
Loading…
Reference in New Issue
Block a user