OSDL::Video::VideoModule Class Reference

#include <OSDLVideo.h>

Collaboration diagram for OSDL::Video::VideoModule:

Collaboration graph
[legend]

List of all members.


Detailed Description

Root module for all video needs.

Notably manages the screen surface.

Note:
if the video subsystem has already been initialized, calling the static methods returning video informations will apply to the current video mode. If the video subsystem has not already been initialized, those static methods will return informations about the best available video mode.

Definition at line 75 of file OSDLVideo.h.


Public Member Functions

bool hasScreenSurface () const throw ()
 Returns whether a screen surface is available.
virtual SurfacegetScreenSurface () const throw ( VideoException )
 Returns the current screen surface, if any.
virtual void setScreenSurface (Surface &newScreenSurface) throw ( VideoException )
 Assigns a new surface to the screen surface.
virtual bool hasRenderer () const throw ()
 Tells whether this video module uses a (video) renderer.
virtual Rendering::VideoRenderergetRenderer () const throw ( VideoException )
 Returns the video renderer currently used.
virtual void setRenderer (Rendering::VideoRenderer &newRenderer) throw ()
 Sets a new video renderer.
virtual bool hasOpenGLContext () const throw ()
 Tells whether this video module has an OpenGL context.
virtual void setOpenGLContext (OpenGL::OpenGLContext &newOpenGLContext) throw ()
 Sets a new OpenGL context.
virtual OpenGL::OpenGLContextgetOpenGLContext () const throw ( VideoException )
 Returns the OpenGL context currently used.
virtual BitsPerPixel getBestColorDepthForMode (Length width, Length height, BitsPerPixel askedBpp, Ceylan::Flags flags) throw ()
 Returns what is the closest recommended bits per pixel choice for specified video mode, according to specified bits per pixel target.
virtual bool isDisplayInitialized () const throw ()
 Tells whether the display is currently running, i.e.
virtual Ceylan::Flags setMode (Length width, Length height, BitsPerPixel askedBpp, Ceylan::Flags flags, OpenGL::Flavour flavour=OpenGL::None) throw ( VideoException )
 Tries to sets up a video mode with the specified width, height and bits-per-pixel.
virtual void resize (Length newWidth, Length newHeight) throw ( VideoException )
 Does everything needed when the application is resized, including calling setMode and updating OpenGL state if necessary.
virtual void redraw () throw ( VideoException )
 This method should be called whenever the screen needs to be redrawn, for example if the window manager asks for it.
virtual void toggleFullscreen () throw ( VideoException )
 Toggles the application between windowed and fullscreen mode, if supported.
virtual void makeBMPScreenshot (const std::string &screenshotFilename) throw ( VideoException )
 Performs a screenshot of onscreen content, and saves it in a BMP file whose name is specified.
virtual bool getEndPointDrawState () const throw ()
 Tells whether line endpoint (final pixel) should be drawn.
virtual void setEndPointDrawState (bool newState) throw ()
 Sets the draw-endpoint mode.
virtual bool getAntiAliasingState () const throw ()
 Tells whether graphics should be anti-aliased, if possible.
virtual void setAntiAliasingState (bool newState) throw ()
 Sets the anti-aliasing mode.
virtual std::string getDriverName () const throw ( VideoException )
 Returns the name of the video driver being currently used (example: 'x11').
virtual void setWindowCaption (const std::string &newTitle, const std::string &iconName) throw ()
 Sets the window title and icon name.
virtual void getWindowCaption (std::string &title, std::string &iconName) throw ()
 Gets the window title and icon name.
virtual void setWindowIcon (const std::string &filename) throw ( VideoException )
 Sets the icon for the display window.
virtual bool iconifyWindow () throw ()
 Iconifies (minimizes) the window.
virtual bool getFrameAccountingState () throw ()
 Tells whether frames shoud be monitored to know the frame-per-second (FPS) indicator.
virtual void setFrameAccountingState (bool newState) throw ()
 Sets the frame-accounting mode.
virtual bool isUsingOpenGL () const throw ()
 Tells whether OpenGL is being used currently by this video module.
virtual const std::string toString (Ceylan::VerbosityLevels level=Ceylan::high) const throw ()
 Returns an user-friendly description of the state of this object.

Static Public Member Functions

static bool IsDisplayInitialized () throw ()
 Tells whether display has already been initialized (VideoModule::setMode called).
static bool GetEndPointDrawState () throw ()
 Tells whether the last pixel of a segment of line should be drawn.
static bool GetAntiAliasingState () throw ()
 Tells whether antialiasing is wanted.
static std::string GetDriverName () throw ( VideoException )
 Returns the name of the video driver being currently used (example: 'x11').
static std::string InterpretFlags (Ceylan::Flags flags) throw ()
 Describes specified video flags according to the semantics used in setMode.
static bool HardwareSurfacesCanBeCreated () throw ( VideoException )
 Returns whether hardware surfaces can be created.
static bool WindowManagerAvailable () throw ( VideoException )
 Returns whether there is a window manager available.
static bool HardwareToHardwareBlitsAccelerated () throw ( VideoException )
 Returns whether hardware to hardware blits are accelerated.
static bool HardwareToHardwareColorkeyBlitsAccelerated () throw ( VideoException )
 Returns whether hardware to hardware colorkey blits are accelerated.
static bool HardwareToHardwareAlphaBlitsAccelerated () throw ( VideoException )
 Returns whether hardware to hardware alpha blits are accelerated.
static bool SoftwareToHardwareBlitsAccelerated () throw ( VideoException )
 Returns whether software to hardware blits are accelerated.
static bool SoftwareToHardwareColorkeyBlitsAccelerated () throw ( VideoException )
 Returns whether software to hardware colorkey blits are accelerated.
static bool SoftwareToHardwareAlphaBlitsAccelerated () throw ( VideoException )
 Returns whether software to hardware alpha blits are accelerated.
static bool ColorFillsAccelerated () throw ( VideoException )
 Returns whether color fills are accelerated.
static Ceylan::Uint32 GetVideoMemorySize () throw ( VideoException )
 Returns the total amount of video memory, in kilobytes.
static Pixels::PixelFormat GetVideoDevicePixelFormat () throw ( VideoException )
 Returns the native format of the video device.
static std::string DescribeVideoCapabilities () throw ( VideoException )
 Returns a summary of video chain capabilities.
static bool AreDefinitionsRestricted (std::list< Definition > &definitions, Ceylan::Flags flags, Pixels::PixelFormat *pixelFormat=0) throw ( VideoException )
 Tells whether definitions are restricted for the specified flags and pixel format.
static std::string DescribeAvailableDefinitions (Ceylan::Flags flags, Pixels::PixelFormat *pixelFormat=0) throw ( VideoException )
 Returns a summary of available screen definitions for specified flags and pixel format.
static std::string DescribeEnvironmentVariables () throw ()
 Returns a summary about the possible use of video-related environment variables, for the selected back-end, expressed in specified format.
static bool IsUsingOpenGL () throw ( VideoException )
 Returns whether OpenGL is being used, at least by one video module.

Static Public Attributes

static const BitsPerPixel UseCurrentColorDepth = 0
 Tells setMode that the color depth of the current display should be used.
static const Ceylan::Flags SoftwareSurface = 0x00000000
 Indicates that the screen surface is to be stored in system memory.
static const Ceylan::Flags HardwareSurface = 0x00000001
 Indicates that the screen surface is to be stored in video memory.
static const Ceylan::Flags AsynchronousBlit = 0x00000004
 Enables the use of asynchronous updates of the display surface.
static const Ceylan::Flags AnyPixelFormat = 0x10000000
 Indicates that the screen surface may use any pixel format.
static const Ceylan::Flags ExclusivePalette = 0x20000000
 Indicates that a surface should have an exclusive palette.
static const Ceylan::Flags DoubleBuffered = 0x40000000
 Indicates that the screen surface is to be double buffered.
static const Ceylan::Flags FullScreen = 0x80000000
 Indicates that the screen surface is to be full screen, not windowed.
static const Ceylan::Flags OpenGL = 0x00000002
 Indicates that the screen surface should have an OpenGL context.
static const Ceylan::Flags Resizable = 0x00000010
 Indicates that the screen surface is to be resizable.
static const Ceylan::Flags WithGUI = 0SDL_WITHGUI
 Indicates that a GUI backend should be used here (ex: Agar).
static const Ceylan::Flags NoFrame = 0x00000020
 Indicates that a window which would correspond to a screen surface should have no title bar nor frame decoration, if possible.

Protected Attributes

Surface_screen
 Internal surface corresponding to the screen.
bool _displayInitialized
 Keeps tracks of setMode calls, be OpenGL used or not.
Rendering::VideoRenderer_renderer
 The video renderer being used, if any.
bool _frameAccountingState
 Records the current frame-accounting state, which tells if frame rate is to be monitored.

Static Protected Attributes

static bool _IsUsingOpenGL = false
 Caches the current state relative to the current use of OpenGL.
static bool _DrawEndPoint = false
 Caches the current state relative to final pixel drawing for lines.
static bool _AntiAliasing = true
 Caches the current state relative to antialiasing.
static const Ceylan::Uint16 DriverNameMaximumLength = 50
 The maximum length for the name of the display driver.

Private Member Functions

 VideoModule () throw ( VideoException )
 Private constructor to be sure it will not be implicitly called.
virtual ~VideoModule () throw ()
 Basic virtual private destructor.
 VideoModule (const VideoModule &source) throw ()
 Copy constructor made private to ensure that it will never be called.
VideoModuleoperator= (const VideoModule &source) throw ()
 Assignment operator made private to ensure that it will never be called.

Private Attributes

OpenGL::OpenGLContext_openGLcontext
 Delay in milliseconds between two displays of the frame rate.
bool _drawEndPoint
 Records the current state relative to final pixel drawing for lines.
bool _antiAliasing
 Records the current antialiasing state.

Static Private Attributes

static const std::string _SDLEnvironmentVariables [] = {}
 Array of all known environment variables related to video, for SDL back-end.

Friends

class OSDL::CommonModule

Constructor & Destructor Documentation

VideoModule::VideoModule (  )  throw ( VideoException ) [private]

Private constructor to be sure it will not be implicitly called.

Exceptions:
VideoException if the video subsystem initialization failed.

Definition at line 187 of file OSDLVideo.cc.

References OSDL::CommonModule::BackendSuccess, OSDL::Utils::getBackendLastError(), and OSDL::CommonModule::UseVideo.

VideoModule::~VideoModule (  )  throw () [private, virtual]

Basic virtual private destructor.

Definition at line 251 of file OSDLVideo.cc.

References _openGLcontext, _renderer, _screen, and OSDL::CommonModule::UseVideo.

OSDL::Video::VideoModule::VideoModule ( const VideoModule source  )  throw () [explicit, private]

Copy constructor made private to ensure that it will never be called.

The compiler should complain whenever this undefined constructor is called, implicitly or not.


Member Function Documentation

bool VideoModule::hasScreenSurface (  )  const throw ()

Returns whether a screen surface is available.

Definition at line 278 of file OSDLVideo.cc.

References _screen.

Surface & VideoModule::getScreenSurface (  )  const throw ( VideoException ) [virtual]

Returns the current screen surface, if any.

The video module keeps ownership of the returned surface: the caller should not deallocate it.

Exceptions:
VideoException if no screen surface is available.

Definition at line 287 of file OSDLVideo.cc.

References _screen.

Referenced by OSDL::Video::Overlay::Overlay().

void VideoModule::setScreenSurface ( Surface newScreenSurface  )  throw ( VideoException ) [virtual]

Assigns a new surface to the screen surface.

Parameters:
newScreenSurface the new screen surface, which must already have a display type corresponding to a screen surface (i.e. not BackBuffer).
See also:
Surface::setDisplayType
Exceptions:
VideoException if the display type of the specified surface does not correspond to a screen surface.

Definition at line 300 of file OSDLVideo.cc.

References _screen, OSDL::Video::Surface::BackBuffer, and OSDL::Video::Surface::getDisplayType().

bool VideoModule::hasRenderer (  )  const throw () [virtual]

Tells whether this video module uses a (video) renderer.

Definition at line 317 of file OSDLVideo.cc.

References _renderer.

OSDL::Rendering::VideoRenderer & VideoModule::getRenderer (  )  const throw ( VideoException ) [virtual]

Returns the video renderer currently used.

Returns:
the current video renderer.
Exceptions:
VideoException if no renderer was being used.

Definition at line 326 of file OSDLVideo.cc.

References _renderer.

void VideoModule::setRenderer ( Rendering::VideoRenderer newRenderer  )  throw () [virtual]

Sets a new video renderer.

This renderer will be in charge of all the subsequently view graphical rendering.

If a previous renderer was used, it will be deleted.

Note:
The renderer will be owned by this Video module and deallocated as such.

Definition at line 340 of file OSDLVideo.cc.

References _renderer.

bool VideoModule::hasOpenGLContext (  )  const throw () [virtual]

Tells whether this video module has an OpenGL context.

Definition at line 352 of file OSDLVideo.cc.

References _openGLcontext.

Referenced by isUsingOpenGL().

void VideoModule::setOpenGLContext ( OpenGL::OpenGLContext newOpenGLContext  )  throw () [virtual]

Sets a new OpenGL context.

If a previous OpenGL context was used, it will be deleted first.

Note:
The OpenGL context will be owned by this Video module and deallocated as such.

Definition at line 375 of file OSDLVideo.cc.

References _IsUsingOpenGL, and _openGLcontext.

OpenGL::OpenGLContext & VideoModule::getOpenGLContext (  )  const throw ( VideoException ) [virtual]

Returns the OpenGL context currently used.

Returns:
the current OpenGL context.
Exceptions:
VideoException if no OpenGL context was being used.

Definition at line 361 of file OSDLVideo.cc.

References _openGLcontext.

virtual BitsPerPixel OSDL::Video::VideoModule::getBestColorDepthForMode ( Length  width,
Length  height,
BitsPerPixel  askedBpp,
Ceylan::Flags  flags 
) throw () [virtual]

Returns what is the closest recommended bits per pixel choice for specified video mode, according to specified bits per pixel target.

Parameters are the same, and have the same meaning, as setMode's ones.

Returns:
0 if the requested mode is not supported under any bit depth, or returns the bits-per-pixel of the closest available mode with the given width, height and requested surface flags.

bool VideoModule::isDisplayInitialized (  )  const throw () [virtual]

Tells whether the display is currently running, i.e.

if it has already been initialized and not been shut down at the moment.

Definition at line 409 of file OSDLVideo.cc.

References _displayInitialized.

Referenced by IsDisplayInitialized(), and setWindowIcon().

virtual Ceylan::Flags OSDL::Video::VideoModule::setMode ( Length  width,
Length  height,
BitsPerPixel  askedBpp,
Ceylan::Flags  flags,
OpenGL::Flavour  flavour = OpenGL::None 
) throw ( VideoException ) [virtual]

Tries to sets up a video mode with the specified width, height and bits-per-pixel.

Requested flags will be respected on a best effort basis, actually obtained flags will be returned.

Parameters:
width the client width (not counting window manager decorations) of the application window.
height the client height (not counting window manager decorations) of the application window.
askedBpp the requested color depth, in bits per pixel. If UseCurrentColorDepth (null) is specified, then the color depth of the display will be used.
flags describes the desired features, such as SoftwareSurface, Resizable, etc. One particularly useful feature is DoubleBuffered, since it allows to suppress most of the tearing on most platforms.
flavour the selected OpenGL flavour, if any, and if OpenGL is being used (see VideoModule::OpenGL setMode flag). Flavours have to be selected no later than this call.
Returns:
the flags that were actually obtained
Exceptions:
VideoException if the setting of the new mode failed.
See also:
SDL counter-part, SDL_SetVideoMode (defined in http://sdldoc.csn.ul.ie/sdlsetvideomode.php)
Note:
If OpenGL is used, then asking for double-buffering (flag DoubleBuffered) is strongly recommended since it prevents nasty visual tearing.

Referenced by resize().

void VideoModule::resize ( Length  newWidth,
Length  newHeight 
) throw ( VideoException ) [virtual]

Does everything needed when the application is resized, including calling setMode and updating OpenGL state if necessary.

Parameters:
newWidth the new width of the application window.
newHeight the new height of the application window.

Definition at line 620 of file OSDLVideo.cc.

References _openGLcontext, _screen, OSDL::Video::Surface::getBitsPerPixel(), OSDL::Video::Surface::getFlags(), OSDL::Video::OpenGL::None, OSDL::Video::OpenGL::Reload, setMode(), and OSDL::Video::Pixels::toString().

Referenced by OSDL::Events::EventsModule::onResizedWindow().

void VideoModule::redraw (  )  throw ( VideoException ) [virtual]

This method should be called whenever the screen needs to be redrawn, for example if the window manager asks for it.

Depending on a renderer being used or not, the screen will be managed.

Definition at line 658 of file OSDLVideo.cc.

References _screen, and OSDL::Video::Surface::redraw().

Referenced by OSDL::Events::EventsModule::enterBasicMainLoop(), OSDL::Events::EventsModule::onScreenNeedsRedraw(), and OSDL::Engine::Scheduler::scheduleRendering().

void VideoModule::toggleFullscreen (  )  throw ( VideoException ) [virtual]

Toggles the application between windowed and fullscreen mode, if supported.

Note:
X11 is the only target currently supported, BeOS support is experimental.

Definition at line 678 of file OSDLVideo.cc.

References _screen, OSDL::Utils::getBackendLastError(), and OSDL::Video::Surface::getSDLSurface().

virtual void OSDL::Video::VideoModule::makeBMPScreenshot ( const std::string &  screenshotFilename  )  throw ( VideoException ) [virtual]

Performs a screenshot of onscreen content, and saves it in a BMP file whose name is specified.

Parameters:
screenshotFilename the target screenshot filename
Exceptions:
VideoException if the operation failed.
Note:
This method exists mainly for platforms lacking Surface support (ex: the Nintendo DS, whose screenshots represent only the content of the main core), even if it will work on Surface-enabled platforms (in this case it will operate on the screen surface, if any).
See also:
Surface::savePNG, Surface::saveBMP.

bool VideoModule::getEndPointDrawState (  )  const throw () [virtual]

Tells whether line endpoint (final pixel) should be drawn.

Note:
Belongs to the state machine settings.
Returns:
true if draw-endpoint mode is set, false otherwise.

Definition at line 884 of file OSDLVideo.cc.

References _drawEndPoint.

Referenced by GetEndPointDrawState().

void VideoModule::setEndPointDrawState ( bool  newState  )  throw () [virtual]

Sets the draw-endpoint mode.

Note:
Belongs to the state machine settings.
Parameters:
newState the new draw-endpoint mode, activated if and only if true.

Definition at line 893 of file OSDLVideo.cc.

References _DrawEndPoint, and _drawEndPoint.

bool VideoModule::getAntiAliasingState (  )  const throw () [virtual]

Tells whether graphics should be anti-aliased, if possible.

Note:
Belongs to the state machine settings.
Returns:
true if anti-aliasing mode is set, false otherwise.

Definition at line 905 of file OSDLVideo.cc.

References _antiAliasing.

Referenced by GetAntiAliasingState().

void VideoModule::setAntiAliasingState ( bool  newState  )  throw () [virtual]

Sets the anti-aliasing mode.

Note:
Belongs to the state machine settings.
Parameters:
newState the new anti-aliasing mode, activated if and only if true.

Definition at line 914 of file OSDLVideo.cc.

References _AntiAliasing, and _antiAliasing.

std::string VideoModule::getDriverName (  )  const throw ( VideoException ) [virtual]

Returns the name of the video driver being currently used (example: 'x11').

See also:
GetDriverName
Exceptions:
VideoException if the operation failed.

Definition at line 926 of file OSDLVideo.cc.

References GetDriverName().

virtual void OSDL::Video::VideoModule::setWindowCaption ( const std::string &  newTitle,
const std::string &  iconName 
) throw () [virtual]

Sets the window title and icon name.

Parameters:
newTitle the new window title.
iconName the new icon name.

virtual void OSDL::Video::VideoModule::getWindowCaption ( std::string &  title,
std::string &  iconName 
) throw () [virtual]

Gets the window title and icon name.

Parameters:
title the current window title.
iconName the icon name
Note:
Uses the specified strings to return title and icon.

void VideoModule::setWindowIcon ( const std::string &  filename  )  throw ( VideoException ) [virtual]

Sets the icon for the display window.

Parameters:
filename the name of the file containing the icon. Its format (ex: PNG) should be auto-detected.
Note:
Win32 icons must be 32x32.

This function must be called before the first call to setMode.

The specified surface will have to be deallocated on exit by the user code.

See also:
LoadImage

Definition at line 970 of file OSDLVideo.cc.

References OSDL::Video::Surface::getSDLSurface(), isDisplayInitialized(), OSDL::Video::TwoDimensional::Image::LoadIcon(), and LOG_DEBUG_VIDEO.

bool VideoModule::iconifyWindow (  )  throw () [virtual]

Iconifies (minimizes) the window.

Note:
If the application is running in a window managed environment, this method attempts to iconify (minimise) it. If this call is successful, the application will receive an ApplicationFocus loss event.
Returns:
true on success, false if iconification is not supported or was refused by the window manager.

Definition at line 1031 of file OSDLVideo.cc.

bool VideoModule::getFrameAccountingState (  )  throw () [virtual]

Tells whether frames shoud be monitored to know the frame-per-second (FPS) indicator.

Note:
Belongs to the state machine settings.
Returns:
true if frame accounting mode is set, false otherwise.

Definition at line 1049 of file OSDLVideo.cc.

References _frameAccountingState.

void VideoModule::setFrameAccountingState ( bool  newState  )  throw () [virtual]

Sets the frame-accounting mode.

If activated, the frame rate will be computed.

Note:
Belongs to the state machine settings.
Parameters:
newState the new frame-counting mode, activated if and only if true.

Definition at line 1058 of file OSDLVideo.cc.

References _frameAccountingState.

bool VideoModule::isUsingOpenGL (  )  const throw () [virtual]

Tells whether OpenGL is being used currently by this video module.

Definition at line 1067 of file OSDLVideo.cc.

References hasOpenGLContext().

const string VideoModule::toString ( Ceylan::VerbosityLevels  level = Ceylan::high  )  const throw () [virtual]

Returns an user-friendly description of the state of this object.

Parameters:
level the requested verbosity level.
Note:
Text output format is determined from overall settings.
See also:
Ceylan::TextDisplayable

Definition at line 1076 of file OSDLVideo.cc.

References _openGLcontext, _renderer, _screen, OSDL::Video::OpenGL::OpenGLContext::toString(), OSDL::Rendering::VideoRenderer::toString(), OSDL::Video::Surface::toString(), and OSDL::Video::Pixels::toString().

bool VideoModule::IsDisplayInitialized (  )  throw () [static]

bool VideoModule::GetEndPointDrawState (  )  throw () [static]

Tells whether the last pixel of a segment of line should be drawn.

Note:
This method is static so that calling it is convenient: no need to explicitly retrieve the common module, then the video module, before knowing the result.
The need to retrieve the right module from scratch at each call is rather inefficient though.

Definition at line 1151 of file OSDLVideo.cc.

References _DrawEndPoint, getEndPointDrawState(), OSDL::getExistingCommonModule(), OSDL::CommonModule::getVideoModule(), OSDL::hasExistingCommonModule(), OSDL::CommonModule::hasVideoModule(), and OSDL::Video::Pixels::toString().

bool VideoModule::GetAntiAliasingState (  )  throw () [static]

Tells whether antialiasing is wanted.

Note:
This method is static so that calling it is convenient: no need to explicitly retrieve the common module, then the video module, before knowing the result.
The need to retrieve the right module from scratch at each call is rather inefficient though.

Definition at line 1201 of file OSDLVideo.cc.

References _AntiAliasing, getAntiAliasingState(), OSDL::getExistingCommonModule(), OSDL::CommonModule::getVideoModule(), OSDL::hasExistingCommonModule(), OSDL::CommonModule::hasVideoModule(), and OSDL::Video::Pixels::toString().

Referenced by OSDL::Video::Surface::resize().

string VideoModule::GetDriverName (  )  throw ( VideoException ) [static]

Returns the name of the video driver being currently used (example: 'x11').

See also:
getDriverName.
Exceptions:
VideoException if the operation failed.

Definition at line 1249 of file OSDLVideo.cc.

References DriverNameMaximumLength.

Referenced by getDriverName().

static std::string OSDL::Video::VideoModule::InterpretFlags ( Ceylan::Flags  flags  )  throw () [static]

Describes specified video flags according to the semantics used in setMode.

Note:
One shall not call this method on flags used with a surface. Use Surface::interpretFlags instead, since their meaning is different.
See also:
setMode.

bool VideoModule::HardwareSurfacesCanBeCreated (  )  throw ( VideoException ) [static]

Returns whether hardware surfaces can be created.

Exceptions:
VideoException if the information could not be obtained.

Definition at line 1407 of file OSDLVideo.cc.

Referenced by DescribeVideoCapabilities().

bool VideoModule::WindowManagerAvailable (  )  throw ( VideoException ) [static]

Returns whether there is a window manager available.

Exceptions:
VideoException if the information could not be obtained.

Definition at line 1431 of file OSDLVideo.cc.

Referenced by DescribeVideoCapabilities().

bool VideoModule::HardwareToHardwareBlitsAccelerated (  )  throw ( VideoException ) [static]

Returns whether hardware to hardware blits are accelerated.

Exceptions:
VideoException if the information could not be obtained.

Definition at line 1455 of file OSDLVideo.cc.

Referenced by DescribeVideoCapabilities().

bool VideoModule::HardwareToHardwareColorkeyBlitsAccelerated (  )  throw ( VideoException ) [static]

Returns whether hardware to hardware colorkey blits are accelerated.

Exceptions:
VideoException if the information could not be obtained.

Definition at line 1481 of file OSDLVideo.cc.

Referenced by DescribeVideoCapabilities().

bool VideoModule::HardwareToHardwareAlphaBlitsAccelerated (  )  throw ( VideoException ) [static]

Returns whether hardware to hardware alpha blits are accelerated.

Exceptions:
VideoException if the information could not be obtained.

Definition at line 1508 of file OSDLVideo.cc.

Referenced by DescribeVideoCapabilities().

bool VideoModule::SoftwareToHardwareBlitsAccelerated (  )  throw ( VideoException ) [static]

Returns whether software to hardware blits are accelerated.

Exceptions:
VideoException if the information could not be obtained.

Definition at line 1534 of file OSDLVideo.cc.

Referenced by DescribeVideoCapabilities().

bool VideoModule::SoftwareToHardwareColorkeyBlitsAccelerated (  )  throw ( VideoException ) [static]

Returns whether software to hardware colorkey blits are accelerated.

Exceptions:
VideoException if the information could not be obtained.

Definition at line 1559 of file OSDLVideo.cc.

Referenced by DescribeVideoCapabilities().

bool VideoModule::SoftwareToHardwareAlphaBlitsAccelerated (  )  throw ( VideoException ) [static]

Returns whether software to hardware alpha blits are accelerated.

Exceptions:
VideoException if the information could not be obtained.

Definition at line 1585 of file OSDLVideo.cc.

Referenced by DescribeVideoCapabilities().

bool VideoModule::ColorFillsAccelerated (  )  throw ( VideoException ) [static]

Returns whether color fills are accelerated.

Exceptions:
VideoException if the information could not be obtained.

Definition at line 1612 of file OSDLVideo.cc.

Referenced by DescribeVideoCapabilities().

Ceylan::Uint32 VideoModule::GetVideoMemorySize (  )  throw ( VideoException ) [static]

Returns the total amount of video memory, in kilobytes.

Exceptions:
VideoException if the information could not be obtained.

Definition at line 1638 of file OSDLVideo.cc.

Referenced by DescribeVideoCapabilities().

Pixels::PixelFormat VideoModule::GetVideoDevicePixelFormat (  )  throw ( VideoException ) [static]

Returns the native format of the video device.

Returns:
If the graphics system has already been initialized (using setMode), returns the pixel format of the current video mode, otherwise returns the pixel format of the "best" available video mode.
Exceptions:
VideoException if the information could not be obtained.

Definition at line 1662 of file OSDLVideo.cc.

Referenced by DescribeVideoCapabilities().

string VideoModule::DescribeVideoCapabilities (  )  throw ( VideoException ) [static]

static bool OSDL::Video::VideoModule::AreDefinitionsRestricted ( std::list< Definition > &  definitions,
Ceylan::Flags  flags,
Pixels::PixelFormat pixelFormat = 0 
) throw ( VideoException ) [static]

Tells whether definitions are restricted for the specified flags and pixel format.

Returns:
false if all definitions are possible for the given pixel format, true if dimensions are restricted, and in this case in the specified list (definitions) available dimension pairs are stored, if any.
Parameters:
definitions an empty list in which dimension pairs will be stored, if not all dimensions are allowed for the given pixel format. The list may remain empty, if nothing is available for specified choice.
flags describes the desired screen surface, with the same meaning as the setMode flags.
format,: desired pixel format. If format is null (0), the definition list will correspond to the "best" mode available.
Exceptions:
VideoException if the operation failed or is not supported.

static std::string OSDL::Video::VideoModule::DescribeAvailableDefinitions ( Ceylan::Flags  flags,
Pixels::PixelFormat pixelFormat = 0 
) throw ( VideoException ) [static]

Returns a summary of available screen definitions for specified flags and pixel format.

Parameters: