Project

General

Profile

« Previous | Next » 

Revision 56c6ca24

Added by Leszek Koltunski almost 6 years ago

OIT: lots of progress on all fronts. Still a few bugs to solve though!

View differences:

src/main/java/org/distorted/library/main/DistortedRenderState.java
184 184
      }
185 185
    }
186 186

  
187
///////////////////////////////////////////////////////////////////////////////////////////////////
188

  
189
  static void enableDepthTest()
190
    {
191
    sState.depthTest = cState.depthTest;
192

  
193
    if (cState.depthTest != 1)
194
      {
195
      cState.depthTest = 1;
196
      GLES31.glEnable(GLES31.GL_DEPTH_TEST);
197
      }
198
    }
199

  
200
///////////////////////////////////////////////////////////////////////////////////////////////////
201

  
202
  static void restoreDepthTest()
203
    {
204
    if (sState.depthTest != cState.depthTest)
205
      {
206
      cState.depthTest = sState.depthTest;
207

  
208
      if (cState.depthTest == 0)
209
        {
210
        GLES31.glDisable(GLES31.GL_DEPTH_TEST);
211
        }
212
      else
213
        {
214
        GLES31.glEnable(GLES31.GL_DEPTH_TEST);
215
        }
216
      }
217
    }
218

  
187 219
///////////////////////////////////////////////////////////////////////////////////////////////////
188 220

  
189 221
  static void switchOffDrawing()

Also available in: Unified diff