Move ComputeDrawRectangle() to Renderer::UpdateDrawRectangle().

This commit is contained in:
NeoBrainX
2012-09-29 00:04:55 +02:00
parent 035840e7b5
commit 78031c2d54
7 changed files with 180 additions and 180 deletions

View File

@ -85,6 +85,10 @@ public:
// Use this to convert a whole native EFB rect to backbuffer coordinates
virtual TargetRectangle ConvertEFBRectangle(const EFBRectangle& rc) = 0;
static const TargetRectangle& GetTargetRectangle() { return target_rc; }
static void UpdateDrawRectangle(int backbuffer_width, int backbuffer_height);
// Use this to upscale native EFB coordinates to IDEAL internal resolution
static unsigned int EFBToScaledX(int x) { return x * GetTargetWidth() / EFB_WIDTH; }
static unsigned int EFBToScaledY(int y) { return y * GetTargetHeight() / EFB_HEIGHT; }
@ -163,6 +167,8 @@ protected:
static float xScale;
static float yScale;
static TargetRectangle target_rc;
// can probably eliminate this static var
static int s_LastEFBScale;