Commit Graph

58 Commits

Author SHA1 Message Date
Cameron Cawley
f2b9f7bb76 BACKENDS: Remove the Windows CE port 2019-11-17 22:33:56 +01:00
Cpasjuste
488bbb267a SWITCH: add nintendo switch support 2019-05-12 11:59:44 +03:00
Cameron Cawley
bcef809e61 WINCE: Fix compilation 2019-04-15 08:06:39 +03:00
Thierry Crozat
20e628cac3 SDL: Remove code for unused DoubleBufferSDLMixerManager 2017-09-12 21:46:20 +01:00
Colin Snover
fa52df018e SDL: Fix DoubleBufferSDLMixerManager doubling audio latency
If it turns out that everything that had previously been fixed by
this manager is broken by this change, everything that had been
fixed probably could have been fixed by just increasing the audio
buffer size in SdlMixerManager. :\
2017-09-12 11:35:50 -05:00
Colin Snover
4a75fbab1b SDL: Reduce audio playback latency
The previous default buffer size of 4096 samples for 44kHz mixer
would add up to 93ms of audio latency, which is fine for early
adventure games, but this is significantly more latency than is
acceptable for games with full motion video. For these games,
the latency needs to be kept within roughly +15ms and -45ms of
video frame presentation to avoid lip sync problems. With this
change, the default audio buffer size is calculated to be 1024
samples at 44kHz (which happens to match what DOSBox uses).

There is a possibility that the reduced latency may cause issues
that did not previously exist with things like the MT-32 emulator,
where a larger buffer size allowed for a larger window where
high-complexity synthesis that could not be generated in realtime
could be balanced out by low-complexity synthesis that could be
generated faster than realtime. In this case, rather than
increasing the system mixer buffer size again, please move the
MT-32 emulator into its own thread and give it its own larger ring
buffer into which it can generate more sample data in advance,
independently from the rest of the audio system.

For other systems where this buffer size reduction might cause a
problem with audio drop-outs, a new audio_buffer_size
configuration option has been added to allow users to tweak the
audio buffer size to match their machine's ability to generate
audio samples.

Fixes Trac#10033. Also improves playback of samples in SCI that
were programmed to restart across several consecutive frames,
relying on lower audio latency in the original engine for this to
not sound bad, like the hopping sound at the start of chapter 1
of KQ7, and the sound of turning on the power in the digger train
in the Lighthouse volcano.
2017-09-12 11:30:01 -05:00
Colin Snover
eb4e9fe1d4 GUI: Remove mostly-broken audio output sample rate control
Removing this GUI control was suggested as far back as 2011 at
<http://lists.scummvm.org/pipermail/scummvm-devel/2011-November/010416.html>.
There were no objections, but it was never removed. When working
on audio latency bugs, I independently rediscovered that the GUI
option was broken: the per-game options would *never* work, and the
option would not take effect until ScummVM was restarted because
there is no API for interacting with the backend audio mixer. So
now, it is finally gone.

Primarily for the sake of future troubleshooting, configurability
of the audio sample frequency within SdlMixerManager is maintained
for the moment, but now users will need to edit their ScummVM
configuration file manually to change it.
2017-09-12 11:27:45 -05:00
cpasjuste
70988527c6 PSP2: Add Playstation Vita (PSP2) support 2017-03-04 15:42:19 -06:00
Bastien Bouclet
f37fb24caa PS3: Set the default audio output rate to 48000 Hz
SDL does an awful job at resampling 44100 -> 48000 Hz
2015-12-15 20:10:19 +01:00
Bastien Bouclet
aa9191c4c4 PS3: Remove the SDL2 mixer manager.
It was only used by the PS3 backend, and the standard SDL mixer was fixed
to work in the PS3 case.
2015-12-15 20:10:19 +01:00
Bastien Bouclet
f985a039d5 SDL: Ensure the audio sample format is supported
When SDL returns an unsupported audio sample format, ask
SDL to do resampling to the one ScummVM expects.

This is needed for the PS3 which natively only supports
32 bits floating point as a sample format.
2015-12-15 20:10:19 +01:00
Bastien Bouclet
b9a1074999 PS3: Make use of an updated SDL2 version
This version, available at https://bitbucket.org/bgK/sdl_psl1ght, is based on SDL 2.0.3.
2015-12-15 20:10:19 +01:00
Einar Johan Trøan Sømåen
07623530f3 SDL: Special case the call to SDL_CreateThread for SDL2, since SDL2 requires threads to be named.
- Fixes compilation on OS X with SDL2 enabled, SDL1 builds should be entirely unaffected.
2015-03-06 02:27:48 +01:00
Johannes Schickel
99f4dafa72 SDL: Also print audio driver used when built with SDL2. 2015-01-25 21:23:26 +01:00
Johannes Schickel
8530997fff SDL: Add experimental support for SDL2.
This is based upon skristiansson's change set to make ScummVM work with SDL2.
2015-01-25 20:23:25 +01:00
Johannes Schickel
e80bdfc5b4 PS3: Default to 44kHz sound output. 2014-06-22 18:23:05 +02:00
Johannes Schickel
cd306f194c SDL: Default to 44kHz sound output. 2014-06-22 18:22:50 +02:00
Johannes Schickel
224cec46a7 WINCE: Make GPL headers consistent in themselves. 2014-02-18 02:39:40 +01:00
Johannes Schickel
1b5c324811 SYMBIAN: Make GPL headers consistent in themselves. 2014-02-18 02:39:38 +01:00
Johannes Schickel
63304ee9ec SDL: Make GPL headers consistent in themselves. 2014-02-18 02:39:38 +01:00
Johannes Schickel
6909a8e29a PS3: Make GPL headers consistent in themselves. 2014-02-18 02:39:37 +01:00
Kirben
a5f0cd06e6 SDL: Revert add warning if "waveout" driver is being used for audio.
This situation was only caused by a buildbot issue, and the relevant
information has been added to the FAQ on the ScummVM web site.
2014-02-17 11:36:53 +11:00
D G Turner
c5e7aa8e93 SDL: Add warning if "waveout" driver is being used for audio.
This will help avoid bug reports like #6510 - "SDL: Audio delay
in daily builds" in future.
2014-02-14 15:34:22 +00:00
D G Turner
a4ad32c5d9 SDL: Add debugging code to output SDL audio driver name being used.
This is to aid with investigation of bug #6510 - "SDL: Audio delay in
daily builds" and similar future issues.
2014-02-12 12:08:47 +00:00
Eugene Sandulenko
f59512c47e RECORDER: Implement Events Recorder 2013-05-17 00:18:09 +03:00
Einar Johan Trøan Sømåen
5d4d65d6d9 JANITORIAL: Fix ){ -> ) { 2013-01-24 20:15:13 +01:00
Johannes Schickel
89abab97e3 JANITORIAL: Remove trailing whitespaces.
Powered by:
git ls-files "*.cpp" "*.h" "*.m" "*.mm" | xargs sed -i -e 's/[ \t]*$//'
2012-09-26 04:17:55 +02:00
Johannes Schickel
223794fb38 ALL: Make use of defined() for the preprocessor consistent.
This does not change the use of defined for some NDS source files, since they
seem to be (based on?) third party code.
2012-03-17 22:02:44 +01:00
Christoph Mallon
23a0f5318c JANITORIAL: Remove trailing empty lines. 2011-08-07 13:53:33 +02:00
CeRiAl
6092b324f3 WINCE: Change default values for "FM_high_quality" & "high_sample_rate"
Changed the default values from "false" to "true" as current devices are
fast enough to handle this. It's still possible to change the values to
"false" if the device isn't fast enough.
2011-07-15 01:39:21 +02:00
Bastien Bouclet
8bd78b6325 PS3: Add a SDL 1.3 mixer, for use with the PS3 backend.
SDL 1.3 allows converting from the S16SYS sound format to F32MSB, which is required by the PS3.
2011-06-22 19:57:38 +02:00
Max Horn
88913c0139 ALL: Remove trailing whitespaces
This tries to make our code a bit more compliant with our code formatting
conventions. For future use, this is the command I used:
  git ls-files "*.cpp" "*.h" | xargs sed -i -e 's/[ \t]*$//'
2011-06-20 00:59:48 +02:00
Alyssa Milburn
a8049f708b BACKENDS: Mono output devices are OK on Symbian. 2011-06-17 19:47:32 +02:00
D G Turner
de96474672 BACKENDS: Fix Compilation. 2011-06-14 00:48:59 +01:00
D G Turner
8c485fe2da BACKENDS: Improve SDL Mixer Output Format Checks and Reporting.
This commit corrects a number of minor issues and adds warnings
for when the desired output parameters given to SDL_OpenAudio()
don't match the obtained.
2011-06-14 00:15:50 +01:00
Max Horn
127a6f920a BUILD: Add SDL_BACKEND=1 to config.mk for all SDL based backends 2011-05-31 00:25:40 +02:00
strangerke
69b1485a22 GIT: Clean up: Suppress SVN tags, now useless 2011-05-12 01:16:22 +02:00
D G Turner
8d2189f1bb WINCE: Fix Mixer Compilation after header changes. 2011-04-29 01:54:15 +01:00
Ori Avtalion
9414d7a6e2 JANITORIAL: Reduce header dependencies in shared code
Some backends may break as I only compiled SDL
2011-04-28 15:08:58 +03:00
dhewg
0ebf92ee38 WINCE: Add Tremolo support 2011-04-22 21:30:42 +02:00
Johannes Schickel
489d4d62cd BACKENDS: Fix compilation for Caanoo and GP2xWiz. 2011-04-19 15:19:19 +02:00
Max Horn
aa452d3aeb WINCE: Make scummvm compile and run again for WinCE platform (patch #3202337) 2011-03-08 12:53:41 +01:00
Max Horn
42ab839dd6 AUDIO: Rename sound/ dir to audio/
svn-id: r55850
2011-02-09 01:09:01 +00:00
Max Horn
4e0e406181 SDL: Move #include <SDL.h> into a special wrapper file
svn-id: r54572
2010-11-29 16:16:50 +00:00
Max Horn
f1cdb318c6 SYMBIAN: Fixes & improvements for SymbianSdlMixerManager (untested)
svn-id: r54519
2010-11-28 14:57:04 +00:00
Alejandro Marzini
58d256c15e SDL: Make use of SDL_BACKEND instead of platform specific defines.
svn-id: r52029
2010-08-12 06:30:26 +00:00
Lars Persson
2e55bcf383 SYMBIAN platform. Correct building of SDL refacturing for Symbian.
svn-id: r51587
2010-08-01 19:40:46 +00:00
Alejandro Marzini
fda9416cc8 Cleanup and documentation.
svn-id: r50609
2010-07-03 00:13:45 +00:00
Alejandro Marzini
a35db656d3 Modularized GP2X backend. Renamed GP2XWIZSdlEventManager to GP2XSdlEventManager, and added GP2X code.
svn-id: r50542
2010-07-01 06:07:24 +00:00
Alejandro Marzini
fd77e4b09c Modularized Linuxmoto port.
svn-id: r50474
2010-06-29 01:08:36 +00:00