mirror of
https://github.com/libretro/RetroArch
synced 2025-04-17 02:43:03 +00:00
(360) Add second hardware filter option
This commit is contained in:
parent
9272fdcdd6
commit
16e7355314
@ -50,7 +50,6 @@
|
||||
<NavDown>XuiBackButton</NavDown>
|
||||
<ItemsText>Load State
|
||||
Save State
|
||||
Hardware filtering:
|
||||
Aspect Ratio:
|
||||
Overscan:
|
||||
Orientation:
|
||||
@ -110,6 +109,18 @@ Return to Dashboard
|
||||
<InterItemSpacing>0.000000,10.000000,0.000000</InterItemSpacing>
|
||||
</Properties>
|
||||
</XuiListItem>
|
||||
<XuiListItem>
|
||||
<Properties>
|
||||
<Id>control_ListItem</Id>
|
||||
<Width>226.000000</Width>
|
||||
<Height>45.000000</Height>
|
||||
<Position>7.000000,22.000000,0.000000</Position>
|
||||
<Anchor>5</Anchor>
|
||||
<Show>false</Show>
|
||||
<Visual>XuiButton</Visual>
|
||||
<InterItemSpacing>0.000000,10.000000,0.000000</InterItemSpacing>
|
||||
</Properties>
|
||||
</XuiListItem>
|
||||
</XuiCommonList>
|
||||
</XuiScene>
|
||||
</XuiCanvas>
|
||||
|
@ -50,7 +50,8 @@
|
||||
<NavDown>XuiBackButton</NavDown>
|
||||
<ItemsText>Rewind:
|
||||
Gamma Correction:
|
||||
Hardware filtering:
|
||||
Hardware filtering shader #1:
|
||||
Hardware filtering shader #2:
|
||||
Custom Scaling/Dual Shaders
|
||||
</ItemsText>
|
||||
</Properties>
|
||||
@ -138,6 +139,18 @@ Custom Scaling/Dual Shaders
|
||||
<InterItemSpacing>0.000000,10.000000,0.000000</InterItemSpacing>
|
||||
</Properties>
|
||||
</XuiListItem>
|
||||
<XuiListItem>
|
||||
<Properties>
|
||||
<Id>control_ListItem</Id>
|
||||
<Width>226.000000</Width>
|
||||
<Height>45.000000</Height>
|
||||
<Position>7.000000,22.000000,0.000000</Position>
|
||||
<Anchor>5</Anchor>
|
||||
<Show>false</Show>
|
||||
<Visual>XuiButton</Visual>
|
||||
<InterItemSpacing>0.000000,10.000000,0.000000</InterItemSpacing>
|
||||
</Properties>
|
||||
</XuiListItem>
|
||||
</XuiCommonList>
|
||||
</XuiScene>
|
||||
</XuiCanvas>
|
||||
|
@ -50,7 +50,6 @@
|
||||
<NavDown>XuiBackButton</NavDown>
|
||||
<ItemsText>Load State
|
||||
Save State
|
||||
Hardware filtering:
|
||||
Aspect Ratio:
|
||||
Overscan:
|
||||
Orientation:
|
||||
@ -98,6 +97,18 @@ Return to Dashboard
|
||||
<InterItemSpacing>0.000000,10.000000,0.000000</InterItemSpacing>
|
||||
</Properties>
|
||||
</XuiListItem>
|
||||
<XuiListItem>
|
||||
<Properties>
|
||||
<Id>control_ListItem</Id>
|
||||
<Width>226.000000</Width>
|
||||
<Height>45.000000</Height>
|
||||
<Position>7.000000,22.000000,0.000000</Position>
|
||||
<Anchor>5</Anchor>
|
||||
<Show>false</Show>
|
||||
<Visual>XuiButton</Visual>
|
||||
<InterItemSpacing>0.000000,10.000000,0.000000</InterItemSpacing>
|
||||
</Properties>
|
||||
</XuiListItem>
|
||||
</XuiCommonList>
|
||||
</XuiScene>
|
||||
</XuiCanvas>
|
||||
|
@ -50,7 +50,8 @@
|
||||
<NavDown>XuiBackButton</NavDown>
|
||||
<ItemsText>Rewind:
|
||||
Gamma Correction:
|
||||
Hardware filtering:
|
||||
Hardware filtering shader #1:
|
||||
Hardware filtering shader #2:
|
||||
Cutom Scaling/Dual Shaders:
|
||||
</ItemsText>
|
||||
</Properties>
|
||||
@ -114,6 +115,18 @@ Cutom Scaling/Dual Shaders:
|
||||
<InterItemSpacing>0.000000,10.000000,0.000000</InterItemSpacing>
|
||||
</Properties>
|
||||
</XuiListItem>
|
||||
<XuiListItem>
|
||||
<Properties>
|
||||
<Id>control_ListItem</Id>
|
||||
<Width>226.000000</Width>
|
||||
<Height>45.000000</Height>
|
||||
<Position>7.000000,22.000000,0.000000</Position>
|
||||
<Anchor>5</Anchor>
|
||||
<Show>false</Show>
|
||||
<Visual>XuiButton</Visual>
|
||||
<InterItemSpacing>0.000000,10.000000,0.000000</InterItemSpacing>
|
||||
</Properties>
|
||||
</XuiListItem>
|
||||
</XuiCommonList>
|
||||
</XuiScene>
|
||||
</XuiCanvas>
|
||||
|
30
360/menu.cpp
30
360/menu.cpp
@ -116,19 +116,6 @@ HRESULT CRetroArchCoreBrowser::OnInit(XUIMessageInit * pInitData, BOOL& bHandled
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
static const wchar_t * set_filter_element(int index)
|
||||
{
|
||||
switch(index)
|
||||
{
|
||||
case FALSE:
|
||||
return L"Hardware filtering: Point filtering";
|
||||
case TRUE:
|
||||
return L"Hardware filtering: Linear interpolation";
|
||||
}
|
||||
|
||||
return L"";
|
||||
}
|
||||
|
||||
HRESULT CRetroArchSettings::OnInit(XUIMessageInit * pInitData, BOOL& bHandled)
|
||||
{
|
||||
GetChildById(L"XuiSettingsList", &m_settingslist);
|
||||
@ -136,7 +123,8 @@ HRESULT CRetroArchSettings::OnInit(XUIMessageInit * pInitData, BOOL& bHandled)
|
||||
|
||||
m_settingslist.SetText(SETTING_EMU_REWIND_ENABLED, g_settings.rewind_enable ? L"Rewind: ON" : L"Rewind: OFF");
|
||||
m_settingslist.SetText(SETTING_GAMMA_CORRECTION_ENABLED, g_console.gamma_correction_enable ? L"Gamma correction: ON" : L"Gamma correction: OFF");
|
||||
m_settingslist.SetText(SETTING_HARDWARE_FILTERING, set_filter_element(g_settings.video.smooth));
|
||||
m_settingslist.SetText(SETTING_HW_TEXTURE_FILTER, g_settings.video.smooth ? L"Hardware filtering shader #1: Linear interpolation" : L"Hardware filtering shader #1: Point filtering");
|
||||
m_settingslist.SetText(SETTING_HW_TEXTURE_FILTER_2, g_settings.video.second_pass_smooth ? L"Hardware filtering shader #2: Linear interpolation" : L"Hardware filtering shader #2: Point filtering");
|
||||
m_settingslist.SetText(SETTING_SCALE_ENABLED, g_console.fbo_enabled ? L"Custom Scaling/Dual Shaders: ON" : L"Custom Scaling/Dual Shaders: OFF");
|
||||
|
||||
return S_OK;
|
||||
@ -146,8 +134,6 @@ HRESULT CRetroArchQuickMenu::OnInit(XUIMessageInit * pInitData, BOOL& bHandled)
|
||||
{
|
||||
GetChildById(L"XuiQuickMenuList", &m_quickmenulist);
|
||||
GetChildById(L"XuiBackButton", &m_back);
|
||||
|
||||
m_quickmenulist.SetText(MENU_ITEM_HARDWARE_FILTERING, set_filter_element(g_settings.video.smooth));
|
||||
switch(g_console.screen_orientation)
|
||||
{
|
||||
case ORIENTATION_NORMAL:
|
||||
@ -198,10 +184,6 @@ HRESULT CRetroArchQuickMenu::OnNotifyPress( HXUIOBJ hObjPressed, int & bHandled
|
||||
return_to_game();
|
||||
}
|
||||
break;
|
||||
case MENU_ITEM_HARDWARE_FILTERING:
|
||||
g_settings.video.smooth = !g_settings.video.smooth;
|
||||
m_quickmenulist.SetText(MENU_ITEM_HARDWARE_FILTERING, set_filter_element(g_settings.video.smooth));
|
||||
break;
|
||||
case MENU_ITEM_KEEP_ASPECT_RATIO:
|
||||
{
|
||||
g_console.aspect_ratio_index++;
|
||||
@ -415,9 +397,13 @@ HRESULT CRetroArchSettings::OnNotifyPress( HXUIOBJ hObjPressed, int & bHandled
|
||||
g_console.gamma_correction_enable = !g_console.gamma_correction_enable;
|
||||
m_settingslist.SetText(SETTING_GAMMA_CORRECTION_ENABLED, g_console.gamma_correction_enable ? L"Gamma correction: ON" : L"Gamma correction: OFF");
|
||||
break;
|
||||
case SETTING_HARDWARE_FILTERING:
|
||||
case SETTING_HW_TEXTURE_FILTER:
|
||||
g_settings.video.smooth = !g_settings.video.smooth;
|
||||
m_settingslist.SetText(SETTING_HARDWARE_FILTERING, set_filter_element(g_settings.video.smooth));
|
||||
m_settingslist.SetText(SETTING_HW_TEXTURE_FILTER, g_settings.video.smooth ? L"Hardware filtering shader #1: Linear interpolation" : L"Hardware filtering shader #1: Point filtering");
|
||||
break;
|
||||
case SETTING_HW_TEXTURE_FILTER_2:
|
||||
g_settings.video.second_pass_smooth = !g_settings.video.second_pass_smooth;
|
||||
m_settingslist.SetText(SETTING_HW_TEXTURE_FILTER_2, g_settings.video.second_pass_smooth ? L"Hardware filtering shader #2: Linear interpolation" : L"Hardware filtering shader #2: Point filtering");
|
||||
break;
|
||||
case SETTING_SCALE_ENABLED:
|
||||
g_console.fbo_enabled = !g_console.fbo_enabled;
|
||||
|
@ -24,7 +24,8 @@ enum
|
||||
{
|
||||
SETTING_EMU_REWIND_ENABLED = 0,
|
||||
SETTING_GAMMA_CORRECTION_ENABLED,
|
||||
SETTING_HARDWARE_FILTERING,
|
||||
SETTING_HW_TEXTURE_FILTER,
|
||||
SETTING_HW_TEXTURE_FILTER_2,
|
||||
SETTING_SCALE_ENABLED
|
||||
};
|
||||
|
||||
|
@ -22,7 +22,6 @@
|
||||
enum {
|
||||
MENU_ITEM_LOAD_STATE = 0,
|
||||
MENU_ITEM_SAVE_STATE,
|
||||
MENU_ITEM_HARDWARE_FILTERING,
|
||||
MENU_ITEM_KEEP_ASPECT_RATIO,
|
||||
MENU_ITEM_OVERSCAN_AMOUNT,
|
||||
MENU_ITEM_ORIENTATION,
|
||||
|
@ -609,8 +609,8 @@ static bool xdk360_gfx_frame(void *data, const void *frame,
|
||||
vid->d3dpp.BackBufferHeight, g_frame_count);
|
||||
set_viewport(false);
|
||||
|
||||
vid->d3d_render_device->SetSamplerState(0, D3DSAMP_MINFILTER, g_settings.video.smooth ? D3DTEXF_LINEAR : D3DTEXF_POINT);
|
||||
vid->d3d_render_device->SetSamplerState(0, D3DSAMP_MAGFILTER, g_settings.video.smooth ? D3DTEXF_LINEAR : D3DTEXF_POINT);
|
||||
vid->d3d_render_device->SetSamplerState(0, D3DSAMP_MINFILTER, g_settings.video.second_pass_smooth ? D3DTEXF_LINEAR : D3DTEXF_POINT);
|
||||
vid->d3d_render_device->SetSamplerState(0, D3DSAMP_MAGFILTER, g_settings.video.second_pass_smooth ? D3DTEXF_LINEAR : D3DTEXF_POINT);
|
||||
vid->d3d_render_device->SetSamplerState(0, D3DSAMP_ADDRESSU, D3DTADDRESS_BORDER);
|
||||
vid->d3d_render_device->SetSamplerState(0, D3DSAMP_ADDRESSV, D3DTADDRESS_BORDER);
|
||||
vid->d3d_render_device->SetVertexDeclaration(vid->v_decl);
|
||||
|
Loading…
x
Reference in New Issue
Block a user