From d840165a324b5c218ca3a4882f030986855c8383 Mon Sep 17 00:00:00 2001 From: "K. S. Ernest (iFire) Lee" Date: Tue, 6 Apr 2021 22:05:56 -0700 Subject: Add `etcpak` library for faster ETC/ETC2/S3TC imports. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - `etc` module was renamed to `etcpak` and modified to use the new library. - PKM importer is removed in the process, it's obsolete. - Old library `etc2comp` is removed. - S3TC compression no longer done via `squish` (but decompression still is). - Slight modifications to etcpak sources for MinGW compatibility, to fix LLVM `-Wc++11-narrowing` errors, and to allow using vendored or system libpng. Co-authored-by: RĂ©mi Verschelde --- thirdparty/etcpak/Dither.hpp | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 thirdparty/etcpak/Dither.hpp (limited to 'thirdparty/etcpak/Dither.hpp') diff --git a/thirdparty/etcpak/Dither.hpp b/thirdparty/etcpak/Dither.hpp new file mode 100644 index 0000000000..e43ce5676d --- /dev/null +++ b/thirdparty/etcpak/Dither.hpp @@ -0,0 +1,21 @@ +#ifndef __DITHER_HPP__ +#define __DITHER_HPP__ + +#include +#include + +#ifdef __AVX2__ +# ifdef _MSC_VER +# include +# else +# include +# endif +#endif + +void Dither( uint8_t* data ); + +#ifdef __AVX2__ +void DitherAvx2( uint8_t* data, __m128i px0, __m128i px1, __m128i px2, __m128i px3 ); +#endif + +#endif -- cgit v1.2.3