aboutsummaryrefslogtreecommitdiff
path: root/backends
diff options
context:
space:
mode:
Diffstat (limited to 'backends')
-rw-r--r--backends/graphics/graphics.h7
-rw-r--r--backends/modular-backend.cpp16
-rw-r--r--backends/modular-backend.h4
3 files changed, 27 insertions, 0 deletions
diff --git a/backends/graphics/graphics.h b/backends/graphics/graphics.h
index d5c36c13c4..e7be2369ed 100644
--- a/backends/graphics/graphics.h
+++ b/backends/graphics/graphics.h
@@ -53,6 +53,13 @@ public:
};
virtual bool setShader(int id) { return false; }
virtual int getShader() const { return 0; }
+ virtual const OSystem::GraphicsMode *getSupportedStretchModes() const {
+ static const OSystem::GraphicsMode noStretchModes[] = {{"NONE", "Normal", 0}, {nullptr, nullptr, 0 }};
+ return noStretchModes;
+ }
+ virtual int getDefaultStretchMode() const { return 0; }
+ virtual bool setStretchMode(int mode) { return false; }
+ virtual int getStretchMode() const { return 0; }
#ifdef USE_RGB_COLOR
virtual Graphics::PixelFormat getScreenFormat() const = 0;
diff --git a/backends/modular-backend.cpp b/backends/modular-backend.cpp
index 944ddd5a47..2c6aaba5a8 100644
--- a/backends/modular-backend.cpp
+++ b/backends/modular-backend.cpp
@@ -93,6 +93,22 @@ int ModularBackend::getShader() const {
return _graphicsManager->getShader();
}
+const OSystem::GraphicsMode *ModularBackend::getSupportedStretchModes() const {
+ return _graphicsManager->getSupportedStretchModes();
+}
+
+int ModularBackend::getDefaultStretchMode() const {
+ return _graphicsManager->getDefaultStretchMode();
+}
+
+bool ModularBackend::setStretchMode(int mode) {
+ return _graphicsManager->setStretchMode(mode);
+}
+
+int ModularBackend::getStretchMode() const {
+ return _graphicsManager->getStretchMode();
+}
+
void ModularBackend::resetGraphicsScale() {
_graphicsManager->resetGraphicsScale();
}
diff --git a/backends/modular-backend.h b/backends/modular-backend.h
index fa34f2921f..ead559cd8b 100644
--- a/backends/modular-backend.h
+++ b/backends/modular-backend.h
@@ -69,6 +69,10 @@ public:
virtual const GraphicsMode *getSupportedShaders() const override;
virtual int getShader() const override;
virtual bool setShader(int id) override;
+ virtual const GraphicsMode *getSupportedStretchModes() const override;
+ virtual int getDefaultStretchMode() const override;
+ virtual bool setStretchMode(int mode) override;
+ virtual int getStretchMode() const override;
virtual void resetGraphicsScale() override;
#ifdef USE_RGB_COLOR
virtual Graphics::PixelFormat getScreenFormat() const override;