Commit graph

23 commits

Author SHA1 Message Date
toxieainc db455ba5c1 add undefd codepath for correct use of the 18bit DAC path (which seems to be triggered for all games)
the volume correction to bring the data back into a valid range is not really needed in practice though, only Daytona2 seems to need it, and also only extremely rarely, so lets just live with a tiny bit of clamping for that game then

while add it, make some formatting similar to MAME, and add one comment regarding a most likely wrong recent MAME change
2022-11-29 12:36:27 -08:00
toxieainc 4c727abdc8 change all INT16 mixing/intermediate clamping to floats
also fixes 3 bugs:
1) mpeg right channel volume was always using the left channel volume, too
2) too high MusicVolume setting was not clamped to 0..200
3) too high SoundVolume setting was not clamped to 0..200
2022-11-06 13:00:13 -08:00
Ian Curtis a742a73772 njz3: Fix sound volume with new quadrophonic audio code 2022-06-19 16:15:54 +00:00
Ian Curtis 83e7b5f45d njz3: Proper quadrophonic audio support. Need 4+ speakers to take advantage otherwise down mixed to stereo. 2022-06-09 21:10:39 +00:00
Matthew Daniels 9ffce8b92a Getting rid of most of the includes from Supermodel.h; each file now explicitly includes the header files it needs.
Making changes to a header file should no longer force the entire project to recompile.
2021-11-22 17:15:06 +00:00
Ian Curtis c0729c1048 fix compiling with visual studio 2020-09-15 08:51:23 +00:00
SpinDizzy 72b2c0eb28 Fixed a longstanding bug that caused stereo channels to be flipped incorrectly.
This was due to the initial audio buffer write position being aligned to the middle of a 4 byte (2 byte left, 2 byte right) audio sample.
In multi-threaded mode, some sort of race condition caused this alignment to be fixed until audio playback was temporarily paused (via pausing, loading a state, etc.)
Audio playback should now be fixed and work consistently in all cases.
2020-09-14 06:59:38 +00:00
Ian Curtis 5e434e2644 build fixes for mac 2020-07-27 10:28:48 +00:00
SpinDizzy 4f347ff3f1 SDL1 to SDL2 internal changes 2020-04-19 08:34:58 +00:00
Ian Curtis f7678d918e remove using namespace from headers .. 2018-01-03 17:51:24 +00:00
Bart Trzynadlowski f34e25dfc7 Massive internal change: removed CConfig object and replaced it with a hierarchical config object system (Util::Config::Node). Games are now defined in an XML file. Hopefully I didn't break too many things :/ 2017-03-27 03:19:15 +00:00
Ian Curtis 5b3eea25fb fix basic compile errors (with vs) 2016-03-22 11:34:32 +00:00
Bart Trzynadlowski 09f9bd81fd Fixed left/right stereo channels -- they were reversed by default. 2012-02-09 17:12:13 +00:00
Bart Trzynadlowski 2f5bf43bda Updated copyright information and added headers to all remaining files except debugger. 2011-09-14 19:08:43 +00:00
Nik Henson 75d446c272 Changes to Audio.cpp:
- audio buffer is now kept as full as possible with new audio buffering method rather than just half full like before (this is okay now that buffer overruns have been eliminated)
- altered minimum size of audio buffer so that audio still works with a zero latency setting (obviously there will still be some latency)
2011-09-12 21:03:16 +00:00
Bart Trzynadlowski cf73207c98 - Nik's new decoupled audio code with fixes to minimize overruns.
- VBlank timing: increased to 20% of a frame.
2011-09-12 05:43:37 +00:00
Bart Trzynadlowski 11d1d61bc2 - Removed BOOL and replaced it with native C++ type, bool.
- Removed TRUE and FALSE, changed to 'true' and 'false' keywords.
2011-09-08 06:34:18 +00:00
Nik Henson 7b58fd0644 Fixed bug which meant that a buffer over-run occuring under certain conditions would leave the write position dangling past the end of the buffer, causing no further sound to be written to the buffer and leaving playback looping indefinitely. 2011-09-01 21:58:10 +00:00
Bart Trzynadlowski bda9efebac - getbass now uses MPC106.
- Fixed some error messages in 53C810.cpp.
- Fixed stereo (was swapped) and added a flip stereo option.
2011-09-01 06:43:01 +00:00
Nik Henson b25cbb2391 Removed setting of writeWrapped to false always on buffer under-run when underRunLoop is true as this is wrong. Suspect this may have been causing looping bug. 2011-08-31 22:30:45 +00:00
Nik Henson 07fd26003e Added option to loop play position back to beginning of audio buffer when a buffer under-run occurs, rather than stalling output as before. This option is now the default behaviour. 2011-08-07 23:09:18 +00:00
Bart Trzynadlowski 2ca7898f1a - Changes submitted by krom: cleaned up spacing in Games.cpp, optimized byte swapping functions in Supermodel.h, minor changes to fix compiler errors in gcc. 2011-08-01 19:12:44 +00:00
Nik Henson 03fa9532eb - Added function-based interface Audio for OSD sound output, together with SDL implementation
- Added object interface CThread for OSD threading and synchronization, together with SDL implementation
- Added multi-threading to CModel3 so that separate CPUs (PPC of main board, 68K of sound board and Z80 of drive board) can be run in separate threads if requested to improve performance on multi-core PCs
- Added -multi-threaded command line option (default is to run single-threaded still)
2011-07-20 21:14:00 +00:00