Commit graph

3372 commits

Author SHA1 Message Date
JetSetIlly
6c446b9b3b bumped version to v0.40.0-preview_3 2025-02-23 19:04:08 +00:00
JetSetIlly
9a99ff7a3e fixed searching for PAL60 in filename and PAL60 sizing
added PAL60 specification. even though it isn't a real specification it
is more convenient and provides better user feedback

moved FrameInfo into frameinfo package, now called Current as in
frameinfo.Current

clarified storage of requested specification by the television:

how the television is probed for the specification has changed, in
particular the current spec is retreived via the GetFrameInfo()
function. in fact, this was how most other packages did it but there
also existed a GetSpecID() which was uncessary

GetReqSpecID() and GetCreationSpecID() removed, replaced with
GetResetSpecID() and IsAutoSpec()

simplified SetSpec(). removed the force argument

removed reset option for vcs.AttachCartridge()
2025-02-23 17:39:08 +00:00
JetSetIlly
8ee181fd8b added FRAME option to TV command
prints out the current frame dimensions
2025-02-23 15:20:50 +00:00
JetSetIlly
68f5a8dd9a fixed DPC detection by adding the missing known size value
clarified through comments what the ideal size and the meaning of dumps
that are larger than the ideal size. (it is output from the cartridges
random number generator)

fixed RNG pump so that it more closely matches the description in the
DPC patent. clarfied that a reset value of 0xff for the RNG will produce
an endless sequence of 0xff values
2025-02-21 16:53:43 +00:00
JetSetIlly
62f7218456 changed signal.VideoBlack to signal.ZeroBlack for clarity
clarified how VideoBlack and ZeroBlack are related in the 2600

ZeroBlack is now a generated and cached colour for both legacy and new
colour models, rather than an implied zero RGB value

the result of this is that VideoBlack and ZeroBlack are now affected by
colour adjustment in the same way, as it is on real hardware. this
happens because the 2600 outputs 0.0 IRE for VideoBlack and not 7.5 IRE
as you might expect. the most immediate recent change to colour
generation used a VideoBlack value of 7.5

we don't yet emulate RGB mods that do use 7.5 for VideoBlack

legacy PAL palette corrected so that the four VideoBlack values are zero
2025-02-21 16:53:43 +00:00
JetSetIlly
96a0e1f7c3 clarified how callfn.Step() result is used 2025-02-20 20:48:06 +00:00
JetSetIlly
e8e9b09d4b arm breakpoints is not enabled unless source is available
by not enabling breakpoint checking the codepath is much shorter
resulting in faster execution of an ARM instruction
2025-02-19 21:44:02 +00:00
JetSetIlly
aadb023bd6 split arm peripherals package into rng and timer
both arm timer implementations now defer complex accumulation until
every 10000 ARM steps or when the current value is required
2025-02-19 16:20:41 +00:00
JetSetIlly
5fe2dd5ba6 ELF strongArmFunctions field is now a sparse array 2025-02-19 07:12:55 +00:00
JetSetIlly
20c59d6272 added debugging flag to elfSection
save checking for .debug string in section name on every
call to inMemory()
2025-02-19 07:12:55 +00:00
JetSetIlly
1c88e1e752 integrity test for legacy colour values
the testing documents the history of the 'standard' stella palette, in
the stella git history, to what seems like the first appearance
2025-02-18 19:57:37 +00:00
JetSetIlly
fb150bc838 reenabled unconvert linter in Makefile 2025-02-16 22:43:12 +00:00
JetSetIlly
f62f58343d bumped version to v0.40.0_preview_2
minimum Go version increased to go1.24.0

disabled unconvert linter. the latest version of the linter does not
work with go1.24.0

modified 0001-statsviz.patch to match changes go version change in go.mod
2025-02-16 21:45:47 +00:00
JetSetIlly
f470f9413e improved rim reflection 2025-02-16 21:15:17 +00:00
JetSetIlly
33fee99a68 legacy colour gamma corrected
default setting legacy adjustment settings altered to compensate

NTSC/PAL Colour Signal section of the television preferences are
now drawn disabled if legacy colour model is active
2025-02-16 16:38:35 +00:00
JetSetIlly
9f4155fbfb added "blue ambient light" option
adds a blue tint to the bevel image around the screen. good for
simulating low light environments.

the strength of the bevel reflection is now dependent on the amount
of blue tint
2025-02-15 13:17:12 +00:00
JetSetIlly
7e0b5e5eda ARM cycle accumulation now uses math.Modf()
the Modf() function generates far more efficient code for separating
the integer and fractional part of a number

added comment about the use of a sparse array for the ARM 'execution
cache' and in particular why one is used despite changes to the map
implementation in v1.24.0 of the go compiler
2025-02-15 10:36:13 +00:00
JetSetIlly
0ea4c2f5ca altered default brightness/saturation values for legacy colour model 2025-02-15 08:24:51 +00:00
JetSetIlly
18262a2ee6 legacy colour model is the default for now
I think the new colour model will cause confusion and there needs to be
a much more solid grounding before it becomes the default

legacy colour model can be colour adjusted. adjustment settings for
legacy and non-legacy are kept separate
2025-02-14 21:14:22 +00:00
JetSetIlly
fe326140c3 refined version package
window now includes revision information if the build is not a "release"
build

added version.Version() function to help with deciding if build is a
"release". supercedes the global Version and Revision variables in the
version package
2025-02-11 21:38:11 +00:00
JetSetIlly
4a94b54e67 sdl audio queue() function called less frequently 2025-02-09 18:47:50 +00:00
JetSetIlly
52a098cff0 updated legacy PAL palette
stella updated the palette data in stella commit 8cebddc
2025-02-09 12:06:31 +00:00
JetSetIlly
ff98f3e088 adjustments no longer applied to legacy colour model
this keeps things simple and should also encourage people to use the new
model

now that the colour adjustment only applies to the new colour model the
default values for brightness, contrast, saturation are once again set
to none neutral values
2025-02-08 18:02:22 +00:00
JetSetIlly
bd0f16f206 contrast adjust assumes gray level of 7.5% (IRE standard)
brightness adjusted by addition rather than multiplication

value of hue0/lum0 set to 7.5%. I've heard conflicting opinions that
hum0/lum0 outputs at 0% which is what the previous version did, but I'm
not sure that's really true
2025-02-08 17:31:50 +00:00
JetSetIlly
928aba0333 IQ and UV no longer multiplied Y
ie 'Y * Saturation * sin(phi)' is now 'Saturation * sin(phi)'

this results in more vivid colour throughout the luminance range, which
I believe is more correct

changed generation saturation and contrast ranges

bright/contr/sat default value set to 1.0 and hue value to 0.0
2025-02-06 22:57:27 +00:00
JetSetIlly
61b74be224 added "legacy" colour model option
the legacy model is the current Stella Standard palette, rather then the
qotile palette used by Gopher2600 previously
2025-02-06 08:44:26 +00:00
JetSetIlly
2efeea8025 small refactor of register package
changes originally part of curtainled refactor of the data type that was
intended to introduce origin tracking
2025-02-01 07:56:41 +00:00
JetSetIlly
3315829a32 missing patch file is no longer a fatal error
error is logged but does not cause the cartridge load to fail

patch file given on the command line is not assumed to be in the
.gopher2600/patches directory

fixed help text for -patch

patch file parsing now tolerates leading space in patch file. this means
the neo style of patch file is now correctly detected if the comment
character is not the first character
2025-01-31 20:26:01 +00:00
JetSetIlly
8d8147ef17 fixed new go vet error (go 1.24.0) in disassembly package 2025-01-31 20:19:04 +00:00
JetSetIlly
e42ca15142 NTSC colour burst correction
the position of hue 1 on the colour wheel was not correct
2025-01-19 20:54:26 +00:00
JetSetIlly
37038b3619 digest video uses the ColorSignal rather than the mapped colour
this means the test is independent of what happens in the colour
generation code
2025-01-17 22:00:01 +00:00
JetSetIlly
f679911e97 bumped version to v0.40.0-preview 2025-01-13 20:08:01 +00:00
JetSetIlly
a43ee21377 Merge branch 'future_REBASE_LIKELY' into release_0.40.0 2025-01-13 19:48:58 +00:00
JetSetIlly
17e6d70f2f added colour reflection on the bevel
the inside of the bevel nearest the screen reflects the colour from the
screen. it's not perfect but it's a nice effect and can form the basis
for something better

screen centering inside solid state bevel moved very slightly to the
right
2025-01-13 19:42:20 +00:00
JetSetIlly
18b9986fed lowered default Brightness and Saturation values
RF interference enabled by default
2025-01-13 18:45:59 +00:00
JetSetIlly
ea11b74bfa change of useBevel pref value calls the playscreen resize() function
simplified the use of FlipY in the CRT sequence

changed ranges for phophor/pixel-fade settings
2025-01-12 17:25:09 +00:00
JetSetIlly
0288e3d968 simplified realtime audio mixer
realtime audio mixers, like SDL audio implementation, are expected to
self-regulate. this makes more sense and the Regulate() idea didn't work
as expected

SDL audio now repeats or drops short bursts of samples as they are
received, in order keep the queue inside a generous window. this seems
to work very well and far better than the previous efforts at regulation

there could maybe be more thought around how many samples should be
repeated or dropped such that it isn't audible

the difference between a realtime mixer and a regular mixer is now just
the SetSpec() function. I'll consider adding the SetSpec() function to
the regular mixer interface and dropping the realtime mixer altogether
2025-01-12 10:12:54 +00:00
JetSetIlly
f4e8d9d7f7 moved CRT prefrences from display to sdlimgui package
we needed more control over the post-change hooks for CRT values. in
particular we wanted the pixel perfect value to call the playscreen's
resize() function when changed. it would be awkward to do that from
a different package

incidentally, the resize() function needs to be called when toggling
pixel perfect mode becaus the CRT and pixel perfect screens may have
different scaling requirements
2025-01-11 23:06:55 +00:00
JetSetIlly
6b3677a20b television ratio wasn't correct on start when bevel is enabled
the bevel requires a bias for the Y scaling that wasn't applied
at program start because the bevel preference hadn't been loaded

you could see the error by resizing the window which forced a
recalculation taking the bevel pref and therefore the bias into
consideration
2025-01-11 21:39:09 +00:00
JetSetIlly
3bd457d2e7 refresh rate for unsynced frame was not correct
the current scanline was used when it should have been the
adjusted total scanlines for the fied. usually the two are
the same when newFrame() is called but will not be when
frame is unsynchronised AND the immediate desync option
is disabled

also tweaked conditions for natural flyback
2025-01-11 16:14:47 +00:00
JetSetIlly
314e1d2dd4 reworked audio system
television signal split into video and audio signal. The audio signal is
only sent then a new sample from the TIA is ready

realtime mixer concept change. the mixer can be informed of a change of
TV spec. this allows the realtime mixer to make an informed judgement
about the required sample rate

the sample rate is unlikely to be ideal however unless the number of
scanlines in the TV image is the same as given in the basic TV
specification (ie. 262 lines for NTSC, 312 for PAL). because of that,
the realtime mixer can also indirectly regulate the rate of calls to
SetAudio(). the Regulate() function is called by the television which
then alters the call frequency to SetAudio() depending on the regulate
value. this effectively keeps the audio buffer nicely filled - neither
too long which would be audibly laggy, or too short which would result
in clipped audio

the values that control the regulation in both the sdlaudio package and
television package will need tweaking to find the best values
2025-01-11 16:14:47 +00:00
JetSetIlly
ed238613f2 committed to VSYNC counting on HSYNC end
it seems to work well and means that games that you would expect
to work with a three scanline requirement, don't fail to sync
2025-01-10 19:22:36 +00:00
JetSetIlly
49c223b90f simplified VSYNC and screen roll
changed how 'force' parameter for television.SetReqSpec() works

debugger TV Screen shows drawing pixel in all instances, even in areas
that are "covered" by no-signal area
2025-01-10 17:46:41 +00:00
JetSetIlly
f2ae53db30 extended visible screen resizing only happens when screen is synced
added explanatory commentary about how VSYNC is counted

removed vsync history (not used)
2025-01-07 18:57:59 +00:00
JetSetIlly
c15dc076ee changed default for rf interference
lowered bottom range for interference values in the prefs window
2025-01-07 10:22:34 +00:00
JetSetIlly
5c2f22b80b removed CRT preview from debugger TV Screen
a CRT preview directly in the debugger should be a separate window.
there's no real value in having the debugging information applied
directly to a CRT rendering
2025-01-07 10:21:08 +00:00
JetSetIlly
d7a832ca61 improved end-of-screen indicator in uncropped TV screen
there was previously a flyback line but that left a large black area for
most ROMs, with no explanation

sensible tooltip for TV screen when outside of TV frame

removed striping parameters for dbgscr_overlay shader

improved VSYNC/VBLANK reflection colours. distinguished how VSYNC is
indicated in the overlay when VBLANK is active and when it is not
2025-01-07 09:54:00 +00:00
JetSetIlly
b93cf1ab8f anything but normal rotation inhibits use of the bevel
bevel bias only applied if bevel is being used

small tv width correction when screen is rotated vertically
2025-01-06 22:48:24 +00:00
JetSetIlly
77a5f24659 divided interference preference into RF noise/ghosting
the noise and ghosting level can be set seperately
2025-01-06 21:02:00 +00:00
JetSetIlly
9088935c5c pixel presentation disables some rendering options if emulation is too slow
it is likely that CPU performance in the pause state can be improved,
particularly for non-active pauses. but we would need to be careful with
the colourgen package - we want changes to the colourgen prefs values to
show up on the screen even when paused. some sort of trigger from the
colourgen package would work but I'm not sure if the added complexity
is worth it
2025-01-03 09:22:06 +00:00