コード例 #1
0
 public GLEx Update()
 {
     if (isClosed)
     {
         return(this);
     }
     if (batch != null)
     {
         GL20 gl = batch.gl;
         // 刷新原始设置
         GLUtils.Reset(gl);
         // 清空背景为黑色
         GLUtils.SetClearColor(gl, LColor.black);
         if (!LSystem.IsHTML5())
         {
             // 禁用色彩抖动
             GLUtils.DisableDither(gl);
             // 禁用深度测试
             GLUtils.DisableDepthTest(gl);
             // 禁用双面剪切
             GLUtils.DisableCulling(gl);
         }
         // 设定画布渲染模式为默认
         this.SetBlendMode(BlendMethod.MODE_NORMAL);
     }
     return(this);
 }
コード例 #2
0
 public virtual GLEx Reset(float red, float green, float blue, float alpha)
 {
     if (isClosed)
     {
         return(this);
     }
     GLUtils.SetClearColor(batch.gl, red, green, blue, alpha);
     this.SetFont(LSystem.GetSystemGameFont());
     this.lastBrush.baseColor  = LColor.DEF_COLOR;
     this.lastBrush.fillColor  = LColor.DEF_COLOR;
     this.lastBrush.baseAlpha  = 1f;
     this.lastBrush.patternTex = null;
     this.SetBlendMode(BlendMethod.MODE_NORMAL);
     this.ResetLineWidth();
     return(this);
 }
コード例 #3
0
 public GLEx Clear(LColor color)
 {
     GLUtils.SetClearColor(batch.gl, color);
     return(this);
 }
コード例 #4
0
 public virtual GLEx Clear(float red, float green, float blue, float alpha)
 {
     GLUtils.SetClearColor(batch.gl, red, green, blue, alpha);
     return(this);
 }