diff options
| author | Ovnuniarchos | 2015-11-19 01:19:19 +0100 |
|---|---|---|
| committer | Ovnuniarchos | 2015-11-19 01:19:19 +0100 |
| commit | a9a330645b29152ccc29b6e075c0ebda24b03e37 (patch) | |
| tree | 2cf319ce8453dd295c40b809b4bf54527e4fe020 /scene/resources/texture.cpp | |
| parent | 0f0dc1a5d328502343c5a902aec552fb01033504 (diff) | |
| parent | 94fdd01241749cb7a575ed5f9fa4c7bbb286901a (diff) | |
| download | godot-a9a330645b29152ccc29b6e075c0ebda24b03e37.tar.gz godot-a9a330645b29152ccc29b6e075c0ebda24b03e37.tar.zst godot-a9a330645b29152ccc29b6e075c0ebda24b03e37.zip | |
Diffstat (limited to 'scene/resources/texture.cpp')
| -rw-r--r-- | scene/resources/texture.cpp | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/scene/resources/texture.cpp b/scene/resources/texture.cpp index 7b261f779..994473f11 100644 --- a/scene/resources/texture.cpp +++ b/scene/resources/texture.cpp @@ -366,6 +366,16 @@ void ImageTexture::set_size_override(const Size2& p_size) { VisualServer::get_singleton()->texture_set_size_override(texture,w,h); } +void ImageTexture::set_path(const String& p_path,bool p_take_over) { + + if (texture.is_valid()) { + VisualServer::get_singleton()->texture_set_path(texture,p_path); + } + + Resource::set_path(p_path,p_take_over); +} + + void ImageTexture::set_storage(Storage p_storage) { storage=p_storage; @@ -944,6 +954,16 @@ float CubeMap::get_lossy_storage_quality() const { return lossy_storage_quality; } +void CubeMap::set_path(const String& p_path,bool p_take_over) { + + if (cubemap.is_valid()) { + VisualServer::get_singleton()->texture_set_path(cubemap,p_path); + } + + Resource::set_path(p_path,p_take_over); +} + + bool CubeMap::_set(const StringName& p_name, const Variant& p_value) { if (p_name=="side/left") { |
