diff --git a/Machines/Atari2600.cpp b/Machines/Atari2600.cpp index db2aaa692..5bc8aed51 100644 --- a/Machines/Atari2600.cpp +++ b/Machines/Atari2600.cpp @@ -36,7 +36,6 @@ void Machine::switch_region() _crt->set_new_timing(228, 312); } - void Machine::get_output_pixel(uint8_t *pixel, int offset) { const uint8_t palette[16][3] = @@ -144,7 +143,7 @@ void Machine::output_pixels(int count) // logic: if in vsync, output that; otherwise if in vblank then output that; // otherwise output a pixel if(_vSyncEnabled) { - state = OutputState::Sync; + state = (_horizontalTimer < 212) ? OutputState::Sync : OutputState::Blank; } else { // blank is decoded as 68 counts; sync and colour burst as 16 counts diff --git a/Outputs/CRT.cpp b/Outputs/CRT.cpp index efc355b2c..2f0e05748 100644 --- a/Outputs/CRT.cpp +++ b/Outputs/CRT.cpp @@ -20,7 +20,7 @@ static const uint32_t kCRTFixedPointOffset = 0x08000000; void CRT::set_new_timing(int cycles_per_line, int height_of_display) { - const int syncCapacityLineChargeThreshold = 5; + const int syncCapacityLineChargeThreshold = 3; const int millisecondsHorizontalRetraceTime = 7; // source: Dictionary of Video and Television Technology, p. 234 const int scanlinesVerticalRetraceTime = 10; // source: ibid @@ -58,7 +58,7 @@ void CRT::set_new_timing(int cycles_per_line, int height_of_display) // width should be 1.0 / _height_of_display, rotated to match the direction float angle = atan2f(scanSpeedYfl, scanSpeedXfl); - float halfLineWidth = (float)_height_of_display * 1.6f; + float halfLineWidth = (float)_height_of_display * 1.2f; _widths[0][0] = (sinf(angle) / halfLineWidth) * kCRTFixedPointRange; _widths[0][1] = (cosf(angle) / halfLineWidth) * kCRTFixedPointRange; }