Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/intern
diff options
context:
space:
mode:
authorBrecht Van Lommel <brecht@blender.org>2020-03-12 19:19:30 +0300
committerBrecht Van Lommel <brecht@blender.org>2020-03-12 19:19:57 +0300
commit75be60a66755f96e6d1d9b7e98bd0836784769f6 (patch)
treefd47572b2e7ce02ec4d139fcc4e136d00add9e8b /intern
parentf130c5ddb640dd7dda61d6a382259c4c89bd6822 (diff)
Fix build error with recent OpenImageIO versions
Diffstat (limited to 'intern')
-rw-r--r--intern/cycles/render/image.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/intern/cycles/render/image.cpp b/intern/cycles/render/image.cpp
index b4539b5ce3c..692f6683e1b 100644
--- a/intern/cycles/render/image.cpp
+++ b/intern/cycles/render/image.cpp
@@ -150,7 +150,7 @@ int ImageHandle::svm_slot(const int tile_index) const
if (manager->osl_texture_system) {
ImageManager::Image *img = manager->images[tile_slots[tile_index]];
- if (img->loader->osl_filepath()) {
+ if (!img->loader->osl_filepath().empty()) {
return -1;
}
}
@@ -394,7 +394,7 @@ int ImageManager::add_image_slot(ImageLoader *loader,
img->params = params;
img->loader = loader;
img->need_metadata = true;
- img->need_load = !(osl_texture_system && img->loader->osl_filepath());
+ img->need_load = !(osl_texture_system && !img->loader->osl_filepath().empty());
img->builtin = builtin;
img->users = 1;
img->mem = NULL;
@@ -794,7 +794,7 @@ void ImageManager::device_free_image(Device *, int slot)
if (osl_texture_system) {
#ifdef WITH_OSL
ustring filepath = img->loader->osl_filepath();
- if (filepath) {
+ if (!filepath.empty()) {
((OSL::TextureSystem *)osl_texture_system)->invalidate(filepath);
}
#endif