Rename CP and XF normal component count enums and update their descriptions

This commit is contained in:
Pokechu22
2022-05-17 11:54:24 -07:00
parent 736466a5d9
commit 46bcdc4372
9 changed files with 49 additions and 49 deletions

View File

@ -123,7 +123,7 @@ struct Set
using Common::EnumMap;
using Formats = EnumMap<Set, ComponentFormat::Float>;
using Elements = EnumMap<Formats, NormalComponentCount::NBT>;
using Elements = EnumMap<Formats, NormalComponentCount::NTB>;
using Indices = std::array<Elements, 2>;
using Types = EnumMap<Indices, VertexComponentFormat::Index16>;
@ -140,11 +140,11 @@ constexpr Types InitializeTable()
table[VCF::Direct][false][NCC::N][FMT::UShort] = Normal_Direct<u16, 1>();
table[VCF::Direct][false][NCC::N][FMT::Short] = Normal_Direct<s16, 1>();
table[VCF::Direct][false][NCC::N][FMT::Float] = Normal_Direct<float, 1>();
table[VCF::Direct][false][NCC::NBT][FMT::UByte] = Normal_Direct<u8, 3>();
table[VCF::Direct][false][NCC::NBT][FMT::Byte] = Normal_Direct<s8, 3>();
table[VCF::Direct][false][NCC::NBT][FMT::UShort] = Normal_Direct<u16, 3>();
table[VCF::Direct][false][NCC::NBT][FMT::Short] = Normal_Direct<s16, 3>();
table[VCF::Direct][false][NCC::NBT][FMT::Float] = Normal_Direct<float, 3>();
table[VCF::Direct][false][NCC::NTB][FMT::UByte] = Normal_Direct<u8, 3>();
table[VCF::Direct][false][NCC::NTB][FMT::Byte] = Normal_Direct<s8, 3>();
table[VCF::Direct][false][NCC::NTB][FMT::UShort] = Normal_Direct<u16, 3>();
table[VCF::Direct][false][NCC::NTB][FMT::Short] = Normal_Direct<s16, 3>();
table[VCF::Direct][false][NCC::NTB][FMT::Float] = Normal_Direct<float, 3>();
// Same as above, since there are no indices
table[VCF::Direct][true][NCC::N][FMT::UByte] = Normal_Direct<u8, 1>();
@ -152,57 +152,57 @@ constexpr Types InitializeTable()
table[VCF::Direct][true][NCC::N][FMT::UShort] = Normal_Direct<u16, 1>();
table[VCF::Direct][true][NCC::N][FMT::Short] = Normal_Direct<s16, 1>();
table[VCF::Direct][true][NCC::N][FMT::Float] = Normal_Direct<float, 1>();
table[VCF::Direct][true][NCC::NBT][FMT::UByte] = Normal_Direct<u8, 3>();
table[VCF::Direct][true][NCC::NBT][FMT::Byte] = Normal_Direct<s8, 3>();
table[VCF::Direct][true][NCC::NBT][FMT::UShort] = Normal_Direct<u16, 3>();
table[VCF::Direct][true][NCC::NBT][FMT::Short] = Normal_Direct<s16, 3>();
table[VCF::Direct][true][NCC::NBT][FMT::Float] = Normal_Direct<float, 3>();
table[VCF::Direct][true][NCC::NTB][FMT::UByte] = Normal_Direct<u8, 3>();
table[VCF::Direct][true][NCC::NTB][FMT::Byte] = Normal_Direct<s8, 3>();
table[VCF::Direct][true][NCC::NTB][FMT::UShort] = Normal_Direct<u16, 3>();
table[VCF::Direct][true][NCC::NTB][FMT::Short] = Normal_Direct<s16, 3>();
table[VCF::Direct][true][NCC::NTB][FMT::Float] = Normal_Direct<float, 3>();
table[VCF::Index8][false][NCC::N][FMT::UByte] = Normal_Index<u8, u8, 1>();
table[VCF::Index8][false][NCC::N][FMT::Byte] = Normal_Index<u8, s8, 1>();
table[VCF::Index8][false][NCC::N][FMT::UShort] = Normal_Index<u8, u16, 1>();
table[VCF::Index8][false][NCC::N][FMT::Short] = Normal_Index<u8, s16, 1>();
table[VCF::Index8][false][NCC::N][FMT::Float] = Normal_Index<u8, float, 1>();
table[VCF::Index8][false][NCC::NBT][FMT::UByte] = Normal_Index<u8, u8, 3>();
table[VCF::Index8][false][NCC::NBT][FMT::Byte] = Normal_Index<u8, s8, 3>();
table[VCF::Index8][false][NCC::NBT][FMT::UShort] = Normal_Index<u8, u16, 3>();
table[VCF::Index8][false][NCC::NBT][FMT::Short] = Normal_Index<u8, s16, 3>();
table[VCF::Index8][false][NCC::NBT][FMT::Float] = Normal_Index<u8, float, 3>();
table[VCF::Index8][false][NCC::NTB][FMT::UByte] = Normal_Index<u8, u8, 3>();
table[VCF::Index8][false][NCC::NTB][FMT::Byte] = Normal_Index<u8, s8, 3>();
table[VCF::Index8][false][NCC::NTB][FMT::UShort] = Normal_Index<u8, u16, 3>();
table[VCF::Index8][false][NCC::NTB][FMT::Short] = Normal_Index<u8, s16, 3>();
table[VCF::Index8][false][NCC::NTB][FMT::Float] = Normal_Index<u8, float, 3>();
// Same for NormalComponentCount::N; differs for NBT
// Same for NormalComponentCount::N; differs for NTB
table[VCF::Index8][true][NCC::N][FMT::UByte] = Normal_Index<u8, u8, 1>();
table[VCF::Index8][true][NCC::N][FMT::Byte] = Normal_Index<u8, s8, 1>();
table[VCF::Index8][true][NCC::N][FMT::UShort] = Normal_Index<u8, u16, 1>();
table[VCF::Index8][true][NCC::N][FMT::Short] = Normal_Index<u8, s16, 1>();
table[VCF::Index8][true][NCC::N][FMT::Float] = Normal_Index<u8, float, 1>();
table[VCF::Index8][true][NCC::NBT][FMT::UByte] = Normal_Index_Indices3<u8, u8>();
table[VCF::Index8][true][NCC::NBT][FMT::Byte] = Normal_Index_Indices3<u8, s8>();
table[VCF::Index8][true][NCC::NBT][FMT::UShort] = Normal_Index_Indices3<u8, u16>();
table[VCF::Index8][true][NCC::NBT][FMT::Short] = Normal_Index_Indices3<u8, s16>();
table[VCF::Index8][true][NCC::NBT][FMT::Float] = Normal_Index_Indices3<u8, float>();
table[VCF::Index8][true][NCC::NTB][FMT::UByte] = Normal_Index_Indices3<u8, u8>();
table[VCF::Index8][true][NCC::NTB][FMT::Byte] = Normal_Index_Indices3<u8, s8>();
table[VCF::Index8][true][NCC::NTB][FMT::UShort] = Normal_Index_Indices3<u8, u16>();
table[VCF::Index8][true][NCC::NTB][FMT::Short] = Normal_Index_Indices3<u8, s16>();
table[VCF::Index8][true][NCC::NTB][FMT::Float] = Normal_Index_Indices3<u8, float>();
table[VCF::Index16][false][NCC::N][FMT::UByte] = Normal_Index<u16, u8, 1>();
table[VCF::Index16][false][NCC::N][FMT::Byte] = Normal_Index<u16, s8, 1>();
table[VCF::Index16][false][NCC::N][FMT::UShort] = Normal_Index<u16, u16, 1>();
table[VCF::Index16][false][NCC::N][FMT::Short] = Normal_Index<u16, s16, 1>();
table[VCF::Index16][false][NCC::N][FMT::Float] = Normal_Index<u16, float, 1>();
table[VCF::Index16][false][NCC::NBT][FMT::UByte] = Normal_Index<u16, u8, 3>();
table[VCF::Index16][false][NCC::NBT][FMT::Byte] = Normal_Index<u16, s8, 3>();
table[VCF::Index16][false][NCC::NBT][FMT::UShort] = Normal_Index<u16, u16, 3>();
table[VCF::Index16][false][NCC::NBT][FMT::Short] = Normal_Index<u16, s16, 3>();
table[VCF::Index16][false][NCC::NBT][FMT::Float] = Normal_Index<u16, float, 3>();
table[VCF::Index16][false][NCC::NTB][FMT::UByte] = Normal_Index<u16, u8, 3>();
table[VCF::Index16][false][NCC::NTB][FMT::Byte] = Normal_Index<u16, s8, 3>();
table[VCF::Index16][false][NCC::NTB][FMT::UShort] = Normal_Index<u16, u16, 3>();
table[VCF::Index16][false][NCC::NTB][FMT::Short] = Normal_Index<u16, s16, 3>();
table[VCF::Index16][false][NCC::NTB][FMT::Float] = Normal_Index<u16, float, 3>();
// Same for NormalComponentCount::N; differs for NBT
// Same for NormalComponentCount::N; differs for NTB
table[VCF::Index16][true][NCC::N][FMT::UByte] = Normal_Index<u16, u8, 1>();
table[VCF::Index16][true][NCC::N][FMT::Byte] = Normal_Index<u16, s8, 1>();
table[VCF::Index16][true][NCC::N][FMT::UShort] = Normal_Index<u16, u16, 1>();
table[VCF::Index16][true][NCC::N][FMT::Short] = Normal_Index<u16, s16, 1>();
table[VCF::Index16][true][NCC::N][FMT::Float] = Normal_Index<u16, float, 1>();
table[VCF::Index16][true][NCC::NBT][FMT::UByte] = Normal_Index_Indices3<u16, u8>();
table[VCF::Index16][true][NCC::NBT][FMT::Byte] = Normal_Index_Indices3<u16, s8>();
table[VCF::Index16][true][NCC::NBT][FMT::UShort] = Normal_Index_Indices3<u16, u16>();
table[VCF::Index16][true][NCC::NBT][FMT::Short] = Normal_Index_Indices3<u16, s16>();
table[VCF::Index16][true][NCC::NBT][FMT::Float] = Normal_Index_Indices3<u16, float>();
table[VCF::Index16][true][NCC::NTB][FMT::UByte] = Normal_Index_Indices3<u16, u8>();
table[VCF::Index16][true][NCC::NTB][FMT::Byte] = Normal_Index_Indices3<u16, s8>();
table[VCF::Index16][true][NCC::NTB][FMT::UShort] = Normal_Index_Indices3<u16, u16>();
table[VCF::Index16][true][NCC::NTB][FMT::Short] = Normal_Index_Indices3<u16, s16>();
table[VCF::Index16][true][NCC::NTB][FMT::Float] = Normal_Index_Indices3<u16, float>();
return table;
}