MityDSP Documentation Index

MityDSP::tcDspDisplayDriver Class Reference

The tcDspDisplayDriver class is a base class to provide generic access to a display frame buffer via the tcDspFpgaDma class. More...

#include <core/DspDisplayDriver.h>

Inheritance diagram for MityDSP::tcDspDisplayDriver:
MityDSP::tcDspLcd MityDSP::tcDspQvga16

List of all members.

Public Member Functions

 tcDspDisplayDriver (tcDspFpgaDma *apDma=NULL, int anDmaChannel=0)
 This constructor is used to open a tcDspDisplayDriver interface via the specified instance of tcDspFpgaDma and channel.
virtual ~tcDspDisplayDriver ()
 This destructor is used to close up and free the resources tied to the display driver.
virtual int GetWidthPixels (void)
 Retrieves display width in pixels.
virtual int GetHeightPixels (void)
 Retrieves display height in pixels.
virtual int GetDepthBits (void)
 Retrieves display color depth in bits per pixel.
virtual int GetFrameBufferBytes (void)
 Returns the required size of the frame buffer (in bytes).
virtual bool SetFrameBuffer (void *apBuffer)
 Updates the current frame buffer, and initiates DMA transfer from the provided buffer.
virtual void * GetFrameBuffer (void)
 Retrieves the current frame buffer in use.
virtual bool GetScreenEnabled ()
 Returns true if the screen is enabled.
virtual void SetScreenEnabled (bool apEnable)
 Enables/Disables the screen.

Protected Attributes

LCK_Handle mhMutex
 Used to serialize access.
int mnWidthPixels
 Pixel width of display.
int mnHeightPixels
 Pixel height of display.
int mnDepthBits
 Color depth of display.
tcDspFpgaDmampDma
 Pointer to instance of tcDspFpgaDma.
int mnDmaChannel
 DMA channel to use.
void * mpFrameBuffer
 Current frame buffer address.
int mnFrameBufferBytes
 Bytes required in frame buffer.
CACHE_L2Mode msL2Mode
 Cache mode.
bool mbScreenEnabled
 Screen enable.

Detailed Description

The tcDspDisplayDriver class is a base class to provide generic access to a display frame buffer via the tcDspFpgaDma class.

Specific derived classes must be provided for different display geometries and color depths.

See also:
tcDspDisplayDriver Page

Constructor & Destructor Documentation

tcDspDisplayDriver::tcDspDisplayDriver ( tcDspFpgaDma apDma = NULL,
int  anDmaChannel = 0 
)

This constructor is used to open a tcDspDisplayDriver interface via the specified instance of tcDspFpgaDma and channel.

Note:
The derived classes determine the width, height, and depth of the physical device. The width should always be the direction scanned out of the frame buffer first. So a quarter VGA display meant to be mounted vertically would have a width of 240 and a height of 320. Conversely, a horizontal QVGA display would have a width of 320 and a height of 240.
Parameters:
[in] apDma Pointer to an instance of tcDspFpgaDma to use to provide access to the frame buffer.
[in] anDmaChannel The DMA channel in apDma to use.
Returns:
None.
See also:
DspDisplayDriver.h
tcDspDisplayDriver::~tcDspDisplayDriver (  )  [virtual]

This destructor is used to close up and free the resources tied to the display driver.

Returns:
None.
See also:
DspDisplayDriver.h

Member Function Documentation

int tcDspDisplayDriver::GetWidthPixels ( void   )  [virtual]

Retrieves display width in pixels.

Returns:
Width in pixels.
See also:
DspDisplayDriver.h
int tcDspDisplayDriver::GetHeightPixels ( void   )  [virtual]

Retrieves display height in pixels.

Returns:
Height in pixels.
See also:
DspDisplayDriver.h
int tcDspDisplayDriver::GetDepthBits ( void   )  [virtual]

Retrieves display color depth in bits per pixel.

Returns:
Depth in bpp.
See also:
DspDisplayDriver.h
int tcDspDisplayDriver::GetFrameBufferBytes ( void   )  [virtual]

Returns the required size of the frame buffer (in bytes).

Returns:
Required frame buffer size.
See also:
DspDisplayDriver.h
bool tcDspDisplayDriver::SetFrameBuffer ( void *  apBuffer  )  [virtual]

Updates the current frame buffer, and initiates DMA transfer from the provided buffer.

If NULL, DMA is disabled.

Parameters:
[in] apBuffer Pointer to the new frame buffer.
Returns:
True if DMA scheduled (or disabled), false otherwise.
See also:
DspDisplayDriver.h

Reimplemented in MityDSP::tcDspLcd, and MityDSP::tcDspQvga16.

void * tcDspDisplayDriver::GetFrameBuffer ( void   )  [virtual]

Retrieves the current frame buffer in use.

Returns:
Frame buffer pointer (NULL if disabled).
See also:
DspDisplayDriver.h
bool tcDspDisplayDriver::GetScreenEnabled ( void   )  [virtual]

Returns true if the screen is enabled.

Returns:
true if screen is enabled (on)
See also:
DspDisplayDriver.h
void tcDspDisplayDriver::SetScreenEnabled ( bool  apEnable  )  [virtual]

Enables/Disables the screen.

Parameters:
[in] apEnable True to turn on the screen, false to turn it off
See also:
DspDisplayDriver.h

Reimplemented in MityDSP::tcDspLcd.


Member Data Documentation

LCK_Handle MityDSP::tcDspDisplayDriver::mhMutex [protected]

Used to serialize access.

Pixel width of display.

Pixel height of display.

Color depth of display.

Pointer to instance of tcDspFpgaDma.

DMA channel to use.

Current frame buffer address.

Bytes required in frame buffer.

CACHE_L2Mode MityDSP::tcDspDisplayDriver::msL2Mode [protected]

Cache mode.

Screen enable.


  
Generated on Fri Sep 23 16:33:49 2011 for MityDSP Core by  Doxygen Version 1.6.1
Copyright © 2009, Critical Link LLC, All rights reserved.