openMSX
|
Represents the output window/screen of openMSX. More...
#include <Display.hh>
Public Types | |
using | Layers = std::vector< Layer * > |
Static Public Attributes | |
static constexpr std::string_view | SCREENSHOT_DIR = "screenshots" |
static constexpr std::string_view | SCREENSHOT_EXTENSION = ".png" |
Additional Inherited Members | |
Protected Member Functions inherited from openmsx::EventListener | |
EventListener ()=default | |
~EventListener ()=default | |
Represents the output window/screen of openMSX.
A display contains several layers.
Definition at line 29 of file Display.hh.
using openmsx::Display::Layers = std::vector<Layer*> |
Definition at line 37 of file Display.hh.
|
explicit |
Definition at line 42 of file Display.cc.
References openmsx::Subject< T >::attach(), openmsx::FINISH_FRAME, openmsx::Reactor::getEventDistributor(), openmsx::RenderSettings::getRendererSetting(), openmsx::Timer::getTime(), openmsx::MACHINE_LOADED, openmsx::CircularBuffer< T, MAXSIZE >::push_front(), openmsx::EventDistributor::registerEventListener(), repeat(), openmsx::SWITCH_RENDERER, and openmsx::WINDOW.
openmsx::Display::~Display | ( | ) |
Definition at line 66 of file Display.cc.
References openmsx::Subject< T >::detach(), openmsx::FINISH_FRAME, openmsx::Reactor::getEventDistributor(), openmsx::RenderSettings::getRendererSetting(), openmsx::MACHINE_LOADED, openmsx::SWITCH_RENDERER, openmsx::EventDistributor::unregisterEventListener(), and openmsx::WINDOW.
void openmsx::Display::addLayer | ( | Layer & | layer | ) |
Definition at line 389 of file Display.cc.
References ranges::find_if(), openmsx::Layer::getZ(), and openmsx::Layer::setDisplay().
Referenced by openmsx::SDLVideoSystem::SDLVideoSystem(), and openmsx::VideoLayer::VideoLayer().
void openmsx::Display::attach | ( | VideoSystemChangeListener & | listener | ) |
Definition at line 115 of file Display.cc.
References contains().
Referenced by openmsx::LaserdiscPlayer::LaserdiscPlayer(), openmsx::VDP::VDP(), and openmsx::Video9000::Video9000().
void openmsx::Display::createVideoSystem | ( | ) |
Definition at line 81 of file Display.cc.
References openmsx::RenderSettings::getRenderer(), and openmsx::RenderSettings::UNINITIALIZED.
void openmsx::Display::detach | ( | VideoSystemChangeListener & | listener | ) |
Definition at line 121 of file Display.cc.
References move_pop_back(), and rfind_unguarded().
Referenced by openmsx::LaserdiscPlayer::~LaserdiscPlayer(), openmsx::V9990::~V9990(), openmsx::VDP::~VDP(), and openmsx::Video9000::~Video9000().
Layer * openmsx::Display::findActiveLayer | ( | ) | const |
Definition at line 126 of file Display.cc.
References ranges::find_if(), and openmsx::Layer::isActive().
|
inline |
Definition at line 65 of file Display.hh.
CliComm & openmsx::Display::getCliComm | ( | ) | const |
Definition at line 110 of file Display.cc.
References openmsx::Reactor::getCliComm().
Referenced by openmsx::PostProcessor::getCliComm(), and openmsx::OSDTopWidget::showAllErrors().
float openmsx::Display::getFps | ( | ) | const |
Definition at line 252 of file Display.cc.
|
inline |
Definition at line 47 of file Display.hh.
Referenced by openmsx::OSDImageBasedWidget::paint(), openmsx::SDLVideoSystem::SDLVideoSystem(), and openmsx::OSDImageBasedWidget::setError().
OutputSurface * openmsx::Display::getOutputSurface | ( | ) |
Definition at line 97 of file Display.cc.
Referenced by openmsx::OSDImageBasedWidget::getRenderedSize().
|
inline |
Definition at line 46 of file Display.hh.
Referenced by openmsx::RendererFactory::createRenderer(), openmsx::RendererFactory::createV9990Renderer(), openmsx::RendererFactory::createVideoSystem(), openmsx::VisibleSurface::resize(), openmsx::VDP::VDP(), openmsx::VisibleSurface::VisibleSurface(), and openmsx::VisibleSurface::~VisibleSurface().
VideoSystem & openmsx::Display::getVideoSystem | ( | ) |
Definition at line 91 of file Display.cc.
Referenced by openmsx::GetClipboardCommand::execute(), and openmsx::SetClipboardCommand::execute().
gl::ivec2 openmsx::Display::getWindowPosition | ( | ) |
Get/set x,y coordinates of top-left window corner.
Either the actual, or the last known coordinates.
Definition at line 222 of file Display.cc.
References retrieveWindowPosition(), and storeWindowPosition().
gl::ivec2 openmsx::Display::getWindowSize | ( | ) | const |
Definition at line 246 of file Display.cc.
References openmsx::RenderSettings::getScaleFactor().
Referenced by openmsx::VisibleSurface::resize(), and openmsx::VisibleSurface::VisibleSurface().
string openmsx::Display::getWindowTitle | ( | ) |
Definition at line 205 of file Display.cc.
References openmsx::Version::full(), openmsx::Reactor::getMotherBoard(), openmsx::Version::RELEASE, and strAppend().
void openmsx::Display::removeLayer | ( | Layer & | layer | ) |
Definition at line 397 of file Display.cc.
References rfind_unguarded().
Referenced by openmsx::SDLVideoSystem::~SDLVideoSystem(), and openmsx::VideoLayer::~VideoLayer().
void openmsx::Display::repaint | ( | ) |
Redraw the display.
The repaintImpl() methods are for internal and VideoSystem/VisibleSurface use only.
Definition at line 373 of file Display.cc.
void openmsx::Display::repaintDelayed | ( | uint64_t | delta | ) |
Definition at line 380 of file Display.cc.
References openmsx::RTSchedulable::isPendingRT(), and openmsx::RTSchedulable::scheduleRT().
Referenced by openmsx::GLSnow::paint(), openmsx::OSDGUI::refresh(), and repaintImpl().
void openmsx::Display::repaintImpl | ( | ) |
Definition at line 329 of file Display.cc.
References openmsx::RTSchedulable::cancelRT(), openmsx::Timer::getTime(), openmsx::CircularBuffer< T, MAXSIZE >::pop_back(), openmsx::CircularBuffer< T, MAXSIZE >::push_front(), repaintDelayed(), and repaintImpl().
Referenced by openmsx::SDLVideoSystem::repaint(), repaintImpl(), and openmsx::SDLVideoSystem::takeScreenShot().
void openmsx::Display::repaintImpl | ( | OutputSurface & | surface | ) |
Definition at line 364 of file Display.cc.
References end(), and openmsx::Layer::NONE.
gl::ivec2 openmsx::Display::retrieveWindowPosition | ( | ) |
Definition at line 241 of file Display.cc.
References openmsx::Reactor::getImGuiManager(), and openmsx::ImGuiManager::retrieveWindowPosition().
Referenced by getWindowPosition().
void openmsx::Display::setWindowPosition | ( | gl::ivec2 | pos | ) |
Definition at line 230 of file Display.cc.
References storeWindowPosition().
void openmsx::Display::storeWindowPosition | ( | gl::ivec2 | pos | ) |
Definition at line 236 of file Display.cc.
References openmsx::Reactor::getImGuiManager(), and openmsx::ImGuiManager::storeWindowPosition().
Referenced by getWindowPosition(), setWindowPosition(), and openmsx::VisibleSurface::~VisibleSurface().
void openmsx::Display::updateZ | ( | Layer & | layer | ) |
Definition at line 402 of file Display.cc.
References ranges::find_if(), openmsx::Layer::getZ(), and rfind_unguarded().
Referenced by openmsx::Layer::setZ().
|
staticconstexpr |
Definition at line 33 of file Display.hh.
|
staticconstexpr |
Definition at line 34 of file Display.hh.