Include OpenGL version string in sysinfo.
This commit is contained in:
committed by
Oliver Brakmann
parent
6b4ccecabe
commit
bc0efbefd1
@@ -78,6 +78,8 @@ namespace OpenRA
|
||||
|
||||
IHardwareCursor CreateHardwareCursor(string name, Size size, byte[] data, int2 hotspot);
|
||||
void SetHardwareCursor(IHardwareCursor cursor);
|
||||
|
||||
string GLVersion { get; }
|
||||
}
|
||||
|
||||
public interface IVertexBuffer<T> : IDisposable
|
||||
|
||||
@@ -273,5 +273,10 @@ namespace OpenRA
|
||||
{
|
||||
return Device.SetClipboardText(text);
|
||||
}
|
||||
|
||||
public string GLVersion
|
||||
{
|
||||
get { return Device.GLVersion; }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -257,11 +257,12 @@ namespace OpenRA.Mods.Common.Widgets.Logic
|
||||
if (!Game.Settings.Debug.SendSystemInformation)
|
||||
return null;
|
||||
|
||||
return "?id={0}&platform={1}&os={2}&runtime={3}&lang={4}&version={5}&mod={6}&modversion={7}".F(
|
||||
return "?id={0}&platform={1}&os={2}&runtime={3}&gl={4}&lang={5}&version={6}&mod={7}&modversion={8}".F(
|
||||
Uri.EscapeUriString(Game.Settings.Debug.UUID),
|
||||
Uri.EscapeUriString(Platform.CurrentPlatform.ToString()),
|
||||
Uri.EscapeUriString(Environment.OSVersion.ToString()),
|
||||
Uri.EscapeUriString(Platform.RuntimeVersion),
|
||||
Uri.EscapeUriString(Game.Renderer.GLVersion),
|
||||
Uri.EscapeUriString(System.Globalization.CultureInfo.InstalledUICulture.TwoLetterISOLanguageName),
|
||||
Uri.EscapeUriString(ModMetadata.AllMods["modchooser"].Version),
|
||||
Uri.EscapeUriString(Game.ModData.Manifest.Mod.Id),
|
||||
|
||||
@@ -33,6 +33,8 @@ namespace OpenRA.Platforms.Default
|
||||
|
||||
public static GLFeatures Features { get; private set; }
|
||||
|
||||
public static string Version { get; private set; }
|
||||
|
||||
public const int GL_FALSE = 0;
|
||||
|
||||
// ClearBufferMask
|
||||
@@ -452,8 +454,8 @@ namespace OpenRA.Platforms.Default
|
||||
{
|
||||
try
|
||||
{
|
||||
var versionString = glGetString(GL_VERSION);
|
||||
var version = versionString.Contains(" ") ? versionString.Split(' ')[0].Split('.') : versionString.Split('.');
|
||||
Version = glGetString(GL_VERSION);
|
||||
var version = Version.Contains(" ") ? Version.Split(' ')[0].Split('.') : Version.Split('.');
|
||||
|
||||
var major = 0;
|
||||
if (version.Length > 0)
|
||||
|
||||
@@ -395,5 +395,7 @@ namespace OpenRA.Platforms.Default
|
||||
VerifyThreadAffinity();
|
||||
return new Shader(name);
|
||||
}
|
||||
|
||||
public string GLVersion { get { return OpenGL.Version; } }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -60,6 +60,8 @@ namespace OpenRA.Platforms.Null
|
||||
|
||||
public IHardwareCursor CreateHardwareCursor(string name, Size size, byte[] data, int2 hotspot) { return null; }
|
||||
public void SetHardwareCursor(IHardwareCursor cursor) { }
|
||||
|
||||
public string GLVersion { get { return "(null)"; } }
|
||||
}
|
||||
|
||||
public class NullShader : IShader
|
||||
|
||||
Reference in New Issue
Block a user