Changeset View
Changeset View
Standalone View
Standalone View
source/blender/modifiers/intern/MOD_displace.c
| Show First 20 Lines • Show All 69 Lines • ▼ Show 20 Lines | static void initData(ModifierData *md) | ||||
| dmd->midlevel = 0.5; | dmd->midlevel = 0.5; | ||||
| dmd->space = MOD_DISP_SPACE_LOCAL; | dmd->space = MOD_DISP_SPACE_LOCAL; | ||||
| } | } | ||||
| static void copyData(ModifierData *md, ModifierData *target) | static void copyData(ModifierData *md, ModifierData *target) | ||||
| { | { | ||||
| #if 0 | #if 0 | ||||
| DisplaceModifierData *dmd = (DisplaceModifierData *) md; | DisplaceModifierData *dmd = (DisplaceModifierData *) md; | ||||
| #endif | |||||
| DisplaceModifierData *tdmd = (DisplaceModifierData *) target; | DisplaceModifierData *tdmd = (DisplaceModifierData *) target; | ||||
| #endif | |||||
| modifier_copyData_generic(md, target); | modifier_copyData_generic(md, target); | ||||
| if (tdmd->texture) { | |||||
| id_us_plus(&tdmd->texture->id); | |||||
| } | |||||
| } | } | ||||
| static void freeData(ModifierData *md) | static void freeData(ModifierData *md) | ||||
| { | { | ||||
| DisplaceModifierData *dmd = (DisplaceModifierData *) md; | DisplaceModifierData *dmd = (DisplaceModifierData *) md; | ||||
| if (dmd->texture) { | if (dmd->texture) { | ||||
| id_us_min(&dmd->texture->id); | id_us_min(&dmd->texture->id); | ||||
| } | } | ||||
| ▲ Show 20 Lines • Show All 366 Lines • Show Last 20 Lines | |||||