mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-13 21:31:53 +00:00
BACKENDS: Move default implementations of getScreenPixelBuffer into BaseBackend
This commit is contained in:
parent
d0fd0f1151
commit
5a47b09455
@ -22,6 +22,8 @@
|
||||
|
||||
#include "backends/base-backend.h"
|
||||
|
||||
#include "graphics/pixelbuffer.h"
|
||||
|
||||
#ifndef DISABLE_DEFAULT_EVENT_MANAGER
|
||||
#include "backends/events/default/default-events.h"
|
||||
#endif
|
||||
@ -49,6 +51,11 @@ void BaseBackend::initBackend() {
|
||||
OSystem::initBackend();
|
||||
}
|
||||
|
||||
Graphics::PixelBuffer BaseBackend::getScreenPixelBuffer() {
|
||||
warning("BaseBackend::getScreenPixelBuffer(): not implemented");
|
||||
return Graphics::PixelBuffer();
|
||||
}
|
||||
|
||||
void BaseBackend::fillScreen(uint32 col) {
|
||||
Graphics::Surface *screen = lockScreen();
|
||||
if (screen)
|
||||
|
@ -30,6 +30,7 @@ class BaseBackend : public OSystem {
|
||||
public:
|
||||
virtual void initBackend();
|
||||
|
||||
virtual Graphics::PixelBuffer getScreenPixelBuffer();
|
||||
virtual void displayMessageOnOSD(const Common::U32String &msg);
|
||||
virtual void displayActivityIconOnOSD(const Graphics::Surface *icon) {}
|
||||
virtual void fillScreen(uint32 col);
|
||||
|
@ -27,7 +27,6 @@
|
||||
#include "backends/platform/3ds/config.h"
|
||||
#include "common/rect.h"
|
||||
#include "graphics/fontman.h"
|
||||
#include "graphics/pixelbuffer.h"
|
||||
#include "gui/gui-manager.h"
|
||||
|
||||
// Used to transfer the final rendered display to the framebuffer
|
||||
@ -187,10 +186,6 @@ bool OSystem_3DS::setGraphicsMode(GraphicsModeID modeID) {
|
||||
}
|
||||
}
|
||||
|
||||
Graphics::PixelBuffer OSystem_3DS::getScreenPixelBuffer() {
|
||||
return Graphics::PixelBuffer();
|
||||
}
|
||||
|
||||
void OSystem_3DS::initSize(uint width, uint height,
|
||||
const Graphics::PixelFormat *format) {
|
||||
debug("3ds initsize w:%d h:%d", width, height);
|
||||
|
@ -141,7 +141,6 @@ public:
|
||||
virtual int getScreenChangeID() const { return _screenChangeId; };
|
||||
GraphicsModeID chooseMode(Graphics::PixelFormat *format);
|
||||
bool setGraphicsMode(GraphicsModeID modeID);
|
||||
virtual Graphics::PixelBuffer getScreenPixelBuffer();
|
||||
|
||||
void beginGFXTransaction();
|
||||
OSystem::TransactionError endGFXTransaction();
|
||||
|
@ -98,8 +98,6 @@ protected:
|
||||
|
||||
public:
|
||||
|
||||
virtual Graphics::PixelBuffer getScreenPixelBuffer();
|
||||
|
||||
// Determine the pixel format currently in use for screen rendering.
|
||||
Graphics::PixelFormat getScreenFormat() const;
|
||||
|
||||
|
@ -24,7 +24,6 @@
|
||||
|
||||
#include "common/scummsys.h"
|
||||
#include "graphics/surface.h"
|
||||
#include "graphics/pixelbuffer.h"
|
||||
#include "dc.h"
|
||||
|
||||
#define SCREEN_W 640
|
||||
@ -186,11 +185,6 @@ void OSystem_Dreamcast::grabPalette(byte *colors, uint start, uint num) const
|
||||
}
|
||||
}
|
||||
|
||||
Graphics::PixelBuffer OSystem_Dreamcast::getScreenPixelBuffer()
|
||||
{
|
||||
return Graphics::PixelBuffer();
|
||||
}
|
||||
|
||||
Graphics::PixelFormat OSystem_Dreamcast::getScreenFormat() const
|
||||
{
|
||||
return screenFormats[_screenFormat];
|
||||
|
@ -42,7 +42,6 @@
|
||||
#include "common/str.h"
|
||||
#include "cdaudio.h"
|
||||
#include "graphics/surface.h"
|
||||
#include "graphics/pixelbuffer.h"
|
||||
#include "touchkeyboard.h"
|
||||
#include "backends/fs/ds/ds-fs-factory.h"
|
||||
|
||||
@ -163,10 +162,6 @@ bool OSystem_DS::getFeatureState(Feature f) {
|
||||
return false;
|
||||
}
|
||||
|
||||
Graphics::PixelBuffer OSystem_DS::getScreenPixelBuffer() {
|
||||
return Graphics::PixelBuffer();
|
||||
}
|
||||
|
||||
void OSystem_DS::initSize(uint width, uint height, const Graphics::PixelFormat *format) {
|
||||
// For Lost in Time, the title screen is displayed in 640x400.
|
||||
// In order to support this game, the screen mode is set, but
|
||||
|
@ -88,7 +88,6 @@ public:
|
||||
virtual int16 getWidth();
|
||||
|
||||
virtual PaletteManager *getPaletteManager() { return this; }
|
||||
virtual Graphics::PixelBuffer getScreenPixelBuffer();
|
||||
protected:
|
||||
// PaletteManager API
|
||||
virtual void setPalette(const byte *colors, uint start, uint num);
|
||||
|
@ -130,7 +130,6 @@ public:
|
||||
|
||||
virtual void beginGFXTransaction();
|
||||
virtual TransactionError endGFXTransaction();
|
||||
virtual Graphics::PixelBuffer getScreenPixelBuffer();
|
||||
|
||||
virtual int16 getHeight();
|
||||
virtual int16 getWidth();
|
||||
|
@ -27,7 +27,6 @@
|
||||
#include "backends/platform/iphone/iphone_video.h"
|
||||
|
||||
#include "graphics/conversion.h"
|
||||
#include "graphics/pixelbuffer.h"
|
||||
|
||||
void OSystem_IPHONE::engineInit() {
|
||||
EventsBaseBackend::engineInit();
|
||||
@ -138,10 +137,6 @@ OSystem::TransactionError OSystem_IPHONE::endGFXTransaction() {
|
||||
return _gfxTransactionError;
|
||||
}
|
||||
|
||||
Graphics::PixelBuffer OSystem_IPHONE::getScreenPixelBuffer() {
|
||||
return Graphics::PixelBuffer();
|
||||
}
|
||||
|
||||
void OSystem_IPHONE::updateOutputSurface() {
|
||||
[g_iPhoneViewInstance performSelectorOnMainThread:@selector(initSurface) withObject:nil waitUntilDone: YES];
|
||||
}
|
||||
|
@ -153,7 +153,6 @@ public:
|
||||
virtual int16 getWidth();
|
||||
|
||||
virtual PaletteManager *getPaletteManager() { return this; }
|
||||
virtual Graphics::PixelBuffer getScreenPixelBuffer();
|
||||
protected:
|
||||
// PaletteManager API
|
||||
virtual void setPalette(const byte *colors, uint start, uint num);
|
||||
|
@ -32,7 +32,6 @@
|
||||
#include "backends/fs/n64/n64-fs-factory.h"
|
||||
#include "backends/saves/default/default-saves.h"
|
||||
#include "backends/timer/default/default-timer.h"
|
||||
#include "graphics/pixelbuffer.h"
|
||||
|
||||
typedef unsigned long long uint64;
|
||||
|
||||
@ -221,10 +220,6 @@ const OSystem::GraphicsMode* OSystem_N64::getSupportedGraphicsModes() const {
|
||||
return s_supportedGraphicsModes;
|
||||
}
|
||||
|
||||
Graphics::PixelBuffer OSystem_N64::getScreenPixelBuffer() {
|
||||
return Graphics::PixelBuffer();
|
||||
}
|
||||
|
||||
int OSystem_N64::getDefaultGraphicsMode() const {
|
||||
return OVERS_NTSC_340X240;
|
||||
}
|
||||
|
@ -41,7 +41,6 @@
|
||||
#include "backends/saves/default/default-saves.h"
|
||||
#include "backends/timer/psp/timer.h"
|
||||
#include "graphics/surface.h"
|
||||
#include "graphics/pixelbuffer.h"
|
||||
#include "audio/mixer_intern.h"
|
||||
|
||||
//#define __PSP_DEBUG_FUNCS__ /* For debugging function calls */
|
||||
@ -131,10 +130,6 @@ const OSystem::GraphicsMode* OSystem_PSP::getSupportedGraphicsModes() const {
|
||||
return _displayManager.getSupportedGraphicsModes();
|
||||
}
|
||||
|
||||
Graphics::PixelBuffer OSystem_PSP::getScreenPixelBuffer() {
|
||||
return Graphics::PixelBuffer();
|
||||
}
|
||||
|
||||
int OSystem_PSP::getDefaultGraphicsMode() const {
|
||||
DEBUG_ENTER_FUNC();
|
||||
return _displayManager.getDefaultGraphicsMode();
|
||||
|
@ -79,7 +79,6 @@ public:
|
||||
virtual Graphics::PixelFormat getScreenFormat() const;
|
||||
virtual Common::List<Graphics::PixelFormat> getSupportedFormats() const;
|
||||
#endif
|
||||
virtual Graphics::PixelBuffer getScreenPixelBuffer();
|
||||
|
||||
// Screen size
|
||||
void initSize(uint width, uint height, const Graphics::PixelFormat *format);
|
||||
|
@ -166,8 +166,6 @@ protected:
|
||||
virtual void setPalette(const byte *colors, uint start, uint num);
|
||||
virtual void grabPalette(byte *colors, uint start, uint num) const;
|
||||
public:
|
||||
virtual Graphics::PixelBuffer getScreenPixelBuffer();
|
||||
|
||||
virtual void setCursorPalette(const byte *colors, uint start, uint num);
|
||||
virtual void copyRectToScreen(const void *buf, int pitch, int x, int y,
|
||||
int w, int h);
|
||||
|
@ -29,7 +29,6 @@
|
||||
|
||||
#include "common/config-manager.h"
|
||||
#include "graphics/conversion.h"
|
||||
#include "graphics/pixelbuffer.h"
|
||||
#include "backends/fs/wii/wii-fs-factory.h"
|
||||
|
||||
#include "osystem.h"
|
||||
@ -375,10 +374,6 @@ void OSystem_Wii::grabPalette(byte *colors, uint start, uint num) const {
|
||||
}
|
||||
}
|
||||
|
||||
Graphics::PixelBuffer OSystem_Wii::getScreenPixelBuffer() {
|
||||
return Graphics::PixelBuffer();
|
||||
}
|
||||
|
||||
void OSystem_Wii::setCursorPalette(const byte *colors, uint start, uint num) {
|
||||
if (!_texMouse.palette) {
|
||||
printf("switching to palette based cursor\n");
|
||||
|
Loading…
Reference in New Issue
Block a user