comparison vdp.h @ 1335:26e72126f9d1

Fixes to sprite phase 2 so that sprite X reads use the exact same slot as on hardware in the case that there are fewer than the max number of sprites on each line. Re-read sprite Y from SAT cache during phase 2 and properly mask the calculated row. Fixes remaining issues with spinning cube scene in Overdrive 2.
author Michael Pavone <pavone@retrodev.com>
date Thu, 27 Apr 2017 23:08:49 -0700
parents 69c25e1188e5
children 35e6a93b4586
comparison
equal deleted inserted replaced
1334:7757d605e365 1335:26e72126f9d1
177 uint16_t border_bot; 177 uint16_t border_bot;
178 uint16_t hscroll_a; 178 uint16_t hscroll_a;
179 uint16_t hscroll_b; 179 uint16_t hscroll_b;
180 uint16_t h40_lines; 180 uint16_t h40_lines;
181 uint16_t output_lines; 181 uint16_t output_lines;
182 uint8_t hslot; //hcounter/2
183 uint8_t sprite_index;
184 uint8_t sprite_draws;
185 int8_t slot_counter;
186 int8_t cur_slot;
187 sprite_draw sprite_draw_list[MAX_DRAWS]; 182 sprite_draw sprite_draw_list[MAX_DRAWS];
188 sprite_info sprite_info_list[MAX_SPRITES_LINE]; 183 sprite_info sprite_info_list[MAX_SPRITES_LINE];
189 uint8_t sat_cache[SAT_CACHE_SIZE]; 184 uint8_t sat_cache[SAT_CACHE_SIZE];
190 uint16_t col_1; 185 uint16_t col_1;
191 uint16_t col_2; 186 uint16_t col_2;
192 uint16_t hv_latch; 187 uint16_t hv_latch;
193 uint16_t prefetch; 188 uint16_t prefetch;
194 uint16_t test_port; 189 uint16_t test_port;
190 uint8_t hslot; //hcounter/2
191 uint8_t sprite_index;
192 uint8_t sprite_draws;
193 int8_t slot_counter;
194 int8_t cur_slot;
195 uint8_t max_sprites_frame;
196 uint8_t max_sprites_line;
195 uint8_t fetch_tmp[2]; 197 uint8_t fetch_tmp[2];
196 uint8_t v_offset; 198 uint8_t v_offset;
197 uint8_t dma_cd; 199 uint8_t dma_cd;
198 uint8_t hint_counter; 200 uint8_t hint_counter;
199 uint8_t flags2; 201 uint8_t flags2;