Ejemplo n.º 1
0
        // ===========================================================
        // Methods
        // ===========================================================

        public static void Reset(/* final */ GL10 pGL)
        {
            GLHelper.sCurrentHardwareBufferID  = -1;
            GLHelper.sCurrentHardwareTextureID = -1;
            GLHelper.sCurrentMatrix            = -1;

            GLHelper.sCurrentSourceBlendMode      = -1;
            GLHelper.sCurrentDestinationBlendMode = -1;

            GLHelper.sCurrentTextureFloatBuffer = null;
            GLHelper.sCurrentVertexFloatBuffer  = null;

            GLHelper.EnableDither(pGL);
            GLHelper.EnableLightning(pGL);
            GLHelper.EnableDepthTest(pGL);
            GLHelper.EnableMultisample(pGL);

            GLHelper.DisableBlend(pGL);
            GLHelper.DisableCulling(pGL);
            GLHelper.DisableTextures(pGL);
            GLHelper.DisableTexCoordArray(pGL);
            GLHelper.DisableVertexArray(pGL);

            GLHelper.sLineWidth = 1;

            GLHelper.sRed   = -1;
            GLHelper.sGreen = -1;
            GLHelper.sBlue  = -1;
            GLHelper.sAlpha = -1;

            GLHelper.EXTENSIONS_VERTEXBUFFEROBJECTS = false;
            GLHelper.EXTENSIONS_DRAWTEXTURE         = false;
        }
Ejemplo n.º 2
0
        /**
         * See {@link FloatBuffer#put(FloatBuffer)}
         */
        public void Put(FastFloatBuffer b)
        {
            ByteBuffer byteBuffer = this.mByteBuffer;

            byteBuffer.Put(b.mByteBuffer);
            this.mFloatBuffer.Position(byteBuffer.Position() >> 2);
            this.mIntBuffer.Position(byteBuffer.Position() >> 2);
        }
Ejemplo n.º 3
0
 public static void VertexPointer(/* final */ GL10 pGL, /* final */ FastFloatBuffer pVertexFloatBuffer)
 {
     if (GLHelper.sCurrentVertexFloatBuffer != pVertexFloatBuffer)
     {
         GLHelper.sCurrentVertexFloatBuffer = pVertexFloatBuffer;
         pGL.GlVertexPointer(2, GL10Consts.GlFloat, 0, pVertexFloatBuffer.mByteBuffer);
     }
 }
Ejemplo n.º 4
0
 public static void TexCoordPointer(/* final */ GL10 pGL, /* final */ FastFloatBuffer pTextureFloatBuffer)
 {
     if (GLHelper.sCurrentTextureFloatBuffer != pTextureFloatBuffer)
     {
         GLHelper.sCurrentTextureFloatBuffer = pTextureFloatBuffer;
         pGL.GlTexCoordPointer(2, GL10Consts.GlFloat, 0, pTextureFloatBuffer.mByteBuffer);
     }
 }