VertexLoader_Position: Tidy up public function definitions

We can use u32 instead of unsigned int to shorten up these definitions
and make them much nicer to read.

While we're at it, change the size array to house u32 elements to match
the return value of the function.
This commit is contained in:
Lioncash 2019-05-30 09:33:43 -04:00
parent 14e544eef8
commit 6f656b7219
2 changed files with 7 additions and 10 deletions

View File

@ -168,7 +168,7 @@ constexpr TPipelineFunction s_table_read_position[4][8][2] = {
},
};
constexpr int s_table_read_position_vertex_size[4][8][2] = {
constexpr u32 s_table_read_position_vertex_size[4][8][2] = {
{
{0, 0},
{0, 0},
@ -200,13 +200,12 @@ constexpr int s_table_read_position_vertex_size[4][8][2] = {
};
} // Anonymous namespace
unsigned int VertexLoader_Position::GetSize(u64 _type, unsigned int _format, unsigned int _elements)
u32 VertexLoader_Position::GetSize(u64 type, u32 format, u32 elements)
{
return s_table_read_position_vertex_size[_type][_format][_elements];
return s_table_read_position_vertex_size[type][format][elements];
}
TPipelineFunction VertexLoader_Position::GetFunction(u64 _type, unsigned int _format,
unsigned int _elements)
TPipelineFunction VertexLoader_Position::GetFunction(u64 type, u32 format, u32 elements)
{
return s_table_read_position[_type][_format][_elements];
return s_table_read_position[type][format][elements];
}

View File

@ -10,9 +10,7 @@
class VertexLoader_Position
{
public:
// GetSize
static unsigned int GetSize(u64 _type, unsigned int _format, unsigned int _elements);
static u32 GetSize(u64 type, u32 format, u32 elements);
// GetFunction
static TPipelineFunction GetFunction(u64 _type, unsigned int _format, unsigned int _elements);
static TPipelineFunction GetFunction(u64 type, u32 format, u32 elements);
};