/KTexComp

Fork of ISPC Texture Compressor

Primary LanguageC++MIT LicenseMIT

Fast ISPC Texture Compressor

Texture compression for BC1-BC7, ETC1 and ASTC.

Uses ISPC compiler.

See Fast ISPC Texture Compressor post on Intel Developer Zone and the included Technical Paper.

Supported compression formats

Strenghts

  • Compression speed runtime adjustable over two magnitudes, making this library suitable for fast iteration and production use.
  • BC7 texture compression.
  • Visual demonstration tools included.

Limitations

  • Lack of notion about user intended colorspaces or compression metrics (sRGB is assumed for LDR input).
  • Limited input formats:
    • BC6H requires clamped fp16 input.
    • Otherwise 8 and 16 bit uint only.
  • Very basic support for BC3 alpha channel and BC4/BC5.
  • BC1 lacks punchthrough alpha support.
  • Only unsigned format of BC4/BC5/BC6H is supported.
  • ASTC is LDR only and won't support block sizes above 8x8.
  • Lack of documentation.
  • No decompression support.
  • No unit testing.

License

ISPC Texture Compressor is distributed under the MIT License.

Build Instructions

Using a later ispc version results in library not running on at least AMD Phenom II on Windows 7. This may or may not be a configuration issue in this project.

  • Windows:

    • Use Visual Studio 2012 on later, build solution or project files.
    • ISPC version 1.8.2 is included in this repo.
  • Mac OS X (outdated):

    • Xcode project file included only for compressor itself, not for the examples.
    • You'll need to get ISPC compiler version 1.8.2 build and put the compiler executable into ISPC Texture Compressor/ispc_osx.
    • Use ISPC Texture Compressor/ispc_texcomp.xcodeproj, tested with Xcode 7.3.
    • Minimum OS X deployment version set to 10.9.
    • dylib install name is set to @executable_path/../Frameworks/$(EXECUTABLE_PATH)
  • Linux:

    • Makefile included only for compressor itself, not for the examples.
    • You'll need to get ISPC compiler version 1.8.2 build and put the compiler executable into ISPC Texture Compressor/ispc_linux.
    • make -f Makefile.linux from ISPC Texture Compressor folder.