/* Quicktex Texture Compression Library Copyright (C) 2021-2022 Andrew Cassidy Partially derived from rgbcx.h written by Richard Geldreich and licenced under the public domain This program is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public License along with this program. If not, see . */ #include #include #include #include "Interpolator.h" namespace py = pybind11; namespace quicktex::bindings { using namespace quicktex::s3tc; using InterpolatorPtr = std::shared_ptr; void InitInterpolator(py::module_ &s3tc) { auto interpolator = s3tc.def_submodule("_interpolator", "internal interpolator module"); // Interpolator py::class_> ideal( interpolator, "Interpolator", R"doc( Interpolator base class representing the ideal interpolation mode, with no rounding for colors 2 and 3. This matches the `D3D10 docs`_ on BC1. .. _D3D10 docs: https://docs.microsoft.com/en-us/windows/win32/direct3d10/d3d10-graphics-programming-guide-resources-block-compression )doc"); // InterpolatorRound py::class_> round(interpolator, "InterpolatorRound", ideal, R"doc( Base: :py:class:`~quicktex.s3tc.interpolator.Interpolator` Interpolator class representing the ideal rounding interpolation mode. Round colors 2 and 3. Matches the AMD Compressonator tool and the `D3D9 docs`_ on DXT1. .. _D3D9 docs: https://docs.microsoft.com/en-us/windows/win32/direct3d9/opaque-and-1-bit-alpha-textures )doc"); // InterpolatorNvidia py::class_> nvidia(interpolator, "InterpolatorNvidia", ideal, R"doc( Base: :py:class:`~quicktex.s3tc.interpolator.Interpolator` Interpolator class representing the Nvidia GPU interpolation mode. )doc"); // InterpolatorAMD py::class_> amd(interpolator, "InterpolatorAMD", ideal, R"doc( Base: :py:class:`~quicktex.s3tc.interpolator.Interpolator` Interpolator class representing the AMD GPU interpolation mode. )doc"); } } // namespace quicktex::bindings