Public Member Functions | Protected Member Functions | Protected Attributes

gnash::renderer::rawfb::RawFBDevice Class Reference

#include <RawFBDevice.h>

Inheritance diagram for gnash::renderer::rawfb::RawFBDevice:
gnash::renderer::GnashDevice

List of all members.

Public Member Functions

 RawFBDevice ()
 RawFBDevice (int)
 RawFBDevice (int argc, char *argv[])
virtual ~RawFBDevice ()
dtype_t getType ()
bool initDevice (int argc, char *argv[])
bool attachWindow (GnashDevice::native_window_t window)
const char * getErrorString (int error)
 Return a string with the error code as text, instead of a numeric value.
int getDepth ()
 Get the depth of the device.
size_t getWidth ()
 Get the width of the device.
size_t getHeight ()
 Get the Height of the device.
bool supportsRenderer (GnashDevice::rtype_t)
 Is the specified renderer supported by this hardware ?
bool isBufferDestroyed ()
 Are buffers destroyed ?
int getID ()
 Get the window ID handle.
int getRedSize ()
 Get the size of the Red pixel.
int getGreenSize ()
 Get the size of the Green pixel.
int getBlueSize ()
 Get the size of the Blue pixel.
bool isNativeRender ()
 Is this renderering natively.
native_window_t getDrawableWindow ()
void createWindow (const char *name, int x, int y, int width, int height)
boost::uint8_t * getFBMemory ()
 Get the memory from the real framebuffer.
boost::uint8_t * getOffscreenBuffer ()
 Get the memory from an offscreen buffer to support Double Buffering.
size_t getStride ()
 Query the system for all supported configs.
size_t getFBMemSize ()
int getHandle ()
void eventLoop (size_t passes)
bool setGrayscaleLUT8 ()
bool isSingleBuffered ()
 Is this device single buffered.
bool swapBuffers ()

Protected Member Functions

void clear ()
 Clear the framebuffer memory.

Protected Attributes

int _fd
std::string _filespec
struct fb_fix_screeninfo _fixinfo
struct fb_var_screeninfo _varinfo
boost::uint8_t * _fbmem
boost::scoped_ptr< boost::uint8_t > _offscreen_buffer
struct fb_cmap _cmap

Constructor & Destructor Documentation

gnash::renderer::rawfb::RawFBDevice::RawFBDevice (  ) 
gnash::renderer::rawfb::RawFBDevice::RawFBDevice ( int   ) 
gnash::renderer::rawfb::RawFBDevice::RawFBDevice ( int  argc,
char *  argv[] 
)
gnash::renderer::rawfb::RawFBDevice::~RawFBDevice (  )  [virtual]

Member Function Documentation

bool gnash::renderer::rawfb::RawFBDevice::attachWindow ( GnashDevice::native_window_t  window  )  [virtual]

Attach Native Window to device. This connects a Native Window to the device so surfaces can be created.

Implements gnash::renderer::GnashDevice.

void gnash::renderer::rawfb::RawFBDevice::clear (  )  [protected]

Clear the framebuffer memory.

void gnash::renderer::rawfb::RawFBDevice::createWindow ( const char *  name,
int  x,
int  y,
int  width,
int  height 
)
void gnash::renderer::rawfb::RawFBDevice::eventLoop ( size_t  passes  ) 

Start an RAWFB event loop. This is only used by testing. Note that calling this function blocks until the specified number of events have been handled. The first 5 are used up by creating the window.

Parameters:
passes the number of events to process before returning.
Returns:
nothing
int gnash::renderer::rawfb::RawFBDevice::getBlueSize (  )  [inline, virtual]

Get the size of the Blue pixel.

Implements gnash::renderer::GnashDevice.

References _varinfo.

int gnash::renderer::rawfb::RawFBDevice::getDepth (  )  [inline, virtual]

Get the depth of the device.

Implements gnash::renderer::GnashDevice.

References _varinfo.

native_window_t gnash::renderer::rawfb::RawFBDevice::getDrawableWindow (  )  [inline]
const char * gnash::renderer::rawfb::RawFBDevice::getErrorString ( int  error  )  [virtual]

Return a string with the error code as text, instead of a numeric value.

Implements gnash::renderer::GnashDevice.

boost::uint8_t* gnash::renderer::rawfb::RawFBDevice::getFBMemory (  )  [inline, virtual]

Get the memory from the real framebuffer.

Reimplemented from gnash::renderer::GnashDevice.

References _fbmem.

size_t gnash::renderer::rawfb::RawFBDevice::getFBMemSize (  )  [inline, virtual]

Reimplemented from gnash::renderer::GnashDevice.

References _fixinfo.

int gnash::renderer::rawfb::RawFBDevice::getGreenSize (  )  [inline, virtual]

Get the size of the Green pixel.

Implements gnash::renderer::GnashDevice.

References _varinfo.

int gnash::renderer::rawfb::RawFBDevice::getHandle (  )  [inline]

References _fd.

size_t gnash::renderer::rawfb::RawFBDevice::getHeight (  )  [inline, virtual]

Get the Height of the device.

Implements gnash::renderer::GnashDevice.

References _varinfo.

int gnash::renderer::rawfb::RawFBDevice::getID (  )  [inline, virtual]

Get the window ID handle.

Implements gnash::renderer::GnashDevice.

boost::uint8_t* gnash::renderer::rawfb::RawFBDevice::getOffscreenBuffer (  )  [inline, virtual]

Get the memory from an offscreen buffer to support Double Buffering.

Reimplemented from gnash::renderer::GnashDevice.

References _offscreen_buffer.

int gnash::renderer::rawfb::RawFBDevice::getRedSize (  )  [inline, virtual]

Get the size of the Red pixel.

Implements gnash::renderer::GnashDevice.

References _varinfo.

size_t gnash::renderer::rawfb::RawFBDevice::getStride (  )  [inline, virtual]

Query the system for all supported configs.

Get the stride of the device

Implements gnash::renderer::GnashDevice.

References _fixinfo.

dtype_t gnash::renderer::rawfb::RawFBDevice::getType (  )  [inline, virtual]

Get the type of the instatiated device. Since the renderer has a single value for the supported device, this is used to see which device has been loaded.

Implements gnash::renderer::GnashDevice.

size_t gnash::renderer::rawfb::RawFBDevice::getWidth (  )  [inline, virtual]

Get the width of the device.

Implements gnash::renderer::GnashDevice.

References _varinfo.

bool gnash::renderer::rawfb::RawFBDevice::initDevice ( int  argc,
char *  argv[] 
) [virtual]

Initialize GNASH Device layer. This mostly just initializes all the private data.

Implements gnash::renderer::GnashDevice.

bool gnash::renderer::rawfb::RawFBDevice::isBufferDestroyed (  )  [inline, virtual]

Are buffers destroyed ?

Implements gnash::renderer::GnashDevice.

bool gnash::renderer::rawfb::RawFBDevice::isNativeRender (  )  [inline, virtual]

Is this renderering natively.

Implements gnash::renderer::GnashDevice.

bool gnash::renderer::rawfb::RawFBDevice::isSingleBuffered (  )  [inline, virtual]

Is this device single buffered.

Implements gnash::renderer::GnashDevice.

bool gnash::renderer::rawfb::RawFBDevice::setGrayscaleLUT8 (  ) 

For 8 bit (palette / LUT) modes, sets a grayscale palette. This GUI currently does not support palette modes.

bool gnash::renderer::rawfb::RawFBDevice::supportsRenderer ( GnashDevice::rtype_t  rtype  )  [inline, virtual]

Is the specified renderer supported by this hardware ?

Implements gnash::renderer::GnashDevice.

bool gnash::renderer::rawfb::RawFBDevice::swapBuffers (  )  [virtual]

Reimplemented from gnash::renderer::GnashDevice.


Member Data Documentation

struct fb_cmap gnash::renderer::rawfb::RawFBDevice::_cmap [protected]
boost::uint8_t* gnash::renderer::rawfb::RawFBDevice::_fbmem [protected]

Referenced by getFBMemory().

Referenced by getHandle().

struct fb_fix_screeninfo gnash::renderer::rawfb::RawFBDevice::_fixinfo [protected]

Referenced by getFBMemSize(), and getStride().

boost::scoped_ptr<boost::uint8_t> gnash::renderer::rawfb::RawFBDevice::_offscreen_buffer [protected]

Referenced by getOffscreenBuffer().


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