Added basic support for custom resource savers and loaders

This commit is contained in:
Marc Gilleron 2018-06-11 02:59:53 +02:00
parent ca28c455bf
commit 065e2670af
77 changed files with 1102 additions and 145 deletions

View file

@ -100,6 +100,7 @@ public:
};
class ResourceFormatLoaderBinary : public ResourceFormatLoader {
GDCLASS(ResourceFormatLoaderBinary, ResourceFormatLoader)
public:
virtual Ref<ResourceInteractiveLoader> load_interactive(const String &p_path, const String &p_original_path = "", Error *r_error = NULL);
virtual void get_recognized_extensions_for_type(const String &p_type, List<String> *p_extensions) const;
@ -152,7 +153,7 @@ public:
};
class ResourceFormatSaverBinary : public ResourceFormatSaver {
GDCLASS(ResourceFormatSaverBinary, ResourceFormatSaver)
public:
static ResourceFormatSaverBinary *singleton;
virtual Error save(const String &p_path, const RES &p_resource, uint32_t p_flags = 0);