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: /**
028: * The <code>GL</code> interface is the parent interface for
029: * the Java(TM) programming language bindings for OpenGL(R) ES 1.0,
030: * 1.1, and extensions.
031: *
032: * <p> The documentation in this interface and its subinterfaces is
033: * normative with respect to instance variable names and values,
034: * method names and signatures, and exception behavior. The remaining
035: * documentation is placed here for convenience and does not replace
036: * the normative documentation found in the OpenGL ES 1.0 and 1.1
037: * specifications, relevant extension specifications, and the OpenGL
038: * specification versions referenced by any of the preceding
039: * specifications.
040: *
041: * <p> A GL object is obtained by calling
042: * <code>EGLContext.getGL()</code>. The returned object will
043: * implement either <code>GL10</code> or <code>GL11</code>, plus any
044: * available extension interfaces (such as <code>GL10Ext</code>,
045: * <code>GL11Ext</code>, or <code>GL11ExtensionPack</code>). The
046: * returned object must be cast to the appropriate interface (possibly
047: * following an <code>instanceof</code> check) in order to call
048: * GL methods.
049: *
050: * <p> A common superinterface is used for OpenGL ES 1.0, OpenGL ES
051: * 1.1, and Khronos-defined core extensions. In order to determine if
052: * the implementation supports GL 1.1, call
053: * <code>glGetString(GL.GL_VERSION)</code>.
054: *
055: * <p> Some methods defined in subinterfaces are available only on
056: * OpenGL ES 1.1. The descriptions of these functions are marked
057: * "(1.1 only)." Similarly, some methods behave slightly differently
058: * across OpenGL ES versions. The sections that differ are marked
059: * "(1.0 only)" and "(1.1 only)" as appropriate. Some methods have an
060: * additional section marked "1.0 Notes" or "1.1 Notes" that applies
061: * to the corresponding engine version.
062: *
063: * <p> Some extensions are defined as a core part of the OpenGL ES
064: * specification (they are extensions relative to desktop OpenGL).
065: * These functions are treated as normal portions of OpenGL ES,
066: * although they may still be queried as extensions using the normal
067: * OpenGL ES query mechanisms.
068: *
069: * <p> Extensions may allow some arguments to take on values other
070: * than those listed in this specification. Implementations that
071: * provide a given extension may pass such values to the underlying
072: * engine.
073: *
074: * <p> Optional profile extensions defined as of the creation of this
075: * specification may be found in the <code>GL10Ext</code>,
076: * <code>GL11Ext</code>, and <code>GL11ExtensionPack</code>
077: * interfaces.
078: *
079: * <h3>Vertex Buffer Objects</h3>
080: *
081: * <p>VBOs are considered to be enabled if the most recent call to
082: * <code>glBindBuffer</code> had a target of
083: * <code>GL_ARRAY_BUFFER</code> and a non-zero <code>buffer</code>
084: * parameter. When VBOs are enabled, only the variant of the
085: * <code>gl*Pointer</code> functions that take an integer offset
086: * (found in the <code>GL11</code> interface) may be called. When
087: * VBOs are disabled, only the variant of the <code>gl*Pointer</code>
088: * functions that take a <code>Buffer</code> may be called.
089: *
090: * <h3>Clamping</h3>
091: *
092: * <p>When method specifies that a value <code>x</code> is clamped to
093: * a range <code>[A, B]</code>, it means that the value
094: * <code>min(max(x, A), B)</code> is used in place of the original
095: * value.
096: */
097: public interface GL {
098:
099: // public void dispose();
100: }
|