Cleanup: Use const variables

This commit is contained in:
2019-09-16 10:48:22 +02:00
parent 95b60634c7
commit 94ecad5809
3 changed files with 15 additions and 15 deletions

View File

@@ -78,15 +78,15 @@ void gpencil_modifier_type_init(GpencilModifierTypeInfo *types[])
bool is_stroke_affected_by_modifier(Object *ob,
char *mlayername,
char *mmaterialname,
int mpassindex,
int gpl_passindex,
int minpoints,
const int mpassindex,
const int gpl_passindex,
const int minpoints,
bGPDlayer *gpl,
bGPDstroke *gps,
bool inv1,
bool inv2,
bool inv3,
bool inv4)
const bool inv1,
const bool inv2,
const bool inv3,
const bool inv4)
{
Material *ma = BKE_material_gpencil_get(ob, gps->mat_nr + 1);
MaterialGPencilStyle *gp_style = ma->gp_style;

View File

@@ -35,15 +35,15 @@ struct bGPDstroke;
bool is_stroke_affected_by_modifier(struct Object *ob,
char *mlayername,
char *mmaterialname,
int mpassindex,
int gpl_passindex,
int minpoints,
const int mpassindex,
const int gpl_passindex,
const int minpoints,
bGPDlayer *gpl,
bGPDstroke *gps,
bool inv1,
bool inv2,
bool inv3,
bool inv4);
const bool inv1,
const bool inv2,
const bool inv3,
const bool inv4);
float get_modifier_point_weight(struct MDeformVert *dvert, bool inverse, int def_nr);

View File

@@ -67,7 +67,7 @@ static void deformStroke(GpencilModifierData *md,
/* It makes sense when adding points to a straight line */
/* e.g. for creating thickness variation in later modifiers. */
int minimum_vert = (mmd->flag | GP_SUBDIV_SIMPLE) ? 2 : 3;
const int minimum_vert = (mmd->flag | GP_SUBDIV_SIMPLE) ? 2 : 3;
if (!is_stroke_affected_by_modifier(ob,
mmd->layername,