Example #1
0
void __SasDoState(PointerWrap &p) {
	p.DoClass(sas);
	p.DoMarker("sceSas");
}
Example #2
0
void VideoCommon_DoState(PointerWrap &p)
{
	// BP Memory
	p.Do(bpmem);
	p.DoMarker("BP Memory");

	// CP Memory
	DoCPState(p);

	// XF Memory
	p.Do(xfmem);
	p.DoMarker("XF Memory");

	// Texture decoder
	p.DoArray(texMem);
	p.DoMarker("texMem");

	// FIFO
	Fifo::DoState(p);
	p.DoMarker("Fifo");

	CommandProcessor::DoState(p);
	p.DoMarker("CommandProcessor");

	PixelEngine::DoState(p);
	p.DoMarker("PixelEngine");

	// the old way of replaying current bpmem as writes to push side effects to pixel shader manager doesn't really work.
	PixelShaderManager::DoState(p);
	p.DoMarker("PixelShaderManager");

	VertexShaderManager::DoState(p);
	p.DoMarker("VertexShaderManager");

	GeometryShaderManager::DoState(p);
	p.DoMarker("GeometryShaderManager");

	VertexManagerBase::DoState(p);
	p.DoMarker("VertexManager");

	BoundingBox::DoState(p);
	p.DoMarker("BoundingBox");


	// TODO: search for more data that should be saved and add it here
}
Example #3
0
void __PsmfPlayerDoState(PointerWrap &p)
{
	p.Do(psmfPlayerMap);

	p.DoMarker("scePsmfPlayer");
}
Example #4
0
	virtual void DoState(PointerWrap &p)
	{
		p.Do(alm);
		p.DoMarker("Alarm");
	}
Example #5
0
	virtual void DoState(PointerWrap &p) {
		p.Do(moduleID_);
		p.Do(retValAddr);
		p.DoMarker("AfterModuleEntryCall");
	}
Example #6
0
void __KernelMbxDoState(PointerWrap &p)
{
	p.Do(mbxWaitTimer);
	CoreTiming::RestoreRegisterEvent(mbxWaitTimer, "MbxTimeout", __KernelMbxTimeout);
	p.DoMarker("sceKernelMbx");
}
Example #7
0
void __PowerDoState(PointerWrap &p) {
    p.DoArray(powerCbSlots, ARRAY_SIZE(powerCbSlots));
    p.Do(volatileMemLocked);
    p.DoMarker("scePower");
}
Example #8
0
	void DoState(PointerWrap &p)
	{
		p.Do(savedCpu);
		p.DoMarker("InterruptState");
	}
Example #9
0
void __SasDoState(PointerWrap &p) {
	if (sas != NULL) {
		sas->DoState(p);
	}
	p.DoMarker("sceSas");
}
Example #10
0
void IntrHandler::DoState(PointerWrap &p)
{
	p.Do(intrNumber);
	p.Do<int, SubIntrHandler>(subIntrHandlers);
	p.DoMarker("IntrHandler");
}
Example #11
0
void PendingInterrupt::DoState(PointerWrap &p)
{
	p.Do(intr);
	p.Do(subintr);
	p.DoMarker("PendingInterrupt");
}
Example #12
0
	void DoState(PointerWrap &p) { p.Do(fontLibID_); p.DoMarker("PostOpenCallback"); }
Example #13
0
	void DoState(PointerWrap &p) {
		p.Do(pgf_);
		p.Do(style_);
		p.DoMarker("Font");
	}
Example #14
0
void __RtcDoState(PointerWrap &p)
{
	p.Do(rtcBaseTime);

	p.DoMarker("sceRtc");
}
Example #15
0
	void DoState(PointerWrap &p) { p.Do(ringAddr_); p.DoMarker("PostPutAction"); }
Example #16
0
	virtual void DoState(PointerWrap &p)
	{
		p.Do(nm);
		p.Do(memoryBlockAddr);
		p.DoMarker("Module");
	}
Example #17
0
void __FontDoState(PointerWrap &p)
{
	p.Do(fontLib);
	p.DoMarker("sceFont");
}
Example #18
0
void __KernelTimeDoState(PointerWrap &p)
{
	p.Do(start_time);
	p.DoMarker("sceKernelTime");
}
Example #19
0
	virtual void DoState(PointerWrap &p)
	{
		p.Do(address);
		p.DoArray(name, sizeof(name));
		p.DoMarker("PMB");
	}
Example #20
0
void GPUCommon::DoState(PointerWrap &p) {
	p.Do(dlIdGenerator);
	p.Do<DisplayList>(dlQueue);
	p.DoMarker("GPUCommon");
}
Example #21
0
void __KernelAlarmDoState(PointerWrap &p)
{
	p.Do(alarmTimer);
	CoreTiming::RestoreRegisterEvent(alarmTimer, "Alarm", __KernelTriggerAlarm);
	p.DoMarker("sceKernelAlarm");
}
Example #22
0
void __KernelVTimerDoState(PointerWrap &p) {
	p.Do(vtimerTimer);
	p.Do(vtimers);
	CoreTiming::RestoreRegisterEvent(vtimerTimer, "VTimer", __KernelTriggerVTimer);
	p.DoMarker("sceKernelVTimer");
}
Example #23
0
	virtual void DoState(PointerWrap &p)
	{
		SubIntrHandler::DoState(p);
		p.Do(alarmID);
		p.DoMarker("AlarmIntrHandler");
	}
Example #24
0
	virtual void DoState(PointerWrap &p) {
		p.Do(nvt);
		p.Do(memoryPtr);
		p.DoMarker("VTimer");
	}
Example #25
0
void __AtracDoState(PointerWrap &p) {
	p.Do(atracMap);
	p.Do(nextAtracID);

	p.DoMarker("sceAtrac");
}
Example #26
0
// This feels like a dubious proposition, mostly...
void __NetDoState(PointerWrap &p) {
	p.Do(netInited);
	p.Do(netAdhocInited);
	p.DoMarker("net");
}
Example #27
0
void __PsmfDoState(PointerWrap &p)
{
	p.Do(psmfMap);

	p.DoMarker("scePsmf");
}
Example #28
0
void __KernelEventFlagDoState(PointerWrap &p)
{
	p.Do(eventFlagWaitTimer);
	CoreTiming::RestoreRegisterEvent(eventFlagWaitTimer, "EventFlagTimeout", __KernelEventFlagTimeout);
	p.DoMarker("sceKernelEventFlag");
}
Example #29
0
	void DoState(PointerWrap &p)
	{
		Memory::DoState(p);
		p.DoMarker("Memory");
		VideoInterface::DoState(p);
		p.DoMarker("VideoInterface");
		SerialInterface::DoState(p);
		p.DoMarker("SerialInterface");
		ProcessorInterface::DoState(p);
		p.DoMarker("ProcessorInterface");
		DSP::DoState(p);
		p.DoMarker("DSP");
		DVDInterface::DoState(p);
		p.DoMarker("DVDInterface");
		GPFifo::DoState(p);
		p.DoMarker("GPFifo");
		ExpansionInterface::DoState(p);
		p.DoMarker("ExpansionInterface");
		AudioInterface::DoState(p);
		p.DoMarker("AudioInterface");

		if (SConfig::GetInstance().bWii)
		{
			WII_IPCInterface::DoState(p);
			p.DoMarker("WII_IPCInterface");
			WII_IPC_HLE_Interface::DoState(p);
			p.DoMarker("WII_IPC_HLE_Interface");
		}

		p.DoMarker("WIIHW");
	}
Example #30
0
static std::string DoState(PointerWrap& p)
{
	u32 version = STATE_VERSION;
	{
		static const u32 COOKIE_BASE = 0xBAADBABE;
		u32 cookie = version + COOKIE_BASE;
		p.Do(cookie);
		version = cookie - COOKIE_BASE;
	}

	std::string version_created_by = scm_rev_str;
	if (version > 42)
		p.Do(version_created_by);
	else
		version_created_by.clear();

	if (version != STATE_VERSION)
	{
		if (version_created_by.empty() && s_old_versions.count(version))
		{
			// The savestate is from an old version that doesn't
			// save the Dolphin version number to savestates, but
			// by looking up the savestate version number, it is possible
			// to know approximately which Dolphin version was used.

			std::pair<std::string, std::string> version_range = s_old_versions.find(version)->second;
			std::string oldest_version = version_range.first;
			std::string newest_version = version_range.second;

			version_created_by = "Dolphin " + oldest_version + " - " + newest_version;
		}

		// because the version doesn't match, fail.
		// this will trigger an OSD message like "Can't load state from other revisions"
		// we could use the version numbers to maintain some level of backward compatibility, but currently don't.
		p.SetMode(PointerWrap::MODE_MEASURE);
		return version_created_by;
	}

	p.DoMarker("Version");

	// Begin with video backend, so that it gets a chance to clear its caches and writeback modified things to RAM
	g_video_backend->DoState(p);
	p.DoMarker("video_backend");

	if (SConfig::GetInstance().m_LocalCoreStartupParameter.bWii)
		Wiimote::DoState(p.GetPPtr(), p.GetMode());
	p.DoMarker("Wiimote");

	PowerPC::DoState(p);
	p.DoMarker("PowerPC");
	HW::DoState(p);
	p.DoMarker("HW");
	CoreTiming::DoState(p);
	p.DoMarker("CoreTiming");
	Movie::DoState(p);
	p.DoMarker("Movie");

#if defined(HAVE_LIBAV) || defined (WIN32)
	AVIDump::DoState();
#endif

	return version_created_by;
}