summaryrefslogtreecommitdiff
path: root/scene/resources/texture.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'scene/resources/texture.cpp')
-rw-r--r--scene/resources/texture.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/scene/resources/texture.cpp b/scene/resources/texture.cpp
index a1e0c95dd9..0b8ad5536c 100644
--- a/scene/resources/texture.cpp
+++ b/scene/resources/texture.cpp
@@ -1781,6 +1781,10 @@ float GradientTexture::get_offset(int pos) const {
return 0; //TODO: Maybe throw some error instead?
}
+Ref<Image> GradientTexture::get_data() const {
+ return VisualServer::get_singleton()->texture_get_data(texture);
+}
+
void GradientTexture::set_color(int pos, const Color &color) {
if (points.size() <= pos) {
points.resize(pos + 1);