Add dumper for DDS and texture converter for reordering colors

This commit is contained in:
Jan
2020-09-04 12:51:13 +02:00
parent 362094b6f0
commit ccef1dca28
11 changed files with 708 additions and 362 deletions

View File

@ -0,0 +1,22 @@
#include "CppUnitTest.h"
#include "Image/ImageFormat.h"
using namespace Microsoft::VisualStudio::CppUnitTestFramework;
namespace ObjCommonTests
{
TEST_CLASS(ImageFormatTests)
{
public:
TEST_METHOD(EnsureAllFormatsArrayIndicesAreIds)
{
Assert::AreEqual(static_cast<unsigned int>(ImageFormatId::MAX), _countof(ImageFormat::ALL_FORMATS));
for(unsigned i = 0; i < _countof(ImageFormat::ALL_FORMATS); i++)
{
Assert::IsNotNull(ImageFormat::ALL_FORMATS[i]);
Assert::AreEqual(i, static_cast<unsigned>(ImageFormat::ALL_FORMATS[i]->GetId()));
}
}
};
}