Lucas Scharenbroich
56bfdc4236
Fix sprite VBUFF offset calculation
2022-02-21 15:58:16 -06:00
Lucas Scharenbroich
e0912c8956
More tweaks and fixes
...
* Adjusted tile calculation when drawing sprites
* Fixed incorred draw order in 16x16 sprite
* Added more early-out checks to save work
2022-02-21 15:45:11 -06:00
Lucas Scharenbroich
b4025f11fc
Fix stray push instruction
2022-02-21 14:31:05 -06:00
Lucas Scharenbroich
9d401a5861
Fix masking bug in sprite pre-calc
2022-02-21 14:25:55 -06:00
Lucas Scharenbroich
54474bbe5f
Add more pre-computed values to the sprite structure
2022-02-21 13:33:39 -06:00
Lucas Scharenbroich
8b9415a7a5
Working through integration bugs
...
* Gave active list dedicated direct page space
* Change active list bit test from ror to asl to avoid barrel shift
* Various address fixes
2022-02-21 10:31:35 -06:00
Lucas Scharenbroich
7f9f4de228
Add sprite back into initialization
2022-02-21 10:29:57 -06:00
Lucas Scharenbroich
bb83e7f7c5
Background rendering again
2022-02-18 20:43:55 -06:00
Lucas Scharenbroich
95572fbf49
Fix the mask values when enumerating through the sprite sheet
2022-02-18 16:20:07 -06:00
Lucas Scharenbroich
260b2097c2
Continue fixing code issues; strange relocation error happening
2022-02-18 13:42:37 -06:00
Lucas Scharenbroich
95058fb969
Checkpoint for sprite rewrite
...
All of the sprite rendering has been deferred down to the level of
the tile drawing. Sprites are no longer drawn/erased, but instead
a sprite sheet is generated in AddSprite and referenced by the
renderer.
Because there is no longer a single off-screen buffer that holds
a copy of all the rendered sprites, the TileStore size must be
expanded to hold a reference to the sprite data address fo each
tile. This increase in data structure size require the TileStore
to be put into its own bank and appropriate code restructuring.
The benefits to the rewrite are significant:
1. Sprites are never drawn/erased off-screen. They are only
ever drawn directly to the screen or play field.
2. The concept of "damaged" sprites is gone. Every dirty tile
automatically renders just to portion of a sprite that it
intersects.
These two properties result in a substantial increase in throughput.
2022-02-18 12:12:32 -06:00
Lucas Scharenbroich
d96928e562
Add separte TileStore bank
2022-02-18 12:11:22 -06:00
Lucas Scharenbroich
d6aee84edf
Add a small animation of parallax scrolling
2022-02-11 16:14:10 -06:00
Lucas Scharenbroich
397df074ac
Sprite state rework; have run out of bank space
2022-02-07 01:19:31 -06:00
Lucas Scharenbroich
89ea425043
Start work on sprite attribute caching
2022-02-04 12:37:05 -06:00
Lucas Scharenbroich
4d7ff46250
Add zelda demo that utilized dirty rectangle updates
2022-02-03 23:46:32 -06:00
Lucas Scharenbroich
8b852485ac
Fix dirty sprite renderer when StartX and StartY are not zero
2022-02-03 23:44:46 -06:00
Lucas Scharenbroich
525f6d9c67
Add specialized erase routines for different sprite sizes
2022-02-03 08:59:10 -06:00
Lucas Scharenbroich
d3b61f8de6
Merge branch 'toolbox-conversion'
2022-02-03 08:51:49 -06:00
Lucas Scharenbroich
1b9425b620
Streamline sprite functions; untested conceptual changes
2022-02-03 08:50:11 -06:00
Lucas Scharenbroich
16a3a385a9
Update some comments
2022-02-02 17:24:27 -06:00
Lucas Scharenbroich
5f492fd557
Save 1 cycle per line in the PEA fast-path for odd-aligned blits
2022-02-02 14:30:48 -06:00
Lucas Scharenbroich
108335e90a
Add link to John Brooks' technical post on fast GS graphics
2022-02-02 10:23:39 -06:00
Lucas Scharenbroich
1fe02e035c
Checkpoint
2022-02-02 10:21:31 -06:00
Lucas Scharenbroich
027f9746ec
Checkpoint of work
2022-01-19 20:58:57 -06:00
Lucas Scharenbroich
3848c98a21
More documentation
2021-11-23 10:26:34 -06:00
Lucas Scharenbroich
9652a20a3b
Add pre-configured play field size table to docs
2021-11-23 09:25:03 -06:00
Lucas Scharenbroich
af1c728303
Fix table entries
2021-11-23 00:17:02 -06:00
Lucas Scharenbroich
e5aacae8c7
Begin work on updating README
2021-11-22 23:53:13 -06:00
Lucas Scharenbroich
b24e5933e0
Add cheezy logo
2021-11-22 21:47:41 -06:00
Lucas Scharenbroich
69ed76a65d
Optimize the simple mixed BG0/BG1 handler
...
There is enough room in the 32-byte exception handler to inline the
9-byte epilogue when generating the code sequence for mixed BG1/BG0
rendering.
This code sequence is generated once and run for as many frames as the
word appear on screen, so saving an uncondition branch (3 cycles) at the
cost of 60 cycles is probably worth it.
2021-11-22 16:56:53 -06:00
Lucas Scharenbroich
7d76089215
Remove some dead code
2021-11-22 16:53:47 -06:00
Lucas Scharenbroich
140126afd8
Optimize odd-aligned case in the blitter
...
The SEP/REP pairs that are used to move in and out
of 8-bit mode to do the single-byte pushed on the left
and right edges of the screen can also be used to clear
the necessary carry and overflow flags.
2021-11-22 16:13:29 -06:00
Lucas Scharenbroich
4075ed911c
Use the 'f' key to have the SPRITE_HIDE flag set every other frame for a flashing effect
2021-11-22 13:27:27 -06:00
Lucas Scharenbroich
5bc9cc7ff2
Add a SPRITE_HIDE flag to toggle whether a sprite is drawn or not
2021-11-22 13:26:25 -06:00
Lucas Scharenbroich
2683a91e93
Fix sprite rendering with overlapping sprites. Must erase all sprites first, then re-render
2021-11-20 21:58:09 -06:00
Lucas Scharenbroich
90267e4646
Test updating tile ID in UpdateSprite for a run sequence.
2021-11-20 20:33:27 -06:00
Lucas Scharenbroich
9b5d3da0e4
Let character remain facing the direction they were moving after stopping
2021-11-20 14:03:00 -06:00
Lucas Scharenbroich
76801c0e5e
Simplify all of the remaining tile blitters
2021-11-20 13:58:24 -06:00
Lucas Scharenbroich
cd5de05d74
Most of the horizontal flip routines are not needed since the _GetTileAddr function returns the correct tile address. Need to finish auditing other Tile blitters
2021-11-20 13:54:19 -06:00
Lucas Scharenbroich
65ce5cbbc0
Add 16x16 vertical flip routine
2021-11-20 13:26:00 -06:00
Lucas Scharenbroich
b607275089
Separate updating a sprite's position with updating it's flags
2021-11-20 12:16:03 -06:00
Lucas Scharenbroich
0cc28f9e6e
Generalize _DrawSprite to handle all sizes and flip bits.
2021-11-20 12:00:21 -06:00
Lucas Scharenbroich
e65e6dac8b
Fix mask generatino of flipped tiles
2021-11-20 11:59:37 -06:00
Lucas Scharenbroich
c92606840a
Fix mask generation bug; mask was reversed
2021-11-20 11:09:57 -06:00
Lucas Scharenbroich
c08a4f7278
Merge pull request #3 from lscharen/expand-exception-handler-space
...
Expand exception handler space
2021-11-19 16:52:18 -06:00
Lucas Scharenbroich
a7ba1e4b6b
Add final tile blitter
2021-11-19 16:48:39 -06:00
Lucas Scharenbroich
fd6c686a95
Fix ordering bug that caused /usr/bin/bash0 values to overwrite the sprite
2021-11-19 16:40:21 -06:00
Lucas Scharenbroich
39303041f9
Add priority dynamic tiles + sprite blitter
2021-11-19 16:30:22 -06:00
Lucas Scharenbroich
44cbba3f23
Add in new variants for sprite and priority tiles
2021-11-19 15:07:43 -06:00