Project

General

Profile

« Previous | Next » 

Revision 625c67de

Added by Leszek Koltunski about 1 year ago

Decouple (to a large degree) the OpenGL Library from Android.

View differences:

src/main/java/org/distorted/examples/deferredjob/DeferredJobRenderer.java
269 269
      android.util.Log.e("DeferredJob", ex.getMessage() );
270 270
      }
271 271

  
272
///////////////////////////////////////////////////////////////////////////////////////////////////
273

  
274
    public int openGlVersion()
275
      {
276
      Context context = mView.getContext();
277
      final ActivityManager activityManager     = (ActivityManager) context.getSystemService(Context.ACTIVITY_SERVICE);
278
      final ConfigurationInfo configurationInfo = activityManager.getDeviceConfigurationInfo();
279
      int glESversion = configurationInfo.reqGlEsVersion;
280
      int major = glESversion >> 16;
281
      int minor = glESversion & 0xff;
282

  
283
      return 100*major + 10*minor;
284
      }
285

  
286 272
///////////////////////////////////////////////////////////////////////////////////////////////////
287 273

  
288 274
    public InputStream localFile(int fileID)

Also available in: Unified diff