コード例 #1
0
ファイル: Reporting.cpp プロジェクト: JakotsuTheOne/ppsspp
	void AddGameInfo(UrlEncoder &postdata)
	{
		// TODO: Maybe ParamSFOData shouldn't include nulls in std::strings?  Don't work to break savedata, though...
		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("sdkver", sceKernelGetCompiledSdkVersion());
	}
コード例 #2
0
ファイル: Reporting.cpp プロジェクト: makotech222/ppsspp
	std::string CurrentGameID()
	{
		// TODO: Maybe ParamSFOData shouldn't include nulls in std::strings?  Don't work to break savedata, though...
		const std::string disc_id = StripTrailingNull(g_paramSFO.GetValueString("DISC_ID"));
		const std::string disc_version = StripTrailingNull(g_paramSFO.GetValueString("DISC_VERSION"));
		return disc_id + "_" + disc_version;
	}
コード例 #3
0
ファイル: Reporting.cpp プロジェクト: 173210/ppsspp
	int Process(int pos)
	{
		Payload &payload = payloadBuffer[pos];

		std::string gpuPrimary, gpuFull;
		if (gpu)
			gpu->GetReportingInfo(gpuPrimary, gpuFull);

		UrlEncoder postdata;
		postdata.Add("version", PPSSPP_GIT_VERSION);
		// TODO: Maybe ParamSFOData shouldn't include nulls in std::strings?  Don't work to break savedata, though...
		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", gpuPrimary);
		postdata.Add("gpu_full", gpuFull);
		postdata.Add("cpu", cpu_info.Summarize());
		postdata.Add("platform", GetPlatformIdentifer());
		postdata.Add("sdkver", sceKernelGetCompiledSdkVersion());
		postdata.Add("pixel_width", PSP_CoreParameter().pixelWidth);
		postdata.Add("pixel_height", PSP_CoreParameter().pixelHeight);
		postdata.Add("ticks", (const uint64_t)CoreTiming::GetTicks());

		if (g_Config.iShowFPSCounter)
		{
			float vps, fps;
			__DisplayGetAveragedFPS(&vps, &fps);
			postdata.Add("vps", vps);
			postdata.Add("fps", fps);
		}

		// TODO: Settings, savestate/savedata status, some measure of speed/fps?

		switch (payload.type)
		{
		case MESSAGE:
			postdata.Add("message", payload.string1);
			postdata.Add("value", payload.string2);
			payload.string1.clear();
			payload.string2.clear();

			SendReportRequest("/report/message", postdata.ToString());
			break;
		}

		return 0;
	}
コード例 #4
0
ファイル: UID.cpp プロジェクト: PatrickRABEL/dicomlib
	/*!
		a UID can only be created from a std::string object.
		The construct verifies that the string conforms to
		the standard description of unique identifiers.

	*/
	UID::UID(const std::string& s) : data_(s)
	{
		if(data_.size()>64)
		{
			std::ostringstream error;
			error << "UID : " << s << " is too long";
			throw InvalidUID(error.str());
		}
		// Following line was previously commented out.
		StripTrailingWhitespace(data_);
		StripTrailingNull(data_);
		std::for_each(data_.begin(),data_.end(),ThrowIfInvalid);

	}
コード例 #5
0
ファイル: Reporting.cpp プロジェクト: makotech222/ppsspp
	void AddGameInfo(UrlEncoder &postdata)
	{
		postdata.Add("game", CurrentGameID());
		postdata.Add("game_title", StripTrailingNull(g_paramSFO.GetValueString("TITLE")));
		postdata.Add("sdkver", sceKernelGetCompiledSdkVersion());
	}