OpenTTD Source 20241224-master-gf74b0cf984
|
A driver for communicating with the user. More...
#include <driver.h>
Public Types | |
enum | Type { DT_BEGIN = 0 , DT_MUSIC = 0 , DT_SOUND , DT_VIDEO , DT_END } |
The type of driver. More... | |
Public Member Functions | |
virtual std::optional< std::string_view > | Start (const StringList &parm)=0 |
Start this driver. | |
virtual void | Stop ()=0 |
Stop this driver. | |
virtual std::string_view | GetName () const =0 |
Get the name of this driver. | |
enum Driver::Type |
|
pure virtual |
Get the name of this driver.
Implemented in MusicDriver_Allegro, MusicDriver_BeMidi, MusicDriver_Cocoa, MusicDriver_DMusic, MusicDriver_ExtMidi, MusicDriver_FluidSynth, MusicDriver_Null, MusicDriver_Win32, SoundDriver_Allegro, SoundDriver_Cocoa, SoundDriver_Null, SoundDriver_SDL, SoundDriver_Win32, SoundDriver_XAudio2, VideoDriver_Allegro, VideoDriver_CocoaOpenGL, VideoDriver_CocoaQuartz, VideoDriver_Dedicated, VideoDriver_Null, VideoDriver_SDL_Default, VideoDriver_SDL_OpenGL, VideoDriver_SDL, and VideoDriver_Win32GDI.
Referenced by VideoDriver_SDL_Base::Start(), and SurveyConfiguration().
|
pure virtual |
Start this driver.
parm | Parameters passed to the driver. |
Implemented in MusicDriver_Null, SoundDriver_Null, MusicDriver_Allegro, MusicDriver_BeMidi, MusicDriver_Cocoa, MusicDriver_DMusic, MusicDriver_ExtMidi, MusicDriver_FluidSynth, MusicDriver_Win32, SoundDriver_Allegro, SoundDriver_Cocoa, SoundDriver_SDL, SoundDriver_Win32, SoundDriver_XAudio2, VideoDriver_Allegro, VideoDriver_CocoaOpenGL, VideoDriver_CocoaQuartz, VideoDriver_Dedicated, VideoDriver_Null, VideoDriver_SDL_OpenGL, VideoDriver_SDL_Base, VideoDriver_SDL, and VideoDriver_Win32GDI.
Referenced by DriverFactoryBase::SelectDriverImpl().
|
pure virtual |
Stop this driver.
Implemented in MusicDriver_Allegro, MusicDriver_BeMidi, MusicDriver_Cocoa, MusicDriver_DMusic, MusicDriver_ExtMidi, MusicDriver_FluidSynth, MusicDriver_Null, MusicDriver_Win32, SoundDriver_Allegro, SoundDriver_Cocoa, SoundDriver_Null, SoundDriver_SDL, SoundDriver_Win32, SoundDriver_XAudio2, VideoDriver_Allegro, VideoDriver_CocoaOpenGL, VideoDriver_Cocoa, VideoDriver_CocoaQuartz, VideoDriver_Dedicated, VideoDriver_Null, VideoDriver_SDL_OpenGL, VideoDriver_SDL_Base, VideoDriver_SDL, VideoDriver_Win32Base, and VideoDriver_Win32GDI.
Referenced by CrashLog::AfterCrashLogCleanup(), DriverFactoryBase::ShutdownDrivers(), and UserErrorI().