diff options
author | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2020-03-08 12:42:11 +0300 |
---|---|---|
committer | Brecht Van Lommel <brecht@blender.org> | 2020-03-11 22:35:38 +0300 |
commit | d8aa613d94caf6a3d82a8f4e9e90b9b8f5c61a7d (patch) | |
tree | 7f85577ae4f37c9bdeba31fd65411b718b19b035 /intern/cycles/blender/blender_volume.cpp | |
parent | ec3eeee46b4885b9167b0dc28d273993d77b8ce6 (diff) |
Cleanup: add ImageHandle to centralize image ownership logic
Diffstat (limited to 'intern/cycles/blender/blender_volume.cpp')
-rw-r--r-- | intern/cycles/blender/blender_volume.cpp | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/intern/cycles/blender/blender_volume.cpp b/intern/cycles/blender/blender_volume.cpp index 4dab60088bb..e11cc4ab18f 100644 --- a/intern/cycles/blender/blender_volume.cpp +++ b/intern/cycles/blender/blender_volume.cpp @@ -48,15 +48,12 @@ static void sync_smoke_volume(Scene *scene, BL::Object &b_ob, Mesh *mesh, float mesh->volume_isovalue = b_domain.clipping(); Attribute *attr = mesh->attributes.add(std); - VoxelAttribute *volume_data = attr->data_voxel(); - ImageMetaData metadata; ImageKey key; key.filename = Attribute::standard_name(std); key.builtin_data = b_ob.ptr.data; - volume_data->manager = image_manager; - volume_data->slot = image_manager->add_image(key, frame, metadata); + attr->add(image_manager->add_image(key, frame)); } /* Create a matrix to transform from object space to mesh texture space. |