diff options
author | Campbell Barton <ideasman42@gmail.com> | 2013-02-21 21:18:27 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2013-02-21 21:18:27 +0400 |
commit | 091d86b9cb769f535fa11d2c7b6274e5206476d3 (patch) | |
tree | cb6db7fa6802f71558a016f1e5239cfb3f0f47c3 /source/blender/editors/uvedit/uvedit_parametrizer.c | |
parent | c84e4da7ddae474a1eb3368844165f21866c5fe5 (diff) |
style cleanup: 'sizeof foo' --> 'sizeof(foo)', add check in style checking script.
Diffstat (limited to 'source/blender/editors/uvedit/uvedit_parametrizer.c')
-rw-r--r-- | source/blender/editors/uvedit/uvedit_parametrizer.c | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/source/blender/editors/uvedit/uvedit_parametrizer.c b/source/blender/editors/uvedit/uvedit_parametrizer.c index 767003bdd84..bf5fc9a3021 100644 --- a/source/blender/editors/uvedit/uvedit_parametrizer.c +++ b/source/blender/editors/uvedit/uvedit_parametrizer.c @@ -709,7 +709,7 @@ static void p_face_restore_uvs(PFace *f) static PVert *p_vert_add(PHandle *handle, PHashKey key, const float co[3], PEdge *e) { - PVert *v = (PVert *)BLI_memarena_alloc(handle->arena, sizeof *v); + PVert *v = (PVert *)BLI_memarena_alloc(handle->arena, sizeof(*v)); copy_v3_v3(v->co, co); v->u.key = key; v->edge = e; @@ -732,7 +732,7 @@ static PVert *p_vert_lookup(PHandle *handle, PHashKey key, const float co[3], PE static PVert *p_vert_copy(PChart *chart, PVert *v) { - PVert *nv = (PVert *)BLI_memarena_alloc(chart->handle->arena, sizeof *nv); + PVert *nv = (PVert *)BLI_memarena_alloc(chart->handle->arena, sizeof(*nv)); copy_v3_v3(nv->co, v->co); nv->uv[0] = v->uv[0]; @@ -786,7 +786,7 @@ static int p_face_exists(ParamHandle *phandle, ParamKey *pvkeys, int i1, int i2, static PChart *p_chart_new(PHandle *handle) { - PChart *chart = (PChart *)MEM_callocN(sizeof *chart, "PChart"); + PChart *chart = (PChart *)MEM_callocN(sizeof(*chart), "PChart"); chart->handle = handle; return chart; @@ -904,7 +904,7 @@ static PBool p_edge_connect_pair(PHandle *handle, PEdge *e, PEdge ***stack, PBoo static int p_connect_pairs(PHandle *handle, PBool impl) { - PEdge **stackbase = MEM_mallocN(sizeof *stackbase * phash_size(handle->hash_faces), "Pstackbase"); + PEdge **stackbase = MEM_mallocN(sizeof(*stackbase) * phash_size(handle->hash_faces), "Pstackbase"); PEdge **stack = stackbase; PFace *f, *first; PEdge *e, *e1, *e2; @@ -999,7 +999,7 @@ static void p_split_vert(PChart *chart, PEdge *e) static PChart **p_split_charts(PHandle *handle, PChart *chart, int ncharts) { - PChart **charts = MEM_mallocN(sizeof *charts * ncharts, "PCharts"), *nchart; + PChart **charts = MEM_mallocN(sizeof(*charts) * ncharts, "PCharts"), *nchart; PFace *f, *nextf; int i; @@ -1041,12 +1041,12 @@ static PFace *p_face_add(PHandle *handle) PEdge *e1, *e2, *e3; /* allocate */ - f = (PFace *)BLI_memarena_alloc(handle->arena, sizeof *f); + f = (PFace *)BLI_memarena_alloc(handle->arena, sizeof(*f)); f->flag = 0; /* init ! */ - e1 = (PEdge *)BLI_memarena_alloc(handle->arena, sizeof *e1); - e2 = (PEdge *)BLI_memarena_alloc(handle->arena, sizeof *e2); - e3 = (PEdge *)BLI_memarena_alloc(handle->arena, sizeof *e3); + e1 = (PEdge *)BLI_memarena_alloc(handle->arena, sizeof(*e1)); + e2 = (PEdge *)BLI_memarena_alloc(handle->arena, sizeof(*e2)); + e3 = (PEdge *)BLI_memarena_alloc(handle->arena, sizeof(*e3)); /* set up edges */ f->edge = e1; @@ -3674,7 +3674,7 @@ static PBool p_triangle_inside(SmoothTriangle *t, float co[2]) static SmoothNode *p_node_new(MemArena *arena, SmoothTriangle **tri, int ntri, float *bmin, float *bmax, int depth) { - SmoothNode *node = BLI_memarena_alloc(arena, sizeof *node); + SmoothNode *node = BLI_memarena_alloc(arena, sizeof(*node)); int axis, i, t1size = 0, t2size = 0; float split, /* mi, */ /* UNUSED */ mx; SmoothTriangle **t1, **t2, *t; @@ -4114,7 +4114,7 @@ static void p_smooth(PChart *chart) ParamHandle *param_construct_begin(void) { - PHandle *handle = MEM_callocN(sizeof *handle, "PHandle"); + PHandle *handle = MEM_callocN(sizeof(*handle), "PHandle"); handle->construction_chart = p_chart_new(handle); handle->state = PHANDLE_STATE_ALLOCATED; handle->arena = BLI_memarena_new((1 << 16), "param construct arena"); |