Skip to main content

ispc_texcomp_py

Win/Mac/Linux MIT Docs

Python bindings for ISPCTextureCompressor.

Installation

pip install ispc_texcomp

Building

ispc has to be available in the PATH for setup.py to work.

Usage

from PIL import Image
import ispc_texcomp_py

# get the rgba data (of an image you want to compress)
img = Image.open(fp)
rgba = Image.tobytes("raw", "RGBA")

# create a RGBASurface
stride = img.width * 4
surface = ispc_texcomp_py.RGBASurface(rgba, img.width, img.height, stride)


# compress the surface (no profile)

# BC1
bc1_compressed: bytes = ispc_texcomp_py.CompressBlocksBC1(surface)

# BC3
bc3_compressed: bytes = ispc_texcomp_py.CompressBlocksBC3(surface)

# BC3
bc4_compressed: bytes = ispc_texcomp_py.CompressBlocksBC4(surface)

# BC5
bc5_compressed: bytes = ispc_texcomp_py.CompressBLocksBC5(surface)


# compress the surface (with profile)

# BC6h
# profile options:
#   veryfast, fast, basic, slow, veryslow
profile = ispc_texcomp_py.BC6HEncSettings.from_profile("fast")
bc6h_compressed: bytes = ispc_texcomp_py.CompressBlocksBC6H(surface, profile)

# BC7
# profile options:
#   ultrafast, veryfast, fast, basic, slow,
#   alpha_ultrafast, alpha_veryfast, alpha_fast, alpha_basic, alpha_slow
profile = ispc_texcomp_py.BC7EncSettings.from_profile("fast")
bc7_compressed: bytes = ispc_texcomp_py.CompressBlocksBC7(surface, profile)

# ETC1
# profile options:
#   slow
profile = ispc_texcomp_py.ETCEncSettings.from_profile("slow")
etc1_compressed: bytes = ispc_texcomp_py.CompressBlocksETC1(surface, profile)

# ASTC
# profile options:
#   fast, alpha_fast, alpha_slow
profile = ispc_texcomp_py.ASTCEncSettings.from_profile("fas", 8, 8)
astc_compressed: bytes = ispc_texcomp_py.CompressBlocksASTC(surface, profile)

Metadata

Release files for ispc-texcomp 1.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for ispc-texcomp 1.0.1
File Size Uploaded
ispc_texcomp-1.0.1.tar.gz 71.4 kB Details

Built distributions (wheels)

Table of built distributions (wheels) for ispc-texcomp 1.0.1
File
ispc_texcomp-1.0.1-cp311-abi3-win_arm64.whl CPython 3.11 abi3 Windows ARM64 Details
ispc_texcomp-1.0.1-cp311-abi3-win_amd64.whl CPython 3.11 abi3 Windows x86-64 Details
ispc_texcomp-1.0.1-cp311-abi3-win32.whl CPython 3.11 abi3 Windows x86-32 Details
ispc_texcomp-1.0.1-cp311-abi3-musllinux_1_2_x86_64.whl CPython 3.11 abi3 Linux musl 1.2+ x86-64 Details
ispc_texcomp-1.0.1-cp311-abi3-musllinux_1_2_i686.whl CPython 3.11 abi3 Linux musl 1.2+ x86-32 Details
ispc_texcomp-1.0.1-cp311-abi3-musllinux_1_2_armv7l.whl CPython 3.11 abi3 Linux musl 1.2+ ARMv7l Details
ispc_texcomp-1.0.1-cp311-abi3-musllinux_1_2_aarch64.whl CPython 3.11 abi3 Linux musl 1.2+ ARM64 Details
ispc_texcomp-1.0.1-cp311-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.11 abi3 Linux glibc 2.17+ x86-64 Details
ispc_texcomp-1.0.1-cp311-abi3-manylinux_2_17_i686.manylinux2014_i686.whl CPython 3.11 abi3 Linux glibc 2.17+ x86-32 Details
ispc_texcomp-1.0.1-cp311-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl CPython 3.11 abi3 Linux glibc 2.17+ ARM64 Details
ispc_texcomp-1.0.1-cp311-abi3-macosx_11_0_arm64.whl CPython 3.11 abi3 macOS 11.0+ ARM64 Details
ispc_texcomp-1.0.1-cp311-abi3-macosx_10_9_x86_64.whl CPython 3.11 abi3 macOS 10.9+ x86-64 Details

Total release size: 10.4 MB

Release files / ispc_texcomp-1.0.1.tar.gz

Download URL ispc_texcomp-1.0.1.tar.gz
Size 71.4 kB
Tags Source
SHA-256 checksum
How to use checksums
d94b794374bde088060143976dcd9d158d66e316301d72a9f1445b6c6d6f2101
BLAKE2b-256 checksum
How to use checksums
f5957bcdf50c697780093e6fe08e32fb43c48ab9a96fd6065f2ea33efcb13f9c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Apr 2, 2025.

Transparency log

Release files / ispc_texcomp-1.0.1-cp311-abi3-win_arm64.whl

Download URL ispc_texcomp-1.0.1-cp311-abi3-win_arm64.whl
Size 182.9 kB
Tags CPython 3.11 Windows ARM64 abi3
SHA-256 checksum
How to use checksums
4d8510c6439bcc858c0dea013fb97528f465ccbebf76d71ccb3276a4176535ae
BLAKE2b-256 checksum
How to use checksums
f8170520e1088ffd2c3ce90bacaddc0cb956253220f9cd938e2421bd98723f89
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Apr 2, 2025.

Transparency log

Release files / ispc_texcomp-1.0.1-cp311-abi3-win_amd64.whl

Download URL ispc_texcomp-1.0.1-cp311-abi3-win_amd64.whl
Size 739.3 kB
Tags CPython 3.11 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
08ef519036b6229e7e207106cdc9a19101deb46cbf105ca8ec9e10d59cc69ac8
BLAKE2b-256 checksum
How to use checksums
3435c787a609de7218eb6d1973e018d07cff650c5318bdee176a6c97547cf353
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Apr 2, 2025.

Transparency log

Release files / ispc_texcomp-1.0.1-cp311-abi3-win32.whl

Download URL ispc_texcomp-1.0.1-cp311-abi3-win32.whl
Size 360.0 kB
Tags CPython 3.11 Windows x86-32 abi3
SHA-256 checksum
How to use checksums
1f1acb004aeda5308487e6720ef1c0513e6a65eec1fbfcf2e7bcaf80b78345cb
BLAKE2b-256 checksum
How to use checksums
7b907c5e3aa2a5bce225d9cb12c848f4ca3bb84a94f45b83983a23ccc37ce73d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Apr 2, 2025.

Transparency log

Release files / ispc_texcomp-1.0.1-cp311-abi3-musllinux_1_2_x86_64.whl

Download URL ispc_texcomp-1.0.1-cp311-abi3-musllinux_1_2_x86_64.whl
Size 1.9 MB
Tags CPython 3.11 Linux musl 1.2+ x86-64 abi3
SHA-256 checksum
How to use checksums
27b228e4db214f53a7739f8206142dc828ecd76e7504f91645896f13e64a077f
BLAKE2b-256 checksum
How to use checksums
5b518e41a25500b684032d17ba1b9f4cf13e3e7d05fdfc34937d811f3dcdf5a1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Apr 2, 2025.

Transparency log

Release files / ispc_texcomp-1.0.1-cp311-abi3-musllinux_1_2_i686.whl

Download URL ispc_texcomp-1.0.1-cp311-abi3-musllinux_1_2_i686.whl
Size 1.7 MB
Tags CPython 3.11 Linux musl 1.2+ x86-32 abi3
SHA-256 checksum
How to use checksums
e04108a292094e991ab126836ee8307d92b7d4f196e126910a8e1fb9c9823646
BLAKE2b-256 checksum
How to use checksums
6ce724f3b484cc4a3cf90fc79861ac0d5aa3934623ceb4851600638f10ff8085
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Apr 2, 2025.

Transparency log

Release files / ispc_texcomp-1.0.1-cp311-abi3-musllinux_1_2_armv7l.whl

Download URL ispc_texcomp-1.0.1-cp311-abi3-musllinux_1_2_armv7l.whl
Size 1.3 MB
Tags CPython 3.11 Linux musl 1.2+ ARMv7l abi3
SHA-256 checksum
How to use checksums
b9281e86de4c3c861a71764d4c6f3956f5b3d188d0e23cbb6e1e43abf56b7391
BLAKE2b-256 checksum
How to use checksums
992e588fdd594b34e6b549d664174e0910c75377650326b3c2540f3dab0c2989
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Apr 2, 2025.

Transparency log

Release files / ispc_texcomp-1.0.1-cp311-abi3-musllinux_1_2_aarch64.whl

Download URL ispc_texcomp-1.0.1-cp311-abi3-musllinux_1_2_aarch64.whl
Size 1.4 MB
Tags CPython 3.11 Linux musl 1.2+ ARM64 abi3
SHA-256 checksum
How to use checksums
29868f117de04eaeceb9b5fae1d3e6aa4896e2be75288950bb40c6b00919dc1c
BLAKE2b-256 checksum
How to use checksums
323d0456e24071d1f299cf5e1067aab40455d068f29a7be1969e61dfd686eed3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Apr 2, 2025.

Transparency log

Release files / ispc_texcomp-1.0.1-cp311-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL ispc_texcomp-1.0.1-cp311-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 939.9 kB
Tags CPython 3.11 Linux glibc 2.17+ x86-64 abi3
SHA-256 checksum
How to use checksums
48cc5f46351b0a6e15d48b68fa9feba57d59a1396c5ed90d93df18c3d84eeca7
BLAKE2b-256 checksum
How to use checksums
2d9456e38e19b622f9de1ece8c32f4584902cc56fe1a3e20a85bbb844cea16bc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Apr 2, 2025.

Transparency log

Release files / ispc_texcomp-1.0.1-cp311-abi3-manylinux_2_17_i686.manylinux2014_i686.whl

Download URL ispc_texcomp-1.0.1-cp311-abi3-manylinux_2_17_i686.manylinux2014_i686.whl
Size 586.5 kB
Tags CPython 3.11 Linux glibc 2.17+ x86-32 abi3
SHA-256 checksum
How to use checksums
467ac7262235db6bb97e99639ea178f0757107e77f46e62780c49f126553936a
BLAKE2b-256 checksum
How to use checksums
d30a1703b933984192c4dbbe93a0065b379e8606e045ccf5e4e3cda69140ced4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Apr 2, 2025.

Transparency log

Release files / ispc_texcomp-1.0.1-cp311-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl

Download URL ispc_texcomp-1.0.1-cp311-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Size 404.1 kB
Tags CPython 3.11 Linux glibc 2.17+ ARM64 abi3
SHA-256 checksum
How to use checksums
cc293b7d83c17ddba275fd3355fa1b5ba2838e02da5fae654c8c31e0d07c8182
BLAKE2b-256 checksum
How to use checksums
147ca4668a7f6001df26253550c97cc1bb9c1de8925b00d15ad4c3a5e82a826e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Apr 2, 2025.

Transparency log

Release files / ispc_texcomp-1.0.1-cp311-abi3-macosx_11_0_arm64.whl

Download URL ispc_texcomp-1.0.1-cp311-abi3-macosx_11_0_arm64.whl
Size 186.2 kB
Tags CPython 3.11 abi3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
ab35d1c4b602000d15b4daacd4c7aecd71f31dd550c60500bfcb4fe5bafce9a8
BLAKE2b-256 checksum
How to use checksums
794fe3e50fe4f2d33afaa6a9fd6310fc946606f6eb9941c9e351ee8ab88b3029
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Apr 2, 2025.

Transparency log

Release files / ispc_texcomp-1.0.1-cp311-abi3-macosx_10_9_x86_64.whl

Download URL ispc_texcomp-1.0.1-cp311-abi3-macosx_10_9_x86_64.whl
Size 708.9 kB
Tags CPython 3.11 abi3 macOS 10.9+ x86-64
SHA-256 checksum
How to use checksums
129f1359ca40dfa4a781e78788033dc6b0b4fc824f12f80f9e26f38b14aa2a0c
BLAKE2b-256 checksum
How to use checksums
23b23e9988ab1170f8bb3007e2c7fed89ee62d4be8141ad5006699a000d7d5bc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Apr 2, 2025.

Transparency log

Release history Release notifications | RSS feed

This release

1.0.1 This release

13 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page