1
0
mirror of https://github.com/TomHarte/CLK.git synced 2024-11-26 08:49:37 +00:00

Add TODO.

This commit is contained in:
Thomas Harte 2023-03-15 22:37:47 -04:00
parent c9543d0b36
commit aa4582956f

View File

@ -133,6 +133,9 @@ void Base<personality>::posit_sprite(LineBuffer &buffer, int sprite_number, int
return; return;
} }
// TODO: the following isn't correct when fetching on the final line before pixels on the Yamaha
// VDPs when vertical offset is non-zero owing to the placement of the modulo. Will reconsider after
// dealing with total frame timing, which might affect the LineBuffer pipeline.
const int sprite_row = (((screen_row + 1) % mode_timing_.total_lines) - ((sprite_position + 1) & 255)) & 255; const int sprite_row = (((screen_row + 1) % mode_timing_.total_lines) - ((sprite_position + 1) & 255)) & 255;
if(sprite_row < 0 || sprite_row >= sprite_height_) return; if(sprite_row < 0 || sprite_row >= sprite_height_) return;
@ -1174,8 +1177,13 @@ int Base<personality>::fetch_line() const {
template <Personality personality> template <Personality personality>
VerticalState Base<personality>::vertical_state() const { VerticalState Base<personality>::vertical_state() const {
if(vertical_active_) return VerticalState::Pixels; if(vertical_active_) {
return fetch_pointer_.row == mode_timing_.total_lines - 1 ? VerticalState::Prefetch : VerticalState::Blank; return VerticalState::Pixels;
} else if(fetch_pointer_.row == mode_timing_.total_lines - 1) {
return VerticalState::Prefetch;
} else {
return VerticalState::Blank;
}
} }
template <Personality personality> template <Personality personality>