[Bf-blender-cvs] [e3ed51d] openvdb: Cleanups: unnecessary includes, small de-duplication, accidental/ unwanted changes, ...

Kévin Dietrich noreply at git.blender.org
Thu Aug 6 00:51:08 CEST 2015


Commit: e3ed51deba70cef6bb8e5d243ea04809faadf70f
Author: Kévin Dietrich
Date:   Thu Aug 6 00:25:26 2015 +0200
Branches: openvdb
https://developer.blender.org/rBe3ed51deba70cef6bb8e5d243ea04809faadf70f

Cleanups: unnecessary includes, small de-duplication, accidental/
unwanted changes, ...

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

M	intern/cycles/kernel/kernel_compat_cpu.h
M	intern/cycles/render/scene.h
M	intern/cycles/util/util_volume.h
M	source/blender/CMakeLists.txt
M	source/blender/editors/object/object_modifier.c
M	source/blender/editors/object/object_ops.c
M	source/blender/editors/space_view3d/drawobject.c

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

diff --git a/intern/cycles/kernel/kernel_compat_cpu.h b/intern/cycles/kernel/kernel_compat_cpu.h
index 3e08b4d..f0efe73 100644
--- a/intern/cycles/kernel/kernel_compat_cpu.h
+++ b/intern/cycles/kernel/kernel_compat_cpu.h
@@ -40,7 +40,6 @@
 #include "util_simd.h"
 #include "util_half.h"
 #include "util_types.h"
-#include "util_vector.h"
 #include "util_volume.h"
 
 #define ccl_addr_space
diff --git a/intern/cycles/render/scene.h b/intern/cycles/render/scene.h
index e588394..3e5cc34 100644
--- a/intern/cycles/render/scene.h
+++ b/intern/cycles/render/scene.h
@@ -24,7 +24,6 @@
 
 #include "kernel_types.h"
 
-#include "util_volume.h"
 #include "util_param.h"
 #include "util_string.h"
 #include "util_system.h"
diff --git a/intern/cycles/util/util_volume.h b/intern/cycles/util/util_volume.h
index f13699f..6638ea0 100644
--- a/intern/cycles/util/util_volume.h
+++ b/intern/cycles/util/util_volume.h
@@ -63,11 +63,14 @@ using std::isfinite;
 using boost::math::isfinite;
 #endif
 
+/* eventually this should be openvdb::math::Ray<float>, but OpenVDB does not
+ * compile in that case */
+typedef openvdb::math::Ray<openvdb::Real> vdb_ray_t;
+
 class vdb_float_volume : public float_volume {
 	typedef openvdb::tools::GridSampler<openvdb::FloatGrid::ConstAccessor, openvdb::tools::PointSampler> point_sampler_t;
 	typedef openvdb::tools::GridSampler<openvdb::FloatGrid::ConstAccessor, openvdb::tools::BoxSampler> box_sampler_t;
 	typedef openvdb::tools::VolumeRayIntersector<openvdb::FloatGrid> isector_t;
-	typedef isector_t::RayType vdb_ray_t;
 
 	/* mainly used to ensure thread safety for the accessors */
 	typedef unordered_map<pthread_t, isector_t *> isect_map;
@@ -240,7 +243,6 @@ class vdb_float3_volume : public float3_volume {
 	typedef openvdb::tools::GridSampler<openvdb::Vec3SGrid::ConstAccessor, openvdb::tools::StaggeredBoxSampler> stag_box_sampler_t;
 
 	typedef openvdb::tools::VolumeRayIntersector<openvdb::Vec3SGrid> isector_t;
-	typedef isector_t::RayType vdb_ray_t;
 
 	/* mainly used to ensure thread safety for the accessors */
 	typedef unordered_map<pthread_t, isector_t *> isect_map;
diff --git a/source/blender/CMakeLists.txt b/source/blender/CMakeLists.txt
index 19d4f20..9a73921 100644
--- a/source/blender/CMakeLists.txt
+++ b/source/blender/CMakeLists.txt
@@ -151,3 +151,4 @@ endif()
 if(WITH_FREESTYLE)
 	add_subdirectory(freestyle)
 endif()
+
diff --git a/source/blender/editors/object/object_modifier.c b/source/blender/editors/object/object_modifier.c
index 1af8fb3..1ceeaa4 100644
--- a/source/blender/editors/object/object_modifier.c
+++ b/source/blender/editors/object/object_modifier.c
@@ -74,7 +74,6 @@
 #include "BKE_ocean.h"
 #include "BKE_paint.h"
 #include "BKE_particle.h"
-#include "BKE_pointcache.h"
 #include "BKE_screen.h"
 #include "BKE_smoke.h"
 #include "BKE_softbody.h"
diff --git a/source/blender/editors/object/object_ops.c b/source/blender/editors/object/object_ops.c
index b81085f..02bdf41 100644
--- a/source/blender/editors/object/object_ops.c
+++ b/source/blender/editors/object/object_ops.c
@@ -144,9 +144,10 @@ void ED_operatortypes_object(void)
 	WM_operatortype_append(OBJECT_OT_skin_radii_equalize);
 	WM_operatortype_append(OBJECT_OT_skin_armature_create);
 	WM_operatortype_append(OBJECT_OT_openvdb_cache_add);
-	WM_operatortype_append(OBJECT_OT_openvdb_cache_remove);
-	WM_operatortype_append(OBJECT_OT_openvdb_cache_move);
+	WM_operatortype_append(OBJECT_OT_openvdb_cache_bake);
 	WM_operatortype_append(OBJECT_OT_openvdb_cache_free);
+	WM_operatortype_append(OBJECT_OT_openvdb_cache_move);
+	WM_operatortype_append(OBJECT_OT_openvdb_cache_remove);
 
 	WM_operatortype_append(OBJECT_OT_correctivesmooth_bind);
 	WM_operatortype_append(OBJECT_OT_meshdeform_bind);
@@ -249,7 +250,6 @@ void ED_operatortypes_object(void)
 	WM_operatortype_append(OBJECT_OT_drop_named_material);
 	WM_operatortype_append(OBJECT_OT_unlink_data);
 	WM_operatortype_append(OBJECT_OT_laplaciandeform_bind);
-	WM_operatortype_append(OBJECT_OT_openvdb_cache_bake);
 
 	WM_operatortype_append(OBJECT_OT_lod_add);
 	WM_operatortype_append(OBJECT_OT_lod_remove);
diff --git a/source/blender/editors/space_view3d/drawobject.c b/source/blender/editors/space_view3d/drawobject.c
index c603578..029bd46 100644
--- a/source/blender/editors/space_view3d/drawobject.c
+++ b/source/blender/editors/space_view3d/drawobject.c
@@ -8066,9 +8066,6 @@ void draw_object(Scene *scene, ARegion *ar, View3D *v3d, Base *base, const short
 
 			/* don't show smoke before simulation starts, this could be made an option in the future */
 			if (smd->domain->fluid && CFRA >= smd->domain->point_cache[0]->startframe) {
-				glLoadMatrixf(rv3d->viewmat);
-				glMultMatrixf(ob->obmat);
-
 				/* get view vector */
 				invert_m4_m4(ob->imat, ob->obmat);
 				mul_v3_mat3_m4v3(viewnormal, ob->imat, rv3d->viewinv[2]);




More information about the Bf-blender-cvs mailing list