Revision 625c67de
Added by Leszek Koltunski about 1 year ago
src/main/java/org/distorted/examples/postprocesstree/PostprocessTreeRenderer.java | ||
---|---|---|
201 | 201 |
android.util.Log.e("PostprocessTree", ex.getMessage() ); |
202 | 202 |
} |
203 | 203 |
|
204 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
|
205 |
|
|
206 |
public int openGlVersion() |
|
207 |
{ |
|
208 |
Context context = mView.getContext(); |
|
209 |
final ActivityManager activityManager = (ActivityManager) context.getSystemService(Context.ACTIVITY_SERVICE); |
|
210 |
final ConfigurationInfo configurationInfo = activityManager.getDeviceConfigurationInfo(); |
|
211 |
int glESversion = configurationInfo.reqGlEsVersion; |
|
212 |
int major = glESversion >> 16; |
|
213 |
int minor = glESversion & 0xff; |
|
214 |
|
|
215 |
return 100*major + 10*minor; |
|
216 |
} |
|
217 |
|
|
218 | 204 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
219 | 205 |
|
220 | 206 |
public InputStream localFile(int fileID) |
Also available in: Unified diff
Decouple (to a large degree) the OpenGL Library from Android.