diff options
author | Juan Linietsky <reduzio@gmail.com> | 2022-08-31 11:12:42 +0200 |
---|---|---|
committer | Juan Linietsky <reduzio@gmail.com> | 2022-09-01 11:16:00 +0200 |
commit | ef17c4668ad18a8732a3bccbd2474887ab394cd7 (patch) | |
tree | 6942237e1f87249ba02e2f7a840512ee2ebc6d68 /editor/export/editor_export.cpp | |
parent | c40855f8189e603bdadca8d32fa7988a249ed96b (diff) |
Add support for scene/resource customization in export plugins
EditorExportPlugin adds a set of callbacks to allow customizing scenes, resources or subresources in all files exported:
* Can take scene files, resource files and subresources in all of them.
* Uses a cache for the converted files if nothing changes, so this work only happens if a file is modified.
* Uses hashing to differentiate export configuration caches.
* Removed the previous conversion code to binary, as this one uses existing stuff.
This API is useful in several scenarios:
* Needed by the "server" export platform to get rid of textures, meshes, audio, etc.
* Needed by text to binary converters.
* Needed by eventual optimizations such as shader precompiling on export, mesh merging and optimization, etc.
This is a draft, feedback is very welcome.
Diffstat (limited to 'editor/export/editor_export.cpp')
-rw-r--r-- | editor/export/editor_export.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/editor/export/editor_export.cpp b/editor/export/editor_export.cpp index d291040bd2..29b6a5e546 100644 --- a/editor/export/editor_export.cpp +++ b/editor/export/editor_export.cpp @@ -351,6 +351,8 @@ EditorExport::EditorExport() { singleton = this; set_process(true); + + GLOBAL_DEF("editor/export/convert_text_resources_to_binary", true); } EditorExport::~EditorExport() { |