Load shared GLESv2 library

This commit is contained in:
pelya
2011-07-29 18:44:49 +03:00
parent 69de188e16
commit 6caefe96a5
5 changed files with 21 additions and 3 deletions

View File

@@ -446,6 +446,16 @@ public class MainActivity extends Activity {
public void LoadLibraries()
{
try
{
if(Globals.NeedGles2)
System.loadLibrary("GLESv2");
}
catch ( UnsatisfiedLinkError e )
{
System.out.println("libSDL: Cannot load GLESv2 lib");
}
try
{
for(String l : Globals.AppLibraries)

View File

@@ -2356,7 +2356,7 @@ class Settings
static void Apply(Activity p)
{
nativeSetVideoDepth(Globals.VideoDepthBpp);
nativeSetVideoDepth(Globals.VideoDepthBpp, Globals.NeedGles2 ? 1 : 0);
if(Globals.SmoothVideo)
nativeSetSmoothVideo();
if( Globals.CompatibilityHacks )
@@ -2489,7 +2489,7 @@ class Settings
private static native void nativeSetMultitouchUsed();
private static native void nativeSetTouchscreenKeyboardUsed();
private static native void nativeSetSmoothVideo();
private static native void nativeSetVideoDepth(int bpp);
private static native void nativeSetVideoDepth(int bpp, int gles2);
private static native void nativeSetCompatibilityHacks();
private static native void nativeSetVideoMultithreaded();
private static native void nativeSetupScreenKeyboard(int size, int drawsize, int theme, int nbuttonsAutoFire, int transparency);