Changeset View
Changeset View
Standalone View
Standalone View
source/blender/gpencil_modifiers/intern/MOD_gpencillength.c
| Context not available. | |||||
| } | } | ||||
| } | } | ||||
| static void bakeModifier(Main *UNUSED(bmain), | |||||
| Depsgraph *UNUSED(depsgraph), | |||||
| GpencilModifierData *md, | |||||
| Object *ob) | |||||
| { | |||||
| bGPdata *gpd = ob->data; | |||||
| LISTBASE_FOREACH (bGPDlayer *, gpl, &gpd->layers) { | |||||
| LISTBASE_FOREACH (bGPDframe *, gpf, &gpl->frames) { | |||||
| LengthGpencilModifierData *lmd = (LengthGpencilModifierData *)md; | |||||
| LISTBASE_FOREACH (bGPDstroke *, gps, &gpf->strokes) { | |||||
| applyLength(lmd, gpd, gps); | |||||
| } | |||||
| } | |||||
| } | |||||
| } | |||||
| /* -------------------------------- */ | |||||
| /* Generic "generateStrokes" callback */ | |||||
| static void deformStroke(GpencilModifierData *md, | static void deformStroke(GpencilModifierData *md, | ||||
| Depsgraph *UNUSED(depsgraph), | Depsgraph *UNUSED(depsgraph), | ||||
| Object *ob, | Object *ob, | ||||
| Context not available. | |||||
| } | } | ||||
| } | } | ||||
| static void bakeModifier(Main *UNUSED(bmain), | |||||
| Depsgraph *depsgraph, | |||||
| GpencilModifierData *md, | |||||
| Object *ob) | |||||
| { | |||||
| bGPdata *gpd = ob->data; | |||||
| LISTBASE_FOREACH (bGPDlayer *, gpl, &gpd->layers) { | |||||
| LISTBASE_FOREACH (bGPDframe *, gpf, &gpl->frames) { | |||||
| LengthGpencilModifierData *lmd = (LengthGpencilModifierData *)md; | |||||
| LISTBASE_FOREACH (bGPDstroke *, gps, &gpf->strokes) { | |||||
| deformStroke(md, depsgraph, ob, gpl, gpf, gps); | |||||
| } | |||||
| } | |||||
| } | |||||
| } | |||||
| static void foreachIDLink(GpencilModifierData *md, Object *ob, IDWalkFunc walk, void *userData) | static void foreachIDLink(GpencilModifierData *md, Object *ob, IDWalkFunc walk, void *userData) | ||||
| { | { | ||||
| LengthGpencilModifierData *mmd = (LengthGpencilModifierData *)md; | LengthGpencilModifierData *mmd = (LengthGpencilModifierData *)md; | ||||
| Context not available. | |||||