-
-
Notifications
You must be signed in to change notification settings - Fork 97
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
Add ASTC to image and VRAM compression for better quality on mobile platforms #5313
Comments
The way I was proposing this to work is to have a "high quality" toggle in the texture import. If on, PC will import BPTC while mobile will use ASTC (high quality). |
For context, this approach is needed because BPTC/ASTC are notoriously slow to compress compared to S3TC and ETC2 (with libsquish and etcpak respectively). ASTC is also not supported on old/low-end mobile devices, and as far as I know, BPTC isn't supported on macOS. Therefore, this has to be opt-in and should be enabled on a per-texture basis (as not all textures may benefit from the increased quality). |
@Calinou M1 supports ASTC, so I guess if you want to use high quality stuff, either you support both or make two separate builds. |
Is this implemented by godotengine/godot#72031? |
As far as I know this is complete. I don't have an android device and exporting to ios is a pain. |
Yep, this is implemented by godotengine/godot#72031. I tested on Android and ASTC is working there |
Describe the project you are working on
Godot Engine, and Social VR 3d game.
Describe the problem or limitation you are having in your project
As described by @reduz, Godot Engine doesn't understand what ASTC is and this means that visual quality is poor on mobile platforms.
Also ASTC in my experience tends to slowly encode.
Describe the feature / enhancement and how it helps to overcome the problem or limitation
Mobile devices uses ASTC, while PC uses BPTC and DXT5. So we need to support both.
ASTC also supports hdr textures.
Basisu is also able to transcode to ASTC.
Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams
Add support for ASTC to Image. Image is designed for blocksizes powers of 2. ASTC has all sorts of blocksizes.
Add
https://github.com/ARM-software/astc-encoder to image and compression / or transcode UASTC.
Pick fastest encoding quality because past experience says astc is slow
Investigate https://github.com/Themaister/Granite/blob/master/assets/shaders/decode/astc.comp ASTC compute shader decoder
Create a "default, quality" toggle in the texture import.
If this enhancement will not be used often, can it be worked around with a few lines of script?
ASTC is not trivial in compute time to encode.
Is there a reason why this should be core and not an add-on in the asset library?
Mobile platforms is part of our supported list.
The text was updated successfully, but these errors were encountered: