Changeset View
Changeset View
Standalone View
Standalone View
source/blender/modifiers/intern/MOD_datatransfer.c
| Show First 20 Lines • Show All 150 Lines • ▼ Show 20 Lines | static bool isDisabled(const struct Scene *UNUSED(scene), | ||||
| return !dtmd->ob_source || dtmd->ob_source->type != OB_MESH; | return !dtmd->ob_source || dtmd->ob_source->type != OB_MESH; | ||||
| } | } | ||||
| #define HIGH_POLY_WARNING 10000 | #define HIGH_POLY_WARNING 10000 | ||||
| #define DT_TYPES_AFFECT_MESH \ | #define DT_TYPES_AFFECT_MESH \ | ||||
| (DT_TYPE_BWEIGHT_VERT | DT_TYPE_BWEIGHT_EDGE | DT_TYPE_CREASE | DT_TYPE_SHARP_EDGE | \ | (DT_TYPE_BWEIGHT_VERT | DT_TYPE_BWEIGHT_EDGE | DT_TYPE_CREASE | DT_TYPE_SHARP_EDGE | \ | ||||
| DT_TYPE_LNOR | DT_TYPE_SHARP_FACE) | DT_TYPE_LNOR | DT_TYPE_SHARP_FACE) | ||||
| static Mesh *applyModifier(ModifierData *md, const ModifierEvalContext *ctx, Mesh *me_mod) | static Mesh *modifyMesh(ModifierData *md, const ModifierEvalContext *ctx, Mesh *me_mod) | ||||
| { | { | ||||
| DataTransferModifierData *dtmd = (DataTransferModifierData *)md; | DataTransferModifierData *dtmd = (DataTransferModifierData *)md; | ||||
| struct Scene *scene = DEG_get_evaluated_scene(ctx->depsgraph); | struct Scene *scene = DEG_get_evaluated_scene(ctx->depsgraph); | ||||
| Mesh *result = me_mod; | Mesh *result = me_mod; | ||||
| ReportList reports; | ReportList reports; | ||||
| /* Only used to check whether we are operating on org data or not... */ | /* Only used to check whether we are operating on org data or not... */ | ||||
| Mesh *me = ctx->object->data; | Mesh *me = ctx->object->data; | ||||
| ▲ Show 20 Lines • Show All 76 Lines • ▼ Show 20 Lines | /* flags */ eModifierTypeFlag_AcceptsMesh | eModifierTypeFlag_SupportsMapping | | ||||
| eModifierTypeFlag_SupportsEditmode | eModifierTypeFlag_UsesPreview, | eModifierTypeFlag_SupportsEditmode | eModifierTypeFlag_UsesPreview, | ||||
| /* copyData */ modifier_copyData_generic, | /* copyData */ modifier_copyData_generic, | ||||
| /* deformVerts */ NULL, | /* deformVerts */ NULL, | ||||
| /* deformMatrices */ NULL, | /* deformMatrices */ NULL, | ||||
| /* deformVertsEM */ NULL, | /* deformVertsEM */ NULL, | ||||
| /* deformMatricesEM */ NULL, | /* deformMatricesEM */ NULL, | ||||
| /* applyModifier */ applyModifier, | /* modifyMesh */ modifyMesh, | ||||
| /* modifyHair */ NULL, | |||||
| /* modifyPointCloud */ NULL, | |||||
| /* modifyVolume */ NULL, | |||||
| /* initData */ initData, | /* initData */ initData, | ||||
| /* requiredDataMask */ requiredDataMask, | /* requiredDataMask */ requiredDataMask, | ||||
| /* freeData */ NULL, | /* freeData */ NULL, | ||||
| /* isDisabled */ isDisabled, | /* isDisabled */ isDisabled, | ||||
| /* updateDepsgraph */ updateDepsgraph, | /* updateDepsgraph */ updateDepsgraph, | ||||
| /* dependsOnTime */ NULL, | /* dependsOnTime */ NULL, | ||||
| /* dependsOnNormals */ dependsOnNormals, | /* dependsOnNormals */ dependsOnNormals, | ||||
| /* foreachObjectLink */ foreachObjectLink, | /* foreachObjectLink */ foreachObjectLink, | ||||
| /* foreachIDLink */ NULL, | /* foreachIDLink */ NULL, | ||||
| /* foreachTexLink */ NULL, | /* foreachTexLink */ NULL, | ||||
| /* freeRuntimeData */ NULL, | /* freeRuntimeData */ NULL, | ||||
| }; | }; | ||||