示例#1
0
static void SaveVmSettings()
{
	ScopedPtr<wxFileConfig> vmini( OpenFileConfig( GetVmSettingsFilename() ) );
	IniSaver vmsaver( vmini );
	g_Conf->EmuOptions.LoadSave( vmsaver );

	sApp.DispatchVmSettingsEvent( vmsaver );
}
示例#2
0
void roomOriginSize(room_s* r, vect3Di_s* o, vect3Di_s* s)
{
	if(!r || (!o && !s))return;

	vect3Di_s m=vect3Di(8192,8192,8192); vect3Di_s M=vect3Di(0,0,0);

	listCell_s *lc=r->rectangles.first;

	while(lc)
	{
		m=vmini(lc->data.position,m);
		m=vmini(vaddi(lc->data.position,lc->data.size),m);
		M=vmaxi(lc->data.position,M);
		M=vmaxi(vaddi(lc->data.position,lc->data.size),M);
		lc=lc->next;
	}

	if(o)*o=m;
	if(s)*s=vsubi(M,m);
}
示例#3
0
static void LoadVmSettings()
{
	// Load virtual machine options and apply some defaults overtop saved items, which
	// are regulated by the PCSX2 UI.

	ScopedPtr<wxFileConfig> vmini( OpenFileConfig( GetVmSettingsFilename() ) );
	IniLoader vmloader( vmini );
	g_Conf->EmuOptions.LoadSave( vmloader );
	g_Conf->EmuOptions.GS.LimitScalar = g_Conf->Framerate.NominalScalar;

	if (g_Conf->EnablePresets){
		g_Conf->IsOkApplyPreset(g_Conf->PresetIndex);
	}

	sApp.DispatchVmSettingsEvent( vmloader );
}