Code cleanup: style
This commit is contained in:
parent
663c800ef3
commit
164841e30e
|
@ -1593,7 +1593,7 @@ static void mesh_calc_modifiers(Scene *scene, Object *ob, float (*inputVertexCos
|
|||
continue;
|
||||
}
|
||||
if (sculpt_mode &&
|
||||
(!has_multires || multires_applied || sculpt_dyntopo))
|
||||
(!has_multires || multires_applied || sculpt_dyntopo))
|
||||
{
|
||||
bool unsupported = false;
|
||||
|
||||
|
|
|
@ -2589,8 +2589,7 @@ void DAG_ids_check_recalc(Main *bmain, Scene *scene, bool time)
|
|||
|
||||
/* we tag based on first ID type character to avoid
|
||||
* looping over all ID's in case there are no tags */
|
||||
if (id && bmain->id_tag_update[id->name[0]])
|
||||
{
|
||||
if (id && bmain->id_tag_update[id->name[0]]) {
|
||||
updated = true;
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -573,7 +573,7 @@ static bool sculpt_modifiers_active(Scene *scene, Sculpt *sd, Object *ob)
|
|||
* \param need_mask So the DerivedMesh thats returned has mask data
|
||||
*/
|
||||
void BKE_sculpt_update_mesh_elements(Scene *scene, Sculpt *sd, Object *ob,
|
||||
bool need_pmap, bool need_mask)
|
||||
bool need_pmap, bool need_mask)
|
||||
{
|
||||
DerivedMesh *dm;
|
||||
SculptSession *ss = ob->sculpt;
|
||||
|
@ -688,14 +688,14 @@ int BKE_sculpt_mask_layers_ensure(Object *ob, MultiresModifierData *mmd)
|
|||
int i, j;
|
||||
|
||||
gmask = CustomData_add_layer(&me->ldata, CD_GRID_PAINT_MASK,
|
||||
CD_CALLOC, NULL, me->totloop);
|
||||
CD_CALLOC, NULL, me->totloop);
|
||||
|
||||
for (i = 0; i < me->totloop; i++) {
|
||||
GridPaintMask *gpm = &gmask[i];
|
||||
|
||||
gpm->level = level;
|
||||
gpm->data = MEM_callocN(sizeof(float) * gridarea,
|
||||
"GridPaintMask.data");
|
||||
"GridPaintMask.data");
|
||||
}
|
||||
|
||||
/* if vertices already have mask, copy into multires data */
|
||||
|
@ -720,9 +720,9 @@ int BKE_sculpt_mask_layers_ensure(Object *ob, MultiresModifierData *mmd)
|
|||
|
||||
gpm->data[0] = avg;
|
||||
gpm->data[1] = (paint_mask[l->v] +
|
||||
paint_mask[next->v]) * 0.5f;
|
||||
paint_mask[next->v]) * 0.5f;
|
||||
gpm->data[2] = (paint_mask[l->v] +
|
||||
paint_mask[prev->v]) * 0.5f;
|
||||
paint_mask[prev->v]) * 0.5f;
|
||||
gpm->data[3] = paint_mask[l->v];
|
||||
}
|
||||
}
|
||||
|
@ -734,7 +734,7 @@ int BKE_sculpt_mask_layers_ensure(Object *ob, MultiresModifierData *mmd)
|
|||
/* create vertex paint mask layer if there isn't one already */
|
||||
if (!paint_mask) {
|
||||
CustomData_add_layer(&me->vdata, CD_PAINT_MASK,
|
||||
CD_CALLOC, NULL, me->totvert);
|
||||
CD_CALLOC, NULL, me->totvert);
|
||||
ret |= SCULPT_MASK_LAYER_CALC_VERT;
|
||||
}
|
||||
|
||||
|
|
|
@ -83,9 +83,9 @@ void MathNode::convertToOperations(NodeConverter &converter, const CompositorCon
|
|||
case 17: /* Modulo */
|
||||
operation = new MathModuloOperation();
|
||||
break;
|
||||
case 18: /* Absolute Value */
|
||||
operation = new MathAbsoluteOperation();
|
||||
break;
|
||||
case 18: /* Absolute Value */
|
||||
operation = new MathAbsoluteOperation();
|
||||
break;
|
||||
}
|
||||
|
||||
if (operation) {
|
||||
|
|
|
@ -3291,7 +3291,8 @@ void uiTemplateRunningJobs(uiLayout *layout, bContext *C)
|
|||
break;
|
||||
}
|
||||
else if (WM_jobs_test(wm, scene, WM_JOB_TYPE_OBJECT_BAKE_TEXTURE) ||
|
||||
WM_jobs_test(wm, scene, WM_JOB_TYPE_OBJECT_BAKE)) {
|
||||
WM_jobs_test(wm, scene, WM_JOB_TYPE_OBJECT_BAKE))
|
||||
{
|
||||
/* Skip bake jobs in compositor to avoid compo header displaying
|
||||
* progress bar which is not being updated (bake jobs only need
|
||||
* to update NC_IMAGE context.
|
||||
|
|
|
@ -216,11 +216,11 @@ static void node_shader_exec_math(void *UNUSED(data), int UNUSED(thread), bNode
|
|||
r = fmod(a, b);
|
||||
break;
|
||||
}
|
||||
case 18: /* Absolute */
|
||||
{
|
||||
r = fabs(a);
|
||||
break;
|
||||
}
|
||||
case 18: /* Absolute */
|
||||
{
|
||||
r = fabs(a);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
out[0]->vec[0] = r;
|
||||
|
|
|
@ -183,11 +183,11 @@ static void valuefn(float *out, TexParams *p, bNode *node, bNodeStack **in, shor
|
|||
break;
|
||||
}
|
||||
|
||||
case 18: /* Absolute */
|
||||
{
|
||||
*out = fabs(in0);
|
||||
break;
|
||||
}
|
||||
case 18: /* Absolute */
|
||||
{
|
||||
*out = fabs(in0);
|
||||
break;
|
||||
}
|
||||
|
||||
default:
|
||||
{
|
||||
|
|
|
@ -486,6 +486,7 @@ static int ghost_event_proc(GHOST_EventHandle evt, GHOST_TUserDataPtr ps_void)
|
|||
default:
|
||||
break;
|
||||
}
|
||||
break;
|
||||
}
|
||||
default:
|
||||
break;
|
||||
|
|
Loading…
Reference in New Issue