mirror of
https://github.com/PCSX2/pcsx2.git
synced 2026-11-16 03:00:36 +01:00
GS: Add prim class name in vertex dump for better readability.
This commit is contained in:
1 parent
c50c24e3c9
commit
eb42ce3343
3 files changed
+10
-2
No files matched your search
@@ -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))
|
||||
|
||||
@@ -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"};
|
||||
|
||||
@@ -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);
|
||||
|
||||
Reference in new issue
Block a user