From 8abe4dc621dfeea7d9183a229c1aebf41e5f2316 Mon Sep 17 00:00:00 2001 From: "Unknown W. Brackets" Date: Sun, 28 Apr 2013 18:56:09 -0700 Subject: [PATCH] Reporting: also send the CPU and platform. --- Core/Reporting.cpp | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/Core/Reporting.cpp b/Core/Reporting.cpp index 974b82f16b..456a199374 100644 --- a/Core/Reporting.cpp +++ b/Core/Reporting.cpp @@ -17,6 +17,7 @@ #include "Core/Reporting.h" +#include "Common/CPUDetect.h" #include "Common/StdThread.h" #include "Core/Config.h" #include "Core/System.h" @@ -207,6 +208,30 @@ namespace Reporting return str; } + std::string GetPlatformIdentifer() + { + // TODO: Do we care about OS version? +#if defined(ANDROID) + return "Android"; +#elif defined(_WIN32) + return "Windows"; +#elif defined(IOS) + return "iOS"; +#elif defined(__APPLE__) + return "Mac"; +#elif defined(__SYMBIAN32__) + return "Symbian"; +#elif defined(__FreeBSD__) + return "BSD"; +#elif defined(BLACKBERRY) + return "Blackberry"; +#elif defined(LOONGSON) + return "Loongson"; +#else + return "Unknown"; +#endif + } + int Process(int pos) { Payload &payload = payloadBuffer[pos]; @@ -220,6 +245,10 @@ namespace Reporting postdata.Add("game", StripTrailingNull(g_paramSFO.GetValueString("DISC_ID")) + "_" + StripTrailingNull(g_paramSFO.GetValueString("DISC_VERSION"))); postdata.Add("game_title", StripTrailingNull(g_paramSFO.GetValueString("TITLE"))); postdata.Add("gpu", gpuInfo); + postdata.Add("cpu", cpu_info.Summarize()); + postdata.Add("platform", GetPlatformIdentifer()); + + // TODO: Settings, savestate/savedata status, some measure of speed/fps? switch (payload.type) {