Commit Graph

23 Commits

Author SHA1 Message Date
S. D. Cloudt 13cc8a0cee Cleanup: Removed SVN headers 2019-11-10 17:59:20 +00:00
Henry Wilson 7c8e7c6b6e Codechange: Use null pointer literal instead of the NULL macro 2019-04-10 23:22:20 +02:00
Niels Martin Hansen 6298b96571 Change: Modernise music control logic implementation (#6839)
Rewrite of almost the entire music control logic to a more modern style, hopefully also easier to understand. The old playlist handling made it look like arcane magic, which it doesn't have to be.

- Playlists are now stored in std::vector of objects instead of arrays of bytes with magic sentinel values, that need to be rotated around all the time. Position in playlist is stored as a simple index.
- The theme song is now reserved for the title screen, it doesn't play on any of the standard playlists, but is still available for use on custom playlists.
- When the player enters/leaves the game from the main menu, the music always restarts.
- Playback state (playing or not) is kept even if music becomes unavailable due to an empty playlist (or an empty music set), so it can restart immediately if music becomes available again.
- The shuffle algorithm was changed to a standard Fisher-Yates.
- Possibly better behavior when editing a custom playlist while it's playing.
- Custom playlists should be compatible.
- Framework for supporting custom playlists with songs from multiple music sets.
2018-06-24 20:06:05 +02:00
Niels Martin Hansen 5ab06ef8a3 Fix: Don't complain if CAT music files are missing entirely
Just complain if an index into a CAT file that exists is invalid.
2018-06-15 23:09:17 +02:00
Niels Martin Hansen 276192f714 Change #6684: Cutting point overrides for music base sets
This improves bad looping of title screen song from Windows TTD, and fixes
a long silence at the end of "Can't get there from here" from Windows TTD.
2018-06-15 23:09:17 +02:00
Niels Martin Hansen 2ae9df7248 Feature: Decoder for DOS version music
This is based on reverse-engineering the TTD DOS driver for General MIDI music.
2018-06-05 22:58:35 +02:00
Niels Martin Hansen f946b3da56 Codechange: Pass a MusicSongInfo struct instead of bare filename to music drivers.
Preparation for later extending the info passed to music drivers.
2018-06-05 22:58:35 +02:00
rubidium 0463dbdc9e (svn r26482) -Codechange: add an include that allows us to undefine/redefine "unsafe" functions to prevent them from being used, and thus having to care about certain aspects of their return values 2014-04-23 20:13:33 +00:00
rubidium 15f671279d (svn r23214) -Codechange: for base media sets pass the "search in tars" parameter to determine what to do 2011-11-14 19:24:22 +00:00
rubidium 4d5dbf5170 (svn r22410) -Document: some more bits ;) 2011-05-02 16:14:23 +00:00
rubidium 83e40b8ced (svn r19674) -Fix [FS#3774]: crash when the music/graphics metadata files were unreadable 2010-04-19 09:34:56 +00:00
rubidium fa6ef9d45d (svn r19219) -Fix: having OpenMSX's files in a subdirectory did not work as it should. 2010-02-23 15:51:26 +00:00
rubidium 03e5434e63 (svn r19206) -Add: concept of fallback base sets, i.e. do not automatically load the NoMusic/NoSound sets when there is another set 2010-02-22 16:24:23 +00:00
yexo f709290220 (svn r19095) -Fix: segfault when a baseset has an empty metadata field 2010-02-11 15:08:55 +00:00
rubidium 82fc28f77f (svn r18809) -Codechange/Cleanup: remove unneeded headers from some files, if a header require a header make it include that header 2010-01-15 16:41:15 +00:00
rubidium 6e97343df6 (svn r18610) -Codechange: don't consider a music set at all for 'best' set when it's missing files 2009-12-23 08:51:46 +00:00
rubidium a8d6d18b22 (svn r18608) -Change: add the concept of music sets 2009-12-22 21:40:29 +00:00
rubidium 7fbc33dae1 (svn r17248) -Fix: add GPL license notice where appropriate 2009-08-21 20:21:05 +00:00
rubidium 099022224f (svn r14810) -Codechange: use the proper style for global variables. 2009-01-03 17:09:31 +00:00
rubidium d03994098b (svn r12971) -Documentation: add @file in files that missed them and add something more than whitespace as description of files that don't have a description. 2008-05-06 15:11:33 +00:00
smatz 110584808d (svn r12557) -Cleanup: use MAX_PATH at two more places 2008-04-04 00:06:51 +00:00
belugas b71354dc40 (svn r8987) -Cleanup: doxygen changes. Again. Mostly (still) @files missing tags and (more than just) a few comments style. 2007-03-03 04:04:22 +00:00
KUDr e373ea7096 (svn r8033) [cpp] - Prepare for merge from branches/cpp (all .c files renamed to .cpp) 2007-01-10 18:12:09 +00:00
Renamed from src/music.c (Browse further)