os/graphics/graphicsresourceservices/graphicsresource/inc/sgconst.h
changeset 0 bde4ae8d615e
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/os/graphics/graphicsresourceservices/graphicsresource/inc/sgconst.h	Fri Jun 15 03:10:57 2012 +0200
     1.3 @@ -0,0 +1,127 @@
     1.4 +// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
     1.5 +// All rights reserved.
     1.6 +// This component and the accompanying materials are made available
     1.7 +// under the terms of "Eclipse Public License v1.0"
     1.8 +// which accompanies this distribution, and is available
     1.9 +// at the URL "http://www.eclipse.org/legal/epl-v10.html".
    1.10 +//
    1.11 +// Initial Contributors:
    1.12 +// Nokia Corporation - initial contribution.
    1.13 +//
    1.14 +// Contributors:
    1.15 +//
    1.16 +// Description:
    1.17 +//
    1.18 +
    1.19 +/**
    1.20 + @file
    1.21 + @publishedPartner
    1.22 + @prototype
    1.23 +*/
    1.24 +
    1.25 +#ifndef SGCONST_H
    1.26 +#define SGCONST_H
    1.27 +
    1.28 +#include <graphics/sgerror.h>
    1.29 +
    1.30 +
    1.31 +/**
    1.32 +@publishedPartner
    1.33 +@prototype
    1.34 +@deprecated
    1.35 +
    1.36 +Identifier of the primary screen, which always exists.
    1.37 +*/
    1.38 +const TInt KSgScreenIdMain = 0;
    1.39 +
    1.40 +
    1.41 +/**
    1.42 +@publishedPartner
    1.43 +@prototype
    1.44 +@deprecated
    1.45 +
    1.46 +Value that specifies, when passed in as screen identifier, that a resource can be
    1.47 +used on all screens.
    1.48 +*/
    1.49 +const TInt KSgScreenIdAny = -1;
    1.50 +
    1.51 +
    1.52 +/**
    1.53 +@publishedPartner
    1.54 +@prototype
    1.55 +@deprecated
    1.56 +
    1.57 +Set of flags that specify how a graphics resource can be used in different rendering
    1.58 +pipelines.
    1.59 +*/
    1.60 +enum TSgUsageFlags
    1.61 +	{
    1.62 +	/** The resource cannot be used in any rendering pipeline. */
    1.63 +	ESgUsageNone = 0,
    1.64 +	/** The resource can be bound as source of DirectGDI rendering. */
    1.65 +	ESgUsageDirectGdiSource = 0x0001,
    1.66 +	/** The resource can be bound as target of DirectGDI rendering. */
    1.67 +	ESgUsageDirectGdiTarget = 0x0002,
    1.68 +	/** The resource can be bound as source of the composition engine. */
    1.69 +	ESgUsageCompositionSource = 0x0004,
    1.70 +	/** The resource can be bound as target of the composition engine. */
    1.71 +	ESgUsageCompositionTarget = 0x0008,
    1.72 +	/** The resource can be used directly as screen contents. */
    1.73 +	ESgUsageScreenSource = 0x0010,
    1.74 +	/** The resource can be bound as OpenGL ES 1.X 2D texture. */
    1.75 +	ESgUsageOpenGlesTexture2D = 0x0020,
    1.76 +	/** The resource can be bound as target of OpenGL ES 1.X rendering. */
    1.77 +	ESgUsageOpenGlesTarget = 0x0040,
    1.78 +	/** The resource can be bound as OpenVG image. */
    1.79 +	ESgUsageOpenVgImage = 0x0080,
    1.80 +	/** The resource can be bound as target of OpenVG rendering. */
    1.81 +	ESgUsageOpenVgTarget = 0x0100,
    1.82 +	/** The resource can be used as destination in calls to eglCopyBuffers(). */
    1.83 +	ESgUsageEglCopyBuffersTarget = 0x0200,
    1.84 +	/** The resource can be bound as OpenGL ES 2.0 2D texture. */
    1.85 +	ESgUsageOpenGles2Texture2D = 0x0400,
    1.86 +	/** The resource can be bound as target of OpenGL ES 2.0 rendering. */
    1.87 +	ESgUsageOpenGles2Target = 0x0800,
    1.88 +	/** The resource can be bound as source of window graphics context rendering. @see CWindowGc */
    1.89 +	ESgUsageWindowGcSource = 0x1000
    1.90 +	};
    1.91 +
    1.92 +
    1.93 +/**
    1.94 +@publishedPartner
    1.95 +@prototype
    1.96 +@deprecated
    1.97 +
    1.98 +Components of TSgCpuAccess. This enumeration is not intended to be used directly, but
    1.99 +provides components for the definition of TSgCpuAccess.
   1.100 +*/
   1.101 +enum TSgCpuAccessComponents
   1.102 +	{
   1.103 +	/** Value of the bit in TSgCpuAccess that indicates ability to read when set. */
   1.104 +	ESgCpuAccessReadable = 1,
   1.105 +	/** Value of the bit in TSgCpuAccess that indicates ability to write when set. */
   1.106 +	ESgCpuAccessWritable = 2
   1.107 +	};
   1.108 +
   1.109 +
   1.110 +/**
   1.111 +@publishedPartner
   1.112 +@prototype
   1.113 +@deprecated
   1.114 +
   1.115 +Enumeration used to specify how a graphics resource can be accessed by the CPU.
   1.116 +*/
   1.117 +enum TSgCpuAccess
   1.118 +	{
   1.119 +	/** The resource cannot be accessed by the CPU. */
   1.120 +	ESgCpuAccessNone = 0,
   1.121 +	/** The resource can only be read by the CPU. */
   1.122 +	ESgCpuAccessReadOnly = ESgCpuAccessReadable,
   1.123 +	/** The resource can only be written by the CPU. */
   1.124 +	ESgCpuAccessWriteOnly = ESgCpuAccessWritable,
   1.125 +	/** The resource can be both read and written by the CPU. */
   1.126 +	ESgCpuAccessReadWrite = ESgCpuAccessReadable | ESgCpuAccessWritable
   1.127 +	};
   1.128 +
   1.129 +
   1.130 +#endif // SGCONST_H