ResidualVM logo ResidualVM website - Forums - Contact us BuildBot - Doxygen - Wiki curved edge

#include <graphics.h>

Inheritance diagram for AndroidGraphicsManager:
Collaboration diagram for AndroidGraphicsManager:

List of all members.

Public Member Functions

 AndroidGraphicsManager ()
virtual ~AndroidGraphicsManager ()
void initSurface ()
void deinitSurface ()
void updateScreen () override
void displayMessageOnOSD (const char *msg)
bool notifyMousePosition (Common::Point &mouse)
Common::Point getMousePosition ()
void setMousePosition (int x, int y)
virtual const
OSystem::GraphicsMode
getSupportedGraphicsModes () const override
virtual int getDefaultGraphicsMode () const override
virtual bool setGraphicsMode (int mode) override
virtual void resetGraphicsScale () override
virtual int getGraphicsMode () const override
virtual bool hasFeature (OSystem::Feature f) const override
virtual void setFeatureState (OSystem::Feature f, bool enable) override
virtual bool getFeatureState (OSystem::Feature f) const override
virtual void showOverlay () override
virtual void hideOverlay () override
virtual void clearOverlay () override
virtual void grabOverlay (void *buf, int pitch) const override
virtual void copyRectToOverlay (const void *buf, int pitch, int x, int y, int w, int h) override
virtual int16 getOverlayHeight () const override
virtual int16 getOverlayWidth () const override
virtual Graphics::PixelFormat getOverlayFormat () const override
virtual int16 getHeight () const override
virtual int16 getWidth () const override
virtual void setPalette (const byte *colors, uint start, uint num) override
 Replace the specified range of the palette with new colors.
virtual void grabPalette (byte *colors, uint start, uint num) const override
 Grabs a specified part of the currently active palette.
virtual void copyRectToScreen (const void *buf, int pitch, int x, int y, int w, int h) override
virtual Graphics::SurfacelockScreen () override
virtual void unlockScreen () override
virtual void fillScreen (uint32 col)
virtual void initSize (uint width, uint height, const Graphics::PixelFormat *format) override
virtual int getScreenChangeID () const override
virtual bool showMouse (bool visible) override
virtual void warpMouse (int x, int y) override
virtual bool lockMouse (bool lock) override
virtual void setMouseCursor (const void *buf, uint w, uint h, int hotspotX, int hotspotY, uint32 keycolor, bool dontScale, const Graphics::PixelFormat *format) override
virtual void setCursorPalette (const byte *colors, uint start, uint num) override
void setupScreen (uint screenW, uint screenH, bool fullscreen, bool accel3d) override
void setupScreen (uint screenW, uint screenH, bool fullscreen, bool accel3d, bool isGame)
virtual Graphics::PixelBuffer getScreenPixelBuffer () override
virtual void suggestSideTextures (Graphics::Surface *left, Graphics::Surface *right) override
void updateScreenRect ()
const GLESBaseTexture * getActiveTexture () const
void clipMouse (Common::Point &p) const
virtual Graphics::PixelFormat getScreenFormat () const override
virtual Common::List
< Graphics::PixelFormat
getSupportedFormats () const override

Protected Member Functions

void setSystemMousePosition (int x, int y)
bool loadVideoMode (uint requestedWidth, uint requestedHeight, const Graphics::PixelFormat &format)
void refreshScreen ()
void * getProcAddress (const char *name) const

Private Types

enum  FixupType { kClear = 0, kClearSwap, kClearUpdate }

Private Member Functions

void setCursorPaletteInternal (const byte *colors, uint start, uint num)
void disableCursorPalette ()
void initOverlay ()
void initViewport ()
void updateEventScale ()
void clearScreen (FixupType type, byte count=1)
void initTexture (GLESBaseTexture **texture, uint width, uint height, const Graphics::PixelFormat *format)

Private Attributes

int _screenChangeID
int _graphicsMode
bool _opengl
bool _fullscreen
bool _ar_correction
bool _force_redraw
GLESBaseTexture * _game_texture
Graphics::PixelBuffer _game_pbuf
OpenGL::FrameBuffer_frame_buffer
int _cursorX
 The position of the mouse cursor, in window coordinates.
int _cursorY
GLES4444Texture * _overlay_texture
bool _show_overlay
GLESBaseTexture * _mouse_texture
GLESBaseTexture * _mouse_texture_palette
GLES5551Texture * _mouse_texture_rgb
Common::Point _mouse_hotspot
uint32 _mouse_keycolor
int _mouse_targetscale
bool _show_mouse
bool _use_mouse_palette

Detailed Description

Definition at line 29 of file graphics.h.


Member Enumeration Documentation

Enumerator:
kClear 
kClearSwap 
kClearUpdate 

Definition at line 123 of file graphics.h.


Constructor & Destructor Documentation

AndroidGraphicsManager::AndroidGraphicsManager (  ) 
virtual AndroidGraphicsManager::~AndroidGraphicsManager (  )  [virtual]

Member Function Documentation

virtual void AndroidGraphicsManager::clearOverlay (  )  [override, virtual]

Implements GraphicsManager.

void AndroidGraphicsManager::clearScreen ( FixupType  type,
byte  count = 1 
) [private]
void AndroidGraphicsManager::clipMouse ( Common::Point p  )  const
virtual void AndroidGraphicsManager::copyRectToOverlay ( const void *  buf,
int  pitch,
int  x,
int  y,
int  w,
int  h 
) [override, virtual]

Implements GraphicsManager.

virtual void AndroidGraphicsManager::copyRectToScreen ( const void *  buf,
int  pitch,
int  x,
int  y,
int  w,
int  h 
) [override, virtual]

Reimplemented from ResVmGraphicsManager.

void AndroidGraphicsManager::deinitSurface (  ) 
void AndroidGraphicsManager::disableCursorPalette (  )  [private]
void AndroidGraphicsManager::displayMessageOnOSD ( const char *  msg  )  [virtual]

Reimplemented from GraphicsManager.

virtual void AndroidGraphicsManager::fillScreen ( uint32  col  )  [virtual]

Reimplemented from ResVmGraphicsManager.

const GLESBaseTexture* AndroidGraphicsManager::getActiveTexture (  )  const
virtual int AndroidGraphicsManager::getDefaultGraphicsMode (  )  const [override, virtual]

Reimplemented from GraphicsManager.

virtual bool AndroidGraphicsManager::getFeatureState ( OSystem::Feature  f  )  const [override, virtual]

Implements GraphicsManager.

virtual int AndroidGraphicsManager::getGraphicsMode (  )  const [override, virtual]

Reimplemented from GraphicsManager.

virtual int16 AndroidGraphicsManager::getHeight (  )  const [override, virtual]

Implements GraphicsManager.

Common::Point AndroidGraphicsManager::getMousePosition (  )  [inline]

Definition at line 42 of file graphics.h.

virtual Graphics::PixelFormat AndroidGraphicsManager::getOverlayFormat (  )  const [override, virtual]

Implements GraphicsManager.

virtual int16 AndroidGraphicsManager::getOverlayHeight (  )  const [override, virtual]

Implements GraphicsManager.

virtual int16 AndroidGraphicsManager::getOverlayWidth (  )  const [override, virtual]

Implements GraphicsManager.

void* AndroidGraphicsManager::getProcAddress ( const char *  name  )  const [protected]
virtual int AndroidGraphicsManager::getScreenChangeID (  )  const [override, virtual]

Implements GraphicsManager.

virtual Graphics::PixelFormat AndroidGraphicsManager::getScreenFormat (  )  const [override, virtual]

Implements GraphicsManager.

virtual Graphics::PixelBuffer AndroidGraphicsManager::getScreenPixelBuffer (  )  [override, virtual]

Implements ResVmGraphicsManager.

virtual Common::List<Graphics::PixelFormat> AndroidGraphicsManager::getSupportedFormats (  )  const [override, virtual]

Reimplemented from ResVmGraphicsManager.

virtual const OSystem::GraphicsMode* AndroidGraphicsManager::getSupportedGraphicsModes (  )  const [override, virtual]

Reimplemented from GraphicsManager.

virtual int16 AndroidGraphicsManager::getWidth (  )  const [override, virtual]

Implements GraphicsManager.

virtual void AndroidGraphicsManager::grabOverlay ( void *  buf,
int  pitch 
) const [override, virtual]

Implements GraphicsManager.

virtual void AndroidGraphicsManager::grabPalette ( byte colors,
uint  start,
uint  num 
) const [override, virtual]

Grabs a specified part of the currently active palette.

The format is the same as for setPalette.

This should return exactly the same RGB data as was setup via previous setPalette calls.

For example, for every valid value of start and num of the following code:

byte origPal[num*3]; // Setup origPal's data however you like g_system->setPalette(origPal, start, num); byte obtainedPal[num*3]; g_system->grabPalette(obtainedPal, start, num);

the following should be true:

memcmp(origPal, obtainedPal, num*3) == 0

See also:
setPalette
Parameters:
colors the palette data, in interleaved RGB format
start the first platte entry to be read
num the number of palette entries to be read
Note:
It is an error if this function gets called when the pixel format in use (the return value of getScreenFormat) has more than one byte per pixel.
See also:
getScreenFormat

Reimplemented from ResVmGraphicsManager.

virtual bool AndroidGraphicsManager::hasFeature ( OSystem::Feature  f  )  const [override, virtual]

Implements GraphicsManager.

virtual void AndroidGraphicsManager::hideOverlay (  )  [override, virtual]

Implements GraphicsManager.

void AndroidGraphicsManager::initOverlay (  )  [private]
virtual void AndroidGraphicsManager::initSize ( uint  width,
uint  height,
const Graphics::PixelFormat format 
) [override, virtual]

Reimplemented from ResVmGraphicsManager.

void AndroidGraphicsManager::initSurface (  ) 
void AndroidGraphicsManager::initTexture ( GLESBaseTexture **  texture,
uint  width,
uint  height,
const Graphics::PixelFormat format 
) [private]
void AndroidGraphicsManager::initViewport (  )  [private]
bool AndroidGraphicsManager::loadVideoMode ( uint  requestedWidth,
uint  requestedHeight,
const Graphics::PixelFormat format 
) [protected]
virtual bool AndroidGraphicsManager::lockMouse ( bool  lock  )  [override, virtual]

Implements ResVmGraphicsManager.

virtual Graphics::Surface* AndroidGraphicsManager::lockScreen (  )  [override, virtual]

Reimplemented from ResVmGraphicsManager.

bool AndroidGraphicsManager::notifyMousePosition ( Common::Point mouse  ) 
void AndroidGraphicsManager::refreshScreen (  )  [protected]
virtual void AndroidGraphicsManager::resetGraphicsScale (  )  [override, virtual]

Reimplemented from GraphicsManager.

virtual void AndroidGraphicsManager::setCursorPalette ( const byte colors,
uint  start,
uint  num 
) [override, virtual]

Reimplemented from ResVmGraphicsManager.

void AndroidGraphicsManager::setCursorPaletteInternal ( const byte colors,
uint  start,
uint  num 
) [private]
virtual void AndroidGraphicsManager::setFeatureState ( OSystem::Feature  f,
bool  enable 
) [override, virtual]

Implements GraphicsManager.

virtual bool AndroidGraphicsManager::setGraphicsMode ( int  mode  )  [override, virtual]

Reimplemented from GraphicsManager.

virtual void AndroidGraphicsManager::setMouseCursor ( const void *  buf,
uint  w,
uint  h,
int  hotspotX,
int  hotspotY,
uint32  keycolor,
bool  dontScale,
const Graphics::PixelFormat format 
) [override, virtual]

Reimplemented from ResVmGraphicsManager.

void AndroidGraphicsManager::setMousePosition ( int  x,
int  y 
) [inline]

Definition at line 43 of file graphics.h.

virtual void AndroidGraphicsManager::setPalette ( const byte colors,
uint  start,
uint  num 
) [override, virtual]

Replace the specified range of the palette with new colors.

The palette entries from 'start' till (start+num-1) will be replaced - so a full palette update is accomplished via start=0, num=256.

The palette data is specified in interleaved RGB format. That is, the first byte of the memory block 'colors' points at is the red component of the first new color; the second byte the green component of the first new color; the third byte the blue component, the last byte to the alpha (transparency) value. Then the second color starts, and so on. So memory looks like this: R1-G1-B1-R2-G2-B2-R3-...

Parameters:
colors the new palette data, in interleaved RGB format
start the first palette entry to be updated
num the number of palette entries to be updated
Note:
It is an error if start+num exceeds 256, behavior is undefined in that case (the backend may ignore it silently or assert).
It is an error if this function gets called when the pixel format in use (the return value of getScreenFormat) has more than one byte per pixel.
See also:
getScreenFormat

Reimplemented from ResVmGraphicsManager.

void AndroidGraphicsManager::setSystemMousePosition ( int  x,
int  y 
) [inline, protected]

Definition at line 107 of file graphics.h.

void AndroidGraphicsManager::setupScreen ( uint  screenW,
uint  screenH,
bool  fullscreen,
bool  accel3d 
) [override, virtual]

Implements ResVmGraphicsManager.

void AndroidGraphicsManager::setupScreen ( uint  screenW,
uint  screenH,
bool  fullscreen,
bool  accel3d,
bool  isGame 
)
virtual bool AndroidGraphicsManager::showMouse ( bool  visible  )  [override, virtual]

Implements GraphicsManager.

virtual void AndroidGraphicsManager::showOverlay (  )  [override, virtual]

Implements GraphicsManager.

virtual void AndroidGraphicsManager::suggestSideTextures ( Graphics::Surface left,
Graphics::Surface right 
) [override, virtual]

Implements ResVmGraphicsManager.

virtual void AndroidGraphicsManager::unlockScreen (  )  [override, virtual]

Reimplemented from ResVmGraphicsManager.

void AndroidGraphicsManager::updateEventScale (  )  [private]
void AndroidGraphicsManager::updateScreen (  )  [override, virtual]

Implements GraphicsManager.

void AndroidGraphicsManager::updateScreenRect (  ) 
virtual void AndroidGraphicsManager::warpMouse ( int  x,
int  y 
) [override, virtual]

Implements GraphicsManager.


Member Data Documentation

Definition at line 140 of file graphics.h.

The position of the mouse cursor, in window coordinates.

Definition at line 151 of file graphics.h.

Definition at line 151 of file graphics.h.

Definition at line 141 of file graphics.h.

Definition at line 139 of file graphics.h.

GLESBaseTexture* AndroidGraphicsManager::_game_texture [private]

Definition at line 144 of file graphics.h.

Definition at line 137 of file graphics.h.

Definition at line 161 of file graphics.h.

Definition at line 162 of file graphics.h.

Definition at line 163 of file graphics.h.

GLESBaseTexture* AndroidGraphicsManager::_mouse_texture [private]

Definition at line 158 of file graphics.h.

Definition at line 159 of file graphics.h.

GLES5551Texture* AndroidGraphicsManager::_mouse_texture_rgb [private]

Definition at line 160 of file graphics.h.

Definition at line 138 of file graphics.h.

GLES4444Texture* AndroidGraphicsManager::_overlay_texture [private]

Definition at line 154 of file graphics.h.

Definition at line 136 of file graphics.h.

Definition at line 164 of file graphics.h.

Definition at line 155 of file graphics.h.

Definition at line 165 of file graphics.h.


The documentation for this class was generated from the following file:


Generated on Sat Aug 8 2020 05:02:43 for ResidualVM by doxygen 1.7.1
curved edge   curved edge