Removed the Projection Hacks since the Original Projection was correct, I never ment to commit those projection changes anyway ;p

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@1063 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
Sonicadvance1 2008-11-04 01:38:20 +00:00
parent 5507cc7b95
commit 712a391cb8
5 changed files with 52 additions and 104 deletions

View File

@ -78,8 +78,6 @@ void Config::Load()
iniFile.Get("Enhancements", "KeepAR", &bKeepAR, false); iniFile.Get("Enhancements", "KeepAR", &bKeepAR, false);
iniFile.Get("Hacks", "InvertDepth", &bInvertDepth, 0); iniFile.Get("Hacks", "InvertDepth", &bInvertDepth, 0);
iniFile.Get("Hacks", "ProjectionHax1", &bProjectionHax1, 0);
iniFile.Get("Hacks", "ProjectionHax2", &bProjectionHax2, 0);
iniFile.Get("Hacks", "EFBToTextureDisable", &bEBFToTextureDisable, 0); iniFile.Get("Hacks", "EFBToTextureDisable", &bEBFToTextureDisable, 0);
} }
@ -114,8 +112,6 @@ void Config::Save()
iniFile.Set("Enhancements", "KeepAR", bKeepAR); iniFile.Set("Enhancements", "KeepAR", bKeepAR);
iniFile.Set("Hacks", "InvertDepth", bInvertDepth); iniFile.Set("Hacks", "InvertDepth", bInvertDepth);
iniFile.Set("Hacks", "ProjectionHax1", bProjectionHax1);
iniFile.Set("Hacks", "ProjectionHax2", bProjectionHax2);
iniFile.Set("Hacks", "EFBToTextureDisable", bEBFToTextureDisable); iniFile.Set("Hacks", "EFBToTextureDisable", bEBFToTextureDisable);
iniFile.Save("gfx_opengl.ini"); iniFile.Save("gfx_opengl.ini");

View File

@ -62,8 +62,6 @@ struct Config
// Hacks // Hacks
bool bInvertDepth; bool bInvertDepth;
bool bProjectionHax1;
bool bProjectionHax2;
bool bEBFToTextureDisable; bool bEBFToTextureDisable;
int iLog; // CONF_ bits int iLog; // CONF_ bits

View File

@ -45,8 +45,6 @@ BEGIN_EVENT_TABLE(ConfigDialog,wxDialog)
EVT_CHECKBOX(ID_USEXFB,ConfigDialog::UseXFBChange) EVT_CHECKBOX(ID_USEXFB,ConfigDialog::UseXFBChange)
EVT_CHECKBOX(ID_DUMPTEXTURES,ConfigDialog::DumpTexturesChange) EVT_CHECKBOX(ID_DUMPTEXTURES,ConfigDialog::DumpTexturesChange)
EVT_CHECKBOX(ID_INVERTDEPTH,ConfigDialog::InvertDepth) EVT_CHECKBOX(ID_INVERTDEPTH,ConfigDialog::InvertDepth)
EVT_CHECKBOX(ID_PROJECTIONHAX1,ConfigDialog::ProjectionHax1)
EVT_CHECKBOX(ID_PROJECTIONHAX2,ConfigDialog::ProjectionHax2)
EVT_CHECKBOX(ID_DISABLELIGHTING,ConfigDialog::DisableLighting) EVT_CHECKBOX(ID_DISABLELIGHTING,ConfigDialog::DisableLighting)
EVT_CHECKBOX(ID_DISABLETEXTURING,ConfigDialog::DisableTexturing) EVT_CHECKBOX(ID_DISABLETEXTURING,ConfigDialog::DisableTexturing)
EVT_CHECKBOX(ID_EFBTOTEXTUREDISABLE,ConfigDialog::EFBToTextureDisable) EVT_CHECKBOX(ID_EFBTOTEXTUREDISABLE,ConfigDialog::EFBToTextureDisable)
@ -203,14 +201,6 @@ void ConfigDialog::CreateGUIControls()
m_EFBToTextureDisable->Enable(true); m_EFBToTextureDisable->Enable(true);
m_EFBToTextureDisable->SetValue(g_Config.bEBFToTextureDisable); m_EFBToTextureDisable->SetValue(g_Config.bEBFToTextureDisable);
m_ProjectionHax1 = new wxCheckBox(m_PageHacks, ID_PROJECTIONHAX1, wxT("Projection before R945"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator);
m_ProjectionHax1->Enable(true);
m_ProjectionHax1->SetValue(g_Config.bProjectionHax1);
m_ProjectionHax2 = new wxCheckBox(m_PageHacks, ID_PROJECTIONHAX2, wxT("Projection hack of R844"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator);
m_ProjectionHax2->Enable(true);
m_ProjectionHax2->SetValue(g_Config.bProjectionHax2);
//Put options in sizers within the notebook //Put options in sizers within the notebook
wxGridBagSizer* sPage1; wxGridBagSizer* sPage1;
sPage1 = new wxGridBagSizer(0, 0); sPage1 = new wxGridBagSizer(0, 0);
@ -277,8 +267,6 @@ void ConfigDialog::CreateGUIControls()
sPage6->SetNonFlexibleGrowMode(wxFLEX_GROWMODE_SPECIFIED); sPage6->SetNonFlexibleGrowMode(wxFLEX_GROWMODE_SPECIFIED);
sPage6->Add(m_InvertDepth, wxGBPosition(0, 0), wxGBSpan(1, 2), wxALL, 5); sPage6->Add(m_InvertDepth, wxGBPosition(0, 0), wxGBSpan(1, 2), wxALL, 5);
sPage6->Add(m_EFBToTextureDisable, wxGBPosition(1, 0), wxGBSpan(1, 2), wxALL, 5); sPage6->Add(m_EFBToTextureDisable, wxGBPosition(1, 0), wxGBSpan(1, 2), wxALL, 5);
sPage6->Add(m_ProjectionHax1, wxGBPosition(2, 0), wxGBSpan(1, 2), wxALL, 5);
sPage6->Add(m_ProjectionHax2, wxGBPosition(3, 0), wxGBSpan(1, 2), wxALL, 5);
m_PageHacks->SetSizer(sPage6); m_PageHacks->SetSizer(sPage6);
sPage6->Layout(); sPage6->Layout();
@ -428,14 +416,6 @@ void ConfigDialog::InvertDepth(wxCommandEvent& event)
{ {
g_Config.bInvertDepth = m_InvertDepth->IsChecked(); g_Config.bInvertDepth = m_InvertDepth->IsChecked();
} }
void ConfigDialog::ProjectionHax1(wxCommandEvent& event)
{
g_Config.bProjectionHax1 = m_ProjectionHax1->IsChecked();
}
void ConfigDialog::ProjectionHax2(wxCommandEvent& event)
{
g_Config.bProjectionHax2 = m_ProjectionHax2->IsChecked();
}
void ConfigDialog::DisableLighting(wxCommandEvent &event) void ConfigDialog::DisableLighting(wxCommandEvent &event)
{ {

View File

@ -82,8 +82,6 @@ class ConfigDialog : public wxDialog
// Hacks // Hacks
void InvertDepth(wxCommandEvent& event); void InvertDepth(wxCommandEvent& event);
void ProjectionHax1(wxCommandEvent& event);
void ProjectionHax2(wxCommandEvent& event);
void EFBToTextureDisable(wxCommandEvent& event); void EFBToTextureDisable(wxCommandEvent& event);
private: private:

View File

@ -451,19 +451,7 @@ void VertexShaderMngr::SetConstants()
g_fProjectionMatrix[9] = 0.0f; g_fProjectionMatrix[9] = 0.0f;
g_fProjectionMatrix[10] = xfregs.rawProjection[4]; g_fProjectionMatrix[10] = xfregs.rawProjection[4];
if((!g_Config.bProjectionHax1 && !g_Config.bProjectionHax2) || (g_Config.bProjectionHax1 && g_Config.bProjectionHax2)) { g_fProjectionMatrix[11] = xfregs.rawProjection[5];
// Working bloom in ZTP
g_fProjectionMatrix[11] = -(0.0f - xfregs.rawProjection[5]); // Yes, it's important that it's done this way.
// Working projection in PSO
// g_fProjectionMatrix[11] = -(1.0f - rawProjection[5]);
}
if(g_Config.bProjectionHax1 && !g_Config.bProjectionHax2) // Before R945
g_fProjectionMatrix[11] = -(1.0f - xfregs.rawProjection[5]);
if(!g_Config.bProjectionHax1 && g_Config.bProjectionHax2) // R844
g_fProjectionMatrix[11] = xfregs.rawProjection[5];
g_fProjectionMatrix[12] = 0.0f; g_fProjectionMatrix[12] = 0.0f;
g_fProjectionMatrix[13] = 0.0f; g_fProjectionMatrix[13] = 0.0f;
// donkopunchstania: GC GPU rounds differently? // donkopunchstania: GC GPU rounds differently?
@ -485,19 +473,7 @@ void VertexShaderMngr::SetConstants()
g_fProjectionMatrix[8] = 0.0f; g_fProjectionMatrix[8] = 0.0f;
g_fProjectionMatrix[9] = 0.0f; g_fProjectionMatrix[9] = 0.0f;
g_fProjectionMatrix[10] = xfregs.rawProjection[4]; g_fProjectionMatrix[10] = xfregs.rawProjection[4];
g_fProjectionMatrix[11] = -(-1.0f - xfregs.rawProjection[5]);
if((!g_Config.bProjectionHax1 && !g_Config.bProjectionHax2) || (g_Config.bProjectionHax1 && g_Config.bProjectionHax2)) {
// Working bloom in ZTP
g_fProjectionMatrix[11] = -(-1.0f - xfregs.rawProjection[5]); // Yes, it's important that it's done this way.
// Working projection in PSO, working Super Monkey Ball
// g_fProjectionMatrix[11] = -(0.0f - xfregs.rawProjection[5]);
}
if(g_Config.bProjectionHax1 && !g_Config.bProjectionHax2) // Before R945
g_fProjectionMatrix[11] = -(0.0f - xfregs.rawProjection[5]);
if(!g_Config.bProjectionHax1 && g_Config.bProjectionHax2) // R844
g_fProjectionMatrix[11] = -xfregs.rawProjection[5];
g_fProjectionMatrix[12] = 0; g_fProjectionMatrix[12] = 0;
g_fProjectionMatrix[13] = 0; g_fProjectionMatrix[13] = 0;