Source Code Cross Referenced for GL11Ext.java in  » 6.0-JDK-Modules » j2me » javax » microedition » khronos » opengles » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » 6.0 JDK Modules » j2me » javax.microedition.khronos.opengles 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /*
002:         * Copyright  1990-2007 Sun Microsystems, Inc. All Rights Reserved.
003:         * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER
004:         * 
005:         * This program is free software; you can redistribute it and/or
006:         * modify it under the terms of the GNU General Public License version
007:         * 2 only, as published by the Free Software Foundation.
008:         * 
009:         * This program is distributed in the hope that it will be useful, but
010:         * WITHOUT ANY WARRANTY; without even the implied warranty of
011:         * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
012:         * General Public License version 2 for more details (a copy is
013:         * included at /legal/license.txt).
014:         * 
015:         * You should have received a copy of the GNU General Public License
016:         * version 2 along with this work; if not, write to the Free Software
017:         * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
018:         * 02110-1301 USA
019:         * 
020:         * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa
021:         * Clara, CA 95054 or visit www.sun.com if you need additional
022:         * information or have any questions.
023:         */
024:
025:        package javax.microedition.khronos.opengles;
026:
027:        import java.nio.*;
028:
029:        /**
030:         * The <code>GL11Ext</code> interface contains the Java(TM)
031:         * programming language bindings for all optional profile extensions
032:         * to OpenGL(R) ES 1.1.
033:         *
034:         * <p> This interface contains constants and methods associated with the
035:         * optional profile extensions for OpenGL ES 1.1.  The runtime OpenGL
036:         * ES engine may or may not implement any particular extensions
037:         * defined in the extension pack.  Functions that require a particular
038:         * extension will throw an <code>UnsupportedOperationException</code>
039:         * if the extension is not available at runtime.
040:         *
041:         * <p> The OpenGL ES 1.1 optional profile extensions comprise the
042:         * following:
043:         *
044:         * <ul>
045:         * <li>OES_draw_texture</li>
046:         * <li>OES_matrix_palette</li>
047:         * </ul>
048:         *
049:         * <p> The documentation in this class is normative with respect to
050:         * instance variable names and values, method names and signatures,
051:         * and exception behavior.  The remaining documentation is placed here
052:         * for convenience and does not replace the normative documentation
053:         * found in the OpenGL ES 1.1 specification and the OpenGL
054:         * specification versions it references.
055:         */
056:        public interface GL11Ext extends GL {
057:
058:            /**
059:             * (1.1 + <code>OES_matrix_palette</code> extension)
060:             * Enable server-side GL capabilities.
061:             *
062:             * <p>The matrix palette extension is enabled if
063:             * <code>cap</code> assumes the value <code>GL_MATRIX_PALETTE_OES</code>.
064:             * See <code>glMatrixMode</code>.
065:             *
066:             * @see GL11#glEnable(int cap)
067:             */
068:            void glEnable(int cap);
069:
070:            /**
071:             * (<code>OES_matrix_palette</code> extension)
072:             * Enable client-side capability.
073:             *
074:             * <p> The <code>OES_matrix_palette</code> extension adds three
075:             * additional values for <code>array</code>:
076:             *
077:             * <ul>
078:             * <li><code>GL_MATRIX_INDEX_ARRAY_OES</code>
079:             *
080:             * <p> If enabled, the matrix index array is enabled. See
081:             * <code>glMatrixIndexPointer</code>.
082:             *
083:             * <li><code>GL_WEIGHT_ARRAY_OES</code>
084:             *
085:             * <p> If enabled, the weight array is enabled. See
086:             * <code>glWeightPointer</code>.
087:             *
088:             * </ul>
089:             *
090:             * @see GL11#glEnableClientState(int array)
091:             */
092:            void glEnableClientState(int array);
093:
094:            /**
095:             * (<code>OES_draw_texture</code> extension)</li>
096:             * Set texture parameters.
097:             * 
098:             * The <code>OES_draw_texture</code> extension adds an additoanl
099:             * value for <code>pname</code>,
100:             * <code>GL_TEXTURE_CROP_RECT_OES</code>, which sets the texture
101:             * cropping rectangle for use by <code>glDrawTexOES</code>.
102:             *
103:             * @see GL11#glTexParameterfv(int target, int pname, float[] params, int offset)
104:             */
105:            void glTexParameterfv(int target, int pname, float[] params,
106:                    int offset);
107:
108:            // OES_draw_texture extension (optional profile extension in 1.1)
109:
110:            //   /**
111:            //    * Flag indicating the presence of the "draw texture" extension.
112:            //    * <code>OES_draw_texture</code> is an optional profile extension in
113:            //    * OpenGL ES 1.1.
114:            //    */
115:            //   int GL_OES_draw_texture      = 1;
116:
117:            /**
118:             * Constant for use with <code>glTexParameter</code>
119:             * (<code>OES_draw_texture</code> extension).
120:             */
121:            int GL_TEXTURE_CROP_RECT_OES = 0x8B9D;
122:
123:            /**
124:             * (<code>OES_draw_texture</code> extension)
125:             * <code>glDrawTexOES</code> draws a texture rectangle to the screen.
126:             *
127:             * <p><code>x</code> and <code>y</code> are given directly in window
128:             * (viewport) coordinates.
129:             *
130:             * <p><code>z</code> is mapped to window depth <code>Zw</code> as
131:             * follows:
132:             *
133:             * <pre>
134:             * If z <= 0 then Zw = n
135:             * If z >= 1 then Zw = f
136:             * Otherwise Zw = n + z * (f - n)
137:             * </pre>
138:             *
139:             * where <i>n</i> and <i>f</i> are the near and far values of
140:             * <code>GL_DEPTH_RANGE</code> respectively.
141:             *
142:             * <p><code>width</code> and <code>height</code> specify the width and
143:             * height of the affected screen rectangle in pixels. These values
144:             * may be positive or negative; however if either of these are
145:             * negative, nothing is drawn.
146:             * 
147:             * <p>Calling one of the <code>DrawTex</code> functions generates a
148:             * fragment for each pixel that overlaps the screen rectangle
149:             * bounded by (<code>x</code>, <code>y</code>) and (<code>x</code> +
150:             * <code>width</code>), (<code>y</code> + <code>height</code>). For
151:             * each generated fragment, the depth is given by Zw as defined
152:             * above, and the color by the current color.
153:             * 
154:             * <p>Texture coordinates for each texture unit are computed as follows:
155:             * 
156:             * <p>Let <code>X</code> and <code>Y</code> be the screen x and y
157:             * coordinates of each sample point associated with the
158:             * fragment. Let <code>Wt</code> and <code>Ht</code> be the width
159:             * and height in texels of the texture currently bound to the
160:             * texture unit. (If the texture is a mipmap, let <code>Wt</code>
161:             * and <code>Ht</code> be the dimensions of the level specified by
162:             * <code>GL_TEXTURE_BASE_LEVEL</code>). Let <code>Ucr</code>,
163:             * <code>Vcr</code>, <code>Wcr</code> and <code>Hcr</code> be
164:             * (respectively) the four integers that make up the texture crop
165:             * rectangle parameter for the currently bound texture. The fragment
166:             * texture coordinates <code>(s, t, r, q)</code> are given by:
167:             * 
168:             * <pre>
169:             * s = (Ucr + (X - x) * (Wcr / width)) / Wt
170:             * t = (Vcr + (Y - y) * (Hcr / height)) / Ht
171:             * r = 0
172:             * q = 1
173:             * </pre>
174:             * 
175:             * <h4>Notes</h4>
176:             * 
177:             * <p>In the specific case where <code>X</code>, <code>Y</code>,
178:             * <code>x</code> and <code>y</code> are all integers,
179:             * <code>Wcr</code>/<code>width</code> and
180:             * <code>Hcr</code>/<code>height</code> are both equal to one, the
181:             * base level is used for the texture read, and fragments are
182:             * sampled at pixel centers, implementations are required to ensure
183:             * that the resulting <code>u</code>, <code>v</code> texture indices
184:             * are also integers. This results in a one-to-one mapping of texels
185:             * to fragments.
186:             * 
187:             * <p>Note that <code>Wcr</code> and/or <code>Hcr</code> can be
188:             * negative. The formulas given above for <code>s</code> and
189:             * <code>t</code> still apply in this case. The result is that if
190:             * <code>Wcr</code> is negative, the source rectangle for
191:             * <code>glDrawTexOES</code> operations lies to the left of the
192:             * reference point (Ucr, Vcr) rather than to the right of it, and
193:             * appears right-to-left reversed on the screen after a call to
194:             * <code>DrawTex</code>. Similarly, if <code>Hcr</code> is negative,
195:             * the source rectangle lies below the reference point <code>(Ucr,
196:             * Vcr)</code> rather than above it, and appears upside-down on the
197:             * screen.
198:             * 
199:             * <p>Note also that <code>s</code>, <code>t</code>, <code>r</code>,
200:             * and <code>q</code> are computed for each fragment as part of
201:             * <code>glDrawTexOES</code> rendering. This implies that the
202:             * texture matrix is ignored and has no effect on the rendered
203:             * result.
204:             * 
205:             * <p><code>glDrawTexOES</code> is available only if the
206:             * <code>OES_draw_texture</code> extension is supported by your
207:             * implementation.
208:             * 
209:             * @param x Specifies the x position of the affected screen rectangle.
210:             * @param y Specifies the x position of the affected screen rectangle.
211:             * @param z Specifies the x position of the affected screen rectangle.
212:             * @param width Specifies the width of the affected screen rectangle
213:             * in pixels.
214:             * @param height Specifies the height of the affected screen
215:             * rectangle in pixels.
216:             *
217:             * @exception UnsupportedOperationException if the
218:             * <code>OES_draw_texture</code> extension is not available.
219:             */
220:            void glDrawTexfOES(float x, float y, float z, float width,
221:                    float height);
222:
223:            /**
224:             * (<code>OES_draw_texture</code> extension)
225:             * Short integer version of <code>glDrawTexOES</code>.
226:             *
227:             * @see #glDrawTexfOES(float x, float y, float z, float width, float height)
228:             *
229:             * @exception UnsupportedOperationException if the
230:             * <code>OES_draw_texture</code> extension is not available.
231:             */
232:            void glDrawTexsOES(short x, short y, short z, short width,
233:                    short height);
234:
235:            /**
236:             * (<code>OES_draw_texture</code> extension)
237:             * Integer version of <code>glDrawTexOES</code>.
238:             *
239:             * @exception UnsupportedOperationException if the
240:             * <code>OES_draw_texture</code> extension is not available.
241:             */
242:            void glDrawTexiOES(int x, int y, int z, int width, int height);
243:
244:            /**
245:             * (<code>OES_draw_texture</code> extension)
246:             * Fixed-point version of <code>glDrawTexOES</code>.
247:             *
248:             * @exception UnsupportedOperationException if the
249:             * <code>OES_draw_texture</code> extension is not available.
250:             */
251:            void glDrawTexxOES(int x, int y, int z, int width, int height);
252:
253:            /**
254:             * (<code>OES_draw_texture</code> extension)
255:             * Floating-point array version of <code>glDrawTexOES</code>.
256:             *
257:             * @param coords An array of at least 5 elements containing the x,
258:             * y, z, width and height values.
259:             * @param offset the starting offset within the
260:             * <code>coords</code> array.
261:             *
262:             * @see #glDrawTexfOES(float x, float y, float z, float width, float height)
263:             *
264:             * @exception UnsupportedOperationException if the
265:             * <code>OES_draw_texture</code> extension is not available.
266:             * @exception IllegalArgumentException if <code>offset</code> is
267:             * less than 0.
268:             * @exception IllegalArgumentException if <code>coords</code> is
269:             * <code>null</code> or if <code>coords.length - offset</code> is
270:             * less than 5.
271:             */
272:            void glDrawTexfvOES(float[] coords, int offset);
273:
274:            /**
275:             * (<code>OES_draw_texture</code> extension)
276:             * Floating-point <code>Buffer</code> version of
277:             * <code>glDrawTexOES</code>.
278:             * 
279:             * @see #glDrawTexfvOES(float[] coords, int offset)
280:             *
281:             * @exception UnsupportedOperationException if the
282:             * <code>OES_draw_texture</code> extension is not available.
283:             * @exception IllegalArgumentException if <code>coords</code> is
284:             * <code>null</code> or if <code>coords.remaining()</code> is less than 5.
285:             */
286:            void glDrawTexfvOES(FloatBuffer coords);
287:
288:            /**
289:             * (<code>OES_draw_texture</code> extension)
290:             * Short integer array version of <code>glDrawTexOES</code>.
291:             *
292:             * @see #glDrawTexfvOES(float[] coords, int offset)
293:             *
294:             * @exception UnsupportedOperationException if the
295:             * <code>OES_draw_texture</code> extension is not available.
296:             * @exception IllegalArgumentException if <code>offset</code> is
297:             * less than 0.
298:             * @exception IllegalArgumentException if <code>coords</code> is
299:             * <code>null</code> or if <code>coords.length - offset</code> is
300:             * less than 5.
301:             */
302:            void glDrawTexsvOES(short[] coords, int offset);
303:
304:            /**
305:             * (<code>OES_draw_texture</code> extension)
306:             * Short integer <code>Buffer</code> version of
307:             * <code>glDrawTexOES</code>.
308:             *
309:             * @see #glDrawTexfvOES(float[] coords, int offset)
310:             *
311:             * @exception UnsupportedOperationException if the
312:             * <code>OES_draw_texture</code> extension is not available.
313:             * @exception IllegalArgumentException if <code>coords</code> is
314:             * <code>null</code> or if <code>coords.remaining()</code> is less than 5.
315:             */
316:            void glDrawTexsvOES(ShortBuffer coords);
317:
318:            /**
319:             * (<code>OES_draw_texture</code> extension)
320:             * Integer array version of <code>glDrawTexOES</code>.
321:             *
322:             * @see #glDrawTexfvOES(float[] coords, int offset)
323:             *
324:             * @exception UnsupportedOperationException if the
325:             * <code>OES_draw_texture</code> extension is not available.
326:             * @exception IllegalArgumentException if <code>offset</code> is
327:             * less than 0.
328:             * @exception IllegalArgumentException if <code>coords</code> is
329:             * <code>null</code> or if <code>coords.length - offset</code> is
330:             * less than 5.
331:             */
332:            void glDrawTexivOES(int[] coords, int offset);
333:
334:            /**
335:             * (<code>OES_draw_texture</code> extension)
336:             * Integer <code>Buffer</code> version of
337:             * <code>glDrawTexOES</code>.
338:             * 
339:             * @see #glDrawTexfvOES(float[] coords, int offset)
340:             *
341:             * @exception UnsupportedOperationException if the
342:             * <code>OES_draw_texture</code> extension is not available.
343:             * @exception IllegalArgumentException if <code>coords</code> is
344:             * <code>null</code> or if <code>coords.remaining()</code> is less than 5.
345:             */
346:            void glDrawTexivOES(IntBuffer coords);
347:
348:            /**
349:             * (<code>OES_draw_texture</code> extension)
350:             * Fixed-point array version of <code>glDrawTexOES</code>.
351:             * 
352:             * @see #glDrawTexfvOES(float[] coords, int offset)
353:             *
354:             * @exception UnsupportedOperationException if the
355:             * <code>OES_draw_texture</code> extension is not available.
356:             * @exception IllegalArgumentException if <code>offset</code> is
357:             * less than 0.
358:             * @exception IllegalArgumentException if <code>coords</code> is
359:             * <code>null</code> or if <code>coords.length - offset</code> is
360:             * less than 5.
361:             */
362:            void glDrawTexxvOES(int[] coords, int offset);
363:
364:            /**
365:             * (<code>OES_draw_texture</code> extension)
366:             * Fixed-point <code>Buffer</code> version of
367:             * <code>glDrawTexOES</code>.
368:             * 
369:             * @see #glDrawTexfvOES(float[] coords, int offset)
370:             *
371:             * @exception UnsupportedOperationException if the
372:             * <code>OES_draw_texture</code> extension is not available.
373:             * @exception IllegalArgumentException if <code>coords</code> is
374:             * <code>null</code> or if <code>coords.remaining()</code> is less than 5.
375:             */
376:            void glDrawTexxvOES(IntBuffer coords);
377:
378:            // OES_matrix_palette (optional profile extension in 1.1)
379:
380:            //   /**
381:            //    * Flag indicating the presence of the
382:            //    * <code>OES_matrix_palette</code> extension.
383:            //    */
384:            //   int GL_OES_matrix_palette                    = 1;
385:
386:            /* OES_matrix_palette */
387:
388:            /**
389:             * Constant for use with <code>glGet</code>
390:             * (<code>OES_matrix_palette</code> extension).
391:             */
392:            int GL_MAX_VERTEX_UNITS_OES = 0x86A4;
393:
394:            /**
395:             * Constant for use with <code>glGet</code>
396:             * (<code>OES_matrix_palette</code> extension).
397:             */
398:            int GL_MAX_PALETTE_MATRICES_OES = 0x8842;
399:
400:            /**
401:             * Constant for use with <code>glMatrixMode</code>
402:             * (<code>OES_matrix_palette</code> extension).
403:             */
404:            int GL_MATRIX_PALETTE_OES = 0x8840;
405:
406:            /**
407:             * Constant for use with <code>glEnableClientState</code> and
408:             * <code>glDisableClientState</code>
409:             * (<code>OES_matrix_palette</code> extension).
410:             */
411:            int GL_MATRIX_INDEX_ARRAY_OES = 0x8844;
412:
413:            /**
414:             * Constant for use with <code>glEnableClientState</code> and
415:             * <code>glDisableClientState</code>
416:             * (<code>OES_matrix_palette</code> extension).
417:             */
418:            int GL_WEIGHT_ARRAY_OES = 0x86AD;
419:
420:            /**
421:             * Constant for use with <code>glGet</code>
422:             * (<code>OES_matrix_palette</code> extension).
423:             */
424:            int GL_MATRIX_INDEX_ARRAY_SIZE_OES = 0x8846;
425:
426:            /**
427:             * Constant for use with <code>glGet</code>
428:             * (<code>OES_matrix_palette</code> extension).
429:             */
430:            int GL_MATRIX_INDEX_ARRAY_TYPE_OES = 0x8847;
431:
432:            /**
433:             * Constant for use with <code>glGet</code>
434:             * (<code>OES_matrix_palette</code> extension).
435:             */
436:            int GL_MATRIX_INDEX_ARRAY_STRIDE_OES = 0x8848;
437:
438:            /**
439:             * Constant for use with <code>glGetPointer</code>
440:             * (<code>OES_matrix_palette</code> extension).
441:             */
442:            int GL_MATRIX_INDEX_ARRAY_POINTER_OES = 0x8849;
443:
444:            /**
445:             * Constant for use with <code>glGet</code>
446:             * (<code>OES_matrix_palette</code> extension).
447:             */
448:            int GL_MATRIX_INDEX_ARRAY_BUFFER_BINDING_OES = 0x8B9E;
449:
450:            /**
451:             * Constant for use with <code>glGet</code>
452:             * (<code>OES_matrix_palette</code> extension).
453:             */
454:            int GL_WEIGHT_ARRAY_SIZE_OES = 0x86AB;
455:
456:            /**
457:             * Constant for use with <code>glGet</code>
458:             * (<code>OES_matrix_palette</code> extension).
459:             */
460:            int GL_WEIGHT_ARRAY_TYPE_OES = 0x86A9;
461:
462:            /**
463:             * Constant for use with <code>glGet</code>
464:             * (<code>OES_matrix_palette</code> extension).
465:             */
466:            int GL_WEIGHT_ARRAY_STRIDE_OES = 0x86AA;
467:
468:            /**
469:             * Constant for use with <code>glGetPointer</code>
470:             * (<code>OES_matrix_palette</code> extension).
471:             */
472:            int GL_WEIGHT_ARRAY_POINTER_OES = 0x86AC;
473:
474:            /**
475:             * Constant for use with <code>glGet</code>
476:             * (<code>OES_matrix_palette</code> extension).
477:             */
478:            int GL_WEIGHT_ARRAY_BUFFER_BINDING_OES = 0x889E;
479:
480:            /**
481:             * (<code>OES_matrix_palette</code> extension) Defines which of the
482:             * palette’s matrices is affected by subsequent matrix operations.
483:             *
484:             * <p><code>glCurrentPaletteMatrixOES</code> defines which of the
485:             * palette’s matrices is affected by subsequent matrix operations
486:             * when the current matrix mode is
487:             * <code>GL_MATRIX_PALETTE_OES</code>.
488:             *
489:             * <h4>Errors</h4>
490:             * 
491:             * <p><code>GL_INVALID_VALUE</code> is generated if
492:             * <code>index</code> is not between 0 and
493:             * <code>GL_MAX_PALETTE_MATRICES_OES</code> - 1.
494:             *
495:             * @param matrixpaletteindex Specifies the index into the palette's matrices.
496:             *
497:             * @exception UnsupportedOperationException if the underlying
498:             * runtime engine does not support the
499:             * <code>OES_matrix_palette</code> extension.
500:             */
501:            void glCurrentPaletteMatrixOES(int matrixpaletteindex);
502:
503:            /**
504:             * (<code>OES_matrix_palette</code> extension) Copies the current
505:             * model view matrix to a matrix in the current matrix palette.
506:             *
507:             * <p><code>glLoadPaletteFromModelViewMatrixOES</code> copies the
508:             * current model view matrix to a matrix in the current matrix
509:             * palette, as specified by glCurrentPaletteMatrix.
510:             *
511:             * @exception UnsupportedOperationException if the underlying
512:             * runtime engine does not support the
513:             * <code>OES_matrix_palette</code> extension.
514:             */
515:            void glLoadPaletteFromModelViewMatrixOES();
516:
517:            /**
518:             * (<code>OES_matrix_palette</code> extension) Define an array of
519:             * matrix indices.
520:             *
521:             * <p><code>glMatrixIndexPointer</code> specifies the location and
522:             * data of an array of matrix indices to use when
523:             * rendering. <code>size</code> specifies the number of matrix
524:             * indices per vertex and <code>type</code> the data type of the
525:             * coordinates. <code>stride</code> specifies the byte stride from
526:             * one matrix index to the next, allowing vertices and attributes to
527:             * be packed into a single array or stored in separate
528:             * arrays. (Single-array storage may be more efficient on some
529:             * implementations.)
530:             *
531:             * <p>These matrices indices are used to blend corresponding matrices
532:             * for a given vertex.
533:             *
534:             * <p>When a matrix index array is specified, <code>size</code>,
535:             * <code>type</code>, <code>stride</code>, and <code>pointer</code>
536:             * are saved as client-side state.
537:             *
538:             * <p>If the matrix index array is enabled, it is used when
539:             * <code>glDrawArrays</code>, or <code>glDrawElements</code> is
540:             * called. To enable and disable the vertex array, call
541:             * <code>glEnableClientState</code> and
542:             * <code>glDisableClientState</code> with the argument
543:             * <code>GL_MATRIX_INDEX_ARRAY_OES</code>. The matrix index array is
544:             * initially disabled and isn't accessed when
545:             * <code>glDrawArrays</code> or <code>glDrawElements</code> is
546:             * called.
547:             *
548:             * <p>Use <code>glDrawArrays</code> to construct a sequence of
549:             * primitives (all of the same type) from prespecified vertex and
550:             * vertex attribute arrays. Use <code>glDrawElements</code> to
551:             * construct a sequence of primitives by indexing vertices and
552:             * vertex attributes.
553:             *
554:             * <h4>Notes</h4>
555:             *
556:             * <p><code>glMatrixIndexPointer</code> is typically implemented on
557:             * the client side.
558:             *
559:             * <h4>Errors</h4>
560:             *
561:             * <p><code>GL_INVALID_VALUE</code> is generated if
562:             * <code>size</code> is greater than
563:             * <code>GL_MAX_VERTEX_UNITS_OES</code>.
564:             *
565:             * <p><code>GL_INVALID_ENUM</code> is generated if <code>type</code>
566:             * is is not an accepted value.
567:             *
568:             * <p><code>GL_INVALID_VALUE</code> is generated if
569:             * <code>stride</code> is negative.
570:             *
571:             * @param size Specifies the number of matrix indices per
572:             * vertex. Must be is less than or equal to
573:             * <code>GL_MAX_VERTEX_UNITS_OES</code>. The initial value is 0.
574:             * @param type Specifies the data type of each matrix index in the
575:             * array. Symbolic constant <code>GL_UNSIGNED_BYTE</code> is
576:             * accepted. The initial value is <code>GL_UNSIGNED_BYTE</code>.
577:             * @param stride Specifies the byte offset between consecutive
578:             * matrix indices. If stride is 0, the matrix indices are understood
579:             * to be tightly packed in the array. The initial value is 0.
580:             * @param pointer Specifies a buffer containing the first matrix
581:             * index of the first vertex in the array. The initial value is 0.
582:             *
583:             * @exception UnsupportedOperationException if the underlying
584:             * runtime engine does not support the
585:             * <code>OES_matrix_palette</code> extension.
586:             * @exception IllegalArgumentException if <code>pointer</code> is
587:             * <code>null</code>.
588:             * @exception IllegalStateException if VBOs are enabled.
589:             */
590:            void glMatrixIndexPointerOES(int size, int type, int stride,
591:                    Buffer pointer);
592:
593:            /**
594:             * VBO version of <code>glMatrixIndexPointerOES</code>.
595:             *
596:             * @see #glMatrixIndexPointerOES(int size, int type, int stride,
597:             * Buffer pointer)
598:             *
599:             * @exception UnsupportedOperationException if the underlying
600:             * runtime engine does not support the
601:             * <code>OES_matrix_palette</code> extension.
602:             * @throws IllegalStateException if VBOs are not enabled.
603:             */
604:            void glMatrixIndexPointerOES(int size, int type, int stride,
605:                    int offset);
606:
607:            /**
608:             * (<code>OES_matrix_palette</code> extension) Define an array of weights.
609:             *
610:             * <p><code>glWeightPointer</code> specifies the location and data
611:             * of an array of weights to use when rendering. <code>size</code>
612:             * specifies the number of weights per vertex and <code>type</code>
613:             * the data type of the coordinates. <code>stride</code> specifies
614:             * the byte stride from one weight to the next allowing vertices and
615:             * attributes to be packed into a single array or stored in separate
616:             * arrays. (Single-array storage may be more efficient on some
617:             * implementations.)
618:             *
619:             * <p>These weights are used to blend corresponding matrices for a
620:             * given vertex.
621:             *
622:             * <p>When a weight array is specified, <code>size</code>,
623:             * <code>type</code>, <code>stride</code>, and <code>pointer</code>
624:             * are saved as client-side state.
625:             *
626:             * <p>If the weight array is enabled, it is used when
627:             * <code>glDrawArrays</code>, or <code>glDrawElements</code> is
628:             * called. To enable and disable the vertex array, call
629:             * <code>glEnableClientState</code> and
630:             * <code>glDisableClientState</code> with the argument
631:             * <code>GL_WEIGHT_ARRAY_OES</code>. The weight array is initially
632:             * disabled and isn't accessed when <code>glDrawArrays</code> or
633:             * <code>glDrawElements</code> is called.
634:             *
635:             * <p>Use <code>glDrawArrays</code> to construct a sequence of
636:             * primitives (all of the same type) from prespecified vertex and
637:             * vertex attribute arrays. Use <code>glDrawElements</code> to
638:             * construct a sequence of primitives by indexing vertices and
639:             * vertex attributes.
640:             *
641:             * <h4>Notes</h4>
642:             *
643:             * <p><code>glWeightPointer</code> is typically implemented on the
644:             * client side.
645:             *
646:             * <h4>Errors</h4>
647:             *
648:             * <p><code>GL_INVALID_VALUE</code> is generated if
649:             * <code>size</code> is greater than
650:             * <code>GL_MAX_VERTEX_UNITS_OES</code>.
651:             *
652:             * <p><code>GL_INVALID_ENUM</code> is generated if <code>type</code>
653:             * is is not an accepted value.
654:             *
655:             * <p><code>GL_INVALID_VALUE</code> is generated if
656:             * <code>stride</code> is negative.
657:             *
658:             * @param size Specifies the number of weights per vertex. Must be
659:             * is less than or equal to
660:             * <code>GL_MAX_VERTEX_UNITS_OES</code>. The initial value is 0.
661:             * @param type Specifies the data type of each weight in the
662:             * array. Symbolic constant <code>GL_FIXED</code> is
663:             * accepted. However, the common profile also accepts the symbolic
664:             * constant <code>GL_FLOAT</code> as well. The initial value is
665:             * <code>GL_FIXED</code> for the common lite profile, or
666:             * <code>GL_FLOAT</code> for the common profile.
667:             * @param stride Specifies the byte offset between consecutive
668:             * weights. If <code>stride</code> is 0, the weights are understood
669:             * to be tightly packed in the array. The initial value is 0.
670:             * @param pointer Specifies a <code>Buffer</code> containing the
671:             * weights of each vertex in the array. The initial value is 0.
672:             *
673:             * @exception UnsupportedOperationException if the underlying
674:             * runtime engine does not support the
675:             * <code>OES_matrix_palette</code> extension.
676:             * @exception IllegalArgumentException if <code>pointer</code> is
677:             * <code>null</code>.
678:             * @exception IllegalStateException if VBOs are enabled.
679:             */
680:            void glWeightPointerOES(int size, int type, int stride,
681:                    Buffer pointer);
682:
683:            /**
684:             * (<code>OES_matrix_palette</code> extension) VBO version of
685:             * <code>glWeightPointerOES</code>.
686:             *
687:             * @see #glWeightPointerOES(int size, int type, int stride, Buffer pointer)
688:             *
689:             * @exception UnsupportedOperationException if the underlying
690:             * runtime engine does not support the
691:             * <code>OES_matrix_palette</code> extension.
692:             * @exception IllegalStateException if VBOs are not enabled.
693:             */
694:            void glWeightPointerOES(int size, int type, int stride, int offset);
695:
696:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.