diff options
author | Clément Foucault <foucault.clem@gmail.com> | 2020-10-20 16:07:12 +0300 |
---|---|---|
committer | Clément Foucault <foucault.clem@gmail.com> | 2020-10-20 16:08:25 +0300 |
commit | 257fe5a6e7777a9d1030f88829fc0cb412c1058d (patch) | |
tree | c983a6507c0cb723a6c88629924523f5f93dc47d /source/blender/blenkernel/intern/volume.cc | |
parent | 360282cf1f838160288eb16d051beb79873c784b (diff) |
Volumes: Fix compilation when building without openVDB
And remove a warning.
Diffstat (limited to 'source/blender/blenkernel/intern/volume.cc')
-rw-r--r-- | source/blender/blenkernel/intern/volume.cc | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/source/blender/blenkernel/intern/volume.cc b/source/blender/blenkernel/intern/volume.cc index 64d053c0e30..5e6f0bb42ef 100644 --- a/source/blender/blenkernel/intern/volume.cc +++ b/source/blender/blenkernel/intern/volume.cc @@ -953,6 +953,7 @@ bool BKE_volume_is_points_only(const Volume *volume) static void volume_update_simplify_level(Volume *volume, const Depsgraph *depsgraph) { +#ifdef WITH_OPENVDB const int simplify_level = BKE_volume_simplify_level(depsgraph); if (volume->runtime.grids) { for (VolumeGrid &grid : *volume->runtime.grids) { @@ -960,6 +961,9 @@ static void volume_update_simplify_level(Volume *volume, const Depsgraph *depsgr } } volume->runtime.default_simplify_level = simplify_level; +#else + UNUSED_VARS(volume, depsgraph); +#endif } static Volume *volume_evaluate_modifiers(struct Depsgraph *depsgraph, @@ -1260,6 +1264,8 @@ VolumeGridType BKE_volume_grid_type(const VolumeGrid *volume_grid) #ifdef WITH_OPENVDB const openvdb::GridBase::Ptr grid = volume_grid->grid(); return BKE_volume_grid_type_openvdb(grid); +#else + UNUSED_VARS(volume_grid); #endif return VOLUME_GRID_UNKNOWN; } |