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/save/SaveRenderer.java
265 265
    android.util.Log.e("Save", ex.getMessage() );
266 266
    }
267 267

  
268
///////////////////////////////////////////////////////////////////////////////////////////////////
269

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

  
279
     return 100*major + 10*minor;
280
     }
281

  
282 268
///////////////////////////////////////////////////////////////////////////////////////////////////
283 269

  
284 270
  public InputStream localFile(int fileID)

Also available in: Unified diff