MityDSP Documentation Index
Public Member Functions | Protected Attributes
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]apDmaPointer to an instance of tcDspFpgaDma to use to provide access to the frame buffer.
[in]anDmaChannelThe 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]apBufferPointer 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]apEnableTrue 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.

int MityDSP::tcDspDisplayDriver::mnWidthPixels
protected

Pixel width of display.

int MityDSP::tcDspDisplayDriver::mnHeightPixels
protected

Pixel height of display.

int MityDSP::tcDspDisplayDriver::mnDepthBits
protected

Color depth of display.

tcDspFpgaDma* MityDSP::tcDspDisplayDriver::mpDma
protected

Pointer to instance of tcDspFpgaDma.

int MityDSP::tcDspDisplayDriver::mnDmaChannel
protected

DMA channel to use.

void* MityDSP::tcDspDisplayDriver::mpFrameBuffer
protected

Current frame buffer address.

int MityDSP::tcDspDisplayDriver::mnFrameBufferBytes
protected

Bytes required in frame buffer.

CACHE_L2Mode MityDSP::tcDspDisplayDriver::msL2Mode
protected

Cache mode.

bool MityDSP::tcDspDisplayDriver::mbScreenEnabled
protected

Screen enable.


  
Generated on Mon Apr 22 2013 11:33:03 for MityDSP Core by  Doxygen Version 1.8.1.1
Copyright © 2009, Critical Link LLC, All rights reserved.