diff options
author | David Snopek <dsnopek@gmail.com> | 2022-12-20 15:49:11 -0600 |
---|---|---|
committer | David Snopek <dsnopek@gmail.com> | 2023-01-23 13:24:54 -0600 |
commit | 74458b6e9bed0f28db3374c7406eacbcf4b09b9d (patch) | |
tree | 9ce6e2833dbe29a75461f1cf3b171fc7e090bdcf /scene/resources/texture.h | |
parent | 91713ced81792b10fdc9367b7f355738e5d52777 (diff) | |
download | redot-engine-74458b6e9bed0f28db3374c7406eacbcf4b09b9d.tar.gz |
Add "dedicated server" export mode which can strip unneeded visual resources
Diffstat (limited to 'scene/resources/texture.h')
-rw-r--r-- | scene/resources/texture.h | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/scene/resources/texture.h b/scene/resources/texture.h index bb86910c0c..7f74ae6941 100644 --- a/scene/resources/texture.h +++ b/scene/resources/texture.h @@ -82,6 +82,8 @@ public: virtual Ref<Image> get_image() const { return Ref<Image>(); } + virtual Ref<Resource> create_placeholder() const; + Texture2D(); }; @@ -450,25 +452,41 @@ public: class Texture2DArray : public ImageTextureLayered { GDCLASS(Texture2DArray, ImageTextureLayered) + +protected: + static void _bind_methods(); + public: Texture2DArray() : ImageTextureLayered(LAYERED_TYPE_2D_ARRAY) {} + + virtual Ref<Resource> create_placeholder() const; }; class Cubemap : public ImageTextureLayered { GDCLASS(Cubemap, ImageTextureLayered); +protected: + static void _bind_methods(); + public: Cubemap() : ImageTextureLayered(LAYERED_TYPE_CUBEMAP) {} + + virtual Ref<Resource> create_placeholder() const; }; class CubemapArray : public ImageTextureLayered { GDCLASS(CubemapArray, ImageTextureLayered); +protected: + static void _bind_methods(); + public: CubemapArray() : ImageTextureLayered(LAYERED_TYPE_CUBEMAP_ARRAY) {} + + virtual Ref<Resource> create_placeholder() const; }; class CompressedTextureLayered : public TextureLayered { @@ -580,6 +598,7 @@ public: virtual int get_depth() const; virtual bool has_mipmaps() const; virtual Vector<Ref<Image>> get_data() const; + virtual Ref<Resource> create_placeholder() const; }; class ImageTexture3D : public Texture3D { |