add GetMonitorAspectRatio

This commit is contained in:
Chris Danford
2006-02-07 04:28:24 +00:00
parent 5db90ce71d
commit f904f05fcc
3 changed files with 7 additions and 0 deletions
@@ -18,6 +18,7 @@ public:
// need to be reloaded. // need to be reloaded.
virtual RString TryVideoMode( const VideoModeParams &p, bool &bNewDeviceOut ) = 0; virtual RString TryVideoMode( const VideoModeParams &p, bool &bNewDeviceOut ) = 0;
virtual void GetDisplayResolutions( DisplayResolutions &out ) const = 0; virtual void GetDisplayResolutions( DisplayResolutions &out ) const = 0;
virtual float GetMonitorAspectRatio() const = 0;
virtual bool IsSoftwareRenderer( RString &sError ) { return false; } virtual bool IsSoftwareRenderer( RString &sError ) { return false; }
@@ -59,6 +59,11 @@ void LowLevelWindow_Win32::GetDisplayResolutions( DisplayResolutions &out ) cons
GraphicsWindow::GetDisplayResolutions( out ); GraphicsWindow::GetDisplayResolutions( out );
} }
float LowLevelWindow_Win32::GetMonitorAspectRatio() const
{
return GraphicsWindow::GetMonitorAspectRatio();
}
int ChooseWindowPixelFormat( const VideoModeParams &p, PIXELFORMATDESCRIPTOR *PixelFormat ) int ChooseWindowPixelFormat( const VideoModeParams &p, PIXELFORMATDESCRIPTOR *PixelFormat )
{ {
ASSERT( GraphicsWindow::GetHwnd() != NULL ); ASSERT( GraphicsWindow::GetHwnd() != NULL );
@@ -11,6 +11,7 @@ public:
void *GetProcAddress( RString s ); void *GetProcAddress( RString s );
RString TryVideoMode( const VideoModeParams &p, bool &bNewDeviceOut ); RString TryVideoMode( const VideoModeParams &p, bool &bNewDeviceOut );
void GetDisplayResolutions( DisplayResolutions &out ) const; void GetDisplayResolutions( DisplayResolutions &out ) const;
float GetMonitorAspectRatio() const;
bool IsSoftwareRenderer( RString &sError ); bool IsSoftwareRenderer( RString &sError );
void SwapBuffers(); void SwapBuffers();
void Update(); void Update();