Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wrong compression to ktx if occlusion Texture have more 1 channels #1007

Closed
Yason83 opened this issue Jul 2, 2023 · 4 comments · Fixed by #1277
Closed

Wrong compression to ktx if occlusion Texture have more 1 channels #1007

Yason83 opened this issue Jul 2, 2023 · 4 comments · Fixed by #1277
Labels
bug Something isn't working external Problems or limitations traced back to other tools. package:cli
Milestone

Comments

@Yason83
Copy link

Yason83 commented Jul 2, 2023

Describe the bug
This image was created in RGBA mode and is used in the occlusionTexture.
During the optimization of the GLB file, it compresses it incorrectly. As far as I understand, it expects the image to be one channel.
2023-07-02_170728

Please advise if there is a way to bypass this issue.
Or is it possible to preprocess all occlusionTexture images into grayscale beforehand?

To Reproduce

  1. Blender add this image to occlusion_1 in model occlusion_1
  2. Export to glb
  3. Compress gltf-transform uastc input.glb output.glb --level 4 --rdo 4 --zstd 24 --verbose
  4. Extract images gltf-transform copy output.glb output.gltf

Versions:

  • cli.js 3.4.5 — Command-line interface (CLI) for the glTF Transform SDK.
@Yason83 Yason83 added the bug Something isn't working label Jul 2, 2023
@donmccurdy donmccurdy added dependencies Pull requests and issues related to dependencies external Problems or limitations traced back to other tools. labels Jul 3, 2023
@donmccurdy donmccurdy added this to the v3.4 milestone Jul 3, 2023
@donmccurdy
Copy link
Owner

donmccurdy commented Jul 3, 2023

Thanks @Yason83! Unless I've misunderstood the KTX-Software CLI's options, I believe the bug may be upstream. I've filed a bug here:

The new alpha release of KTX-Software doesn't appear to have this problem so the issue may get resolved on its own soon enough too. glTF Transform will need to be updated to use the next KTX Software version, when that is released.

@donmccurdy donmccurdy modified the milestones: v3.4, v3.5 Jul 23, 2023
@Yason83
Copy link
Author

Yason83 commented Aug 18, 2023

Could you give an approximate timeline on when we can expect this issue to be fixed?

@donmccurdy
Copy link
Owner

This will depend on when the issue is fixed upstream in KTX-Software and released. I have the impression they are working on it, but I don't know when that will be complete.

@donmccurdy donmccurdy modified the milestones: v3.5, Backlog Aug 22, 2023
@donmccurdy donmccurdy removed the dependencies Pull requests and issues related to dependencies label Sep 5, 2023
@donmccurdy
Copy link
Owner

KTX Software v4.3 is now stable — moving this to the glTF Transform v4 milestone.

https://github.com/KhronosGroup/KTX-Software/releases

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working external Problems or limitations traced back to other tools. package:cli
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants