diff options
author | Campbell Barton <ideasman42@gmail.com> | 2013-11-25 08:33:41 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2013-11-25 08:36:19 +0400 |
commit | 2b4c68b902b261127f7deabf922048c41be6fb55 (patch) | |
tree | 1c40311a6c8e13ea4754fc692283b11cafdb8bea /source/blender/editors/armature | |
parent | 295116ea6b3a81a6c7b84d8a9d21288108c5f19e (diff) |
CMake Build: option to compile without opennl/superlu.
Diffstat (limited to 'source/blender/editors/armature')
-rw-r--r-- | source/blender/editors/armature/CMakeLists.txt | 8 | ||||
-rw-r--r-- | source/blender/editors/armature/armature_skinning.c | 6 | ||||
-rw-r--r-- | source/blender/editors/armature/meshlaplacian.c | 15 |
3 files changed, 25 insertions, 4 deletions
diff --git a/source/blender/editors/armature/CMakeLists.txt b/source/blender/editors/armature/CMakeLists.txt index 1a0841f5342..ca2dc1b66e2 100644 --- a/source/blender/editors/armature/CMakeLists.txt +++ b/source/blender/editors/armature/CMakeLists.txt @@ -27,7 +27,6 @@ set(INC ../../makesrna ../../windowmanager ../../../../intern/guardedalloc - ../../../../intern/opennl/extern ) set(INC_SYS @@ -67,4 +66,11 @@ if(WITH_INTERNATIONAL) add_definitions(-DWITH_INTERNATIONAL) endif() +if(WITH_OPENNL) + add_definitions(-DWITH_OPENNL) + list(APPEND INC_SYS + ../../../../intern/opennl/extern + ) +endif() + blender_add_lib(bf_editor_armature "${SRC}" "${INC}" "${INC_SYS}") diff --git a/source/blender/editors/armature/armature_skinning.c b/source/blender/editors/armature/armature_skinning.c index 5f15d15d478..7ec0acf12d1 100644 --- a/source/blender/editors/armature/armature_skinning.c +++ b/source/blender/editors/armature/armature_skinning.c @@ -386,9 +386,13 @@ static void add_verts_to_dgroups(ReportList *reports, Scene *scene, Object *ob, /* compute the weights based on gathered vertices and bones */ if (heat) { const char *error = NULL; + +#ifdef WITH_OPENNL heat_bone_weighting(ob, mesh, verts, numbones, dgrouplist, dgroupflip, root, tip, selected, &error); - +#else + error = "Built without OpenNL"; +#endif if (error) { BKE_report(reports, RPT_WARNING, error); } diff --git a/source/blender/editors/armature/meshlaplacian.c b/source/blender/editors/armature/meshlaplacian.c index 16d7f9c9420..3b285e12331 100644 --- a/source/blender/editors/armature/meshlaplacian.c +++ b/source/blender/editors/armature/meshlaplacian.c @@ -46,13 +46,14 @@ #include "BLI_polardecomp.h" #endif -#include "ONL_opennl.h" - #include "ED_mesh.h" #include "ED_armature.h" #include "meshlaplacian.h" +#ifdef WITH_OPENNL + +#include "ONL_opennl.h" /* ************* XXX *************** */ static void waitcursor(int UNUSED(val)) {} @@ -2006,3 +2007,13 @@ void mesh_deform_bind(Scene *scene, MeshDeformModifierData *mmd, float *vertexco waitcursor(0); } +#else /* WITH_OPENNL */ + +#ifdef __GNUC__ +# pragma GCC diagnostic ignored "-Wunused-parameter" +#endif + +void mesh_deform_bind(Scene *scene, MeshDeformModifierData *mmd, float *vertexcos, int totvert, float cagemat[4][4]) {} +void *modifier_mdef_compact_influences_link_kludge = modifier_mdef_compact_influences; + +#endif /* WITH_OPENNL */ |