Update contrib.
1 // Copyright (c) 2001-2009 Nokia Corporation and/or its subsidiary(-ies).
2 // All rights reserved.
3 // This component and the accompanying materials are made available
4 // under the terms of "Eclipse Public License v1.0"
5 // which accompanies this distribution, and is available
6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
8 // Initial Contributors:
9 // Nokia Corporation - initial contribution.
16 #include <graphicsaccelerator.h>
19 // Dummy implementation
21 LOCAL_D const TGraphicsAcceleratorCaps SoftwareAcceleratorCapabilities =
23 sizeof(TGraphicsAcceleratorCaps), //TInt iStructureSize; // The size of this class
24 1, //TInt iVersion; // == 1 to specify current API
25 {0}, //Tint iVendorUid; // Optional ID
28 TGraphicsAcceleratorCaps::EMaskBitmapNone, //iMaskType;
35 {0,0,0,0} //iReserved[0] is used for supported orientations, iReserved[1]-iReserved[3] are reserved;
39 Allocates and constructs an instance of a derived class and initialises its
42 @param aBitmap The bitmap for the accelerator to draw to. This may be any
43 type of bitmap, including a hardware bitmap.
44 @return Pointer to the initialised graphics accelerator object.
45 @see TGraphicsAcceleratorCaps::iDisplayModes
46 @leave KErrNoMemory There is no memory to allocate the graphics accelerator
47 KErrNotSupported There is no graphics accelerator supporting the display mode given by the bitmap parameter
49 EXPORT_C CSoftwareGraphicsAccelerator* CSoftwareGraphicsAccelerator::NewL(CFbsBitmap* /*aBitmap*/)
51 User::Leave(KErrNotSupported);
56 Gets the generic capabilities of the accelerator, including which display modes
57 are supported for the bitmap passed to NewL().
59 Generic capabilities apply to all software graphics accelerators on the device.
60 The function is static, so it can be used to find out the capabilities of
61 graphics accelerators before deciding on whether or not to create one.
63 The CGraphicsAccelerator::Capabilities() function provides information about
64 the capabilities of a particular graphics accelerator.
66 As capabilities may vary depending on the display mode of a bitmap, this method
67 should indicate as supported any features which are only available in some
70 @return Generic capabilities for software graphics accelerators.
72 EXPORT_C const TGraphicsAcceleratorCaps* CSoftwareGraphicsAccelerator::GenericCapabilities()
74 return &SoftwareAcceleratorCapabilities;