Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoseph Eagar <joeedh@gmail.com>2011-02-27 09:19:40 +0300
committerJoseph Eagar <joeedh@gmail.com>2011-02-27 09:19:40 +0300
commitf01261d040be27337db9f9996d648a279c89b7c4 (patch)
treec448230939b3c90d53ce8852dd00925d6052e3a4 /source/blender/modifiers/intern/MOD_decimate.c
parentdcaeda5c4e3a0687251b8511de4f2e8b85ef75c0 (diff)
parent2198cfdb2deec8b2e85e242c74a032f43d0b26ca (diff)
merge with/from trunk at r35190
Diffstat (limited to 'source/blender/modifiers/intern/MOD_decimate.c')
-rw-r--r--source/blender/modifiers/intern/MOD_decimate.c30
1 files changed, 26 insertions, 4 deletions
diff --git a/source/blender/modifiers/intern/MOD_decimate.c b/source/blender/modifiers/intern/MOD_decimate.c
index f75fc0dd1f4..4eae988f92f 100644
--- a/source/blender/modifiers/intern/MOD_decimate.c
+++ b/source/blender/modifiers/intern/MOD_decimate.c
@@ -30,9 +30,16 @@
*
*/
+/** \file blender/modifiers/intern/MOD_decimate.c
+ * \ingroup modifiers
+ */
+
+
#include "DNA_meshdata_types.h"
#include "BLI_math.h"
+#include "BLI_utildefines.h"
+
#include "BKE_cdderivedmesh.h"
#include "BKE_mesh.h"
@@ -41,8 +48,11 @@
#include "MEM_guardedalloc.h"
+#ifdef WITH_MOD_DECIMATE
#include "LOD_decimation.h"
+#endif
+#include "MOD_util.h"
static void initData(ModifierData *md)
{
@@ -59,9 +69,11 @@ static void copyData(ModifierData *md, ModifierData *target)
tdmd->percent = dmd->percent;
}
-static DerivedMesh *applyModifier(
- ModifierData *md, Object *ob, DerivedMesh *derivedData,
- int useRenderParams, int isFinalCalc)
+#ifdef WITH_MOD_DECIMATE
+static DerivedMesh *applyModifier(ModifierData *md, Object *UNUSED(ob),
+ DerivedMesh *derivedData,
+ int UNUSED(useRenderParams),
+ int UNUSED(isFinalCalc))
{
DecimateModifierData *dmd = (DecimateModifierData*) md;
DerivedMesh *dm = derivedData, *result = NULL;
@@ -179,7 +191,15 @@ exit:
return dm;
}
-
+#else // WITH_MOD_DECIMATE
+static DerivedMesh *applyModifier(ModifierData *UNUSED(md), Object *UNUSED(ob),
+ DerivedMesh *derivedData,
+ int UNUSED(useRenderParams),
+ int UNUSED(isFinalCalc))
+{
+ return derivedData;
+}
+#endif // WITH_MOD_DECIMATE
ModifierTypeInfo modifierType_Decimate = {
/* name */ "Decimate",
@@ -189,6 +209,7 @@ ModifierTypeInfo modifierType_Decimate = {
/* flags */ eModifierTypeFlag_AcceptsMesh,
/* copyData */ copyData,
/* deformVerts */ 0,
+ /* deformMatrices */ 0,
/* deformVertsEM */ 0,
/* deformMatricesEM */ 0,
/* applyModifier */ applyModifier,
@@ -199,6 +220,7 @@ ModifierTypeInfo modifierType_Decimate = {
/* isDisabled */ 0,
/* updateDepgraph */ 0,
/* dependsOnTime */ 0,
+ /* dependsOnNormals */ 0,
/* foreachObjectLink */ 0,
/* foreachIDLink */ 0,
};