mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-23 14:19:46 -06:00
Fix some minor bugs pointed out by PVS Studio (thanks!)
This commit is contained in:
@ -595,7 +595,7 @@ void drawShadedTexSubQuad(ID3D11ShaderResourceView* texture,
|
||||
|
||||
// only upload the data to VRAM if it changed
|
||||
if (stsq_observer ||
|
||||
memcmp(rDest, &tex_sub_quad_data.rdest, sizeof(rDest)) != 0 ||
|
||||
memcmp(rDest, &tex_sub_quad_data.rdest, sizeof(*rDest)) != 0 ||
|
||||
tex_sub_quad_data.u1 != u1 || tex_sub_quad_data.v1 != v1 ||
|
||||
tex_sub_quad_data.u2 != u2 || tex_sub_quad_data.v2 != v2 || tex_sub_quad_data.G != G)
|
||||
{
|
||||
|
@ -383,7 +383,7 @@ void drawShadedTexQuad(IDirect3DTexture9 *texture,
|
||||
float v2=((float)rSource->bottom) * sh;
|
||||
float g = 1.0f/Gamma;
|
||||
|
||||
struct Q2DVertex { float x,y,z,rhw,u,v,w,h,G; } coords[4] = {
|
||||
const struct Q2DVertex { float x,y,z,rhw,u,v,w,h,G; } coords[4] = {
|
||||
{-1.0f - dw,-1.0f + dh, 0.0f,1.0f, u1, v2, sw, sh, g},
|
||||
{-1.0f - dw, 1.0f + dh, 0.0f,1.0f, u1, v1, sw, sh, g},
|
||||
{ 1.0f - dw,-1.0f + dh, 0.0f,1.0f, u2, v2, sw, sh, g},
|
||||
|
Reference in New Issue
Block a user