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

ResVmGraphicsManager Class Reference

Abstract class for graphics manager. More...

#include <resvm-graphics.h>

Inheritance diagram for ResVmGraphicsManager:
Collaboration diagram for ResVmGraphicsManager:

List of all members.

Public Member Functions

virtual Common::List
< Graphics::PixelFormat
getSupportedFormats () const
virtual void initSize (uint width, uint height, const Graphics::PixelFormat *format=NULL)
virtual void beginGFXTransaction ()
virtual OSystem::TransactionError endGFXTransaction ()
virtual void setPalette (const byte *colors, uint start, uint num)
 Replace the specified range of the palette with new colors.
virtual void grabPalette (byte *colors, uint start, uint num) const
 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)
virtual Graphics::SurfacelockScreen ()
virtual void unlockScreen ()
virtual void fillScreen (uint32 col)
virtual void setShakePos (int shakeXOffset, int shakeYOffset)
virtual void setFocusRectangle (const Common::Rect &rect)
virtual void clearFocusRectangle ()
virtual void setMouseCursor (const void *buf, uint w, uint h, int hotspotX, int hotspotY, uint32 keycolor, bool dontScale=false, const Graphics::PixelFormat *format=NULL)
virtual void setCursorPalette (const byte *colors, uint start, uint num)
virtual void setupScreen (uint screenW, uint screenH, bool fullscreen, bool accel3d)=0
virtual Graphics::PixelBuffer getScreenPixelBuffer ()=0
virtual void suggestSideTextures (Graphics::Surface *left, Graphics::Surface *right)=0
virtual void saveScreenshot ()
virtual bool lockMouse (bool lock)=0

Detailed Description

Abstract class for graphics manager.

Subclasses implement the real functionality.

Definition at line 39 of file resvm-graphics.h.


Member Function Documentation

virtual void ResVmGraphicsManager::beginGFXTransaction (  )  [inline, virtual]

Implements GraphicsManager.

Definition at line 49 of file resvm-graphics.h.

virtual void ResVmGraphicsManager::clearFocusRectangle (  )  [inline, virtual]

Implements GraphicsManager.

Definition at line 59 of file resvm-graphics.h.

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

Implements GraphicsManager.

Reimplemented in AndroidGraphicsManager.

Definition at line 53 of file resvm-graphics.h.

virtual OSystem::TransactionError ResVmGraphicsManager::endGFXTransaction (  )  [inline, virtual]

Implements GraphicsManager.

Definition at line 50 of file resvm-graphics.h.

virtual void ResVmGraphicsManager::fillScreen ( uint32  col  )  [inline, virtual]

Implements GraphicsManager.

Reimplemented in AndroidGraphicsManager.

Definition at line 56 of file resvm-graphics.h.

virtual Graphics::PixelBuffer ResVmGraphicsManager::getScreenPixelBuffer (  )  [pure virtual]

Implemented in AndroidGraphicsManager.

virtual Common::List<Graphics::PixelFormat> ResVmGraphicsManager::getSupportedFormats (  )  const [inline, virtual]

Implements GraphicsManager.

Reimplemented in AndroidGraphicsManager.

Definition at line 43 of file resvm-graphics.h.

virtual void ResVmGraphicsManager::grabPalette ( byte colors,
uint  start,
uint  num 
) const [inline, 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

Implements GraphicsManager.

Reimplemented in AndroidGraphicsManager.

Definition at line 52 of file resvm-graphics.h.

virtual void ResVmGraphicsManager::initSize ( uint  width,
uint  height,
const Graphics::PixelFormat format = NULL 
) [inline, virtual]

Implements GraphicsManager.

Reimplemented in AndroidGraphicsManager.

Definition at line 48 of file resvm-graphics.h.

virtual bool ResVmGraphicsManager::lockMouse ( bool  lock  )  [pure virtual]

Implemented in AndroidGraphicsManager.

virtual Graphics::Surface* ResVmGraphicsManager::lockScreen (  )  [inline, virtual]

Implements GraphicsManager.

Reimplemented in AndroidGraphicsManager.

Definition at line 54 of file resvm-graphics.h.

virtual void ResVmGraphicsManager::saveScreenshot (  )  [inline, virtual]

Definition at line 67 of file resvm-graphics.h.

virtual void ResVmGraphicsManager::setCursorPalette ( const byte colors,
uint  start,
uint  num 
) [inline, virtual]

Implements GraphicsManager.

Reimplemented in AndroidGraphicsManager.

Definition at line 61 of file resvm-graphics.h.

virtual void ResVmGraphicsManager::setFocusRectangle ( const Common::Rect rect  )  [inline, virtual]

Implements GraphicsManager.

Definition at line 58 of file resvm-graphics.h.

virtual void ResVmGraphicsManager::setMouseCursor ( const void *  buf,
uint  w,
uint  h,
int  hotspotX,
int  hotspotY,
uint32  keycolor,
bool  dontScale = false,
const Graphics::PixelFormat format = NULL 
) [inline, virtual]

Implements GraphicsManager.

Reimplemented in AndroidGraphicsManager.

Definition at line 60 of file resvm-graphics.h.

virtual void ResVmGraphicsManager::setPalette ( const byte colors,
uint  start,
uint  num 
) [inline, 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

Implements GraphicsManager.

Reimplemented in AndroidGraphicsManager.

Definition at line 51 of file resvm-graphics.h.

virtual void ResVmGraphicsManager::setShakePos ( int  shakeXOffset,
int  shakeYOffset 
) [inline, virtual]

Implements GraphicsManager.

Definition at line 57 of file resvm-graphics.h.

virtual void ResVmGraphicsManager::setupScreen ( uint  screenW,
uint  screenH,
bool  fullscreen,
bool  accel3d 
) [pure virtual]

Implemented in AndroidGraphicsManager.

virtual void ResVmGraphicsManager::suggestSideTextures ( Graphics::Surface left,
Graphics::Surface right 
) [pure virtual]

Implemented in AndroidGraphicsManager.

virtual void ResVmGraphicsManager::unlockScreen (  )  [inline, virtual]

Implements GraphicsManager.

Reimplemented in AndroidGraphicsManager.

Definition at line 55 of file resvm-graphics.h.


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


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