Main Page   Class Hierarchy   Compound List   File List   Compound Members   File Members

Display Class Reference

Collaboration diagram for Display:

Collaboration graph
[legend]
List of all members.

Detailed Description

The device's physical display area.

It provides access to the physical properties of the area (dimensions, color), and it provides access to the display canvas and the viewport canvas for drawing. It manages the double-buffering functionality for flicker-free drawing.
It also enables the framework to setup the physical display. This functionality is not directly accessible.

Definition at line 84 of file Display.h.

Public Types

enum  Density { DENSITY_SINGLE = 1, DENSITY_DOUBLE = 2 }
 Constants to express the display density. More...


Public Member Functions

Construction / Destruction
 Display () SEC_RAZOR_INIT
 Construct a new Display.

virtual ~Display () SEC_RAZOR_INIT
 Destroy the Display.

void destroy () SEC_RAZOR_INIT
Output management
void beginDrawViewport ()
 Begin drawing into the offscreen viewport.

virtual void endDrawViewport (RectangleType *dirtyRectangle)
 End drawing into the offscreen viewport.

virtual void showViewport ()=0
 Display offscreen viewport.

virtual void captureDisplay () SEC_RAZOR_INIT=0
 Capture the display for use with Razor!

virtual void releaseDisplay () SEC_RAZOR_INIT=0
 Release the display from use by Razor! Make it usable by the OS again.

Physical Display management
virtual void initDisplay (const DisplayProperties &displayProperties) SEC_RAZOR_INIT=0
void initViewport (const ViewportProperties &viewport) SEC_RAZOR_INIT
Canvas management
CanvasgetDisplayCanvas () const SEC_RAZOR
 Get the display canvas.

CanvasgetViewportCanvas () const SEC_RAZOR
 Get the viewport canvas.


Static Public Attributes

UInt16 cols
 The physical width (columns) of the display.

UInt16 rows
 The physical height (rows) of the display.

UInt32 depth
 The depth of the display in bpp.

Density density
 The density of the display as a Density enumeration member.

Boolean colorMode
 Is this a color display?

Boolean directColor
 Is this a direct color (non-palettized) display?


Protected Member Functions

virtual void createViewportCanvas (const ViewportProperties &viewport) SEC_RAZOR_INIT=0
virtual void resetDisplay () SEC_RAZOR_INIT=0
 Set the display back to normal.


Protected Attributes

ViewportProperties viewport
CanvasdisplayCanvas
CanvasviewportCanvas
RectangleType currentBounds
RectangleType lastBounds
RectangleType copyBounds


Member Enumeration Documentation

enum Display::Density
 

Constants to express the display density.

Enumeration values:
DENSITY_SINGLE  a single density display, used by lores devices
DENSITY_DOUBLE  a double density display, used by hires devices

Definition at line 90 of file Display.h.


Constructor & Destructor Documentation

Display::Display  
 

Construct a new Display.

virtual Display::~Display   [virtual]
 

Destroy the Display.


Member Function Documentation

void Display::destroy  
 

void Display::beginDrawViewport  
 

Begin drawing into the offscreen viewport.

virtual void Display::endDrawViewport RectangleType *    dirtyRectangle [virtual]
 

End drawing into the offscreen viewport.

Parameters:
dirtyRectangle the area that was modified by the viewport draw operations. NULL means the entire viewport is dirty.

virtual void Display::showViewport   [pure virtual]
 

Display offscreen viewport.

virtual void Display::captureDisplay   [pure virtual]
 

Capture the display for use with Razor!

virtual void Display::releaseDisplay   [pure virtual]
 

Release the display from use by Razor! Make it usable by the OS again.

virtual void Display::initDisplay const DisplayProperties   displayProperties [pure virtual]
 

void Display::initViewport const ViewportProperties   viewport
 

Canvas* Display::getDisplayCanvas   const
 

Get the display canvas.

Canvas* Display::getViewportCanvas   const
 

Get the viewport canvas.

virtual void Display::createViewportCanvas const ViewportProperties   viewport [protected, pure virtual]
 

virtual void Display::resetDisplay   [protected, pure virtual]
 

Set the display back to normal.


Member Data Documentation

UInt16 Display::cols [static]
 

The physical width (columns) of the display.

Definition at line 163 of file Display.h.

UInt16 Display::rows [static]
 

The physical height (rows) of the display.

Definition at line 168 of file Display.h.

UInt32 Display::depth [static]
 

The depth of the display in bpp.

Definition at line 173 of file Display.h.

Density Display::density [static]
 

The density of the display as a Density enumeration member.

Definition at line 178 of file Display.h.

Boolean Display::colorMode [static]
 

Is this a color display?

Definition at line 183 of file Display.h.

Boolean Display::directColor [static]
 

Is this a direct color (non-palettized) display?

Definition at line 188 of file Display.h.

ViewportProperties Display::viewport [protected]
 

Definition at line 201 of file Display.h.

Canvas* Display::displayCanvas [protected]
 

Definition at line 204 of file Display.h.

Canvas* Display::viewportCanvas [protected]
 

Definition at line 205 of file Display.h.

RectangleType Display::currentBounds [protected]
 

Definition at line 209 of file Display.h.

RectangleType Display::lastBounds [protected]
 

Definition at line 210 of file Display.h.

RectangleType Display::copyBounds [protected]
 

Definition at line 211 of file Display.h.


The documentation for this class was generated from the following file:
Razor! Engine Developer's Guide. Copyright © by Tilo Christ. All Rights Reserved. Last updated: 31 May 2003