diff options
Diffstat (limited to 'source/blender/blenkernel/intern/volume_render.cc')
-rw-r--r-- | source/blender/blenkernel/intern/volume_render.cc | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/source/blender/blenkernel/intern/volume_render.cc b/source/blender/blenkernel/intern/volume_render.cc index e7620be6401..700bd63c9d4 100644 --- a/source/blender/blenkernel/intern/volume_render.cc +++ b/source/blender/blenkernel/intern/volume_render.cc @@ -102,9 +102,8 @@ bool BKE_volume_grid_dense_floats(const Volume *volume, } const openvdb::Vec3i resolution = bbox.dim().asVec3i(); - const int64_t num_voxels = static_cast<int64_t>(resolution[0]) * - static_cast<int64_t>(resolution[1]) * - static_cast<int64_t>(resolution[2]); + const int64_t num_voxels = int64_t(resolution[0]) * int64_t(resolution[1]) * + int64_t(resolution[2]); const int channels = BKE_volume_grid_channels(volume_grid); const int elem_size = sizeof(float) * channels; float *voxels = static_cast<float *>(MEM_malloc_arrayN(num_voxels, elem_size, __func__)); |