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

160 Commits

Author SHA1 Message Date
Thomas Harte
82aa6d074a 'type' is out, at least for the time being. 2015-09-05 20:25:30 -04:00
Thomas Harte
6a0b4e86c8 An Xcode beta version bump, nothing more. 2015-09-05 17:21:36 -04:00
Thomas Harte
53e699516b Disabled multisampling unless and until I can get the per-pixel cost down. 2015-09-05 17:21:16 -04:00
Thomas Harte
7fb6c86d9d Okay, it looks like colour 3 is approximately phase offset 0, and the palette wraps around after 14 entries, not 16. Also got a bit less dependent on floating point accuracy for the step. 2015-09-05 17:10:41 -04:00
Thomas Harte
39027b675d Fixed YIQ conversion and made sampling pattern slightly more rational. 2015-09-05 17:09:24 -04:00
Thomas Harte
80cf3d9301 Formally gave the 2600 responsibility for providing the code that decodes one of the things it has put into a buffer into a composite sample. 2015-09-03 12:28:16 -04:00
Thomas Harte
ac8fc9a1a0 Experimenting with pre-encoding luminance and chrominance separation over on the
CPU as otherwise the GPU does them repetitively and more awkwardly (as it's working purely in floats). It means uploading twice as much data though, so I don't
 know. Still only half as much as the RGBA path of a few days ago. Will experiment.

Also slightly adjusted division of responsibility in the fragment shader per the
 desire to have the `sample` function owned externally.
2015-09-03 11:15:23 -04:00
Thomas Harte
11acf3f2d3 Made some further minor attempted improvements. 2015-09-02 20:51:56 -04:00
Thomas Harte
161450942a Removed outdated comment. This is better now than it was. 2015-09-02 17:20:23 -04:00
Thomas Harte
0d6094d842 Attempted very basic vectorisation, plus some minor other clean-ups. 2015-09-02 17:17:22 -04:00
Thomas Harte
f60ba4f487 Added a note about horribleness to the source. You never know who's looking. 2015-09-01 22:38:15 -04:00
Thomas Harte
cb6e6e8acb It's the worst fragment shader you'll ever see. The worst. But this attempts NTSC composite video emulation, artefacts included. 2015-09-01 22:36:45 -04:00
Thomas Harte
5fe0cff692 Fine. I'll accept 'bin' files if I must. 2015-08-19 21:36:50 -04:00
Thomas Harte
043d2f9896 It sounds like the two sync signals are exclusive ORd. 2015-08-19 21:36:33 -04:00
Thomas Harte
3c3c4d2f7c Enlarged drawing range a little. 2015-08-19 21:35:26 -04:00
Thomas Harte
c5e480cfae Threw in missile repeats. 2015-08-19 09:46:57 -04:00
Thomas Harte
28fad66272 Okay, so I had those constants transposed. What a klutz I've been! 2015-08-19 09:09:00 -04:00
Thomas Harte
f74d9ee373 Copied in quote. So that I can stop looking it up. 2015-08-18 22:36:32 -04:00
Thomas Harte
a62c7f5c56 At last! Discovered CRT scanning bug; was always moving by the full proposed run length along the scan, not the time until the next event. Using this, have implemented proper vertical sync at last (I think). Have disabled scanline banding too, as now everything meets up it's more helpful to be able to see with clarity. 2015-08-18 22:22:47 -04:00
Thomas Harte
462a791ed3 Ensured that no backlog accumulates of cycles to run. Otherwise the background queue was lagging behind. 2015-08-18 21:13:54 -04:00
Thomas Harte
ca6b54536e Added fire and reset inputs. 2015-08-18 20:58:05 -04:00
Thomas Harte
88d5064737 Not that it makes a lot of difference, there being no names to mangle, but moved the closing #ifdef __cplusplus to the idiomatic place. 2015-08-18 20:33:59 -04:00
Thomas Harte
bc805a90fe Wired up joystick directions, at least, and fire button presses get as far as the C++. But there's some latching to figure out before they'll work. 2015-08-18 20:33:24 -04:00
Thomas Harte
902795d61c Switched vertical sync detection method, at least for now. They never happen automatically (I need to fix that) and just always take effect if detected in the lower half of the display. PAL/NTSC is determined just by looking at the refresh rate. 2015-08-18 00:17:03 -04:00
Thomas Harte
d21ccddeef Fixed: _vBlankExtend is now cleared at the correct moment. 2015-08-17 17:54:36 -04:00
Thomas Harte
a33d31d02a Fixed to allow loading of ROMs less than 1kb in size. 2015-08-17 00:34:01 -04:00
Thomas Harte
083b678785 Quickie: observed that the initial position is one scanline dirty, not zero. Also switched to a size_t on the write pointer, size_t being the correct C size for into-memory offsets. 2015-08-17 00:25:32 -04:00
Thomas Harte
df68aeff5a Fixed: made sure that _vBlankExtend resets itself even on non-pixel lines. 2015-08-17 00:09:28 -04:00
Thomas Harte
414849f166 Confirmed: pixel counters are not paused by programmatic vertical blank. 2015-08-16 17:34:20 -04:00
Thomas Harte
cde9bb7ebc Put common shift step into a macro. 2015-08-16 16:12:20 -04:00
Thomas Harte
a693c081f8 Switched on the appropriate compiler warnings re: signed comparisons and implicit conversions. Fixed all less-than-explicit calls. 2015-08-16 16:08:29 -04:00
Thomas Harte
1cc479affd Removed redundant GL call. 2015-08-16 15:40:03 -04:00
Thomas Harte
410c09cb35 Made attempt not to touch the _collisions registers (which are instance variables) unless the local variables imply it's potentially necessary. So that's a broad phase on collisions, I guess. 2015-08-16 15:39:40 -04:00
Thomas Harte
40cb1cf60d ... and the ball graphic. 2015-08-16 11:24:33 -04:00
Thomas Harte
afaa86a649 Minor thing: skip the internal counter stuff if we're definitely going to end up with a transparent pixel anyway for the player and missile graphics. 2015-08-16 11:23:46 -04:00
Thomas Harte
4b5aabdd54 Attempted to take even more out of the inner pixel loop. 2015-08-13 23:23:04 +01:00
Thomas Harte
391789e75c Removed stray space. 2015-08-13 23:22:51 +01:00
Thomas Harte
cbe76ea5d5 Got rid of the thread hopping in order to redraw the GL view. Which appears to help significantly with total application cost. 2015-08-13 22:01:25 +01:00
Thomas Harte
92c7d56cc3 Tiny little speed improvement. Every little helps. 2015-08-13 21:50:24 +01:00
Thomas Harte
17bbe27c9a As an experiment, performed some very basic moving of playfield composition outside of the pixel loop. 2015-08-13 21:32:22 +01:00
Thomas Harte
033655835a My understanding now is that object position counting will begin the cycle after the call is made, not that cycle, and that the timer loops just once, with the logic for counter pumping being whether the relevant flag is still set, irregardless of whether the counter is still going. 2015-08-13 18:59:23 +01:00
Thomas Harte
b440fed323 Fixed a couple of incorrect references to horizontal constants or calculations where the intention is to use vertical. 2015-08-13 18:29:07 +01:00
Thomas Harte
323aa27e13 Fixed: paging is based directly on the access, independent of the read/write line (since it isn't actually exposed to catridges). 2015-08-13 15:04:30 +01:00
Thomas Harte
59c872ada6 Attempted to reintroduce suitably noted emergency flyback. To re-enable auto-selection of PAL. 2015-08-13 14:55:53 +01:00
Thomas Harte
9838e01cc1 Made a first attempt at paging. 2015-08-13 13:24:02 +01:00
Thomas Harte
9ca57b80a7 Minor steps to help with diagnostics; all commented out or merely to benefit with breakpoint placement. 2015-08-13 08:43:10 +01:00
Thomas Harte
cc98534f94 Added test for NOP, discovering the undocumented ones to be the incorrect length. 2015-08-13 07:32:50 +01:00
Thomas Harte
6616265d93 Fixed collision tests, added a few more timing tests. 2015-08-13 03:33:45 +01:00
Thomas Harte
dd0f17130a Found and fixed some timing errors in absolute indexed and in (indirect), y addressing modes: neither is able in write or read-modify-write modes to shave a cycle as then can when reading. 2015-08-13 02:58:39 +01:00
Thomas Harte
975836c30f Added a quick snippet test, discovering that I've cut a cycle from read/modify/writes. 2015-08-13 02:18:41 +01:00