diff options
author | Juan Linietsky <reduzio@gmail.com> | 2017-01-05 09:16:00 -0300 |
---|---|---|
committer | Juan Linietsky <reduzio@gmail.com> | 2017-01-05 09:16:00 -0300 |
commit | 0f7af4ea51744cda23c4d3c7481f9c332973d1d4 (patch) | |
tree | 27b8914062558b5648655ccf3db13251d217af98 /scene/io | |
parent | 9e477babb3bf0ce5179395c2a5155a3f3cd36798 (diff) |
-Changed most project settings in the engine, so they have major and minor categories.
-Changed SectionedPropertyEditor to support this
-Renamed Globals singleton to GlobalConfig, makes more sense.
-Changed the logic behind persisten global settings, instead of the persist checkbox, a revert button is now available
Diffstat (limited to 'scene/io')
-rw-r--r-- | scene/io/resource_format_image.cpp | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/scene/io/resource_format_image.cpp b/scene/io/resource_format_image.cpp index b1034041ba..cc3d9baa74 100644 --- a/scene/io/resource_format_image.cpp +++ b/scene/io/resource_format_image.cpp @@ -125,7 +125,7 @@ RES ResourceFormatLoaderImage::load(const String &p_path, const String& p_origin if (max_texture_size && (image.get_width() > max_texture_size || image.get_height() > max_texture_size)) { - if (bool(Globals::get_singleton()->get("debug/max_texture_size_alert"))) { + if (bool(GlobalConfig::get_singleton()->get("debug/image_loader/max_texture_size_alert"))) { OS::get_singleton()->alert("Texture is too large: '"+p_path+"', at "+itos(image.get_width())+"x"+itos(image.get_height())+". Max allowed size is: "+itos(max_texture_size)+"x"+itos(max_texture_size)+".","BAD ARTIST, NO COOKIE!"); } @@ -185,7 +185,7 @@ uint32_t ResourceFormatLoaderImage::load_image_flags(const String &p_path) { if (flags_found.has("filter")) { if (flags_found["filter"]) flags|=Texture::FLAG_FILTER; - } else if (bool(GLOBAL_DEF("image_loader/filter",true))) { + } else if (bool(GLOBAL_DEF("rendering/image_loader/filter",true))) { flags|=Texture::FLAG_FILTER; } @@ -193,14 +193,14 @@ uint32_t ResourceFormatLoaderImage::load_image_flags(const String &p_path) { if (flags_found.has("gen_mipmaps")) { if (flags_found["gen_mipmaps"]) flags|=Texture::FLAG_MIPMAPS; - } else if (bool(GLOBAL_DEF("image_loader/gen_mipmaps",true))) { + } else if (bool(GLOBAL_DEF("rendering/image_loader/gen_mipmaps",true))) { flags|=Texture::FLAG_MIPMAPS; } if (flags_found.has("repeat")) { if (flags_found["repeat"]) flags|=Texture::FLAG_REPEAT; - } else if (bool(GLOBAL_DEF("image_loader/repeat",true))) { + } else if (bool(GLOBAL_DEF("rendering/image_loader/repeat",true))) { flags|=Texture::FLAG_REPEAT; } @@ -252,11 +252,11 @@ String ResourceFormatLoaderImage::get_resource_type(const String &p_path) const ResourceFormatLoaderImage::ResourceFormatLoaderImage() { - max_texture_size = GLOBAL_DEF("debug/max_texture_size",0); - GLOBAL_DEF("debug/max_texture_size_alert",false); - debug_load_times=GLOBAL_DEF("debug/image_load_times",false); - GLOBAL_DEF("image_loader/filter",true); - GLOBAL_DEF("image_loader/gen_mipmaps",true); - GLOBAL_DEF("image_loader/repeat",false); + max_texture_size = GLOBAL_DEF("debug/image_loader/max_texture_size",0); + GLOBAL_DEF("debug/image_loader/max_texture_size_alert",false); + debug_load_times=GLOBAL_DEF("debug/image_loader/image_load_times",false); + GLOBAL_DEF("rendering/image_loader/filter",true); + GLOBAL_DEF("rendering/image_loader/gen_mipmaps",true); + GLOBAL_DEF("rendering/image_loader/repeat",false); } |