summaryrefslogtreecommitdiff
path: root/src/video_core/rasterizer.cpp
diff options
context:
space:
mode:
authorGravatar Yuri Kunde Schlesner2015-08-17 18:25:21 -0300
committerGravatar Yuri Kunde Schlesner2015-08-24 22:16:28 -0300
commit0fcabd2b11a5b1d4d16f6f6bdf1efd54d2c45237 (patch)
treea1651d48113413e2de1e6e309362511b1ff7ffa8 /src/video_core/rasterizer.cpp
parentcitra-qt: Add helper function to get a monospace QFont (diff)
downloadyuzu-0fcabd2b11a5b1d4d16f6f6bdf1efd54d2c45237.tar.gz
yuzu-0fcabd2b11a5b1d4d16f6f6bdf1efd54d2c45237.tar.xz
yuzu-0fcabd2b11a5b1d4d16f6f6bdf1efd54d2c45237.zip
Integrate the MicroProfile profiling library
This brings goodies such as a configurable user interface and multi-threaded timeline view.
Diffstat (limited to 'src/video_core/rasterizer.cpp')
-rw-r--r--src/video_core/rasterizer.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/video_core/rasterizer.cpp b/src/video_core/rasterizer.cpp
index b83798b0f..4a159da8e 100644
--- a/src/video_core/rasterizer.cpp
+++ b/src/video_core/rasterizer.cpp
@@ -7,6 +7,7 @@
7#include "common/color.h" 7#include "common/color.h"
8#include "common/common_types.h" 8#include "common/common_types.h"
9#include "common/math_util.h" 9#include "common/math_util.h"
10#include "common/microprofile.h"
10#include "common/profiler.h" 11#include "common/profiler.h"
11 12
12#include "core/hw/gpu.h" 13#include "core/hw/gpu.h"
@@ -267,6 +268,7 @@ static int SignedArea (const Math::Vec2<Fix12P4>& vtx1,
267}; 268};
268 269
269static Common::Profiling::TimingCategory rasterization_category("Rasterization"); 270static Common::Profiling::TimingCategory rasterization_category("Rasterization");
271MICROPROFILE_DEFINE(GPU_Rasterization, "GPU", "Rasterization", MP_RGB(50, 50, 240));
270 272
271/** 273/**
272 * Helper function for ProcessTriangle with the "reversed" flag to allow for implementing 274 * Helper function for ProcessTriangle with the "reversed" flag to allow for implementing
@@ -279,6 +281,7 @@ static void ProcessTriangleInternal(const Shader::OutputVertex& v0,
279{ 281{
280 const auto& regs = g_state.regs; 282 const auto& regs = g_state.regs;
281 Common::Profiling::ScopeTimer timer(rasterization_category); 283 Common::Profiling::ScopeTimer timer(rasterization_category);
284 MICROPROFILE_SCOPE(GPU_Rasterization);
282 285
283 // vertex positions in rasterizer coordinates 286 // vertex positions in rasterizer coordinates
284 static auto FloatToFix = [](float24 flt) { 287 static auto FloatToFix = [](float24 flt) {