openMSX
|
#include <SDLVideoSystem.hh>
Public Member Functions | |
SDLVideoSystem (Reactor &reactor, CommandConsole &console) | |
Activates this video system. More... | |
~SDLVideoSystem () override | |
Deactivates this video system. More... | |
std::unique_ptr< Rasterizer > | createRasterizer (VDP &vdp) override |
Create the rasterizer selected by the current renderer setting. More... | |
std::unique_ptr< V9990Rasterizer > | createV9990Rasterizer (V9990 &vdp) override |
Create the V9990 rasterizer selected by the current renderer setting. More... | |
std::unique_ptr< LDRasterizer > | createLDRasterizer (LaserdiscPlayer &ld) override |
bool | checkSettings () override |
Requests that this renderer checks its settings against the current RenderSettings. More... | |
void | flush () override |
Finish pending drawing operations and make them visible to the user. More... | |
void | takeScreenShot (const std::string &filename, bool withOsd) override |
Take a screenshot. More... | |
void | updateWindowTitle () override |
Called when the window title string has changed. More... | |
gl::ivec2 | getMouseCoord () override |
Returns the current mouse pointer coordinates. More... | |
OutputSurface * | getOutputSurface () override |
TODO. More... | |
void | showCursor (bool show) override |
bool | getCursorEnabled () override |
std::string | getClipboardText () override |
void | setClipboardText (zstring_view text) override |
void | repaint () override |
Requests a repaint of the output surface. More... | |
![]() | |
virtual | ~VideoSystem ()=default |
virtual std::unique_ptr< Rasterizer > | createRasterizer (VDP &vdp)=0 |
Create the rasterizer selected by the current renderer setting. More... | |
virtual std::unique_ptr< V9990Rasterizer > | createV9990Rasterizer (V9990 &vdp)=0 |
Create the V9990 rasterizer selected by the current renderer setting. More... | |
virtual std::unique_ptr< LDRasterizer > | createLDRasterizer (LaserdiscPlayer &ld)=0 |
virtual bool | checkSettings () |
Requests that this renderer checks its settings against the current RenderSettings. More... | |
virtual void | flush ()=0 |
Finish pending drawing operations and make them visible to the user. More... | |
virtual void | takeScreenShot (const std::string &filename, bool withOsd) |
Take a screenshot. More... | |
virtual void | updateWindowTitle () |
Called when the window title string has changed. More... | |
virtual gl::ivec2 | getMouseCoord ()=0 |
Returns the current mouse pointer coordinates. More... | |
virtual OutputSurface * | getOutputSurface ()=0 |
TODO. More... | |
virtual void | showCursor (bool show)=0 |
virtual bool | getCursorEnabled ()=0 |
virtual std::string | getClipboardText ()=0 |
virtual void | setClipboardText (zstring_view text)=0 |
virtual void | repaint ()=0 |
Requests a repaint of the output surface. More... | |
Additional Inherited Members | |
![]() | |
VideoSystem ()=default | |
Definition at line 21 of file SDLVideoSystem.hh.
|
explicit |
Activates this video system.
InitException | If initialisation fails. |
Definition at line 29 of file SDLVideoSystem.cc.
References openmsx::Display::addLayer(), openmsx::Subject< T >::attach(), openmsx::Reactor::getEventDistributor(), openmsx::Display::getOSDGUI(), openmsx::RenderSettings::getScaleFactorSetting(), openmsx::EventDistributor::registerEventListener(), and openmsx::RESIZE.
|
override |
Deactivates this video system.
Definition at line 49 of file SDLVideoSystem.cc.
References openmsx::Subject< T >::detach(), openmsx::Reactor::getEventDistributor(), openmsx::RenderSettings::getScaleFactorSetting(), openmsx::Display::removeLayer(), openmsx::RESIZE, and openmsx::EventDistributor::unregisterEventListener().
|
overridevirtual |
Requests that this renderer checks its settings against the current RenderSettings.
If possible, update the settings of this renderer. The implementation in the Renderer base class checks whether the right renderer is selected. Subclasses are encouraged to check more settings.
Reimplemented from openmsx::VideoSystem.
Definition at line 205 of file SDLVideoSystem.cc.
References openmsx::RenderSettings::getFullScreen().
|
overridevirtual |
Implements openmsx::VideoSystem.
Definition at line 145 of file SDLVideoSystem.cc.
References openmsx::LaserdiscPlayer::getMotherBoard(), openmsx::RenderSettings::getRenderer(), openmsx::RenderSettings::SDL, openmsx::RenderSettings::SDLGL_PP, and UNREACHABLE.
|
overridevirtual |
Create the rasterizer selected by the current renderer setting.
Video systems that use a rasterizer must override this method.
vdp | The VDP whose display will be rendered. |
Implements openmsx::VideoSystem.
Definition at line 61 of file SDLVideoSystem.cc.
References openmsx::MSXDevice::getMotherBoard(), openmsx::MSXDevice::getName(), openmsx::RenderSettings::getRenderer(), openmsx::RenderSettings::SDL, openmsx::RenderSettings::SDLGL_PP, and UNREACHABLE.
|
overridevirtual |
Create the V9990 rasterizer selected by the current renderer setting.
Video systems that use a rasterizer must override this method.
vdp | The V9990 whose display will be rendered. |
Implements openmsx::VideoSystem.
Definition at line 102 of file SDLVideoSystem.cc.
References openmsx::MSXDevice::getMotherBoard(), openmsx::MSXDevice::getName(), openmsx::RenderSettings::getRenderer(), openmsx::RenderSettings::SDL, openmsx::RenderSettings::SDLGL_PP, and UNREACHABLE.
|
overridevirtual |
Finish pending drawing operations and make them visible to the user.
Implements openmsx::VideoSystem.
Definition at line 216 of file SDLVideoSystem.cc.
|
overridevirtual |
Implements openmsx::VideoSystem.
Definition at line 264 of file SDLVideoSystem.cc.
|
overridevirtual |
Implements openmsx::VideoSystem.
Definition at line 259 of file SDLVideoSystem.cc.
|
overridevirtual |
Returns the current mouse pointer coordinates.
Implements openmsx::VideoSystem.
Definition at line 242 of file SDLVideoSystem.cc.
|
overridevirtual |
|
overridevirtual |
Requests a repaint of the output surface.
An implementation might start a repaint directly, or trigger a queued rendering.
Implements openmsx::VideoSystem.
Definition at line 283 of file SDLVideoSystem.cc.
References openmsx::Display::repaintImpl().
|
overridevirtual |
Implements openmsx::VideoSystem.
Definition at line 274 of file SDLVideoSystem.cc.
References zstring_view::c_str().
|
overridevirtual |
Implements openmsx::VideoSystem.
Definition at line 254 of file SDLVideoSystem.cc.
|
overridevirtual |
Take a screenshot.
The default implementation throws an exception.
filename | Name of the file to save the screenshot to. |
withOsd | Should OSD elements be included in the screenshot. |
MSXException | If taking the screen shot fails. |
Reimplemented from openmsx::VideoSystem.
Definition at line 221 of file SDLVideoSystem.cc.
References openmsx::Display::repaintImpl().
|
overridevirtual |
Called when the window title string has changed.
Reimplemented from openmsx::VideoSystem.
Definition at line 237 of file SDLVideoSystem.cc.