[Bf-blender-cvs] [1bb702df1e1] blender-v2.82-release: OpenVDB: Fix IOError in try catch statement
Sebastián Barschkis
noreply at git.blender.org
Thu Feb 6 17:24:16 CET 2020
Commit: 1bb702df1e1678b83a7238af2a28ecb73b4fb069
Author: Sebastián Barschkis
Date: Thu Feb 6 17:24:09 2020 +0100
Branches: blender-v2.82-release
https://developer.blender.org/rB1bb702df1e1678b83a7238af2a28ecb73b4fb069
OpenVDB: Fix IOError in try catch statement
Broader exception handling for OpenVDB IO errors.
===================================================================
M intern/mantaflow/intern/MANTA_main.cpp
===================================================================
diff --git a/intern/mantaflow/intern/MANTA_main.cpp b/intern/mantaflow/intern/MANTA_main.cpp
index 11b8fb820d6..798ad9c2854 100644
--- a/intern/mantaflow/intern/MANTA_main.cpp
+++ b/intern/mantaflow/intern/MANTA_main.cpp
@@ -2174,6 +2174,7 @@ void MANTA::exportLiquidScript(FluidModifierData *mmd)
bool floater = mmd->domain->particle_type & FLUID_DOMAIN_PARTICLE_FOAM;
bool tracer = mmd->domain->particle_type & FLUID_DOMAIN_PARTICLE_TRACER;
bool obstacle = mmd->domain->active_fields & FLUID_DOMAIN_ACTIVE_OBSTACLE;
+ bool fractions = mmd->domain->flags & FLUID_DOMAIN_USE_FRACTIONS;
bool guiding = mmd->domain->active_fields & FLUID_DOMAIN_ACTIVE_GUIDE;
bool invel = mmd->domain->active_fields & FLUID_DOMAIN_ACTIVE_INVEL;
@@ -2210,6 +2211,8 @@ void MANTA::exportLiquidScript(FluidModifierData *mmd)
manta_script += fluid_alloc_guiding;
if (obstacle)
manta_script += fluid_alloc_obstacle;
+ if (fractions)
+ manta_script += fluid_alloc_fractions;
if (invel)
manta_script += fluid_alloc_invel;
@@ -2891,7 +2894,7 @@ int MANTA::updateGridFromVDB(const char *filename, float *grid)
try {
file.open();
}
- catch (const openvdb::v5_1::IoError) {
+ catch (const openvdb::IoError) {
std::cout << "MANTA::updateGridFromVDB(): IOError, invalid OpenVDB file: " << filename
<< std::endl;
return 0;
More information about the Bf-blender-cvs
mailing list