aboutsummaryrefslogtreecommitdiff
path: root/audio/musicplugin.h
AgeCommit message (Collapse)Author
2017-12-03BASE: Remove bad casts between incompatible Plugin typesColin Snover
Previously, a C-style cast was used to convert a Common::Array<Plugin *>, populated with pointers to StaticPlugin and DynamicPlugin instances, to a Common::Array<PluginSubclass<T> *>, but PluginSubclass<T> is a *sibling* class to StaticPlugin/DynamicPlugin, so this cast was invalid and the results undefined. The methods for retrieving subclasses of plugins can't be easily changed to just generate an array of temporary wrapper objects that expose an identical API which dereferences to the preferred PluginObject subclass because pointers to these objects are retained by other parts of ScummVM, so the wrappers would needed to be persisted or they would need to just re-expose the underlying Plugin object again. This indicated that a way to solve this problem is to have the callers receive Plugin objects and get the PluginObject from the Plugin by explicitly stating their desired type, in a similar manner to std::get(std::variant), so that the pattern used by this patch to solve the problem. Closes gh-1051.
2014-02-18AUDIO: Make GPL headers consistent in themselves.Johannes Schickel
2011-10-28AUDIO: Adapt include guard names to the "new" directory name.Johannes Schickel
2011-06-05AUDIO: fix device detection (missing rom files for MT-32 emu)athrxx
This is an attempt to fix the problem Max described in his devel mail. The presence of the rom files will now be checked in detectDevice(). In case of failure there will be fallback attempts. The user will get notified of the detection failure if he has expressly selected the device that failed. Please test with your platform / engine (with or without rom files).
2011-05-12GIT: Clean up: Suppress SVN tags, now uselessstrangerke
2011-04-28JANITORIAL: Reduce header dependencies in shared codeOri Avtalion
Some backends may break as I only compiled SDL
2011-02-09AUDIO: Rename sound/ dir to audio/Max Horn
svn-id: r55850