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
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
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
removed TotalAlloc field because it's meaningless really and
causes people to think more memory is being allocated than is
reality
added GC CPU % field
this seems to help the screen rendering to mesh with the monitor's
VSYNC. this method was already in place when switching between
full-screen and windowed mode
the current policy is to run time.Sleep() for the duration of a frame
(1000/60ms for a 60Hz monitor) before calling GLSwap() and to do that
for 5 consecutive frames
for the specific instance of WINDOWEVENT_RESIZED the GLSwap() is
also completely inhibited for a frame
outside of the window event period a random sleep of between 1 and 10
microseconds is introduced
tweaked frame queue slack indicator
emulation is nudged when the queue slack gets too short in addition to
when the render catches up to the emulation
undoing frame advancement skips back two frames rather than one. this
helps flicker kerneals and doesn't seem to introduce any visual
consequence
added queue slack meter to playscreen overlay. this replaces the "input
lag" field. the input lag can now be seen to change depending on load
screen can now be repositioning and sized so that it fits inside the
bevel. this needs improvement such that a bevel can specify how the
screen needs to be transformed for the bevel
set ClearColor before calling gl.Clear(). this completes the change
started in 8763b77f
reintroduction of the old idea of indicating whether the screen is
"atari safe" (as per the Stella Programmer's Guide). the indicator is
now a tick icon next to the VBLANK information
television would not desynchronise if scanlines was less than user
preference
desync is now less aggressive. for example, the transition between the
map screen and main screen in Lord of the Rings would trigger a full
screen roll but now it's less noticeable
debugger no longer sends play, pause notifications to the gui. the gui
polls for that information as required
govern package now has SubState type to complement the State type.
StateIntegrity() function enforces combinations of State and SubState,
called from debugger.setState() function
playmode notifications reworked and contained in a single playmode_overlay.go
file. this includes the FPS and screen detail
preference value sdlimgui.playmode.fpsOverlay replaced with
sdlimgui.playmode.fpsDetail. still toggled with F7 key
coproc icon moved to top-left corner of playmode overlay and only
visible when FPS detail is showing
when FPS detail is showing multiple (small) icons care shown. when it is
not showing, a single (large) icon is shown according to the priority of
the icon. eg. pause indicator has higher priority than the mute
indicator