remove unused GetMonitorAspectRatio
This commit is contained in:
@@ -178,7 +178,6 @@ public:
|
||||
|
||||
virtual RString GetApiDescription() const = 0;
|
||||
virtual void GetDisplayResolutions( DisplayResolutions &out ) const = 0;
|
||||
virtual float GetMonitorAspectRatio() const = 0;
|
||||
|
||||
// Don't override this. Override TryVideoMode() instead.
|
||||
// This will set the video mode to be as close as possible to params.
|
||||
|
||||
@@ -325,16 +325,6 @@ void RageDisplay_D3D::GetDisplayResolutions( DisplayResolutions &out ) const
|
||||
}
|
||||
}
|
||||
|
||||
float RageDisplay_D3D::GetMonitorAspectRatio() const
|
||||
{
|
||||
#if defined(XBOX)
|
||||
VideoModeParams p = GetActualVideoModeParams();
|
||||
return p.width / (float)p.height;
|
||||
#else
|
||||
return g_DesktopMode.Width / (float)g_DesktopMode.Height;
|
||||
#endif
|
||||
}
|
||||
|
||||
D3DFORMAT FindBackBufferType(bool bWindowed, int iBPP)
|
||||
{
|
||||
HRESULT hr;
|
||||
|
||||
@@ -12,7 +12,6 @@ public:
|
||||
|
||||
virtual RString GetApiDescription() const { return "D3D"; }
|
||||
virtual void GetDisplayResolutions( DisplayResolutions &out ) const;
|
||||
virtual float GetMonitorAspectRatio() const;
|
||||
void ResolutionChanged();
|
||||
const PixelFormatDesc *GetPixelFormatDesc(PixelFormat pf) const;
|
||||
|
||||
|
||||
@@ -11,7 +11,6 @@ public:
|
||||
|
||||
virtual RString GetApiDescription() const { return "Null"; }
|
||||
virtual void GetDisplayResolutions( DisplayResolutions &out ) const;
|
||||
virtual float GetMonitorAspectRatio() const { return 4/3.f; }
|
||||
const PixelFormatDesc *GetPixelFormatDesc(PixelFormat pf) const;
|
||||
|
||||
bool BeginFrame() { return true; }
|
||||
|
||||
@@ -536,11 +536,6 @@ void RageDisplay_OGL::GetDisplayResolutions( DisplayResolutions &out ) const
|
||||
g_pWind->GetDisplayResolutions( out );
|
||||
}
|
||||
|
||||
float RageDisplay_OGL::GetMonitorAspectRatio() const
|
||||
{
|
||||
return g_pWind->GetMonitorAspectRatio();
|
||||
}
|
||||
|
||||
static void CheckPalettedTextures()
|
||||
{
|
||||
RString sError;
|
||||
|
||||
@@ -14,7 +14,6 @@ public:
|
||||
|
||||
virtual RString GetApiDescription() const { return "OpenGL"; }
|
||||
virtual void GetDisplayResolutions( DisplayResolutions &out ) const;
|
||||
virtual float GetMonitorAspectRatio() const;
|
||||
void ResolutionChanged();
|
||||
const PixelFormatDesc *GetPixelFormatDesc(PixelFormat pf) const;
|
||||
|
||||
|
||||
@@ -25,7 +25,6 @@ public:
|
||||
// need to be reloaded.
|
||||
virtual RString TryVideoMode( const VideoModeParams &p, bool &bNewDeviceOut ) = 0;
|
||||
virtual void GetDisplayResolutions( DisplayResolutions &out ) const = 0;
|
||||
virtual float GetMonitorAspectRatio() const = 0;
|
||||
|
||||
virtual void LogDebugInformation() const { }
|
||||
virtual bool IsSoftwareRenderer( RString &sError ) { return false; }
|
||||
|
||||
@@ -25,7 +25,6 @@ public:
|
||||
void *GetProcAddress( RString s );
|
||||
RString TryVideoMode( const VideoModeParams& p, bool& newDeviceOut );
|
||||
void GetDisplayResolutions( DisplayResolutions &dr ) const;
|
||||
float GetMonitorAspectRatio() const;
|
||||
|
||||
void SwapBuffers();
|
||||
void Update();
|
||||
|
||||
@@ -62,11 +62,6 @@ void LowLevelWindow_Win32::GetDisplayResolutions( DisplayResolutions &out ) cons
|
||||
GraphicsWindow::GetDisplayResolutions( out );
|
||||
}
|
||||
|
||||
float LowLevelWindow_Win32::GetMonitorAspectRatio() const
|
||||
{
|
||||
return GraphicsWindow::GetMonitorAspectRatio();
|
||||
}
|
||||
|
||||
int ChooseWindowPixelFormat( const VideoModeParams &p, PIXELFORMATDESCRIPTOR *PixelFormat )
|
||||
{
|
||||
ASSERT( GraphicsWindow::GetHwnd() != NULL );
|
||||
|
||||
@@ -11,7 +11,6 @@ public:
|
||||
void *GetProcAddress( RString s );
|
||||
RString TryVideoMode( const VideoModeParams &p, bool &bNewDeviceOut );
|
||||
void GetDisplayResolutions( DisplayResolutions &out ) const;
|
||||
float GetMonitorAspectRatio() const;
|
||||
bool IsSoftwareRenderer( RString &sError );
|
||||
void SwapBuffers();
|
||||
void Update();
|
||||
|
||||
@@ -316,11 +316,6 @@ void LowLevelWindow_X11::GetDisplayResolutions( DisplayResolutions &out ) const
|
||||
}
|
||||
}
|
||||
|
||||
float LowLevelWindow_X11::GetMonitorAspectRatio() const
|
||||
{
|
||||
return 4.0f/3;
|
||||
}
|
||||
|
||||
bool LowLevelWindow_X11::SupportsThreadedRendering()
|
||||
{
|
||||
return g_pBackgroundContext != NULL;
|
||||
|
||||
@@ -21,7 +21,6 @@ public:
|
||||
const VideoModeParams &GetActualVideoModeParams() const { return CurrentParams; }
|
||||
|
||||
void GetDisplayResolutions( DisplayResolutions &out ) const;
|
||||
float GetMonitorAspectRatio() const;
|
||||
|
||||
bool SupportsRenderToTexture() const;
|
||||
RenderTarget *CreateRenderTarget();
|
||||
|
||||
@@ -518,18 +518,6 @@ void GraphicsWindow::GetDisplayResolutions( DisplayResolutions &out )
|
||||
}
|
||||
}
|
||||
|
||||
float GraphicsWindow::GetMonitorAspectRatio()
|
||||
{
|
||||
// There's no way to query the monitor for this, so assume that the
|
||||
// normal desktop resolution is using square pixels.
|
||||
DEVMODE dm;
|
||||
ZERO( dm );
|
||||
dm.dmSize = sizeof(dm);
|
||||
BOOL bResult = EnumDisplaySettings( NULL, ENUM_REGISTRY_SETTINGS, &dm );
|
||||
ASSERT( bResult );
|
||||
return dm.dmPelsWidth / (float)dm.dmPelsHeight;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* (c) 2004 Glenn Maynard
|
||||
|
||||
@@ -25,7 +25,6 @@ namespace GraphicsWindow
|
||||
void DestroyGraphicsWindow();
|
||||
|
||||
void GetDisplayResolutions( DisplayResolutions &out );
|
||||
float GetMonitorAspectRatio();
|
||||
|
||||
const VideoModeParams &GetParams();
|
||||
HDC GetHDC();
|
||||
|
||||
Reference in New Issue
Block a user