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

git.blender.org/blender-addons.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVilém Duha <vilda.novak@gmail.com>2020-12-30 14:04:27 +0300
committerVilém Duha <vilda.novak@gmail.com>2020-12-30 14:04:27 +0300
commiteb514f2106defdccb0f6d4ce8ae8a254b23b844c (patch)
treee924ff1ebc566333508e19f8caf29be0f450b767 /blenderkit
parentf56c051d7475d1c5592e5e1f54b43aa8c0d44f53 (diff)
BlenderKit: fix thumbnailer
The bakground was too glossy and could create unnecessary gradients in the background Fix hiding of the modifier for high particle counts with particle_plants
Diffstat (limited to 'blenderkit')
-rw-r--r--blenderkit/append_link.py11
-rw-r--r--blenderkit/blendfiles/thumbnailer.blendbin295494 -> 296184 bytes
2 files changed, 7 insertions, 4 deletions
diff --git a/blenderkit/append_link.py b/blenderkit/append_link.py
index d0bc59b0..4044a30d 100644
--- a/blenderkit/append_link.py
+++ b/blenderkit/append_link.py
@@ -273,12 +273,15 @@ def append_particle_system(file_name, obnames=[], location=(0, 0, 0), link=False
target_object.display_type = 'BOUNDS'
# 2nd level of optimization - reduce percentage of displayed particles.
ps.display_percentage = min(ps.display_percentage, max(1, int(100 * display_threshold / total_count)))
- # 3rd level - hide particle system from viewport.
- if total_count > total_max_threshold:
- ps.show_viewport = False
- #only now set the particle system count, if set sooner blender would probably crash quite often.
+ #here we can also tune down number of children displayed.
+ #set the count
ps.count = count
+ #add the modifier
bpy.ops.object.particle_system_add()
+ # 3rd level - hide particle system from viewport - is done on the modifier..
+ if total_count > total_max_threshold:
+ target_object.modifiers[-1].show_viewport = False
+
target_object.particle_systems[-1].settings = ps
target_object.select_set(False)
diff --git a/blenderkit/blendfiles/thumbnailer.blend b/blenderkit/blendfiles/thumbnailer.blend
index 88cf8655..f588fda9 100644
--- a/blenderkit/blendfiles/thumbnailer.blend
+++ b/blenderkit/blendfiles/thumbnailer.blend
Binary files differ