summaryrefslogtreecommitdiff
path: root/scene/resources/texture.h
diff options
context:
space:
mode:
Diffstat (limited to 'scene/resources/texture.h')
-rw-r--r--scene/resources/texture.h11
1 files changed, 4 insertions, 7 deletions
diff --git a/scene/resources/texture.h b/scene/resources/texture.h
index 4b5b504510..281a33929c 100644
--- a/scene/resources/texture.h
+++ b/scene/resources/texture.h
@@ -37,8 +37,8 @@
#include "core/os/rw_lock.h"
#include "core/os/thread_safe.h"
#include "core/resource.h"
-#include "scene/resources/color_ramp.h"
#include "scene/resources/curve.h"
+#include "scene/resources/gradient.h"
#include "servers/visual_server.h"
/**
@@ -111,7 +111,7 @@ private:
Size2 size_override;
float lossy_storage_quality;
mutable Ref<BitMap> alpha_cache;
- Ref<Image> image_cache;
+ bool image_stored;
protected:
virtual void reload_from_file();
@@ -126,11 +126,7 @@ protected:
void _set_data(Dictionary p_data);
- static bool keep_images_cached;
-
public:
- static void set_keep_images_cached(bool p_enable);
-
void create(int p_width, int p_height, Image::Format p_format, uint32_t p_flags = FLAGS_DEFAULT);
void create_from_image(const Ref<Image> &p_image, uint32_t p_flags = FLAGS_DEFAULT);
@@ -191,7 +187,7 @@ public:
};
private:
- Error _load_data(const String &p_path, int &tw, int &th, int &flags, Ref<Image> &image, int p_size_limit = 0);
+ Error _load_data(const String &p_path, int &tw, int &th, int &tw_custom, int &th_custom, int &flags, Ref<Image> &image, int p_size_limit = 0);
String path_to_file;
RID texture;
Image::Format format;
@@ -207,6 +203,7 @@ private:
protected:
static void _bind_methods();
+ void _validate_property(PropertyInfo &property) const;
public:
typedef void (*TextureFormatRequestCallback)(const Ref<StreamTexture> &);