mirror of https://github.com/PCSX2/pcsx2.git
GSVector: Add constructor to dispatch same values
This commit is contained in:
parent
85fe24cede
commit
055f236aa5
|
@ -126,8 +126,8 @@ public:
|
||||||
VSConstantBuffer()
|
VSConstantBuffer()
|
||||||
{
|
{
|
||||||
Vertex_Scale_Offset = GSVector4::zero();
|
Vertex_Scale_Offset = GSVector4::zero();
|
||||||
DepthMask = GSVector2i(0, 0);
|
DepthMask = GSVector2i(0);
|
||||||
PointSize = GSVector2(0, 0);
|
PointSize = GSVector2(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
__forceinline bool Update(const VSConstantBuffer* cb)
|
__forceinline bool Update(const VSConstantBuffer* cb)
|
||||||
|
|
|
@ -231,7 +231,7 @@ bool GSRenderer::Merge(int field)
|
||||||
src[i] = GSVector4(r) * scale / GSVector4(tex[i]->GetSize()).xyxy();
|
src[i] = GSVector4(r) * scale / GSVector4(tex[i]->GetSize()).xyxy();
|
||||||
src_hw[i] = (GSVector4(r) + GSVector4 (0, y_offset[i], 0, y_offset[i])) * scale / GSVector4(tex[i]->GetSize()).xyxy();
|
src_hw[i] = (GSVector4(r) + GSVector4 (0, y_offset[i], 0, y_offset[i])) * scale / GSVector4(tex[i]->GetSize()).xyxy();
|
||||||
|
|
||||||
GSVector2 off(0, 0);
|
GSVector2 off(0);
|
||||||
GSVector2i display_diff(dr[i].left - display_baseline.x, dr[i].top - display_baseline.y);
|
GSVector2i display_diff(dr[i].left - display_baseline.x, dr[i].top - display_baseline.y);
|
||||||
GSVector2i frame_diff(fr[i].left - frame_baseline.x, fr[i].top - frame_baseline.y);
|
GSVector2i frame_diff(fr[i].left - frame_baseline.x, fr[i].top - frame_baseline.y);
|
||||||
|
|
||||||
|
|
|
@ -58,7 +58,7 @@ protected:
|
||||||
GSDeviceDX::PSConstantBuffer ps_cb;
|
GSDeviceDX::PSConstantBuffer ps_cb;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
GSRendererDX(GSTextureCache* tc, const GSVector2& pixelcenter = GSVector2(0, 0));
|
GSRendererDX(GSTextureCache* tc, const GSVector2& pixelcenter = GSVector2(0));
|
||||||
virtual ~GSRendererDX();
|
virtual ~GSRendererDX();
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
|
@ -25,7 +25,7 @@
|
||||||
#include "resource.h"
|
#include "resource.h"
|
||||||
|
|
||||||
GSRendererDX11::GSRendererDX11()
|
GSRendererDX11::GSRendererDX11()
|
||||||
: GSRendererDX(new GSTextureCache11(this), GSVector2(-0.5f, -0.5f))
|
: GSRendererDX(new GSTextureCache11(this), GSVector2(-0.5f))
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -253,10 +253,10 @@ void GSRendererDX9::UpdateFBA(GSTexture* rt)
|
||||||
|
|
||||||
GSVertexPT1 vertices[] =
|
GSVertexPT1 vertices[] =
|
||||||
{
|
{
|
||||||
{GSVector4(dst.x, -dst.y, 0.5f, 1.0f), GSVector2(0, 0)},
|
{GSVector4(dst.x, -dst.y, 0.5f, 1.0f), GSVector2(0)},
|
||||||
{GSVector4(dst.z, -dst.y, 0.5f, 1.0f), GSVector2(0, 0)},
|
{GSVector4(dst.z, -dst.y, 0.5f, 1.0f), GSVector2(0)},
|
||||||
{GSVector4(dst.x, -dst.w, 0.5f, 1.0f), GSVector2(0, 0)},
|
{GSVector4(dst.x, -dst.w, 0.5f, 1.0f), GSVector2(0)},
|
||||||
{GSVector4(dst.z, -dst.w, 0.5f, 1.0f), GSVector2(0, 0)},
|
{GSVector4(dst.z, -dst.w, 0.5f, 1.0f), GSVector2(0)},
|
||||||
};
|
};
|
||||||
|
|
||||||
dev->IASetVertexBuffer(vertices, sizeof(vertices[0]), countof(vertices));
|
dev->IASetVertexBuffer(vertices, sizeof(vertices[0]), countof(vertices));
|
||||||
|
|
|
@ -55,6 +55,12 @@ public:
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
GSVector2T(T x)
|
||||||
|
{
|
||||||
|
this->x = x;
|
||||||
|
this->y = x;
|
||||||
|
}
|
||||||
|
|
||||||
GSVector2T(T x, T y)
|
GSVector2T(T x, T y)
|
||||||
{
|
{
|
||||||
this->x = x;
|
this->x = x;
|
||||||
|
|
Loading…
Reference in New Issue