summaryrefslogtreecommitdiff
path: root/Source/Core/VideoCommon/VertexManagerBase.cpp
diff options
context:
space:
mode:
authorTony Wasserka <neobrainx@gmail.com>2014-02-16 22:08:28 +0100
committerTony Wasserka <neobrainx@gmail.com>2014-02-16 22:08:28 +0100
commitde5bfd0bced8b12811d461b8e6683effa6b672fb (patch)
treedc1209fbb812f995c831583c314a01506a099a89 /Source/Core/VideoCommon/VertexManagerBase.cpp
parent2a7a94387ca0e096f698c0468307bfe6b1d365d7 (diff)
parent647aad0a19acc2a7bcb637160bb43d794771ed41 (diff)
Merge pull request #37 from degasus/VideoCommonApiFixes
VideoCommon API cleanups
Diffstat (limited to 'Source/Core/VideoCommon/VertexManagerBase.cpp')
-rw-r--r--Source/Core/VideoCommon/VertexManagerBase.cpp14
1 files changed, 12 insertions, 2 deletions
diff --git a/Source/Core/VideoCommon/VertexManagerBase.cpp b/Source/Core/VideoCommon/VertexManagerBase.cpp
index c4980ae190..0ea44d9a57 100644
--- a/Source/Core/VideoCommon/VertexManagerBase.cpp
+++ b/Source/Core/VideoCommon/VertexManagerBase.cpp
@@ -11,6 +11,8 @@
#include "RenderBase.h"
#include "BPStructs.h"
#include "XFMemory.h"
+#include "Debugger.h"
+#include "PerfQueryBase.h"
#include "VertexManagerBase.h"
#include "MainBase.h"
@@ -216,8 +218,16 @@ void VertexManager::Flush()
VertexShaderManager::SetConstants();
PixelShaderManager::SetConstants();
- // TODO: need to merge more stuff into VideoCommon
- g_vertex_manager->vFlush();
+ bool useDstAlpha = !g_ActiveConfig.bDstAlphaPass && bpmem.dstalpha.enable && bpmem.blendmode.alphaupdate
+ && bpmem.zcontrol.pixel_format == PIXELFMT_RGBA6_Z24;
+
+ if(PerfQueryBase::ShouldEmulate())
+ g_perf_query->EnableQuery(bpmem.zcontrol.early_ztest ? PQG_ZCOMP_ZCOMPLOC : PQG_ZCOMP);
+ g_vertex_manager->vFlush(useDstAlpha);
+ if(PerfQueryBase::ShouldEmulate())
+ g_perf_query->DisableQuery(bpmem.zcontrol.early_ztest ? PQG_ZCOMP_ZCOMPLOC : PQG_ZCOMP);
+
+ GFX_DEBUGGER_PAUSE_AT(NEXT_FLUSH, true);
IsFlushed = true;
}