Commit graph

701 commits

Author SHA1 Message Date
Vitaly Novichkov
e31830e8be ADLMIDI: Tiny warning fix 2018-03-24 21:26:30 +01:00
Vitaly Novichkov
be81e00722 ADLMIDI: Added built-in ability to disable unneeded MUS and XMI converters
Also embedded MIDI sequencer has been disabled too as it is not needed in GZDoom

I made that to allow easier updates of ADLMIDI into newer versions without of any future troubles and conflicts
2018-03-24 21:26:30 +01:00
Christoph Oelckers
4e012e3765 - fill in the ADL bank menu from the internal table. Some of the names had to be shortened to prevent it from getting too confusing. 2018-03-24 21:19:10 +01:00
Christoph Oelckers
49ab99a383 Merge branch 'master' of https://github.com/coelckers/gzdoom 2018-03-24 19:40:52 +01:00
Christoph Oelckers
b8f2d1fc06 - better CVAR control for Timidity++ reverb. 2018-03-24 19:40:39 +01:00
Christoph Oelckers
4978d979e8 - fixed Windows version of snd_mididevice.
- removed mus2mis and xmi2mid converters from OPNMidi, because they are not needed.
- moved the data file for OPNMidi into gzdoom.pk3.
2018-03-24 18:29:12 +01:00
Christoph Oelckers
8aeb6531be Merge branch 'opnMIDI' of https://github.com/Wohlstand/gzdoom into opnmidi 2018-03-24 17:10:50 +01:00
Vitaly Novichkov
6308fb311b Added support for libOPNMIDI Playing device 2018-03-24 17:58:47 +03:00
Vitaly Novichkov
46942cb27f Added libOPNMIDI sources 2018-03-24 17:52:52 +03:00
alexey.lysiuk
a4bee610b4 Added runtime warning about usage of unsupported OpenAL implementation
https://forum.zdoom.org/viewtopic.php?t=59920
2018-03-24 15:00:36 +02:00
alexey.lysiuk
c4b3dcf266 Fixed indent of OpenAL initialization messages
Tab characters should not be used for indenting messages in console
2018-03-24 14:53:47 +02:00
alexey.lysiuk
40bf8a421e User's OpenAL library has precedence over Apple's framework
https://forum.zdoom.org/viewtopic.php?t=59920
2018-03-24 12:09:23 +02:00
Vitaly Novichkov
4f104b0da9 Fixed incorrect pitch processing in the ADLMIDI 2018-03-23 00:35:20 +01:00
Rachael Alexanderson
0893f0c01e Merge remote-tracking branch 'origin/master' into adlMIDI 2018-03-22 14:28:54 -04:00
Vitaly Novichkov
4481ebbdd2 Fixed an incorrect ADLMIDI playback
As DMX uses both 10'th and 16'th channels for percussions, I'll turn a 16'th channel into percussive by XG way on every init/reset.
2018-03-22 04:30:10 -04:00
alexey.lysiuk
d58169f1b0 Fixed crash with very short music loop
https://forum.zdoom.org/viewtopic.php?t=59883
2018-03-21 12:28:12 +02:00
alexey.lysiuk
f242f0631b Fixed crash in when MP3 length guesstimation failed
https://forum.zdoom.org/viewtopic.php?t=59881
2018-03-20 18:01:35 +02:00
raa-eruanna
251f0c8459 - add one more missing include to make GCC happy 2018-03-12 22:39:50 -04:00
Marisa Kirisame
fb5eae8aaa Added some missing zlib.h and stdint.h includes 2018-03-12 21:06:03 -04:00
Christoph Oelckers
5fccdd9acd - added missing return to translation code.
- a bit of header cleanup.

* moved <zlib.h> and <bzlib.h> from files.h to files_decompress.cpp because they are no longer needed for defining the interface.
* added <functional> to the precompiled header
2018-03-12 21:18:11 +01:00
Christoph Oelckers
73248e7f86 - added a missing nullptr check in Instruments::free_soundfonts() 2018-03-12 18:55:05 +01:00
Christoph Oelckers
b939836846 - renamed FileRdr back to FileReader. 2018-03-11 19:29:37 +01:00
Christoph Oelckers
0be1ed252b - rewrote the operator>> methods of FileReader as normal functions for clarity. 2018-03-11 18:20:49 +01:00
Christoph Oelckers
833dbee167 - fixed some issues with m_swap's design.
The native byte order converters were defined as macros which hid some issues due to lack of type checks.
Additionally the ???Long variants taking 'long' variables were removed, because longs are not always 32 bits so this could be destructive.
As a result of this, removed several DWORDs from struct definitions in i_crash.cpp.
2018-03-11 14:35:36 +01:00
Christoph Oelckers
8bbfd39f42 - fixed some remaining issues:
* initial positioning in a subsection of a file failed. This mainly affected music playback.
* made the FileRdr constructor which takes a FileReaderInterface private so that everything that needs it must be explicitly declared as friend.
* removed a few redundant construction initializers for FileRdrs.
* loading compressed nodes needs to check the validity of its reader.
* use GetLength to detemine the size of a Zip file instead of doing another seek to the end.
* removed duplicate Length variables.
2018-03-11 13:26:30 +01:00
Christoph Oelckers
b14ee50d0d - transition to new FileReader interface complete, but untested. 2018-03-11 12:33:46 +01:00
Christoph Oelckers
6f8ca2eace - fixed a few issues from implicit FileReader conversion. 2018-03-10 20:47:17 +01:00
Christoph Oelckers
b315bc3be0 - added a few more FileRdr replacements
- fixed: The streaming music player must return the file reader if it fails to open, so that the next player can still use it.
- fixed: Timidity++'s Instruments class did not delete the sound font when it was destroyed.

..-
2018-03-10 20:33:49 +01:00
Christoph Oelckers
56991a9ace - Removed FileReader from SoundFont manager.
- renamed close_file to tf_close for consistency.
2018-03-10 20:10:17 +01:00
Christoph Oelckers
5fa63c396d - sound code and most of texture code converted to FileRdr.
This allowed to remove a lot of bad pointer voodoo in the music loader, because the new class does not allow duplication of the reader object
2018-03-10 18:45:11 +01:00
Christoph Oelckers
26e948357e - added an abstract FileReader wrapper.
The idea here is to decouple the actual reader creation from the code using them so that, for example, the Open function can decide if it wants to open the file regularly or memory mapped and return different readers as deemed useful. For that to work the exposed object needs to be an abstract wrapper so that this can be done without having to use pointers and all the drawbacks coming from that.
So far put to use in a few parts of the music code so the general functionality could be tested.
2018-03-10 13:46:35 +01:00
alexey.lysiuk
7f17121df8 Fixed crash in MIDI to wave writer 2018-03-08 11:38:02 +02:00
alexey.lysiuk
cea64ea092 Moved old Nuked and Java OPL3 to own namespaces
This helps to avoid clashing of OPL3 classes
2018-03-08 10:18:49 +02:00
alexey.lysiuk
114e56b334 Moved old NukedOPL to own namespace
This fixes linking issues on non-MSVC targets and improves code navigation
2018-03-08 09:51:37 +02:00
Christoph Oelckers
2d2d44baad - integrated ADL as a proper device in the MIDI device list.
- resorted the MIDI device menu option by device types (i.e. all SW synths first, FM synths second)
- allow setting the ADL bank.
2018-03-07 21:20:25 +01:00
Christoph Oelckers
fd801b8b94 Merge branch 'adlMIDI'
# Conflicts:
#	src/sound/musicformats/music_midistream.cpp
2018-03-07 20:31:32 +01:00
Christoph Oelckers
9b61ee9618 - fixed: The MIDI wave writer set the sample rate to save at too late.
This was done after the players had already been created. To ensure that everything gets set properly it is necessary to pass the desired sample rate to the device's constructor and let it make sure that a proper sample rate gets set.
2018-03-06 22:41:27 +01:00
Christoph Oelckers
4d4edcfbfb - fixed setup for Timidity++ playback frequency. 2018-03-06 19:52:29 +01:00
alexey.lysiuk
77e1a1d289 Replaced usages of fluid_settings_getstr() function
This function is deprecated since FluidSynth 1.1.9 and removed in upcoming 2.x
2018-03-05 12:31:50 +02:00
alexey.lysiuk
d0ec6ef1d4 TiMidity++ now loads SF2 soundfont with spaces in path 2018-03-04 13:09:29 +02:00
alexey.lysiuk
8145b52037 Added explicit fallback to default soundfont
With no soundfonts found the game crashed on startup
Local UNIX build had the same issue because $PROGDIR/soundfonts is not in search path
2018-03-03 15:17:30 +02:00
Christoph Oelckers
e1bb14803e - print an error message if the requested MIDI device cannot be started.
This will only be done the first time a given setup fails. Repeated messages will be muted.
2018-03-03 08:52:25 +01:00
Christoph Oelckers
4c0f68bcd4 Merge branch 'master' into timidity++
# Conflicts:
#	src/sound/musicformats/music_midistream.cpp
2018-03-02 00:08:12 +01:00
Christoph Oelckers
4ccbc4ea9e - Send a GM reset SYSEX event when music playback is started. 2018-02-28 09:46:28 +01:00
Christoph Oelckers
eb124f6160 - made the sound font loading a bit more error resistant.
- implemented a fallback both for sound font lookup and for MIDI device selection so that if some non-working combination is set up, the player will fall back to something that works.
2018-02-26 16:36:30 +01:00
alexey.lysiuk
6bc2be1ca4 Fixed GCC 6+ compilation error
In file included from /usr/include/c++/6/math.h:36:0,
                 from src/vectors.h:43,
                 from src/sound/i_soundinternal.h:7,
                 from src/sound/i_sound.h:39,
                 from src/sound/i_musicinterns.h:5,
                 from src/sound/timidity/timidity.cpp:36:
/usr/include/c++/6/cmath:407:11: error: ‘::pow’ has not been declared
2018-02-26 14:46:24 +02:00
alexey.lysiuk
22819e640a Fixed GCC 4.9 compilation error
src/sound/timiditypp/instrum.cpp:45:26: error: array used as initializer
2018-02-26 14:00:29 +02:00
alexey.lysiuk
4fdf488960 Fixed MSVC compilation warning
VC\include\type_traits(1468): warning C4800: 'int': forcing value to bool 'true' or 'false' (performance warning)
src\sound\musicformats\music_midistream.cpp(832): note: see reference to function template instantiation 'std::function<bool (int)>::function<MIDIStreamer::SetMIDISource::<lambda_...>,int,void>(_Fx)' being compiled
2018-02-26 13:22:36 +02:00
alexey.lysiuk
14802c0547 Fixed GCC compilation error
src/sound/timiditypp/reverb.h:467:6: error: declaration of ‘TimidityPlus::lfo TimidityPlus::<anonymous struct>::lfo’ [-fpermissive]
src/sound/timiditypp/reverb.h:61:8: error: changes meaning of ‘lfo’ from ‘struct TimidityPlus::lfo’ [-fpermissive]
2018-02-26 13:10:32 +02:00
Christoph Oelckers
f405d630df - Redid CVar synchronization for Timidity++. 2018-02-26 09:55:04 +01:00