[Bf-blender-cvs] [c5d0084] openvdb: Fix compilation error when WITH_OPENVDB is off (again).

Kévin Dietrich noreply at git.blender.org
Thu Jun 11 16:36:22 CEST 2015


Commit: c5d008460600e54594402317dec889fbba36aacb
Author: Kévin Dietrich
Date:   Thu Jun 11 16:29:01 2015 +0200
Branches: openvdb
https://developer.blender.org/rBc5d008460600e54594402317dec889fbba36aacb

Fix compilation error when WITH_OPENVDB is off (again).

===================================================================

M	source/blender/blenkernel/intern/smoke.c
M	source/blender/editors/space_view3d/CMakeLists.txt
M	source/blender/editors/space_view3d/drawobject.c

===================================================================

diff --git a/source/blender/blenkernel/intern/smoke.c b/source/blender/blenkernel/intern/smoke.c
index 5e2c72b..890c341 100644
--- a/source/blender/blenkernel/intern/smoke.c
+++ b/source/blender/blenkernel/intern/smoke.c
@@ -3486,7 +3486,7 @@ void smokeModifier_OpenVDB_export(SmokeModifierData *smd, Scene *scene, Object *
 
 void smokeModifier_OpenVDB_import(SmokeModifierData *smd, Scene *scene, Object *ob, OpenVDBCache *cache)
 {
-	UNUSED_VARS(smd, scene, ob);
+	UNUSED_VARS(smd, scene, ob, cache);
 }
 
 void smokeModifier_OpenVDB_update_transform(SmokeModifierData *smd, Scene *scene,
diff --git a/source/blender/editors/space_view3d/CMakeLists.txt b/source/blender/editors/space_view3d/CMakeLists.txt
index 967636c..a9b706b 100644
--- a/source/blender/editors/space_view3d/CMakeLists.txt
+++ b/source/blender/editors/space_view3d/CMakeLists.txt
@@ -90,4 +90,8 @@ if(WITH_FREESTYLE)
 	add_definitions(-DWITH_FREESTYLE)
 endif()
 
+if(WITH_OPENVDB)
+	add_definitions(-DWITH_OPENVDB)
+endif()
+
 blender_add_lib(bf_editor_space_view3d "${SRC}" "${INC}" "${INC_SYS}")
diff --git a/source/blender/editors/space_view3d/drawobject.c b/source/blender/editors/space_view3d/drawobject.c
index 5c62534..becb2b1 100644
--- a/source/blender/editors/space_view3d/drawobject.c
+++ b/source/blender/editors/space_view3d/drawobject.c
@@ -8036,12 +8036,14 @@ void draw_object(Scene *scene, ARegion *ar, View3D *v3d, Base *base, const short
 				BKE_boundbox_init_from_minmax(&bb, p0, p1);
 				draw_box(bb.vec, false);
 
+#ifdef WITH_OPENVDB
 				glLoadMatrixf(rv3d->viewmat);
 				if (sds->density)
 					OpenVDB_draw_primitive(sds->density, true, true, true, true);
 				if (sds->density_high)
 					OpenVDB_draw_primitive(sds->density_high, true, true, true, true);
 				glMultMatrixf(sds->fluidmat);
+#endif
 			}
 
 			/* don't show smoke before simulation starts, this could be made an option in the future */




More information about the Bf-blender-cvs mailing list