Added not implemeted rendering backend chosing

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@1568 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
nakeee 2008-12-17 22:09:33 +00:00
parent 0159a027e4
commit c0b5aaa995
3 changed files with 57 additions and 33 deletions

View File

@ -32,46 +32,47 @@ struct Config
void Save(); void Save();
// General // General
bool bFullscreen; bool bFullscreen;
bool renderToMainframe; bool renderToMainframe;
char iFSResolution[16]; char iFSResolution[16];
char iWindowedRes[16]; char iWindowedRes[16];
bool bStretchToFit; char iBackend[10];
bool bKeepAR; bool bStretchToFit;
bool bHideCursor; bool bKeepAR;
bool bSafeTextureCache; bool bHideCursor;
bool bSafeTextureCache;
// Enhancements // Enhancements
int iMultisampleMode; int iMultisampleMode;
bool bForceFiltering; bool bForceFiltering;
int iMaxAnisotropy; int iMaxAnisotropy;
// Information // Information
bool bShowFPS; bool bShowFPS;
bool bOverlayStats; bool bOverlayStats;
bool bTexFmtOverlayEnable; bool bTexFmtOverlayEnable;
bool bTexFmtOverlayCenter; bool bTexFmtOverlayCenter;
// Render // Render
bool bUseXFB; bool bUseXFB;
bool bWireFrame; bool bWireFrame;
bool bDisableLighting; bool bDisableLighting;
bool bDisableTexturing; bool bDisableTexturing;
// Utility // Utility
char texDumpPath[280]; char texDumpPath[280];
bool bDumpTextures; bool bDumpTextures;
// Hacks // Hacks
bool bEFBToTextureDisable; bool bEFBToTextureDisable;
bool bEFBToTextureDisableHotKey; bool bEFBToTextureDisableHotKey;
bool bProjectionHax1; bool bProjectionHax1;
bool bProjectionHax2; bool bProjectionHax2;
int iLog; // CONF_ bits int iLog; // CONF_ bits
int iSaveTargetId; int iSaveTargetId;
//currently unused: //currently unused:
int iCompileDLsLevel; int iCompileDLsLevel;
bool bShowShaderErrors; bool bShowShaderErrors;
}; };

View File

@ -110,13 +110,20 @@ void ConfigDialog::CreateGUIControls()
m_KeepAR->SetValue(g_Config.bKeepAR); m_KeepAR->SetValue(g_Config.bKeepAR);
m_HideCursor = new wxCheckBox(m_PageGeneral, ID_HIDECURSOR, wxT("Hide mouse cursor"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator); m_HideCursor = new wxCheckBox(m_PageGeneral, ID_HIDECURSOR, wxT("Hide mouse cursor"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator);
m_HideCursor->SetValue(g_Config.bHideCursor); m_HideCursor->SetValue(g_Config.bHideCursor);
wxStaticText *FSText = new wxStaticText(m_PageGeneral, ID_FSTEXT, wxT("Fullscreen video mode:"), wxDefaultPosition, wxDefaultSize, 0); wxStaticText *FSText = new wxStaticText(m_PageGeneral, ID_FSTEXT, wxT("Fullscreen video mode:"), wxDefaultPosition, wxDefaultSize, 0);
m_FullscreenCB = new wxComboBox(m_PageGeneral, ID_FULLSCREENCB, wxEmptyString, wxDefaultPosition, wxDefaultSize, arrayStringFor_FullscreenCB, 0, wxDefaultValidator); m_FullscreenCB = new wxComboBox(m_PageGeneral, ID_FULLSCREENCB, wxEmptyString, wxDefaultPosition, wxDefaultSize, arrayStringFor_FullscreenCB, 0, wxDefaultValidator);
m_FullscreenCB->SetValue(wxString::FromAscii(g_Config.iFSResolution)); m_FullscreenCB->SetValue(wxString::FromAscii(g_Config.iFSResolution));
wxStaticText *WMText = new wxStaticText(m_PageGeneral, ID_WMTEXT, wxT("Windowed resolution:"), wxDefaultPosition, wxDefaultSize, 0); wxStaticText *WMText = new wxStaticText(m_PageGeneral, ID_WMTEXT, wxT("Windowed resolution:"), wxDefaultPosition, wxDefaultSize, 0);
m_WindowResolutionCB = new wxComboBox(m_PageGeneral, ID_WINDOWRESOLUTIONCB, wxEmptyString, wxDefaultPosition, wxDefaultSize, arrayStringFor_WindowResolutionCB, 0, wxDefaultValidator); m_WindowResolutionCB = new wxComboBox(m_PageGeneral, ID_WINDOWRESOLUTIONCB, wxEmptyString, wxDefaultPosition, wxDefaultSize, arrayStringFor_WindowResolutionCB, 0, wxDefaultValidator);
m_WindowResolutionCB->SetValue(wxString::FromAscii(g_Config.iWindowedRes)); m_WindowResolutionCB->SetValue(wxString::FromAscii(g_Config.iWindowedRes));
wxStaticText *BEText = new wxStaticText(m_PageGeneral, ID_BETEXT, wxT("Rendering backend:"), wxDefaultPosition, wxDefaultSize, 0);
m_RenderBackend = new wxComboBox(m_PageGeneral, ID_RENDERBACKEND, wxEmptyString, wxDefaultPosition, wxDefaultSize, arrayStringFor_RenderBackend, 0, wxDefaultValidator);
m_RenderBackend->SetValue(wxString::FromAscii(g_Config.iBackend));
// Enhancements // Enhancements
sbEnhancements = new wxStaticBoxSizer(wxVERTICAL, m_PageGeneral, wxT("Enhancements")); sbEnhancements = new wxStaticBoxSizer(wxVERTICAL, m_PageGeneral, wxT("Enhancements"));
m_ForceFiltering = new wxCheckBox(m_PageGeneral, ID_FORCEFILTERING, wxT("Force bi/trilinear filtering (May cause small glitches)"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator); m_ForceFiltering = new wxCheckBox(m_PageGeneral, ID_FORCEFILTERING, wxT("Force bi/trilinear filtering (May cause small glitches)"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator);
@ -149,6 +156,8 @@ void ConfigDialog::CreateGUIControls()
sBasic->Add(m_FullscreenCB, wxGBPosition(5, 1), wxGBSpan(1, 1), wxALL, 5); sBasic->Add(m_FullscreenCB, wxGBPosition(5, 1), wxGBSpan(1, 1), wxALL, 5);
sBasic->Add(WMText, wxGBPosition(6, 0), wxGBSpan(1, 1), wxALIGN_CENTER_VERTICAL|wxALL, 5); sBasic->Add(WMText, wxGBPosition(6, 0), wxGBSpan(1, 1), wxALIGN_CENTER_VERTICAL|wxALL, 5);
sBasic->Add(m_WindowResolutionCB, wxGBPosition(6, 1), wxGBSpan(1, 1), wxALL, 5); sBasic->Add(m_WindowResolutionCB, wxGBPosition(6, 1), wxGBSpan(1, 1), wxALL, 5);
sBasic->Add(BEText, wxGBPosition(7, 0), wxGBSpan(1, 1), wxALIGN_CENTER_VERTICAL|wxALL, 5);
sBasic->Add(m_RenderBackend, wxGBPosition(7, 1), wxGBSpan(1, 1), wxALL, 5);
sbBasic->Add(sBasic); sbBasic->Add(sBasic);
sGeneral->Add(sbBasic, 0, wxEXPAND|wxALL, 5); sGeneral->Add(sbBasic, 0, wxEXPAND|wxALL, 5);
@ -294,6 +303,12 @@ void ConfigDialog::AddWindowReso(char *reso)
m_WindowResolutionCB->Append(wxString::FromAscii(reso)); m_WindowResolutionCB->Append(wxString::FromAscii(reso));
} }
void ConfigDialog::AddRenderBackend(char *backend)
{
m_RenderBackend->Append(wxString::FromAscii(backend));
}
void ConfigDialog::AddAAMode(int mode) void ConfigDialog::AddAAMode(int mode)
{ {
wxString tmp; wxString tmp;
@ -334,6 +349,9 @@ void ConfigDialog::GeneralSettingsChanged(wxCommandEvent& event)
case ID_WINDOWRESOLUTIONCB: case ID_WINDOWRESOLUTIONCB:
strcpy(g_Config.iWindowedRes, m_WindowResolutionCB->GetValue().mb_str() ); strcpy(g_Config.iWindowedRes, m_WindowResolutionCB->GetValue().mb_str() );
break; break;
case ID_RENDERBACKEND:
strcpy(g_Config.iBackend, m_RenderBackend->GetValue().mb_str() );
break;
case ID_FORCEFILTERING: case ID_FORCEFILTERING:
g_Config.bForceFiltering = m_ForceFiltering->IsChecked(); g_Config.bForceFiltering = m_ForceFiltering->IsChecked();
break; break;

View File

@ -42,6 +42,7 @@ class ConfigDialog : public wxDialog
void AddFSReso(char *reso); void AddFSReso(char *reso);
void AddWindowReso(char *reso); void AddWindowReso(char *reso);
void AddRenderBackend(char *backend);
void AddAAMode(int mode); void AddAAMode(int mode);
private: private:
@ -76,6 +77,8 @@ class ConfigDialog : public wxDialog
wxComboBox *m_FullscreenCB; wxComboBox *m_FullscreenCB;
wxArrayString arrayStringFor_WindowResolutionCB; wxArrayString arrayStringFor_WindowResolutionCB;
wxComboBox *m_WindowResolutionCB; wxComboBox *m_WindowResolutionCB;
wxArrayString arrayStringFor_RenderBackend;
wxComboBox *m_RenderBackend;
wxCheckBox *m_ForceFiltering; // advanced wxCheckBox *m_ForceFiltering; // advanced
wxChoice *m_MaxAnisotropyCB; wxChoice *m_MaxAnisotropyCB;
@ -115,6 +118,8 @@ class ConfigDialog : public wxDialog
ID_FULLSCREENCB, ID_FULLSCREENCB,
ID_WMTEXT, ID_WMTEXT,
ID_WINDOWRESOLUTIONCB, ID_WINDOWRESOLUTIONCB,
ID_BETEXT,
ID_RENDERBACKEND,
ID_FORCEFILTERING, ID_FORCEFILTERING,
ID_MAXANISOTROPY, ID_MAXANISOTROPY,