Symbian
Symbian Developer Library

SYMBIAN OS V9.4

Feedback

[Index] [Previous] [Next]

#include <GraphicsAccelerator.h>
Link against: _lubbock_scdv.lib

Class CHardwareGraphicsAccelerator

class CHardwareGraphicsAccelerator : public CGraphicsAccelerator;

Description

A factory for creating 2D graphics accelerator objects whose graphics operations are implemented in hardware, software or a mixture of both.

Objects of derived classes can only write to hardware bitmaps (RHardwareBitmap). Note that graphics accelerators may support only a subset of all graphics operations.

Derivation

Members

Defined in CHardwareGraphicsAccelerator:

Inherited from CBase:

See also:


Construction and destruction


NewL(RHardwareBitmap)

IMPORT_C static CHardwareGraphicsAccelerator* NewL(RHardwareBitmap aBitmap);

Description

Create a new CHardwareGraphicsAccelerator for use with a given hardware bitmap.

Do not use, link against scdv.lib.

Parameters

RHardwareBitmap aBitmap

A bitmap that can be drawn by graphics acceleration hardware. It can be any bitmap.

Return value

CHardwareGraphicsAccelerator *

Reference to hardware graphics accelerator object.

[Top]


Member functions


GenericCapabilities()

IMPORT_C static const TGraphicsAcceleratorCaps* GenericCapabilities();

Description

Gets the generic capabilities of the accelerator, including the supported display modes for the bitmap passed to CHardwareGraphicsAccelerator::NewL(RHardwareBitmap).

Do not use, link against scdv.lib.

Return value

const TGraphicsAcceleratorCaps *

Generic capabilities for software graphics accelerators.


Capabilities()

virtual const TGraphicsAcceleratorCaps* Capabilities()=0;

Description

Returns the capabilities of the graphics accelerator.

Return value

const TGraphicsAcceleratorCaps *

The capabilities of the accelerator.


Operation(const TGraphicsOperation &)

virtual TInt Operation(const TGraphicsOperation &aOperation)=0;

Description

Requests the graphics accelerator to perform a single graphics operation.

Parameters

const TGraphicsOperation &aOperation

An instance of a TGraphicsOperation-derived class that identifies the graphics operation to be performed.

Return value

TInt

KErrNone if successful, otherwise one of the system error codes. The function should return KErrNotSupported if the accelerator does not support the requested operation.


Operation(const TGraphicsOperation &,TInt,TRect *)

virtual TInt Operation(const TGraphicsOperation &aOperation, TInt aNumClipRects, TRect *aClipRects)=0;

Description

Requests the graphics accelerator perform a single graphics operation within a clipping region. This version is of CHardwareGraphicsAccelerator::Operation(const TGraphicsOperation &) is only usable if the accelerator capabilities returned by CHardwareGraphicsAccelerator::Capabilities() indicate that clipping to a region is supported.

Parameters

const TGraphicsOperation &aOperation

An instance of a TGraphicsOperation-derived class that identifies the graphics operation to be performed.

TInt aNumClipRects

The number of rectangles in the clipping region.

TRect *aClipRects

A pointer to the first rectangle in the clipping region.

Return value

TInt

KErrNone if successful, otherwise one of the system error codes. The function should return KErrNotSupported if the accelerator does not support the requested operation.

See also:


Operation(TDes8 &)

virtual TInt Operation(TDes8 &aBuffer)=0;

Description

Requests the graphics accelerator perform one or more graphics operations contained in a buffer.

The underlying implementation may be able to process a group of graphics operations more efficiently than if CHardwareGraphicsAccelerator::Operation(const TGraphicsOperation &) was called for each individually.

This function should be implemented as if CHardwareGraphicsAccelerator::Operation(const TGraphicsOperation &) was called in turn for each operation contained in the buffer. Each operation should be carried out immediately after the one preceding it. If a method returns an error, the length of aBuffer should be set to indicate the number of operations that have been successfully processed. In this case, the operation in which the error occurred will be indicated by the memory address &aBuffer[aBuffer.Length()].

Parameters

TDes8 &aBuffer

A descriptor which holds a concatenation of graphics operations (TGraphicsOperation-derived objects).

Return value

TInt

KErrNone if successful, otherwise one of the system error codes. The function should return KErrNotSupported if the accelerator does not support any of the requested operations.


Operation(TDes8 &,TInt,TRect *)

virtual TInt Operation(TDes8 &aBuffer, TInt aNumClipRects, TRect *aClipRects)=0;

Description

Requests the graphics accelerator perform one or more graphics operations within a clipping region. This version is of CHardwareGraphicsAccelerator::Operation(const TGraphicsOperation &) is only usable if the accelerator capabilities returned by CHardwareGraphicsAccelerator::Capabilities() indicate that clipping to a region is supported.

The underlying implementation may be able to process a group of graphics operations more efficiently than if CHardwareGraphicsAccelerator::Operation(const TGraphicsOperation &) was called for each individually.

This function should be implemented as if CHardwareGraphicsAccelerator::Operation(const TGraphicsOperation &) was called in turn for each operation contained in the buffer. Each operation should be carried out immediately after the one preceding it. If a method returns an error, the length of aBuffer should be set to indicate the number of operations that have been successfully processed. In this case, the operation in which the error occurred will be indicated by the memory address &aBuffer[aBuffer.Length()].

Parameters

TDes8 &aBuffer

A descriptor which holds a concatenation of graphics operations (TGraphicsOperation objects).

TInt aNumClipRects

The number of rectangles in the clipping region.

TRect *aClipRects

A pointer to the first rectangle in the clipping region.

Return value

TInt

KErrNone if successful, otherwise one of the system error codes. The function should return KErrNotSupported if the accelerator does not support any of the requested operations.

See also:


Reserved_1()

virtual void Reserved_1()=0;

Description


Reserved_2()

virtual void Reserved_2()=0;

Description


Reserved_3()

virtual void Reserved_3()=0;

Description


Reserved_4()

virtual void Reserved_4()=0;

Description