Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[Android] Fix an issue where emulation would crash if we couldn't ret…
…rieve GPU information. Also if we can't get the graphics information, give them the benefit of the doubt and enable the GLES3 option.
  • Loading branch information
Sonicadvance1 committed Oct 7, 2013
1 parent d4bd5fd commit a40daac
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
Expand Up @@ -72,6 +72,7 @@ public void onCreate(Bundle savedInstanceState)
SharedPreferences prefs = PreferenceManager.getDefaultSharedPreferences(this);
if (prefs.getString("gpuPref", "Software Rendering").equals("OGL")
&& VideoSettingsFragment.SupportsGLES3()
&& VideoSettingsFragment.m_GLVendor != null
&& VideoSettingsFragment.m_GLVendor.equals("Qualcomm"))
NativeLibrary.SetDimensions((int)screenHeight, (int)screenWidth);
else
Expand Down
Expand Up @@ -190,6 +190,14 @@ public static boolean SupportsGLES3()
// Is a Tegra 4 since it supports 24bit depth
mSupportsGLES3 = true;
}
if (!mSupportsGLES3 &&
m_GLVendor == null &&
m_GLRenderer == null &&
m_GLExtensions == null)
{
// Couldn't get information. Give them the benefit of the doubt
mSupportsGLES3 = true;
}
return mSupportsGLES3;
}

Expand Down

0 comments on commit a40daac

Please sign in to comment.