opengles/openglesinterface/documentation/implementers_guide.html
branchRCL_3
changeset 20 25ffed67c7ef
parent 0 5d03bc08d59c
equal deleted inserted replaced
19:bbf46f59e123 20:25ffed67c7ef
       
     1 <html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"><title>Khronos API Implementers' Guidelines</title><link rel="stylesheet" href="igstyle.css" type="text/css"><meta name="generator" content="DocBook XSL Stylesheets V1.69.1"><meta name="description" content="Guidelines to be followed by implementers of Khronos Group
       
     2 		APIs"><style type="text/css">
       
     3 body { background-image: url('draft.png');
       
     4        background-repeat: no-repeat;
       
     5        background-position: top left;
       
     6        /* The following properties make the watermark "fixed" on the page. */
       
     7        /* I think that's just a bit too distracting for the reader... */
       
     8        /* background-attachment: fixed; */
       
     9        /* background-position: center center; */
       
    10      }</style></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="article" lang="en"><div class="titlepage"><div><div><h1 class="title"><a name="id4739083"></a>Khronos API Implementers' Guidelines</h1></div><div><div class="authorgroup"><h4 class="editedby">Edited by</h4><h3 class="editor"><span class="firstname">Mark</span> <span class="surname">Callow</span></h3><div class="affiliation"><span class="orgname">HI Corporation<br></span></div><code class="email">&lt;<a href="mailto:callow_mark%20at%20hicorp.co.jp">callow_mark at hicorp.co.jp</a>&gt;</code><p></p></div></div><div><p class="copyright">Copyright © 2007 The Khronos Group Inc.</p></div><div><div class="legalnotice"><a name="legal"></a><p>This document is protected by copyright laws and contains
       
    11 		material proprietary to the Khronos Group, Inc. It or any components
       
    12 		may not be reproduced, republished, distributed, transmitted,
       
    13 		displayed, broadcast or otherwise exploited in any manner without
       
    14 		the express prior written permission of Khronos Group.
       
    15 	   	The receipt or possession of this
       
    16 		document does not convey any rights to reproduce, disclose, or
       
    17 		distribute its contents, or to manufacture, use, or sell anything
       
    18 	   	that it may describe, in whole or in part.</p><p>Khronos Group grants express permission to any current Promoter,
       
    19 		Contributor or Adopter member of Khronos to copy and redistribute
       
    20 		UNMODIFIED versions of this document in any fashion, provided
       
    21 		that NO CHARGE is made for the document and the latest available
       
    22 		update of the document is used whenever possible.
       
    23 	   	Such distributed document may be
       
    24 		re-formatted AS LONG AS the contents of the document are not
       
    25 		changed in any way.  The document may be incorporated into a
       
    26 		product that is sold as long as such product includes significant
       
    27 		independent work developed by the seller. A link to the current
       
    28 		version of this document on the Khronos Group web-site should
       
    29 		be included whenever possible with document distributions.</p><p>Khronos Group makes no, and expressly disclaims any,
       
    30 		representations or warranties, express or implied, regarding this
       
    31 		document, including, without limitation, any implied warranties
       
    32 		of merchantability or fitness for a particular purpose or
       
    33 		non-infringement of any intellectual property. Khronos Group makes
       
    34 		no, and expressly disclaims any, warranties, express or implied,
       
    35 		regarding the correctness, accuracy, completeness, timeliness, and
       
    36 		reliability of the document. Under no circumstances will the Khronos
       
    37 		Group, or any of its Promoters, Contributors or Members or their
       
    38 		respective partners, officers, directors, employees, agents or
       
    39 		representatives be liable for any damages, whether direct, indirect,
       
    40 		special or consequential damages for lost revenues, lost profits,
       
    41 		or otherwise, arising from or in connection with these
       
    42 		materials.</p><p><span class="trademark">Khronos</span>™ is a trademark of
       
    43 		The Khronos Group Inc. <span class="trademark">OpenGL</span>®
       
    44 		is a registered trademark, and
       
    45 		<span class="trademark">OpenGL ES</span>™is a trademark, of
       
    46 		Silicon Graphics, Inc.</p></div></div><div><div class="revhistory"><table border="1" width="100%" summary="Revision history"><tr><th align="left" valign="top" colspan="3"><b>Revision History</b></th></tr><tr><td align="left">Revision 0.9.0</td><td align="left">2006-12-08 19:15:11 -0800</td><td align="left">msc</td></tr><tr><td align="left" colspan="3">First docbook version</td></tr><tr><td align="left">Revision 0.91.0</td><td align="left">2006-12-12 17:26:03 -0800</td><td align="left">msc</td></tr><tr><td align="left" colspan="3">Public review version: amended copyright notice; changed OpenKODE and GLES utility library names.</td></tr></table></div></div><div><div class="abstract"><p class="title"><b>Abstract</b></p><p>Guidelines to be followed by implementers of Khronos Group
       
    47 		<em class="glossterm">APIs</em></p></div></div></div><hr></div><div class="toc"><p><b>Table of Contents</b></p><dl><dt><span class="section"><a href="#introduction">Introduction</a></span></dt><dt><span class="section"><a href="#generalguidelines">General Guidelines </a></span></dt><dd><dl><dt><span class="section"><a href="#controlled">Vendor Controlled Platforms (e.g. BREW, SymbianOS)</a></span></dt><dt><span class="section"><a href="#uncontrolled">Uncontrolled Platforms (e.g. GNU/Linux, Windows, Windows CE)</a></span></dt></dl></dd><dt><span class="section"><a href="#id4787332">Acknowledgements</a></span></dt><dt><span class="glossary"><a href="#id4787444">Glossary</a></span></dt></dl></div><div class="list-of-tables"><p><b>List of Tables</b></p><dl><dt>1. <a href="#id4713194">Header File Names and Locations</a></dt><dt>2. <a href="#id4786950">Recommended Library Names</a></dt></dl></div><div class="section" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="introduction"></a>Introduction</h2></div></div></div><p> This document provides guidelines for
       
    48 	  <a href="#gls_implementer"><em class="firstterm">implementers
       
    49 	  </em></a>
       
    50 	  of OpenGL ES, OpenVG and other <a href="#gls_api"><em class="firstterm">API</em></a>
       
    51 	  standards specified by the Khronos Group.
       
    52 	  The aim of these hints is to provide commonality between implementations to 
       
    53 	  ease the logistical problems faced by developers using multiple different 
       
    54 	  implementations of an <em class="glossterm">API</em>.
       
    55    	</p><p> One of the primary goals is to allow an application binary to run 
       
    56 	  on top of multiple different OpenGL ES / OpenVG / EGL implementations 
       
    57 	  on the same platform. </p><p> Implementers are strongly urged to comply with these guidelines. 
       
    58 	</p></div><div class="section" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="generalguidelines"></a>General Guidelines </h2></div></div></div><div class="section" lang="en"><div class="titlepage"><div><div><h3 class="title"><a name="controlled"></a>Vendor Controlled Platforms (e.g. BREW, SymbianOS)</h3></div></div></div><p> Implementers should follow the linkage specifications established 
       
    59 		by the
       
    60 		<a href="#gls_vendor"><em class="firstterm">platform vendor</em></a>
       
    61 		.
       
    62 	  </p><div class="itemizedlist"><ul type="opencircle"><li style="list-style-type: circle"><p> Use the header files, (e.g., for OpenGL ES, gl.h &amp; egl.h) 
       
    63 			provided by the platform vendor. </p></li><li style="list-style-type: circle"><p> Use the function names specified in those header files. </p></li><li style="list-style-type: circle"><p>Implement all <em class="glossterm">API</em>
       
    64 			entry points in the same way as in the
       
    65 			<em class="glossterm">vendor</em>-provided
       
    66 			<a href="#gls_abi"><em class="firstterm">ABI</em></a>. That is,
       
    67 			functions should be functions, in-line functions should be
       
    68 			in-line functions and macros should be macros.
       
    69 		  </p></li><li style="list-style-type: circle"><p> Use the platform specified library names. </p></li></ul></div><p>Vendors of controlled platforms are strongly urged to follow the
       
    70 		recommendations given below for <a href="#uncontrolled" title="Uncontrolled Platforms (e.g. GNU/Linux, Windows, Windows CE)">
       
    71 		Uncontrolled Platforms</a> when adding a Khronos Group
       
    72 	    <em class="glossterm">API</em> to their platform.
       
    73 	  </p></div><div class="section" lang="en"><div class="titlepage"><div><div><h3 class="title"><a name="uncontrolled"></a>Uncontrolled Platforms (e.g. GNU/Linux, Windows, Windows CE)</h3></div></div></div><p> When providing implementations for platforms where the vendor 
       
    74 		does not provide standard linkage specifications, implementers
       
    75 		are urged to follow the following recommendations.</p><div class="section" lang="en"><div class="titlepage"><div><div><h4 class="title"><a name="headerfiles"></a> Header Files </h4></div></div></div><div class="section" lang="en"><div class="titlepage"><div><div><h5 class="title"><a name="hfgeneral"></a>General</h5></div></div></div><div class="itemizedlist"><ul type="disc"><li><p>Use the Khronos provided header files (e.g., for OpenGL 
       
    76 				ES, <code class="filename">gl.h</code> &amp;
       
    77 				<code class="filename">egl.h</code>). If changes are
       
    78 				unavoidable, consider contributing your changes back to Khronos
       
    79 				by updating the standard header files in the Khronos Subversion
       
    80 				tree. </p></li><li><p> If you make your own header files and the platform is 
       
    81 				Windows, make sure they are suitable for use with
       
    82 				<a href="#gls_mfc"><em class="firstterm"><span class="acronym">MFC</span></em></a>.
       
    83 			   	For example 
       
    84 				<code class="code">#define EGL_DEFAULT_DISPLAY GetDC(0)</code>
       
    85 				is broken for MFC. You need to use 
       
    86 				<code class="code">::GetDC(0)</code>
       
    87 				because several MFC have their own 
       
    88 				<code class="code">GetDC(void)</code>
       
    89 				methods.</p></li></ul></div></div><div class="section" lang="en"><div class="titlepage"><div><div><h5 class="title"><a name="hfegl"></a>EGL</h5></div></div></div><div class="itemizedlist"><ul type="disc"><li><p> Package the EGL header files 
       
    90 				<code class="filename">egl.h</code>
       
    91 				and
       
    92 				<code class="filename">eglplatform.h</code>
       
    93 				in the folder 
       
    94 				<code class="filename">EGL</code>.
       
    95 			  </p></li><li><p> <code class="filename">eglplatform.h</code>
       
    96 			   	contains platform
       
    97 				dependent items and needs to be modified by the implementer.
       
    98 				In particular the
       
    99 				<span class="type">eglNativeDisplayType</span>, 
       
   100 				<span class="type">eglNativeWindowType</span>, and 
       
   101 				<span class="type">eglNativePixmapType</span>
       
   102 				typedefs must be defined as appropriate for the platform
       
   103 				(typically, they will be typedef'ed to corresponding types
       
   104 				in the native window system). Developer documentation should
       
   105 				mention the correspondence so that developers know what
       
   106 			   	parameters to pass to 
       
   107 				<code class="function">eglCreateWindowSurface</code>, 
       
   108 				<code class="function">eglCreatePixmapSurface</code>, and 
       
   109 				<code class="function">eglCopyBuffers</code>.
       
   110 			   	Documentation should also describe the format of the 
       
   111 				<em class="parameter"><code>display_id</code></em>
       
   112 				parameter to 
       
   113 				<code class="function">eglGetDisplay</code>,
       
   114 			   	since this is a platform-specific identifier.</p></li><li><p> Include 
       
   115 				<code class="filename">eglplatform.h</code>
       
   116 				in 
       
   117 				<code class="filename">egl.h</code>
       
   118 				thus: 
       
   119 				<code class="code">#include &lt;EGL/eglplatform.h&gt;</code>
       
   120 				. Do not use 
       
   121 				<code class="code">#include &lt;eglplatform.h&gt;</code>
       
   122 				because app. makefiles will then need 2 different 
       
   123 				<em class="parameter"><code>-I&lt;path&gt;</code></em>
       
   124 				options to find both include files. </p></li><li><p> Do not include 
       
   125 				<code class="filename">gl.h</code>
       
   126 				in 
       
   127 				<code class="filename">egl.h</code>
       
   128 				. </p></li></ul></div></div><div class="section" lang="en"><div class="titlepage"><div><div><h5 class="title"><a name="hfgles1x"></a> OpenGL ES 1.x </h5></div></div></div><div class="itemizedlist"><ul type="disc"><li><p> Package the OpenGL ES header files 
       
   129 				<code class="filename">gl.h</code>
       
   130 				and 
       
   131 				<code class="filename">glplatform.h</code>
       
   132 				in the folder 
       
   133 				<code class="filename">GLES</code>
       
   134 				.  </p></li><li><p> <code class="filename">glplatform.h</code>
       
   135 				contains platform dependent items and may need to be
       
   136 				modified by the implementer. Implementers are encouraged
       
   137 				to provide their additions for newly supported platforms
       
   138 				to the Khronos Group for inclusion in the Adopters'
       
   139 				distribution.</p></li><li><p> For compatibility with GLES 1.0 implementations, include 
       
   140 				in 
       
   141 				<code class="filename">GLES</code>
       
   142 				a special 
       
   143 				<code class="filename">egl.h</code>
       
   144 				containing the following: 
       
   145 				</p><div class="informalexample"><pre class="programlisting">
       
   146 #include &lt;EGL/egl.h&gt;
       
   147 #include &lt;GLES/gl.h&gt;</pre></div><p>
       
   148 				This is because many early OpenGL ES 1.0 implementations
       
   149 				included 
       
   150 				<code class="filename">gl.h</code>
       
   151 				in 
       
   152 				<code class="filename">egl.h</code>
       
   153 				so many existing applications only include 
       
   154 				<code class="filename">egl.h</code>
       
   155 				. </p></li><li><p>The name <code class="filename">glu.h</code>
       
   156 				is reserved for future use by the Khronos Group.</p></li></ul></div></div><div class="section" lang="en"><div class="titlepage"><div><div><h5 class="title"><a name="hfgles2x"></a> OpenGL ES 2.x </h5></div></div></div><div class="itemizedlist"><ul type="disc"><li><p>The core header files for OpenGL ES 2.x are called
       
   157 			   	<code class="filename">gl2.h</code> and
       
   158 			    <code class="filename">gl2platform.h</code> to
       
   159 			    keep them distinct from the GLES 1.x header files and enable
       
   160 			    application to use both versions.</p></li><li><p>The function declarations and constant definitions for
       
   161 			   	OpenGL ES 2.x are divided into 2 header files: 
       
   162 			    <code class="filename">gl2.h</code>
       
   163 			    declares and defines all the core functions and constants; 
       
   164 			    <code class="filename">gl2ext.h</code>
       
   165 				declares and defines functions and constants for all
       
   166 				Khronos approved extensions and can be used even if the
       
   167 				implementation doesn't provide a particular extension.</p><p>Functions and constants for Implementer
       
   168 				extensions should be declared and defined in an implementer's
       
   169 				own header file using names and constant values obtained from
       
   170 				the Khronos Group's Extension Registry.</p></li><li><p>Package all these header files in the folder
       
   171 			    <code class="filename">GLES2</code>.</p></li><li><p>The name <code class="filename">glu2.h</code>
       
   172 				is reserved for future use by the Khronos Group.</p></li></ul></div></div><div class="section" lang="en"><div class="titlepage"><div><div><h5 class="title"><a name="hfopenkode"></a>OpenKODE</h5></div></div></div><div class="itemizedlist"><ul type="disc"><li><p>Package the OpenKODE header files 
       
   173 		        <code class="filename">kd.h</code>
       
   174 		        and
       
   175 		        <code class="filename">kdplatform.h</code>
       
   176 		        in the folder 
       
   177 				<code class="filename">KD</code>.
       
   178 			  </p></li><li><p>Implementers are encouraged to code
       
   179 				<code class="filename">kd.h</code> such that it
       
   180 				includes as few as possible of the platform's include files,
       
   181 				and to avoid declaring C and POSIX standard functions. This
       
   182 				will ease the creation of portable OpenKODE applications,
       
   183 			   	and help stop non-portable code being added accidentally.
       
   184 			  </p></li></ul></div></div><div class="section" lang="en"><div class="titlepage"><div><div><h5 class="title"><a name="hfopenvg"></a>OpenVG</h5></div></div></div><div class="itemizedlist"><ul type="disc"><li><p>Package the OpenVG header files 
       
   185 		        <code class="filename">openvg.h</code>
       
   186 		        and, when provided, 
       
   187 		        <code class="filename">vgu.h</code>
       
   188 		        in the folder 
       
   189 		        <code class="filename">VG</code>
       
   190 				.</p></li></ul></div></div><div class="section" lang="en"><div class="titlepage"><div><div><h5 class="title"><a name="hfsummary"></a>Header File Summary</h5></div></div></div><div class="table"><a name="id4713194"></a><p class="title"><b>Table 1. Header File Names and Locations</b></p><table summary="Header File Names and Locations" border="1"><colgroup><col align="left"><col align="left"><col align="left"><col align="left"><col align="left"></colgroup><thead><tr><th align="left"> API </th><th align="left"> Location </th><th align="left"> Header Files </th><th align="left"> How to include </th><th align="left"> Provider </th></tr></thead><tbody><tr><td rowspan="2" align="left" valign="top"> EGL 1.x </td><td rowspan="2" align="left" valign="top"> 
       
   191 					<code class="filename">EGL</code>
       
   192 				  </td><td align="left"> 
       
   193 					<code class="filename">egl.h</code>
       
   194 				  </td><td align="left"> 
       
   195 					<code class="code">#include &lt;EGL/egl.h&gt;</code>
       
   196 				  </td><td align="left">
       
   197 					Khronos
       
   198 				  </td></tr><tr><td align="left"> 
       
   199 					<code class="filename">eglplatform.h</code>
       
   200 					<sup>[<a name="id4713330" href="#ftn.id4713330">1</a>]</sup>
       
   201 				  </td><td align="left"> 
       
   202 					Included by <code class="filename">egl.h</code>
       
   203 				  </td><td align="left">
       
   204 					Vendor or Implementer
       
   205 				  </td></tr><tr><td rowspan="3" align="left" valign="top"> OpenGL ES 1.x </td><td rowspan="3" align="left" valign="top"> 
       
   206 					<code class="filename">GLES</code>
       
   207 				  </td><td align="left"> 
       
   208 					<code class="filename">gl.h</code>
       
   209 				  </td><td align="left"> 
       
   210 					<code class="code">#include &lt;GLES/gl.h&gt;</code>
       
   211 				  </td><td align="left">
       
   212 					Khronos
       
   213 				  </td></tr><tr><td align="left"> 
       
   214 					<code class="filename">glplatform.h</code>
       
   215 					<sup>[<a name="id4713439" href="#ftn.id4713439">2</a>]</sup>
       
   216 				  </td><td align="left"> 
       
   217 					Included by <code class="filename">gl.h</code>
       
   218 				  </td><td align="left">
       
   219 					Vendor or Implementer
       
   220 				  </td></tr><tr><td align="left">
       
   221 					<code class="filename">glu.h</code>
       
   222 				  </td><td colspan="2" align="center">
       
   223 					Reserved for future use
       
   224 				  </td></tr><tr><td rowspan="4" align="left" valign="top"> OpenGL ES 2.x </td><td rowspan="4" align="left" valign="top"> 
       
   225 					<code class="filename">GLES2</code>
       
   226 				  </td><td align="left"> 
       
   227 					<code class="filename">gl2.h</code>
       
   228 				  </td><td align="left"> 
       
   229 					<code class="code">#include &lt;GLES2/gl2.h&gt;</code>
       
   230 				  </td><td align="left">
       
   231 					Khronos
       
   232 				  </td></tr><tr><td align="left"> 
       
   233 					<code class="filename">gl2platform.h</code>
       
   234 				  </td><td align="left"> 
       
   235 					Included by <code class="filename">gl2.h</code>
       
   236 				  </td><td align="left">
       
   237 					Vendor or Implementer
       
   238 				  </td></tr><tr><td align="left"> 
       
   239 					<code class="filename">gl2ext.h</code>
       
   240 				  </td><td align="left"> 
       
   241 					<code class="code">#include &lt;GLES2/gl2ext.h&gt;</code>
       
   242 				  </td><td align="left">
       
   243 					Khronos
       
   244 				  </td></tr><tr><td align="left">
       
   245 					<code class="filename">glu2.h</code>
       
   246 				  </td><td colspan="2" align="center">
       
   247 					Reserved for future use
       
   248 				  </td></tr><tr><td rowspan="2" align="left" valign="top"> OpenKODE 1.x </td><td rowspan="2" align="left" valign="top"> 
       
   249 					<code class="filename">KD</code>
       
   250 				  </td><td align="left"> 
       
   251 					<code class="filename">kd.h</code>
       
   252 				  </td><td align="left"> 
       
   253 					<code class="code">#include &lt;KD/kd.h&gt;</code>
       
   254 				  </td><td align="left">
       
   255 					Khronos
       
   256 				  </td></tr><tr><td align="left"> 
       
   257 					<code class="filename">kdplatform.h</code>
       
   258 				  </td><td align="left"> 
       
   259 					Included by <code class="filename">kd.h</code>
       
   260 				  </td><td align="left">
       
   261 					Vendor or Implementer
       
   262 				  </td></tr><tr><td rowspan="2" align="left" valign="top"> OpenVG 1.x </td><td rowspan="2" align="left" valign="top"> 
       
   263 					<code class="filename">VG</code>
       
   264 				  </td><td align="left"> 
       
   265 					<code class="filename">openvg.h</code>
       
   266 				  </td><td align="left"> 
       
   267 					<code class="code">#include &lt;VG/openvg.h&gt;</code>
       
   268 				  </td><td align="left">
       
   269 					Khronos
       
   270 				  </td></tr><tr><td align="left"> 
       
   271 					<code class="filename">vgu.h</code>
       
   272 					<sup>[<a name="id4786686" href="#ftn.id4786686">3</a>]</sup>
       
   273 				  </td><td align="left"> 
       
   274 					<code class="code">#include &lt;VG/vgu.h&gt;</code>
       
   275 				  </td><td align="left">
       
   276 					Khronos
       
   277 				  </td></tr></tbody></table><div class="footnotes"><div class="footnote"><p><sup>[<a name="ftn.id4713330" href="#id4713330">1</a>] </sup>
       
   278 						Many early EGL implementations used
       
   279 						<code class="filename">egltypes.h</code>
       
   280 						instead of the now recommended
       
   281 						<code class="filename">eglplatform.h</code>
       
   282 						.</p></div><div class="footnote"><p><sup>[<a name="ftn.id4713439" href="#id4713439">2</a>] </sup>
       
   283 						<code class="filename">glplatform.h</code>
       
   284 						does not exist in many early implementations of
       
   285 						OpenGL ES 1.x. Platform dependent declarations were
       
   286 						included directly in <code class="filename">gl.h
       
   287 					  </code>.</p></div><div class="footnote"><p><sup>[<a name="ftn.id4786686" href="#id4786686">3</a>] </sup>
       
   288 						Required, if the OpenVG utility library is provided.
       
   289 					  </p></div></div></div></div><div class="section" lang="en"><div class="titlepage"><div><div><h5 class="title"><a name="notes"></a>Notes </h5></div></div></div><div class="itemizedlist"><ul type="disc"><li><p>To find the include files, use appropriate compiler 
       
   290 			  options in the makefiles for your sample programs; e.g.
       
   291 			  <em class="parameter"><code>-I</code></em> (gcc, linux) or
       
   292 			  <em class="parameter"><code>/I</code></em> (Visual C++).
       
   293 			</p></li><li><p>Given the different IDEs &amp; compilers people use, 
       
   294 			  especially on Windows, it is not possible to recommend a system 
       
   295 			  location to place these include files. Where obvious choices 
       
   296 			  exist Khronos recommends implementers take advantage of them. 
       
   297 			</p></li><li><p>In particular, GNU/Linux implementations should
       
   298 			  follow the 
       
   299 			  <a href="http://www.pathname.com/fhs/" target="_top"> 
       
   300 				<em class="citetitle">Filesystem Hierarchy Standard</em>
       
   301 			  </a>
       
   302 			  for location of headers and libraries. 
       
   303 			</p></li></ul></div></div></div><div class="section" lang="en"><div class="titlepage"><div><div><h4 class="title"><a name="libraries"></a>Libraries</h4></div></div></div><div class="itemizedlist"><ul type="disc"><li><p>It is highly desirable to implement all
       
   304 			  <em class="glossterm">API</em> entry points as
       
   305 			  function calls. However in the OpenKODE core, macros or in-lines
       
   306 			  may be used instead of a function call provided the following
       
   307 			  rules are followed:
       
   308 			</p><div class="itemizedlist"><ul type="circle"><li><p>When calling a function, each argument must be evaluated
       
   309 				  exactly once (although the order of evaluation is
       
   310 				  undefined).</p></li><li><p>It must be possible to take the address of function.
       
   311 			    </p></li></ul></div></li><li><p>
       
   312 			  Except in cases where macros are allowed, ensure the
       
   313 			  <em class="glossterm">API</em> function
       
   314 			  names exported by your lib &amp; dll files match the function
       
   315 			  names specified by the Khronos standard for the
       
   316 			  <em class="glossterm">API</em> you are
       
   317 			  implementing. 
       
   318 		  </p></li></ul></div><div class="section" lang="en"><div class="titlepage"><div><div><h5 class="title"><a name="lpackaging"></a>Packaging</h5></div></div></div><div class="itemizedlist"><ul type="disc"><li><p>OpenGL ES, EGL, OpenVG and OpenKODE entry points should
       
   319 				be packaged in separate libraries.</p></li><li><p>However to provide backward compatibility for existing
       
   320 				applications, two OpenGL ES 1.1 libraries should be provided:
       
   321 			   	one with and one without the EGL entry points.</p><p> 
       
   322 				<span class="emphasis"><em>Note: There are extant implementations of the dual 
       
   323 			  	OpenGL ES libraries demonstrating this is possible on Symbian, 
       
   324 			  	GNU/Linux, Win32 and WinCE.</em></span>
       
   325 		  	  </p><p>For OpenGL ES 2.x, only a library without EGL entry points 
       
   326 			    is needed.</p></li></ul></div></div><div class="section" lang="en"><div class="titlepage"><div><div><h5 class="title"><a name="lnaming"></a>Naming</h5></div></div></div><p>Khronos recommends the library names shown in the following 
       
   327 			table: </p><div class="table"><a name="id4786950"></a><p class="title"><b>Table 2. Recommended Library Names</b></p><table summary="Recommended Library Names" border="1"><colgroup><col align="left"><col align="left"></colgroup><thead><tr><th align="left"> API/Entry Points </th><th align="left"> Name </th></tr></thead><tbody><tr><td align="left"> EGL </td><td align="left"> 
       
   328 					<code class="filename">libEGL.{lib,dll}</code>
       
   329 				  </td></tr><tr><td align="left"> OpenGL ES 1.x with EGL (Common Profile)</td><td align="left"> 
       
   330 					<code class="filename">libGLES_CM.{lib,dll}</code>
       
   331 					<sup>[<a name="fnreq" href="#ftn.fnreq">1</a>]</sup>
       
   332 					<sup>[<a name="fndepr" href="#ftn.fndepr">2</a>]</sup>
       
   333 				  </td></tr><tr><td align="left"> OpenGL ES 1.x with EGL (Lite Profile) </td><td align="left"> 
       
   334 					<code class="filename">libGLES_CL.{lib,dll}</code>
       
   335 					<sup>[<a href="#ftn.fnreq">1</a>]</sup>
       
   336 					<sup>[<a href="#ftn.fndepr">2</a>]</sup>
       
   337 				  </td></tr><tr><td align="left"> OpenGL ES 1.x without EGL </td><td align="left"> 
       
   338 					<code class="filename">libGLESv1_C[LM].{lib,dll}</code>
       
   339 					<sup>[<a name="fnsprev" href="#ftn.fnsprev">3</a>]</sup>
       
   340 				  </td></tr><tr><td align="left"> OpenGL ES 2.x without EGL </td><td align="left"> 
       
   341 					<code class="filename">libGLESv2.{lib,dll}</code>
       
   342 				  </td></tr><tr><td align="left"> </td><td align="left"> 
       
   343 					<code class="filename">libGLUESv1.{lib,dll}</code>
       
   344 					<sup>[<a name="fnreserved" href="#ftn.fnreserved">4</a>]</sup>
       
   345 				  </td></tr><tr><td align="left"> </td><td align="left"> 
       
   346 					<code class="filename">libGLUESv2.{lib,dll}</code>
       
   347 					<sup>[<a href="#ftn.fnreserved">4</a>]</sup>
       
   348 				  </td></tr><tr><td align="left"> OpenKODE </td><td align="left"> 
       
   349 					<code class="filename">libKD{lib,dll}</code>
       
   350 				  </td></tr><tr><td align="left"> OpenVG </td><td align="left"> 
       
   351 					<code class="filename">libOpenVG{lib,dll}</code>
       
   352 				  </td></tr><tr><td align="left"> OpenVG Utilities (when present) </td><td align="left"> 
       
   353 					<code class="filename">libOpenVGU.{lib,dll}</code>
       
   354 				  </td></tr></tbody></table><div class="footnotes"><div class="footnote"><p><sup>[<a name="ftn.fnreq" href="#fnreq">1</a>] </sup> These names are required for OpenGL ES 1.0 
       
   355 						and the libraries must contain the EGL entry points 
       
   356 						as detailed in Chapter 8, 
       
   357 						<span class="emphasis"><em>Packaging</em></span>,
       
   358 					   	of the OpenGL ES 1.0 specification.</p></div><div class="footnote"><p><sup>[<a name="ftn.fndepr" href="#fndepr">2</a>] </sup> These names are deprecated for OpenGL ES 1.1 
       
   359 						and beyond and should only be used for a library 
       
   360 						that includes the EGL entry points in order to support 
       
   361 						legacy applications. </p></div><div class="footnote"><p><sup>[<a name="ftn.fnsprev" href="#fnsprev">3</a>] </sup> 
       
   362 						<span class="emphasis"><em>The OpenGL ES 1.1 specification at revision 1.1.09
       
   363 						  was updated to specify these alternate names for GLES
       
   364 						  libraries that do not contain the EGL entry points.
       
   365 						</em></span>
       
   366 					  </p></div><div class="footnote"><p><sup>[<a name="ftn.fnreserved" href="#fnreserved">4</a>] </sup>These names are reserved for future use by the
       
   367 						Khronos Group.</p></div></div></div></div><div class="section" lang="en"><div class="titlepage"><div><div><h5 class="title"><a name="notes2"></a>Notes </h5></div></div></div><div class="itemizedlist"><ul type="disc"><li><p><span class="emphasis"><em>The extensions
       
   368 				<code class="filename">.lib</code>
       
   369 				&amp; <code class="filename">.dll</code>
       
   370 				are allowed to vary by platform. On GNU/Linux for example 
       
   371 				they should be .a and .so to match that platform's
       
   372 				conventions.</em></span></p></li></ul></div></div></div></div></div><div class="section" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="id4787332"></a>Acknowledgements</h2></div></div></div><p class="ackno"> 
       
   373 	<p>Thanks to all the members of the Khronos Group for their input
       
   374 	  and in particular to the following:
       
   375 	</p>
       
   376 	<table class="simplelist" border="0" summary="Simple list"><tr><td>
       
   377 	    <span class="othercredit"><span class="firstname">Petri</span> <span class="surname">Kero</span></span>
       
   378 	  </td></tr><tr><td>
       
   379 	    <span class="othercredit"><span class="firstname">Jon</span> <span class="surname">Leech</span></span>
       
   380 	  </td></tr><tr><td> 
       
   381 		<span class="othercredit"><span class="firstname">Robert</span> <span class="surname">Palmer</span></span>
       
   382 	  </td></tr><tr><td> 
       
   383 		<span class="othercredit"><span class="firstname">Jani</span> <span class="surname">Vaarala</span></span>
       
   384 	  </td></tr><tr><td> 
       
   385 		<span class="othercredit"><span class="firstname">Hans-Martin</span> <span class="surname">Will</span></span>
       
   386 	  </td></tr></table>
       
   387   </p></div><div class="glossary"><div class="titlepage"><div><div><h2 class="title"><a name="id4787444"></a>Glossary</h2></div></div></div><dl><dt><a name="gls_abi"></a>Application Binary Interface (ABI)</dt><dd><p>
       
   388 		  The low-level interface between a compiled application program and the
       
   389 		  operating system or its libraries.
       
   390 		</p></dd><dt><a name="gls_api"></a>Application Programming Interface (API)</dt><dd><p>
       
   391 		  The source-code level interface between an application program
       
   392 		  and the operating system or its libraries.
       
   393 		</p></dd><dt><a name="gls_implementer"></a>Implementer</dt><dd><p>
       
   394 		  A company or person who implements a Khronos API.
       
   395 		</p></dd><dt><a name="gls_mfc"></a>Microsoft Foundation Classes (MFC)</dt><dd><p>
       
   396 		  A set of C++ utility classes provided by Microsoft Corporation.
       
   397 		</p></dd><dt><a name="gls_vendor"></a>Platform Vendor (Vendor)</dt><dd><p>
       
   398 		  A company providing an operating system platform that includes an
       
   399 		  <em class="glossterm">ABI</em>
       
   400 		  specification for one or more Khronos APIs. E.g., Qualcomm (OpenGL ES
       
   401 		  on BREW) and Symbian (OpenGL ES on Symbian OS). A Vendor may also be
       
   402 		  an <em class="glossterm">Implementer.</em>
       
   403 		</p></dd></dl></div></div></body></html>