VideoCommon: Remove backbuffer size parameters from methods

We have the s_backbuffer_{width,height} fields to represent this, so
there's no point in passing them as parameters every time.
This commit is contained in:
Stenzek
2016-11-10 23:31:44 +10:00
parent a83ca587c6
commit 6db0ee9561
6 changed files with 30 additions and 30 deletions

View File

@ -188,7 +188,7 @@ void Renderer::CalculateTargetScale(int x, int y, int* scaledX, int* scaledY)
}
// return true if target size changed
bool Renderer::CalculateTargetSize(unsigned int framebuffer_width, unsigned int framebuffer_height)
bool Renderer::CalculateTargetSize()
{
int newEFBWidth, newEFBHeight;
newEFBWidth = newEFBHeight = 0;
@ -449,10 +449,10 @@ void Renderer::DrawDebugText()
g_renderer->RenderText(final_yellow, 20, 20, 0xFFFFFF00);
}
void Renderer::UpdateDrawRectangle(int backbuffer_width, int backbuffer_height)
void Renderer::UpdateDrawRectangle()
{
float FloatGLWidth = (float)backbuffer_width;
float FloatGLHeight = (float)backbuffer_height;
float FloatGLWidth = static_cast<float>(s_backbuffer_width);
float FloatGLHeight = static_cast<float>(s_backbuffer_height);
float FloatXOffset = 0;
float FloatYOffset = 0;

View File

@ -93,7 +93,7 @@ public:
virtual TargetRectangle ConvertEFBRectangle(const EFBRectangle& rc) = 0;
static const TargetRectangle& GetTargetRectangle() { return target_rc; }
static void UpdateDrawRectangle(int backbuffer_width, int backbuffer_height);
static void UpdateDrawRectangle();
// Use this to convert a single target rectangle to two stereo rectangles
static void ConvertStereoRectangle(const TargetRectangle& rc, TargetRectangle& leftRc,
@ -143,7 +143,7 @@ public:
virtual void ChangeSurface(void* new_surface_handle) {}
protected:
static void CalculateTargetScale(int x, int y, int* scaledX, int* scaledY);
bool CalculateTargetSize(unsigned int framebuffer_width, unsigned int framebuffer_height);
bool CalculateTargetSize();
static void CheckFifoRecording();
static void RecordVideoMemory();