From b0a1cf2c9ae696b07f7a236bc855a5ab4a493dcb Mon Sep 17 00:00:00 2001 From: Brecht Van Lommel Date: Tue, 17 Mar 2020 14:41:48 +0100 Subject: Objects: add Volume object type, and prototypes for Hair and PointCloud Only the volume object is exposed in the user interface. It is based on OpenVDB internally. Drawing and rendering code will follow in another commit. https://wiki.blender.org/wiki/Source/Objects/Volume https://wiki.blender.org/wiki/Reference/Release_Notes/2.83/Volumes Hair and PointCloud object types are hidden behind a WITH_NEW_OBJECT_TYPES build option. These are unfinished, and included only to make it easier to cooperate on development in the future and avoid tricky merges. https://wiki.blender.org/wiki/Source/Objects/New_Object_Types Ref T73201, T68981 Differential Revision: https://developer.blender.org/D6945 --- source/blender/blenkernel/intern/object_update.c | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) (limited to 'source/blender/blenkernel/intern/object_update.c') diff --git a/source/blender/blenkernel/intern/object_update.c b/source/blender/blenkernel/intern/object_update.c index 20b2ab9409f..66c3b2ea26e 100644 --- a/source/blender/blenkernel/intern/object_update.c +++ b/source/blender/blenkernel/intern/object_update.c @@ -45,6 +45,7 @@ #include "BKE_editmesh.h" #include "BKE_effect.h" #include "BKE_gpencil_modifier.h" +#include "BKE_hair.h" #include "BKE_image.h" #include "BKE_key.h" #include "BKE_layer.h" @@ -56,8 +57,10 @@ #include "BKE_object.h" #include "BKE_particle.h" #include "BKE_pointcache.h" +#include "BKE_pointcloud.h" #include "BKE_scene.h" #include "BKE_gpencil.h" +#include "BKE_volume.h" #include "MEM_guardedalloc.h" @@ -225,6 +228,15 @@ void BKE_object_handle_data_update(Depsgraph *depsgraph, Scene *scene, Object *o BKE_gpencil_update_layer_parent(depsgraph, ob); break; } + case OB_HAIR: + BKE_hair_data_update(depsgraph, scene, ob); + break; + case OB_POINTCLOUD: + BKE_pointcloud_data_update(depsgraph, scene, ob); + break; + case OB_VOLUME: + BKE_volume_data_update(depsgraph, scene, ob); + break; } /* particles */ @@ -354,6 +366,15 @@ void BKE_object_batch_cache_dirty_tag(Object *ob) case OB_GPENCIL: BKE_gpencil_batch_cache_dirty_tag(ob->data); break; + case OB_HAIR: + BKE_hair_batch_cache_dirty_tag(ob->data, BKE_HAIR_BATCH_DIRTY_ALL); + break; + case OB_POINTCLOUD: + BKE_pointcloud_batch_cache_dirty_tag(ob->data, BKE_POINTCLOUD_BATCH_DIRTY_ALL); + break; + case OB_VOLUME: + BKE_volume_batch_cache_dirty_tag(ob->data, BKE_VOLUME_BATCH_DIRTY_ALL); + break; } } -- cgit v1.2.3