[Glide64] Make n64_z_scale private
This commit is contained in:
parent
799fa6700d
commit
30fc06152f
|
@ -79,7 +79,7 @@ CSettings::CSettings() :
|
||||||
m_correct_viewport(false), //correct viewport values
|
m_correct_viewport(false), //correct viewport values
|
||||||
m_zmode_compare_less(false), //force GR_CMP_LESS for zmode=0 (opaque)and zmode=1 (interpenetrating)
|
m_zmode_compare_less(false), //force GR_CMP_LESS for zmode=0 (opaque)and zmode=1 (interpenetrating)
|
||||||
m_old_style_adither(false), //apply alpha dither regardless of alpha_dither_mode
|
m_old_style_adither(false), //apply alpha dither regardless of alpha_dither_mode
|
||||||
n64_z_scale(0), //scale vertex z value before writing to depth buffer, as N64 does.
|
m_n64_z_scale(false), //scale vertex z value before writing to depth buffer, as N64 does.
|
||||||
|
|
||||||
m_hacks((hacks_t)0),
|
m_hacks((hacks_t)0),
|
||||||
|
|
||||||
|
@ -178,7 +178,7 @@ void CSettings::RegisterSettings(void)
|
||||||
game_setting(Set_adjust_aspect, "adjust_aspect", true);
|
game_setting(Set_adjust_aspect, "adjust_aspect", true);
|
||||||
game_setting(Set_zmode_compare_less, "zmode_compare_less", false);
|
game_setting(Set_zmode_compare_less, "zmode_compare_less", false);
|
||||||
game_setting(Set_old_style_adither, "old_style_adither", false);
|
game_setting(Set_old_style_adither, "old_style_adither", false);
|
||||||
game_setting(Set_n64_z_scale, "n64_z_scale", 0);
|
game_setting(Set_n64_z_scale, "n64_z_scale", false);
|
||||||
game_setting_default(Set_optimize_texrect, "optimize_texrect", Set_optimize_texrect_default);
|
game_setting_default(Set_optimize_texrect, "optimize_texrect", Set_optimize_texrect_default);
|
||||||
game_setting(Set_ignore_aux_copy, "ignore_aux_copy", false);
|
game_setting(Set_ignore_aux_copy, "ignore_aux_copy", false);
|
||||||
game_setting(Set_hires_buf_clear, "hires_buf_clear", true);
|
game_setting(Set_hires_buf_clear, "hires_buf_clear", true);
|
||||||
|
@ -731,7 +731,7 @@ void CSettings::ReadGameSettings(const char * name)
|
||||||
m_adjust_aspect = GetSetting(Set_adjust_aspect);
|
m_adjust_aspect = GetSetting(Set_adjust_aspect);
|
||||||
m_zmode_compare_less = GetSetting(Set_zmode_compare_less);
|
m_zmode_compare_less = GetSetting(Set_zmode_compare_less);
|
||||||
m_old_style_adither = GetSetting(Set_old_style_adither);
|
m_old_style_adither = GetSetting(Set_old_style_adither);
|
||||||
g_settings->n64_z_scale = GetSetting(Set_n64_z_scale);
|
m_n64_z_scale = GetSetting(Set_n64_z_scale) != 0;
|
||||||
|
|
||||||
m_ScreenRes = GetSetting(Set_Resolution);
|
m_ScreenRes = GetSetting(Set_Resolution);
|
||||||
if (m_ScreenRes >= GetScreenResolutionCount()) { m_ScreenRes = GetDefaultScreenRes(); }
|
if (m_ScreenRes >= GetScreenResolutionCount()) { m_ScreenRes = GetDefaultScreenRes(); }
|
||||||
|
|
|
@ -253,7 +253,7 @@ public:
|
||||||
inline bool correct_viewport(void) const { return m_correct_viewport; } //correct viewport values
|
inline bool correct_viewport(void) const { return m_correct_viewport; } //correct viewport values
|
||||||
inline bool zmode_compare_less(void) const { return m_zmode_compare_less; } //force GR_CMP_LESS for zmode=0 (opaque)and zmode=1 (interpenetrating)
|
inline bool zmode_compare_less(void) const { return m_zmode_compare_less; } //force GR_CMP_LESS for zmode=0 (opaque)and zmode=1 (interpenetrating)
|
||||||
inline bool old_style_adither(void) const { return m_old_style_adither; } //apply alpha dither regardless of alpha_dither_mode
|
inline bool old_style_adither(void) const { return m_old_style_adither; } //apply alpha dither regardless of alpha_dither_mode
|
||||||
int n64_z_scale; //scale vertex z value before writing to depth buffer, as N64 does.
|
inline bool n64_z_scale(void) const { return m_n64_z_scale; } //scale vertex z value before writing to depth buffer, as N64 does.
|
||||||
|
|
||||||
inline bool hacks(hacks_t hack) const { return (m_hacks & hack) == hack; } //Special game hacks
|
inline bool hacks(hacks_t hack) const { return (m_hacks & hack) == hack; } //Special game hacks
|
||||||
|
|
||||||
|
@ -372,6 +372,7 @@ private:
|
||||||
bool m_correct_viewport;
|
bool m_correct_viewport;
|
||||||
bool m_zmode_compare_less;
|
bool m_zmode_compare_less;
|
||||||
bool m_old_style_adither;
|
bool m_old_style_adither;
|
||||||
|
bool m_n64_z_scale;
|
||||||
hacks_t m_hacks;
|
hacks_t m_hacks;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -1025,7 +1025,7 @@ static void CalculateLOD(VERTEX *v, int n)
|
||||||
|
|
||||||
float ScaleZ(float z)
|
float ScaleZ(float z)
|
||||||
{
|
{
|
||||||
if (g_settings->n64_z_scale)
|
if (g_settings->n64_z_scale())
|
||||||
{
|
{
|
||||||
int iz = (int)(z*8.0f + 0.5f);
|
int iz = (int)(z*8.0f + 0.5f);
|
||||||
if (iz < 0) iz = 0;
|
if (iz < 0) iz = 0;
|
||||||
|
|
Loading…
Reference in New Issue