diff --git a/pcsx2/GS/GSState.cpp b/pcsx2/GS/GSState.cpp index 587f58a6ec..30628648b9 100644 --- a/pcsx2/GS/GSState.cpp +++ b/pcsx2/GS/GSState.cpp @@ -595,7 +595,7 @@ void GSState::DumpVertices(const std::string& filename) file << std::endl; // Dump vertices - file << "vertex:" << std::endl; + file << "vertex: # " << GSUtil::GetPrimClassName(m_vt.m_primclass) << std::endl; const u32 count = m_index.tail; GSVertex* buffer = &m_vertex.buff[0]; for (u32 i = 0; i < count; ++i) @@ -631,7 +631,7 @@ void GSState::DumpVertices(const std::string& filename) // Dump extra info for STQ if (PRIM->TME && !PRIM->FST) { - file << "vertex_stq:" << std::endl; + file << "vertex_stq: # " << GSUtil::GetPrimClassName(m_vt.m_primclass) << std::endl; for (u32 i = 0; i < count; ++i) { if ((n > 1) && (i > 0) && ((i % n) == 0)) diff --git a/pcsx2/GS/GSUtil.cpp b/pcsx2/GS/GSUtil.cpp index c1ae7eedb6..17603d50a5 100644 --- a/pcsx2/GS/GSUtil.cpp +++ b/pcsx2/GS/GSUtil.cpp @@ -114,6 +114,13 @@ const char* GSUtil::GetPrimName(u32 prim) return (prim < std::size(names)) ? names[prim] : ""; } +const char* GSUtil::GetPrimClassName(u32 primclass) +{ + static constexpr const char* names[] = { + "POINT", "LINE", "TRIANGLE", "SPRITE", "INVALID"}; + return (primclass < std::size(names)) ? names[primclass] : ""; +} + const char* GSUtil::GetMMAGName(u32 mmag) { static constexpr const char* names[] = {"NEAREST", "LINEAR"}; diff --git a/pcsx2/GS/GSUtil.h b/pcsx2/GS/GSUtil.h index a2ee28a847..b37407eb50 100644 --- a/pcsx2/GS/GSUtil.h +++ b/pcsx2/GS/GSUtil.h @@ -15,6 +15,7 @@ public: static const char* GetWMName(u32 wm); static const char* GetZTSTName(u32 ztst); static const char* GetPrimName(u32 prim); + static const char* GetPrimClassName(u32 primclass); static const char* GetMMAGName(u32 mmag); static const char* GetMMINName(u32 mmin); static const char* GetMTBAName(u32 mtba);