Age | Commit message (Collapse) | Author |
|
|
|
|
|
The idea here is that if two voices are generating the same tone,
the square wave generator should be in sync so that the wave forms
amplify each other, rather than cancelling each other out.
|
|
In AGI games, the numeric keypad is used as an alias for cursor keys to
allow stationary and 8 directional input, but while the predictive
dialog is open, this is more sensibly mapped to numeric input to
allow use of the predictive input on desktop ports.
|
|
|
|
This was a regression introduced by
4b2f92b5e56a1fc273c8c8d2e69b747f938ea92f (r55135)
|
|
|
|
|
|
|
|
Safer and less portability issues.
|
|
|
|
I'm unable to test this change, but it avoids using a pointer to store
an int temporarily.
|
|
AGI: Fix //gs output
|
|
|
|
|
|
|
|
|
|
This fixes a leak in PreAGI games (which never deleted their
RandomSource), ensures that PreAGI's RandomSource has a name (and hence
is registered with the event recorder) and even slightly simplifies the
AgiEngine destructor.
|
|
This also removes the dependency of engines on the event recorder header
and API, and will make it easier to RandomSources that are not properly
registered.
|
|
This unifies the engine names in MetaEngine::getName() and the
credits. In particular drop "Engine" or "engine" from the names when
it was present and use expanded names in credits when the
MetaEngine uses it (e.g. "Beneath a Steel Sky" instead of "BASS").
|
|
|
|
From patch #3298149
|
|
Right now, a few places in the frontend code still use printf and
consorts. We mark the affected files with a FIXME for now, and
add a dedicated exception for each. To be fixed!
Also tweak FORBIDDEN_SYMBOL_REPLACEMENT to hopefully really always
enforce a compiler error
|
|
Some backends may break as I only compiled SDL
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
MKID_BE relied on unspecified behavior of the C++ compiler,
and as such was always a bit unsafe. The new MKTAG macro
is slightly less elegant, but does no longer depend on the
behavior of the compiler.
Inspired by FFmpeg, which has an almost identical macro.
|
|
Also add comments describing which instruments use swap mode or vibrato,
plus print debug messages when those instruments are actually being played.
|
|
|
|
|
|
Make the player be centered on a fixed number of "generators" instead of
MIDI channels that arbitrarily allocate generators for notes.
Make the audio stream to be stereo and for sample rate use _sampleRate.
Rewrite the synthesis core:
* Make generators use both oscillators
* Implement swap mode for oscillators
* Fix envelope update frequency
|
|
|
|
|
|
|
|
This also should fix some regressions from the previous
commits, related to MidiParser's either being leaked,
or being deleted and then used again (i.e., crashing).
I tested as many games as I had available, but further
testing of all affected engines is called for anyway.
|
|
As a side effect, this fixes the incorrect handling of 'All Note Off'
in SoundGenMIDI::send.
|
|
|
|
The regression affected AGOS and maybe some others; specifically,
the real MidiDriver would have been deleted twice -- I previously
missed that the Engine instances takes care of freeing the real
MidiDriver, not the MidiPlayer wrapping it.
This commit should clarify the ownership of the real MidiDriver for
most pseudo MidiDrivers.
|
|
Many engines follow the advice in audio/midiparser.h and create a
"pseudo-MidiDriver" subclass. But MidiParser really only needs a tiny
subset of the MidiDriver capabilities, namely those found in
MidiDriver_BASE. So we try to subclass from that whenever possible; this
allows us to remove many stub methods, and enables further future
simplifications.
|
|
This in turn enables modifying MidiDriver_MPU401::close() to allow
it to be called on a midi driver that has not yet been opened.
The specific issue that triggered me to make these changes was a
crash-upon-quit in HUGO, caused by it instantiating a midi driver,
then encountering an error (missing hugo.dat) *before* having
opened the new midi driver; the general cleanup code then tries
to close the (not yet opened) midi driver -> kaboom
Also fixed some engines which were leaking MidiDriver instances.
|
|
|
|
|
|
Using the timer mechanism for just a simple counter is not just
overkill, its also inaccurate. When using a call frequency of x,
and waiting for y callbacks, the passed time will not be x*y.
The problem amplifies on slower platforms and/or fair thread
schedulers.
Use absolute times instead. Most notably, the walking speed of
the avatar is now smooth on android, but probably on all other
handhelds we support too.
|
|
|