os/graphics/graphicsresourceservices/graphicsresourceinterface/inc/sgconst.h
changeset 0 bde4ae8d615e
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/os/graphics/graphicsresourceservices/graphicsresourceinterface/inc/sgconst.h	Fri Jun 15 03:10:57 2012 +0200
     1.3 @@ -0,0 +1,59 @@
     1.4 +// Copyright (c) 2007-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 +// Graphics Resource - constants
    1.18 +//
    1.19 +
    1.20 +#ifndef SGCONST_H
    1.21 +#define SGCONST_H
    1.22 +
    1.23 +#include <pixelformats.h>
    1.24 +#include <sgresource/sgerror.h>
    1.25 +
    1.26 +/**
    1.27 +The constants defined in TSgUsageBits correspond to the different usages for which 
    1.28 +an image can be created.  They can be combined using the bitwise OR operator to 
    1.29 +specify more than one usage.
    1.30 +*/
    1.31 +enum TSgUsageBits
    1.32 +	{
    1.33 +	/** Usage as a VGImage with OpenVG via EGLImage.*/
    1.34 +	ESgUsageBitOpenVgImage        = 0x0001,
    1.35 +	/** Usage as a two-dimensional texture with OpenGL ES 1.x via EGLImage.*/
    1.36 +	ESgUsageBitOpenGlesTexture2D  = 0x0002,
    1.37 +	/** Usage as a two-dimensional texture with OpenGL ES 2.x via EGLImage.*/
    1.38 +	ESgUsageBitOpenGles2Texture2D = 0x0004,
    1.39 +	/** Usage as a target of an OpenVG rendering context.*/
    1.40 +	ESgUsageBitOpenVgSurface      = 0x0010,
    1.41 +	/** Usage as a target of an OpenGL ES 1.x rendering context.*/
    1.42 +	ESgUsageBitOpenGlesSurface    = 0x0020,
    1.43 +	/** Usage as a target of an OpenGL ES 2.x rendering context.*/
    1.44 +	ESgUsageBitOpenGles2Surface   = 0x0040,
    1.45 +	/** Usage as a target of an OpenGL rendering context.*/
    1.46 +	ESgUsageBitOpenGlSurface      = 0x0080
    1.47 +	};
    1.48 +
    1.49 +/**
    1.50 +The subset of pixel formats defined in pixelformats.h which are guaranteed to be 
    1.51 +supported by all implementations of the Graphics Resource API.
    1.52 +*/
    1.53 +enum TSgPixelFormat
    1.54 +	{
    1.55 +	ESgPixelFormatARGB_8888_PRE = EUidPixelFormatARGB_8888_PRE,
    1.56 +	ESgPixelFormatARGB_8888     = EUidPixelFormatARGB_8888,
    1.57 +	ESgPixelFormatXRGB_8888     = EUidPixelFormatXRGB_8888,
    1.58 +	ESgPixelFormatRGB_565       = EUidPixelFormatRGB_565,
    1.59 +	ESgPixelFormatA_8           = EUidPixelFormatA_8
    1.60 +	};
    1.61 +
    1.62 +#endif // SGCONST_H