diff options
| author | Lioncash <mathew1800@gmail.com> | 2017-02-07 23:11:04 -0500 |
|---|---|---|
| committer | Lioncash <mathew1800@gmail.com> | 2017-02-08 00:05:17 -0500 |
| commit | d9d069e02464476cf2bcf7bd6389f3c8f2a8c21e (patch) | |
| tree | 416365cb8c229befc916b810f495eeb67887db1d /Source/Core/VideoCommon/VertexManagerBase.cpp | |
| parent | 22fbcc67fca2496e800151573ebe4fae8d9218a3 (diff) | |
OpcodeDecoding: Convert #defines into enum constants
Gets several constants out of global scope.
Diffstat (limited to 'Source/Core/VideoCommon/VertexManagerBase.cpp')
| -rw-r--r-- | Source/Core/VideoCommon/VertexManagerBase.cpp | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/Source/Core/VideoCommon/VertexManagerBase.cpp b/Source/Core/VideoCommon/VertexManagerBase.cpp index f4a32eada3..2fd3affcaf 100644 --- a/Source/Core/VideoCommon/VertexManagerBase.cpp +++ b/Source/Core/VideoCommon/VertexManagerBase.cpp @@ -107,22 +107,22 @@ u32 VertexManagerBase::GetRemainingIndices(int primitive) { switch (primitive) { - case GX_DRAW_QUADS: - case GX_DRAW_QUADS_2: + case OpcodeDecoder::GX_DRAW_QUADS: + case OpcodeDecoder::GX_DRAW_QUADS_2: return index_len / 5 * 4; - case GX_DRAW_TRIANGLES: + case OpcodeDecoder::GX_DRAW_TRIANGLES: return index_len / 4 * 3; - case GX_DRAW_TRIANGLE_STRIP: + case OpcodeDecoder::GX_DRAW_TRIANGLE_STRIP: return index_len / 1 - 1; - case GX_DRAW_TRIANGLE_FAN: + case OpcodeDecoder::GX_DRAW_TRIANGLE_FAN: return index_len / 6 * 4 + 1; - case GX_DRAW_LINES: + case OpcodeDecoder::GX_DRAW_LINES: return index_len; - case GX_DRAW_LINE_STRIP: + case OpcodeDecoder::GX_DRAW_LINE_STRIP: return index_len / 2 + 1; - case GX_DRAW_POINTS: + case OpcodeDecoder::GX_DRAW_POINTS: return index_len; default: @@ -133,22 +133,22 @@ u32 VertexManagerBase::GetRemainingIndices(int primitive) { switch (primitive) { - case GX_DRAW_QUADS: - case GX_DRAW_QUADS_2: + case OpcodeDecoder::GX_DRAW_QUADS: + case OpcodeDecoder::GX_DRAW_QUADS_2: return index_len / 6 * 4; - case GX_DRAW_TRIANGLES: + case OpcodeDecoder::GX_DRAW_TRIANGLES: return index_len; - case GX_DRAW_TRIANGLE_STRIP: + case OpcodeDecoder::GX_DRAW_TRIANGLE_STRIP: return index_len / 3 + 2; - case GX_DRAW_TRIANGLE_FAN: + case OpcodeDecoder::GX_DRAW_TRIANGLE_FAN: return index_len / 3 + 2; - case GX_DRAW_LINES: + case OpcodeDecoder::GX_DRAW_LINES: return index_len; - case GX_DRAW_LINE_STRIP: + case OpcodeDecoder::GX_DRAW_LINE_STRIP: return index_len / 2 + 1; - case GX_DRAW_POINTS: + case OpcodeDecoder::GX_DRAW_POINTS: return index_len; default: |
