VideoCommon: Minor changes

Make Renderer::GetMaxTextureSize return u32 instead of int.
This commit is contained in:
Shawn Hoffman
2016-10-03 06:51:46 -07:00
parent cc66f0336f
commit 86112c7258
11 changed files with 14 additions and 15 deletions

View File

@ -1273,7 +1273,7 @@ void Renderer::SetInterlacingMode()
// TODO
}
int Renderer::GetMaxTextureSize()
u32 Renderer::GetMaxTextureSize()
{
return DX11::D3D::GetMaxTextureSize();
}

View File

@ -58,7 +58,7 @@ public:
static bool CheckForResize();
int GetMaxTextureSize() override;
u32 GetMaxTextureSize() override;
private:
void BlitScreen(TargetRectangle src, TargetRectangle dst, D3DTexture2D* src_texture,

View File

@ -1287,7 +1287,7 @@ void Renderer::SetInterlacingMode()
// EXISTINGD3D11TODO
}
int Renderer::GetMaxTextureSize()
u32 Renderer::GetMaxTextureSize()
{
return DX12::D3D::GetMaxTextureSize();
}

View File

@ -58,7 +58,7 @@ public:
static bool CheckForResize();
int GetMaxTextureSize() override;
u32 GetMaxTextureSize() override;
static D3D12_BLEND_DESC GetResetBlendDesc();
static D3D12_DEPTH_STENCIL_DESC GetResetDepthStencilDesc();

View File

@ -19,7 +19,7 @@ public:
void PokeEFB(EFBAccessType type, const EfbPokeData* points, size_t num_points) override {}
u16 BBoxRead(int index) override { return 0; }
void BBoxWrite(int index, u16 value) override {}
int GetMaxTextureSize() override { return 16 * 1024; }
u32 GetMaxTextureSize() override { return 16 * 1024; }
TargetRectangle ConvertEFBRectangle(const EFBRectangle& rc) override;
void SwapImpl(u32 xfb_addr, u32 fb_width, u32 fb_stride, u32 fb_height, const EFBRectangle& rc,

View File

@ -1809,14 +1809,14 @@ bool Renderer::SaveScreenshot(const std::string& filename, const TargetRectangle
return TextureToPng(data.get(), W * 4, filename, W, H, false);
}
int Renderer::GetMaxTextureSize()
u32 Renderer::GetMaxTextureSize()
{
// Right now nvidia seems to do something very weird if we try to cache GL_MAX_TEXTURE_SIZE in
// init. This is a workaround that lets
// us keep the perf improvement that caching it gives us.
if (s_max_texture_size == 0)
glGetIntegerv(GL_MAX_TEXTURE_SIZE, &s_max_texture_size);
return s_max_texture_size;
return static_cast<u32>(s_max_texture_size);
}
void Renderer::ChangeSurface(void* new_surface_handle)

View File

@ -103,7 +103,7 @@ public:
bool SaveScreenshot(const std::string& filename, const TargetRectangle& rc) override;
int GetMaxTextureSize() override;
u32 GetMaxTextureSize() override;
void ChangeSurface(void* new_surface_handle) override;

View File

@ -30,7 +30,7 @@ public:
u16 BBoxRead(int index) override;
void BBoxWrite(int index, u16 value) override;
int GetMaxTextureSize() override { return 16 * 1024; };
u32 GetMaxTextureSize() override { return 16 * 1024; };
TargetRectangle ConvertEFBRectangle(const EFBRectangle& rc) override;
void SwapImpl(u32 xfbAddr, u32 fbWidth, u32 fbStride, u32 fbHeight, const EFBRectangle& rc,

View File

@ -38,7 +38,7 @@ public:
void PokeEFB(EFBAccessType type, const EfbPokeData* points, size_t num_points) override;
u16 BBoxRead(int index) override;
void BBoxWrite(int index, u16 value) override;
int GetMaxTextureSize() override { return 16 * 1024; }
u32 GetMaxTextureSize() override { return 16 * 1024; }
TargetRectangle ConvertEFBRectangle(const EFBRectangle& rc) override;
void SwapImpl(u32 xfb_addr, u32 fb_width, u32 fb_stride, u32 fb_height, const EFBRectangle& rc,