mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2026-05-05 09:00:39 -04:00
Makes VertexLoader_Normal completely stateless, eliminating the need for an Init() function, and by extension, also gets rid of the need for the FifoAnalyzer to have an Init() function.
40 lines
774 B
C++
40 lines
774 B
C++
// Copyright 2011 Dolphin Emulator Project
|
|
// Licensed under GPLv2+
|
|
// Refer to the license.txt file included.
|
|
|
|
#pragma once
|
|
|
|
#include "Common/CommonTypes.h"
|
|
|
|
#include "VideoCommon/CPMemory.h"
|
|
|
|
namespace FifoAnalyzer
|
|
{
|
|
u8 ReadFifo8(const u8*& data);
|
|
u16 ReadFifo16(const u8*& data);
|
|
u32 ReadFifo32(const u8*& data);
|
|
|
|
enum DecodeMode
|
|
{
|
|
DECODE_RECORD,
|
|
DECODE_PLAYBACK,
|
|
};
|
|
|
|
u32 AnalyzeCommand(const u8* data, DecodeMode mode);
|
|
|
|
struct CPMemory
|
|
{
|
|
TVtxDesc vtxDesc;
|
|
VAT vtxAttr[8];
|
|
u32 arrayBases[16];
|
|
u32 arrayStrides[16];
|
|
};
|
|
|
|
void LoadCPReg(u32 subCmd, u32 value, CPMemory& cpMem);
|
|
|
|
void CalculateVertexElementSizes(int sizes[], int vatIndex, const CPMemory& cpMem);
|
|
|
|
extern bool s_DrawingObject;
|
|
extern FifoAnalyzer::CPMemory s_CpMem;
|
|
} // namespace FifoAnalyzer
|