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:
authorKévin Dietrich <kevin.dietrich@mailoo.org>2021-03-12 01:45:42 +0300
committerKévin Dietrich <kevin.dietrich@mailoo.org>2021-03-12 02:15:15 +0300
commit2ebf4fbbfb9afc2439ddce139243d226087662e9 (patch)
treeda6a0380ea929765940b4d68c404edb6a7453cd2 /intern
parent3256f0d52c8f172c340a7ef5154e780308e777ca (diff)
Alembic procedural: fix potential zero scale matrix generation
This can happen during user edits or with files missing the global scale property.
Diffstat (limited to 'intern')
-rw-r--r--intern/cycles/render/alembic.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/intern/cycles/render/alembic.cpp b/intern/cycles/render/alembic.cpp
index 468ebf7140f..4a9d1dbb04b 100644
--- a/intern/cycles/render/alembic.cpp
+++ b/intern/cycles/render/alembic.cpp
@@ -1017,6 +1017,10 @@ void AlembicObject::setup_transform_cache(float scale)
cached_data.transforms.clear();
cached_data.transforms.invalidate_last_loaded_time();
+ if (scale == 0.0f) {
+ scale = 1.0f;
+ }
+
if (xform_time_sampling) {
cached_data.transforms.set_time_sampling(*xform_time_sampling);
}