Exemple #1
0
        public static void CheckGLError(string tag, string label)
        {
            int error;

            while ((error = GLES20.GlGetError()) != GLES20.GlNoError)
            {
                Log.Error(tag, label + ": glError " + error);
                throw new Exception(label + ": glError " + error);
            }
        }
Exemple #2
0
        static void CheckGlError(string func)
        {
            int error;

            while ((error = GLES20.GlGetError()) != GLES20.GlNoError)
            {
                Log.Error(Tag, func + ": GlError " + error);
                throw new InvalidOperationException(func + ": GlError " + error);
            }
        }
 public static void CheckGlError(string op)
 {
     try
     {
         int error = GLES20.GlGetError();
         if (error != GLES20.GlNoError)
         {
             throw new RuntimeException(op + ": glError " + error);
         }
     }
     catch (Exception e)
     {
         Console.WriteLine(e);
     }
 }
Exemple #4
0
 public static void CheckGlError(string op)
 {
     try
     {
         int error = GLES20.GlGetError();
         if (error != GLES20.GlNoError)
         {
             throw new RuntimeException(op + ": glError " + error);
         }
     }
     catch (Exception e)
     {
         Methods.DisplayReportResultTrack(e);
     }
 }
        /// <summary>
        /// Check OpenGL ES running exceptions and throw them when necessary.
        /// </summary>
        /// <param name="tag">Exception information.</param>
        /// <param name="label">Program label.</param>
        public static void CheckGlError(string tag, string label)
        {
            int lastError = GLES20.GlNoError;
            int error     = GLES20.GlGetError();

            while (error != GLES20.GlNoError)
            {
                Log.Debug(tag, label + ": glError " + error);
                lastError = error;
                error     = GLES20.GlGetError();
            }
            if (lastError != GLES20.GlNoError)
            {
                throw new ArDemoRuntimeException(label + ": glError " + lastError);
            }
        }
        // Assert that no OpenGL ES 2.0 error has been raised.
        private static void checkNoGLES2Error()
        {
            int error = GLES20.GlGetError();

            abortUnless(error == GLES20.GlNoError, "GLES20 error: " + error);
        }