Beispiel #1
0
 public static void Reset(GL gl)
 {
     GLUtils.currentHardwareTextureID    = -1;
     GLUtils.currentSourceBlendMode      = -1;
     GLUtils.currentDestinationBlendMode = -1;
     GLUtils.DisableBlend(gl);
     GLUtils.DisableCulling(gl);
     GLUtils.DisableTextures(gl);
     GLUtils.DisableTexCoordArray(gl);
     GLUtils.DisableTexColorArray(gl);
     GLUtils.DisableVertexArray(gl);
     GLUtils.red   = -1;
     GLUtils.green = -1;
     GLUtils.blue  = -1;
     GLUtils.alpha = -1;
 }
Beispiel #2
0
 /// <summary>
 /// 此函数在标准XNA环境下无需调用(因为标准XNA【暂停】时不会回收纹理资源),除非进行全面的纹理重制
 /// </summary>
 public static void Reload()
 {
     lock (lazyTextures)
     {
         if (lazyTextures.Count > 0)
         {
             foreach (LTexture texture in lazyTextures.Values)
             {
                 if (texture != null)
                 {
                     texture.isLoaded  = false;
                     texture.reload    = true;
                     texture._hashCode = 1;
                     if (texture.childs != null)
                     {
                         LSystem.Load(new ReloadUpdateable(texture));
                     }
                 }
             }
             LTextureBatch.isBatchCacheDitry = true;
         }
         GLUtils.Reload();
     }
 }
Beispiel #3
0
 public static void SetClearColor(GL gl10, LColor c)
 {
     GLUtils.SetColor(gl10, c.r, c.g, c.b, c.a);
 }