epoc32/include/EGL/egltypes.h
branchSymbian3
changeset 4 837f303aceeb
parent 3 e1b950c65cb4
     1.1 --- a/epoc32/include/EGL/egltypes.h	Wed Mar 31 12:27:01 2010 +0100
     1.2 +++ b/epoc32/include/EGL/egltypes.h	Wed Mar 31 12:33:34 2010 +0100
     1.3 @@ -1,9 +1,9 @@
     1.4 -// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
     1.5 +// Copyright (c) 2003-2009 Nokia Corporation and/or its subsidiary(-ies).
     1.6  // All rights reserved.
     1.7  // This component and the accompanying materials are made available
     1.8 -// under the terms of the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members
     1.9 +// under the terms of "Eclipse Public License v1.0"
    1.10  // which accompanies this distribution, and is available
    1.11 -// at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
    1.12 +// at the URL "http://www.eclipse.org/legal/epl-v10.html".
    1.13  //
    1.14  // Initial Contributors:
    1.15  // Nokia Corporation - initial contribution.
    1.16 @@ -11,42 +11,79 @@
    1.17  // Contributors:
    1.18  //
    1.19  // Description:
    1.20 -// GLES/EGLTYPES.H
    1.21 +// EGL/EGLTYPES.H
    1.22  // 
    1.23  //
    1.24  
    1.25 -#ifndef __GLES_EGLTYPES_H_
    1.26 -#define __GLES_EGLTYPES_H_
    1.27 +#ifndef __EGL_EGLTYPES_H__
    1.28 +#define __EGL_EGLTYPES_H__
    1.29 +
    1.30 +#include <e32def.h>
    1.31 +
    1.32 +
    1.33 +#ifndef EGLAPIENTRY
    1.34 +#define EGLAPIENTRY
    1.35 +#endif
    1.36 +
    1.37 +#ifndef EGLAPIENTRYP
    1.38 +#define EGLAPIENTRYP EGLAPIENTRY*
    1.39 +#endif
    1.40 +
    1.41 +#ifndef EGL_APIENTRY
    1.42 +#define EGL_APIENTRY EGLAPIENTRY
    1.43 +#endif
    1.44 +
    1.45 +#ifndef EGLAPI
    1.46 +#define EGLAPI IMPORT_C
    1.47 +#endif
    1.48  
    1.49  
    1.50  /**
    1.51 -@publishedPartner
    1.52 +@publishedAll
    1.53 +@released
    1.54 +*/
    1.55  
    1.56 -__OPENGLESHEADERS_LEGACY_EGL_1_1
    1.57 -    
    1.58 -The purpose of this define is to allow the staged migration to
    1.59 -EGL 1.3 from EGL 1.1 taken from the perspective of OpenGL ES 1.X
    1.60 +/*
    1.61 +** egltypes.h is platform dependent. It defines:
    1.62 +**
    1.63 +**     - EGL types and resources
    1.64 +**     - Native types
    1.65 +**     - EGL and native handle values
    1.66 +**
    1.67 +** EGL types and resources are to be typedef'ed with appropriate platform
    1.68 +** dependent resource handle types. EGLint must be an integer of at least
    1.69 +** 32-bit.
    1.70 +**
    1.71 +** NativeDisplayType, NativeWindowType and NativePixmapType are to be
    1.72 +** replaced with corresponding types of the native window system in egl.h.
    1.73 +**
    1.74 +** EGL and native handle values must match their types.
    1.75 +**
    1.76 +*/
    1.77  
    1.78 -If __OPENGLESHEADERS_LEGACY_EGL_1_1 is defined, then GLES/egl.h and
    1.79 -GLES/egltypes.h will only provide the EGL 1.1 API; in particular no
    1.80 -symbols from a later version of EGL will be seen at a source code level.
    1.81 -This is considered to be legacy behaviour.  If
    1.82 -__OPENGLESHEADERS_LEGACY_EGL_1_1 is not defined, the GLES/egl.h
    1.83 -and GLES/egltypes.h header files will re-direct to the system-wide
    1.84 -EGL/egl.h. and EGL/egltypes.h respectively.
    1.85  
    1.86 -The use of GLES/egl.h or GLES/egltypes.h by applications is considered
    1.87 -legacy behaviour because applications should instead use EGL/egl.h
    1.88 -or EGL/egltypes.h respectively.
    1.89 +typedef int EGLBoolean;
    1.90 +typedef int EGLint;
    1.91 +typedef int EGLenum;
    1.92  
    1.93 -When this legacy behaviour is desired, the define should be placed in an
    1.94 -OEM-specific system-wide .hrh file.  Symbian product configurations
    1.95 -never set this legacy behaviour.
    1.96 -*/
    1.97 -#ifdef __OPENGLESHEADERS_LEGACY_EGL_1_1
    1.98 -#include <GLES/legacy_egl_1_1/egltypes.h>
    1.99 -#else
   1.100 -#include <EGL/egltypes.h>
   1.101 -#endif
   1.102 +typedef int EGLDisplay;
   1.103 +typedef int EGLConfig;
   1.104 +typedef int EGLSurface;
   1.105 +typedef int EGLContext;
   1.106 +typedef int EGLClientBuffer;
   1.107  
   1.108 -#endif /* __GLES_EGLTYPES_H_ */
   1.109 +typedef int    NativeDisplayType;
   1.110 +typedef void*  NativeWindowType;
   1.111 +typedef void*  NativePixmapType;
   1.112 +
   1.113 +/* EGL 1.2 types, renamed for consistency in EGL 1.3 */
   1.114 +typedef NativeDisplayType EGLNativeDisplayType;
   1.115 +typedef NativePixmapType EGLNativePixmapType;
   1.116 +typedef NativeWindowType EGLNativeWindowType;
   1.117 +
   1.118 +#define EGL_DEFAULT_DISPLAY 0
   1.119 +#define EGL_NO_CONTEXT 0
   1.120 +#define EGL_NO_DISPLAY 0
   1.121 +#define EGL_NO_SURFACE 0
   1.122 +
   1.123 +#endif // __EGL_EGLTYPES_H__