Colors become lighter when transcoding .basis to .ktx
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 35/100
- Tipo di issue
- Bug
- Chiarezza
- Abbastanza chiara
- Stato di attività
- Ferma
- Stack tecnologico
- cpp
- Ambito
- computer-graphics
Direzione di ricerca
Start by comparing the .basis to .ktx transcoding path with the .basis to .png unpack path; the issue does not name source files or tests. Check how the KTX output records and handles color space, then reproduce with the provided cubemap commands and images. Done means the generated KTX colors match the expected source colors in the reported viewers.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Hello, I'm trying to use basisu to bundle and compress the 6 images of a cube map. It does work, however the resulting .ktx file ends up considerably lighter than the source file. I am using filament as my rendering engine which unfortunately does not support ktx2 cubemaps (I'm stuck on just .ktx) and the compressed format must work on mac, webassembly, iOS and Android so my supported compression formats are limited.
Here is how I compress to .basis and then to .ktx
basisu -tex_type cubemap Face_2.jpg Face_0.jpg Face_4.jpg Face_5.jpg Face_1.jpg Face_3.jpg
basisu -unpack -ktx_only -format_only 1 Face_2.basis
It appears to me the problem is in the .basis to .ktx step. I say this because unpacking the .basis file to .png produces the correct colors. I use the following command to unpack to .pngs:
basisu -unpack -no_ktx Face_2.basis
Let me know if you have any suggestions as to what might be wrong. None of the sRGB/linear basisu command line options seem to help. According to filament the final .ktx file is in linear and not sRGB color space. See the below screen shots.
One of the 6 source images:

One of the 6 images unpacked from the .basis file to .png with correct colors:

A screenshot from the mac preview application of the .ktx file with the overly light colors. Filament displays the same overly light colors.

Thanks,
Omri
- Lingua principale
- C++
- Stelle
- 3.1k
- Fork
- 347
- Merge medio
- 4g 3h
- PR unite (30g)
- 1
Preparare l'ambiente
Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di BinomialLLC/basis_universal
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
BinomialLLC/basis_universal#476 ·
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 84/100
BinomialLLC/basis_universal#471 · 1 commento · 1 reazione ·
-
ktx2_transcoder::transcode_image_level asserts on a malformed uncompressedByteLength instead of returning falseForse già presa @albertrodriguezclo l’ha presa 24 giorni fa. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 25/100
BinomialLLC/basis_universal#472 · 2 commenti · 1 reazione ·
-
Difficoltà 3/5 1-2 giorni Idoneità per principianti 48/100
BinomialLLC/basis_universal#465 ·
-
Support custom key/value pairs in KTX2 compressionForse già presa Una pull request collegata a questa issue è aperta o già unita. Aperta
Difficoltà 3/5 1-2 giorni Idoneità per principianti 54/100
BinomialLLC/basis_universal#454 · 1 commento ·
Tutte le issue di BinomialLLC/basis_universal
Issue simili
-
area:qmc bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 69/100
I maintainer di solito rispondono entro 3 giorni
-
bug good first issue
Difficoltà 2/5 1-3 ore Idoneità per principianti 74/100
ASGC-Game-Jam/asgc-gamejam-2026#563 ·
I maintainer di solito rispondono entro 1 giorno
-
area/ysql kind/bug priority/medium status/awaiting-triage
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
yugabyte/yugabyte-db#37523 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 62/100
Cockatrice/Cockatrice#7896 ·
I maintainer di solito rispondono entro 1 giorno
-
mlir
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
llvm/llvm-project#241070 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno