diff options
author | Campbell Barton <ideasman42@gmail.com> | 2012-02-27 14:35:39 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2012-02-27 14:35:39 +0400 |
commit | 47c373c7a970fa4bd26453a6e35a4b066f2b77e4 (patch) | |
tree | 43d916fb86bcf797afa834649706669694225fe8 /source/blender/render | |
parent | 120297734b4a01d93e5223e02f255b5aef01e281 (diff) |
style cleanup (mostly whitespace)
Diffstat (limited to 'source/blender/render')
6 files changed, 18 insertions, 19 deletions
diff --git a/source/blender/render/intern/raytrace/rayobject_octree.cpp b/source/blender/render/intern/raytrace/rayobject_octree.cpp index 20121b0e51e..648cb940af4 100644 --- a/source/blender/render/intern/raytrace/rayobject_octree.cpp +++ b/source/blender/render/intern/raytrace/rayobject_octree.cpp @@ -515,15 +515,15 @@ static void octree_fill_rayface(Octree *oc, RayFace *face) copy_v3_v3(co4, face->v4); for(c=0;c<3;c++) { - rtf[0][c]= (co1[c]-oc->min[c])*ocfac[c] ; - rts[0][c]= (short)rtf[0][c]; - rtf[1][c]= (co2[c]-oc->min[c])*ocfac[c] ; - rts[1][c]= (short)rtf[1][c]; - rtf[2][c]= (co3[c]-oc->min[c])*ocfac[c] ; - rts[2][c]= (short)rtf[2][c]; + rtf[0][c] = (co1[c] - oc->min[c]) * ocfac[c]; + rts[0][c] = (short)rtf[0][c]; + rtf[1][c] = (co2[c] - oc->min[c]) * ocfac[c]; + rts[1][c] = (short)rtf[1][c]; + rtf[2][c] = (co3[c] - oc->min[c]) * ocfac[c]; + rts[2][c] = (short)rtf[2][c]; if(RE_rayface_isQuad(face)) { - rtf[3][c]= (co4[c]-oc->min[c])*ocfac[c] ; - rts[3][c]= (short)rtf[3][c]; + rtf[3][c] = (co4[c] - oc->min[c]) * ocfac[c]; + rts[3][c] = (short)rtf[3][c]; } } diff --git a/source/blender/render/intern/raytrace/reorganize.h b/source/blender/render/intern/raytrace/reorganize.h index 5de88a919ec..6efe37b81a3 100644 --- a/source/blender/render/intern/raytrace/reorganize.h +++ b/source/blender/render/intern/raytrace/reorganize.h @@ -175,8 +175,8 @@ void pushup(Node *parent) Node **prev = &parent->child; for(Node *child = parent->child; RE_rayobject_isAligned(child) && child; ) { - float c_area = bb_area(child->bb, child->bb+3) ; - int nchilds = count_childs(child); + const float c_area = bb_area(child->bb, child->bb + 3); + const int nchilds = count_childs(child); float original_cost = ((p_area != 0.0f)? (c_area / p_area)*nchilds: 1.0f) + 1; float flatten_cost = nchilds; if(flatten_cost < original_cost && nchilds >= 2) diff --git a/source/blender/render/intern/source/gammaCorrectionTables.c b/source/blender/render/intern/source/gammaCorrectionTables.c index 68c4903704a..c0e69323745 100644 --- a/source/blender/render/intern/source/gammaCorrectionTables.c +++ b/source/blender/render/intern/source/gammaCorrectionTables.c @@ -131,9 +131,9 @@ void makeGammaTables(float gamma) /* multiplication factors used in scaling the interpolation. */ for (i = 0; i < RE_GAMMA_TABLE_SIZE; i++ ) { gamfactor_table[i] = inv_color_step - * (gamma_range_table[i + 1] - gamma_range_table[i]) ; + * (gamma_range_table[i + 1] - gamma_range_table[i]); inv_gamfactor_table[i] = inv_color_step - * (inv_gamma_range_table[i + 1] - inv_gamma_range_table[i]) ; + * (inv_gamma_range_table[i + 1] - inv_gamma_range_table[i]); } } /* end of void makeGammaTables(float gamma) */ diff --git a/source/blender/render/intern/source/shadbuf.c b/source/blender/render/intern/source/shadbuf.c index 88d86d5bd43..0cd5c361499 100644 --- a/source/blender/render/intern/source/shadbuf.c +++ b/source/blender/render/intern/source/shadbuf.c @@ -978,8 +978,7 @@ static float readdeepvisibility(DeepSample *dsample, int tot, int z, int bias, f /* tricky stuff here; we use ints which can overflow easily with bias values */ ds= dsample; - for(a=0; a<tot && (z-bias > ds->z); a++, ds++) - ; + for (a=0; a<tot && (z-bias > ds->z); a++, ds++) {} if(a == tot) { if(biast) diff --git a/source/blender/render/intern/source/shadeinput.c b/source/blender/render/intern/source/shadeinput.c index e0b5da817cb..052f9769b4e 100644 --- a/source/blender/render/intern/source/shadeinput.c +++ b/source/blender/render/intern/source/shadeinput.c @@ -185,7 +185,7 @@ void shade_input_do_shade(ShadeInput *shi, ShadeResult *shr) } /* MIST */ - if((shi->passflag & SCE_PASS_MIST) || ((R.wrld.mode & WO_MIST) && (shi->mat->mode & MA_NOMIST)==0)) { + if((shi->passflag & SCE_PASS_MIST) || ((R.wrld.mode & WO_MIST) && (shi->mat->mode & MA_NOMIST)==0)) { if(R.r.mode & R_ORTHO) shr->mist= mistfactor(-shi->co[2], shi->co); else @@ -447,7 +447,7 @@ void shade_input_set_strand_texco(ShadeInput *shi, StrandRen *strand, StrandVert } } - if((texco & TEXCO_UV) || (mode & (MA_VERTEXCOL|MA_VERTEXCOLP|MA_FACETEXTURE))) { + if((texco & TEXCO_UV) || (mode & (MA_VERTEXCOL|MA_VERTEXCOLP|MA_FACETEXTURE))) { MCol *mcol; float *uv; char *name; @@ -1076,7 +1076,7 @@ void shade_input_set_shade_texco(ShadeInput *shi) } } - if((texco & TEXCO_UV) || (mode & (MA_VERTEXCOL|MA_VERTEXCOLP|MA_FACETEXTURE))) { + if((texco & TEXCO_UV) || (mode & (MA_VERTEXCOL|MA_VERTEXCOLP|MA_FACETEXTURE))) { VlakRen *vlr= shi->vlr; MTFace *tface; MCol *mcol; diff --git a/source/blender/render/intern/source/sunsky.c b/source/blender/render/intern/source/sunsky.c index e824b81096b..71ca2e056ac 100644 --- a/source/blender/render/intern/source/sunsky.c +++ b/source/blender/render/intern/source/sunsky.c @@ -315,9 +315,9 @@ void GetSkyXYZRadiancef(struct SunSky* sunsky, const float varg[3], float color_ * */ static void ComputeAttenuatedSunlight(float theta, int turbidity, float fTau[3]) { - float fBeta ; + float fBeta; float fTauR, fTauA; - float m ; + float m; float fAlpha; int i; |