-
Notifications
You must be signed in to change notification settings - Fork 320
Home
We gratefully acknowledge the Sponsors and Supporters of this software. Without their help, this project would not exist.
Unless otherwise explicitly indicated, all documents here are Copyright © 2016–2026 Binomial LLC. All rights reserved except as granted under the Apache 2.0 license.
Here are the Release Notes.
- LICENSE - The LICENSE covering our source code, specs and wiki documents (unless otherwise indicated). The source code LICENSE file (also Apache 2.0) is in the main repo here.
- NOTICE - Our NOTICE file, provided in accordance with the Apache License, Version 2.0 (§4(d))
- Other Legal/IP/License Information - GPU Texture Formats, Zstd, etc.
- JPEG for ASTC - Part of the XUASTC LDR specification
- GPU Textures as Derived (Compiled) Data - A conceptual model for modern texture distribution based on shader compilation principles
- Basis Universal: Textures as Universal Latents
- XUASTC LDR Specification
- UASTC HDR 4x4 Texture Specification
- UASTC HDR 6x6 Intermediate Texture Specification
- ASTC and XUASTC LDR Usage Guide
- UASTC LDR 4x4 Implementation Details
- ASTC HDR 6x6 and UASTC HDR 6x6i Support Notes
- Project Policies
- How to Use and Configure the Transcoder
- How to Deploy ETC1S Texture Content Using Basis Universal
- Transcoder Texture Format Support for ETC1S and UASTC LDR 4x4
- A table showing which OpenGL texture format corresponds to each supported transcoder texture format.
- ETC1S Compression Effort Levels
- ETC1S Encoder Speed
- Transcoder Debugging
The library and transcoder module is written in C++, but we do support a plain C-API that exposes all key functionality. The C API is FFI-friendly and also designed for WASM use (when the encoder library or transcoder is compiled as a WASM WASI module). This is the API we use for native Python and in our WASI WASM modules, but it's also callable from any language that supports plain C API's. Also see the pure C API example.
Python support is layered on top of our C API, which is documented above. We support calling this API from Python either via the libraries compiled as WASM WASI modules (single threaded only, so compression is slow, but transcoding is fast), or via native .so or .pyd files (which internally supports multithreaded compression). We've so far tested Python support under Windows and Ubuntu Linux with Python v3.12.3. More info is here, or see the Windows build instructions. The module first tries to load native .so's or .pyd's, and if this fails it'll try falling back to our WASM WASI modules via the wasmtime package. The native code's C API is completely made available to Python using pybind11.
The higher level Python API's are not stable yet (we are new to Python), but the lower level C API it depends on is quite stable. Several low-level tests, higher-level LDR/HDR compression and transcoding tests, and a simple example explode_ktx2 command line tool written entirely in Python are in the python directory.
- Python+OpenGL Pixel Shader Deblocking Sample - It's easy to greatly reduce block artifacts from large block size ASTC textures by using a special pixel shader to sample the texture. The shader detects when it's going to sample near a block border (which is entirely predictable and easy to determine) and applies a small horizontal and/or vertical filter across only block boundaries. This shader is compatible with mipmapping, bilinear and trilinear filtering, and anisotropic filtering, and any ASTC block size.
- Pure C API example - Written in C, shows how to use our plain C API.
- WebGL examples - Also see our Javascript emscripten API wrappers
- C++ Transcoding Example
- C++ Compression/Transcoding Example
- Python Examples
- KTX2 File Format Support Technical Details - Documents how we utilize the KTX2 file format (header ID's, DFD info, key-value fields etc.)
- .basis File Format Overview
- .basis File Format Forward/Backward Compatibility
- Using Basis Universal to decompress any supported GPU texture format
- Transcoder Internals: Analytical Real-time Encoders - These internal real-time GPU texture block encoders are available for use by developers for advanced use cases
- How to benchmark or directly call the UASTC LDR 4x4 functions without using .basis