diff options
author | Lyuma <xn.lyuma@gmail.com> | 2023-01-30 23:37:55 -0800 |
---|---|---|
committer | Lyuma <xn.lyuma@gmail.com> | 2023-02-01 01:42:36 -0800 |
commit | bc24d0135944dedbdbaa8f6aff8f9faee772fe3e (patch) | |
tree | 48d03b8273c0ff940bba3c531dec26e62a4e41d3 /modules/gltf/doc_classes | |
parent | 0810ecaafdbee3ea747219e6ab3a8de5d2216a09 (diff) |
gltf: Add GLTFHandleBinary::HANDLE_BINARY_EMBED_AS_UNCOMPRESSED
This option allows for a safe fallback for embedded gltf textures in cases where VRAM compression is not needed.
Add an is_editor_hint guard around GLTFHandleBinary::HANDLE_BINARY_EXTRACT_TEXTURES, to use EMBED_AS_UNCOMPRESSED by default at runtime.
This provides an option for pixel art to be stored losslessly.
Additionally, respect project importer defaults for texture import settings.
Avoid writing and reimporting extracted textures identical to version on disk.
Diffstat (limited to 'modules/gltf/doc_classes')
-rw-r--r-- | modules/gltf/doc_classes/GLTFState.xml | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/modules/gltf/doc_classes/GLTFState.xml b/modules/gltf/doc_classes/GLTFState.xml index b8943795a0..b322c07cec 100644 --- a/modules/gltf/doc_classes/GLTFState.xml +++ b/modules/gltf/doc_classes/GLTFState.xml @@ -264,10 +264,16 @@ </members> <constants> <constant name="HANDLE_BINARY_DISCARD_TEXTURES" value="0"> + Discards all embedded textures and uses untextured materials. </constant> <constant name="HANDLE_BINARY_EXTRACT_TEXTURES" value="1"> + Extracts embedded textures to be reimported and compressed. Editor only. Acts as uncompressed at runtime. </constant> <constant name="HANDLE_BINARY_EMBED_AS_BASISU" value="2"> + Embeds textures VRAM compressed with Basis Universal into the generated scene. + </constant> + <constant name="HANDLE_BINARY_EMBED_AS_UNCOMPRESSED" value="3"> + Embeds textures compressed losslessly into the generated scene, matching old behavior. </constant> </constants> </class> |