Further minor D3D11 fixes

This commit is contained in:
Henrik Rydgard 2017-02-17 18:43:27 +01:00
parent 3481dae20a
commit 13a3d179d5
2 changed files with 9 additions and 8 deletions

View file

@ -554,10 +554,10 @@ void FramebufferManagerD3D11::SimpleBlit(
float x, y, z, u, v;
};
Vtx vtx[4] = {
{ dX * destX1, dY * destY1, 0.0f, sX * srcX1, sY * srcY1 },
{ dX * destX2, dY * destY1, 0.0f, sX * srcX2, sY * srcY1 },
{ dX * destX1, dY * destY2, 0.0f, sX * srcX1, sY * srcY2 },
{ dX * destX2, dY * destY2, 0.0f, sX * srcX2, sY * srcY2 },
{ -1.0f + 2.0f * dX * destX1, 1.0f - 2.0f * dY * destY1, 0.0f, sX * srcX1, sY * srcY1 },
{ -1.0f + 2.0f * dX * destX2, 1.0f - 2.0f * dY * destY1, 0.0f, sX * srcX2, sY * srcY1 },
{ -1.0f + 2.0f * dX * destX1, 1.0f - 2.0f * dY * destY2, 0.0f, sX * srcX1, sY * srcY2 },
{ -1.0f + 2.0f * dX * destX2, 1.0f - 2.0f * dY * destY2, 0.0f, sX * srcX2, sY * srcY2 },
};
D3D11_MAPPED_SUBRESOURCE map;
@ -608,7 +608,7 @@ void FramebufferManagerD3D11::BlitFramebuffer(VirtualFramebuffer *dst, int dstX,
int dstY1 = dstY * dstYFactor;
int dstY2 = (dstY + h) * dstYFactor;
// Direct3D 9 doesn't support rect -> self.
// Direct3D doesn't support rect -> self.
Draw::Framebuffer *srcFBO = src->fbo;
if (src == dst) {
Draw::Framebuffer *tempFBO = GetTempFBO(src->renderWidth, src->renderHeight, (Draw::FBColorDepth)src->colorDepth);

View file

@ -181,7 +181,7 @@ static const CommandTableEntry commandTable[] = {
{ GE_CMD_CULLFACEENABLE, FLAG_FLUSHBEFOREONCHANGE },
{ GE_CMD_DITHERENABLE, FLAG_FLUSHBEFOREONCHANGE },
{ GE_CMD_STENCILOP, FLAG_FLUSHBEFOREONCHANGE },
{ GE_CMD_STENCILTEST, FLAG_FLUSHBEFOREONCHANGE, DIRTY_STENCILREPLACEVALUE },
{ GE_CMD_STENCILTEST, FLAG_FLUSHBEFOREONCHANGE, DIRTY_STENCILREPLACEVALUE | DIRTY_FOGCOEF }, // These are combined in D3D11
{ GE_CMD_STENCILTESTENABLE, FLAG_FLUSHBEFOREONCHANGE },
{ GE_CMD_ALPHABLENDENABLE, FLAG_FLUSHBEFOREONCHANGE },
{ GE_CMD_BLENDMODE, FLAG_FLUSHBEFOREONCHANGE },
@ -505,11 +505,12 @@ void GPU_D3D11::CheckGPUFeatures() {
features |= GPU_SUPPORTS_BLEND_MINMAX;
features |= GPU_SUPPORTS_TEXTURE_LOD_CONTROL;
features |= GPU_PREFER_CPU_DOWNLOAD;
features |= GPU_SUPPORTS_ACCURATE_DEPTH;
features |= GPU_SUPPORTS_ACCURATE_DEPTH; // Breaks text in PaRappa for some reason.
features |= GPU_SUPPORTS_ANISOTROPY;
features |= GPU_SUPPORTS_OES_TEXTURE_NPOT;
features |= GPU_SUPPORTS_LARGE_VIEWPORTS;
features |= GPU_SUPPORTS_DUALSOURCE_BLEND;
// features |= GPU_SUPPORTS_ANY_COPY_IMAGE;
features |= GPU_SUPPORTS_ANY_COPY_IMAGE;
if (!g_Config.bHighQualityDepth) {
features |= GPU_SCALE_DEPTH_FROM_24BIT_TO_16BIT;