Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2012-03-11 23:09:01 +0400
committerCampbell Barton <ideasman42@gmail.com>2012-03-11 23:09:01 +0400
commitc21c58f44c16b3d503d81577c1943f1f4b47b675 (patch)
tree1cb0bc60de38cd96f67f196e9c71f096b9c2c691 /source/blender/blenkernel
parent65895a2a383738d6edf0d82b428483065d672305 (diff)
style cleanup, also remove unused externs.
Diffstat (limited to 'source/blender/blenkernel')
-rw-r--r--source/blender/blenkernel/BKE_cloth.h30
-rw-r--r--source/blender/blenkernel/BKE_collision.h6
-rw-r--r--source/blender/blenkernel/BKE_curve.h54
-rw-r--r--source/blender/blenkernel/intern/DerivedMesh.c2
-rw-r--r--source/blender/blenkernel/intern/bvhutils.c2
-rw-r--r--source/blender/blenkernel/intern/cdderivedmesh.c8
-rw-r--r--source/blender/blenkernel/intern/collision.c2
-rw-r--r--source/blender/blenkernel/intern/displist.c2
-rw-r--r--source/blender/blenkernel/intern/mball.c6
-rw-r--r--source/blender/blenkernel/intern/particle_system.c2
-rw-r--r--source/blender/blenkernel/intern/property.c2
-rw-r--r--source/blender/blenkernel/intern/sequencer.c2
-rw-r--r--source/blender/blenkernel/intern/softbody.c4
-rw-r--r--source/blender/blenkernel/intern/text.c10
14 files changed, 64 insertions, 68 deletions
diff --git a/source/blender/blenkernel/BKE_cloth.h b/source/blender/blenkernel/BKE_cloth.h
index 98e273f59b2..435832f8c87 100644
--- a/source/blender/blenkernel/BKE_cloth.h
+++ b/source/blender/blenkernel/BKE_cloth.h
@@ -198,32 +198,32 @@ int cloth_bvh_objcollision (struct Object *ob, struct ClothModifierData * clmd,
////////////////////////////////////////////////
// needed for cloth.c
-int implicit_init ( struct Object *ob, struct ClothModifierData *clmd );
-int implicit_free ( struct ClothModifierData *clmd );
-int implicit_solver ( struct Object *ob, float frame, struct ClothModifierData *clmd, struct ListBase *effectors );
-void implicit_set_positions ( struct ClothModifierData *clmd );
+int implicit_init (struct Object *ob, struct ClothModifierData *clmd );
+int implicit_free (struct ClothModifierData *clmd );
+int implicit_solver (struct Object *ob, float frame, struct ClothModifierData *clmd, struct ListBase *effectors );
+void implicit_set_positions (struct ClothModifierData *clmd );
/////////////////////////////////////////////////
// cloth.c
////////////////////////////////////////////////
// needed for modifier.c
-void cloth_free_modifier_extern ( struct ClothModifierData *clmd );
-void cloth_free_modifier ( struct ClothModifierData *clmd );
-void cloth_init ( struct ClothModifierData *clmd );
-void clothModifier_do ( struct ClothModifierData *clmd, struct Scene *scene, struct Object *ob, struct DerivedMesh *dm, float (*vertexCos)[3]);
+void cloth_free_modifier_extern (struct ClothModifierData *clmd );
+void cloth_free_modifier (struct ClothModifierData *clmd );
+void cloth_init (struct ClothModifierData *clmd );
+void clothModifier_do (struct ClothModifierData *clmd, struct Scene *scene, struct Object *ob, struct DerivedMesh *dm, float (*vertexCos)[3]);
int cloth_uses_vgroup(struct ClothModifierData *clmd);
// needed for collision.c
-void bvhtree_update_from_cloth ( struct ClothModifierData *clmd, int moving );
-void bvhselftree_update_from_cloth ( struct ClothModifierData *clmd, int moving );
+void bvhtree_update_from_cloth (struct ClothModifierData *clmd, int moving );
+void bvhselftree_update_from_cloth (struct ClothModifierData *clmd, int moving );
// needed for button_object.c
-void cloth_clear_cache ( struct Object *ob, struct ClothModifierData *clmd, float framenr );
+void cloth_clear_cache (struct Object *ob, struct ClothModifierData *clmd, float framenr );
// needed for cloth.c
-int cloth_add_spring ( struct ClothModifierData *clmd, unsigned int indexA, unsigned int indexB, float restlength, int spring_type);
+int cloth_add_spring (struct ClothModifierData *clmd, unsigned int indexA, unsigned int indexB, float restlength, int spring_type);
////////////////////////////////////////////////
@@ -242,9 +242,9 @@ typedef struct
{
const char *name;
CM_SOLVER_ID id;
- int ( *init ) ( struct Object *ob, struct ClothModifierData *clmd );
- int ( *solver ) ( struct Object *ob, float framenr, struct ClothModifierData *clmd, struct ListBase *effectors );
- int ( *free ) ( struct ClothModifierData *clmd );
+ int ( *init ) (struct Object *ob, struct ClothModifierData *clmd );
+ int ( *solver ) (struct Object *ob, float framenr, struct ClothModifierData *clmd, struct ListBase *effectors );
+ int ( *free ) (struct ClothModifierData *clmd );
}
CM_SOLVER_DEF;
diff --git a/source/blender/blenkernel/BKE_collision.h b/source/blender/blenkernel/BKE_collision.h
index 75fdc4981a0..d20417d5604 100644
--- a/source/blender/blenkernel/BKE_collision.h
+++ b/source/blender/blenkernel/BKE_collision.h
@@ -130,14 +130,14 @@ FaceCollPair;
// used in modifier.c from collision.c
/////////////////////////////////////////////////
-BVHTree *bvhtree_build_from_mvert ( struct MFace *mfaces, unsigned int numfaces, struct MVert *x, unsigned int numverts, float epsilon );
-void bvhtree_update_from_mvert ( BVHTree * bvhtree, struct MFace *faces, int numfaces, struct MVert *x, struct MVert *xnew, int numverts, int moving );
+BVHTree *bvhtree_build_from_mvert(struct MFace *mfaces, unsigned int numfaces, struct MVert *x, unsigned int numverts, float epsilon );
+void bvhtree_update_from_mvert(BVHTree * bvhtree, struct MFace *faces, int numfaces, struct MVert *x, struct MVert *xnew, int numverts, int moving );
/////////////////////////////////////////////////
// move Collision modifier object inter-frame with step = [0,1]
// defined in collisions.c
-void collision_move_object ( struct CollisionModifierData *collmd, float step, float prevstep );
+void collision_move_object(struct CollisionModifierData *collmd, float step, float prevstep);
/////////////////////////////////////////////////
// used in effect.c
diff --git a/source/blender/blenkernel/BKE_curve.h b/source/blender/blenkernel/BKE_curve.h
index dd0c021f281..fa3a1a6897a 100644
--- a/source/blender/blenkernel/BKE_curve.h
+++ b/source/blender/blenkernel/BKE_curve.h
@@ -54,27 +54,27 @@ struct Scene;
#define CU_DO_RADIUS(cu, nu) ((CU_DO_TILT(cu, nu) || ((cu)->flag & CU_PATH_RADIUS) || (cu)->bevobj || (cu)->ext1!=0.0f || (cu)->ext2!=0.0f) ? 1:0)
-void unlink_curve( struct Curve *cu);
+void unlink_curve(struct Curve *cu);
void free_curve_editNurb_keyIndex(struct EditNurb *editnurb);
void free_curve_editNurb(struct Curve *cu);
-void free_curve( struct Curve *cu);
+void free_curve(struct Curve *cu);
void BKE_free_editfont(struct Curve *cu);
struct Curve *add_curve(const char *name, int type);
-struct Curve *copy_curve( struct Curve *cu);
-void make_local_curve( struct Curve *cu);
+struct Curve *copy_curve(struct Curve *cu);
+void make_local_curve(struct Curve *cu);
struct ListBase *curve_editnurbs(struct Curve *cu);
-short curve_type( struct Curve *cu);
-void test_curve_type( struct Object *ob);
-void update_curve_dimension( struct Curve *cu );
-void tex_space_curve( struct Curve *cu);
-int count_curveverts( struct ListBase *nurb);
-int count_curveverts_without_handles( struct ListBase *nurb);
-void freeNurb( struct Nurb *nu);
-void freeNurblist( struct ListBase *lb);
-struct Nurb *duplicateNurb( struct Nurb *nu);
-void duplicateNurblist( struct ListBase *lb1, struct ListBase *lb2);
-void test2DNurb( struct Nurb *nu);
-void minmaxNurb( struct Nurb *nu, float *min, float *max);
+short curve_type(struct Curve *cu);
+void test_curve_type(struct Object *ob);
+void update_curve_dimension(struct Curve *cu );
+void tex_space_curve(struct Curve *cu);
+int count_curveverts(struct ListBase *nurb);
+int count_curveverts_without_handles(struct ListBase *nurb);
+void freeNurb(struct Nurb *nu);
+void freeNurblist(struct ListBase *lb);
+struct Nurb *duplicateNurb(struct Nurb *nu);
+void duplicateNurblist(struct ListBase *lb1, struct ListBase *lb2);
+void test2DNurb(struct Nurb *nu);
+void minmaxNurb(struct Nurb *nu, float *min, float *max);
void nurbs_knot_calc_u(struct Nurb *nu);
void nurbs_knot_calc_v(struct Nurb *nu);
@@ -83,19 +83,19 @@ void makeNurbfaces(struct Nurb *nu, float *coord_array, int rowstride, int resol
void makeNurbcurve(struct Nurb *nu, float *coord_array, float *tilt_array, float *radius_array, float *weight_array, int resolu, int stride);
void forward_diff_bezier(float q0, float q1, float q2, float q3, float *p, int it, int stride);
float *make_orco_curve(struct Scene *scene, struct Object *ob);
-float *make_orco_surf( struct Object *ob);
+float *make_orco_surf(struct Object *ob);
void makebevelcurve(struct Scene *scene, struct Object *ob, struct ListBase *disp, int forRender);
-void makeBevelList( struct Object *ob);
+void makeBevelList(struct Object *ob);
-void calchandleNurb( struct BezTriple *bezt, struct BezTriple *prev, struct BezTriple *next, int mode);
-void calchandlesNurb( struct Nurb *nu);
-void testhandlesNurb( struct Nurb *nu);
-void autocalchandlesNurb( struct Nurb *nu, int flag);
+void calchandleNurb(struct BezTriple *bezt, struct BezTriple *prev, struct BezTriple *next, int mode);
+void calchandlesNurb(struct Nurb *nu);
+void testhandlesNurb(struct Nurb *nu);
+void autocalchandlesNurb(struct Nurb *nu, int flag);
void autocalchandlesNurb_all(ListBase *editnurb, int flag);
void sethandlesNurb(ListBase *editnurb, short code);
-void switchdirectionNurb( struct Nurb *nu);
+void switchdirectionNurb(struct Nurb *nu);
void addNurbPoints(struct Nurb *nu, int number);
void addNurbPointsBezier(struct Nurb *nu, int number);
@@ -107,11 +107,11 @@ float (*curve_getKeyVertexCos(struct Curve *cu, struct ListBase *lb, float *key)
void curve_applyKeyVertexTilts(struct Curve *cu, struct ListBase *lb, float *key);
/* nurb checks if they can be drawn, also clamp order func */
-int check_valid_nurb_u( struct Nurb *nu);
-int check_valid_nurb_v( struct Nurb *nu);
+int check_valid_nurb_u(struct Nurb *nu);
+int check_valid_nurb_v(struct Nurb *nu);
-int clamp_nurb_order_u( struct Nurb *nu);
-int clamp_nurb_order_v( struct Nurb *nu);
+int clamp_nurb_order_u(struct Nurb *nu);
+int clamp_nurb_order_v(struct Nurb *nu);
ListBase *BKE_curve_nurbs(struct Curve *cu);
diff --git a/source/blender/blenkernel/intern/DerivedMesh.c b/source/blender/blenkernel/intern/DerivedMesh.c
index 4c683b2b2c8..235bc695b66 100644
--- a/source/blender/blenkernel/intern/DerivedMesh.c
+++ b/source/blender/blenkernel/intern/DerivedMesh.c
@@ -80,8 +80,6 @@ static DerivedMesh *navmesh_dm_createNavMeshForVisualization(DerivedMesh *dm);
#include "GPU_extensions.h"
#include "GPU_material.h"
-extern GLubyte stipple_quarttone[128]; /* glutil.c, bad level data */
-
static void add_shapekey_layers(DerivedMesh *dm, Mesh *me, Object *ob);
static void shapekey_layers_to_keyblocks(DerivedMesh *dm, Mesh *me, int actshape_uid);
diff --git a/source/blender/blenkernel/intern/bvhutils.c b/source/blender/blenkernel/intern/bvhutils.c
index 4cade876d09..bbe210f2ce6 100644
--- a/source/blender/blenkernel/intern/bvhutils.c
+++ b/source/blender/blenkernel/intern/bvhutils.c
@@ -754,7 +754,7 @@ void bvhcache_insert(BVHCache *cache, BVHTree *tree, int type)
item->type = type;
item->tree = tree;
- BLI_linklist_prepend( cache, item );
+ BLI_linklist_prepend(cache, item);
}
diff --git a/source/blender/blenkernel/intern/cdderivedmesh.c b/source/blender/blenkernel/intern/cdderivedmesh.c
index cf435e96332..cc3705780e4 100644
--- a/source/blender/blenkernel/intern/cdderivedmesh.c
+++ b/source/blender/blenkernel/intern/cdderivedmesh.c
@@ -441,14 +441,14 @@ static void cdDM_drawEdges(DerivedMesh *dm, int drawLooseEdges, int drawAllEdges
}
if( prevdraw != draw ) {
if( prevdraw > 0 && (i-prevstart) > 0 ) {
- GPU_buffer_draw_elements( dm->drawObject->edges, GL_LINES, prevstart*2, (i-prevstart)*2 );
+ GPU_buffer_draw_elements(dm->drawObject->edges, GL_LINES, prevstart * 2, (i - prevstart) * 2);
}
prevstart = i;
}
prevdraw = draw;
}
if( prevdraw > 0 && (i-prevstart) > 0 ) {
- GPU_buffer_draw_elements( dm->drawObject->edges, GL_LINES, prevstart*2, (i-prevstart)*2 );
+ GPU_buffer_draw_elements(dm->drawObject->edges, GL_LINES, prevstart * 2, (i-prevstart) * 2);
}
}
GPU_buffer_unbind();
@@ -489,14 +489,14 @@ static void cdDM_drawLooseEdges(DerivedMesh *dm)
}
if( prevdraw != draw ) {
if( prevdraw > 0 && (i-prevstart) > 0) {
- GPU_buffer_draw_elements( dm->drawObject->edges, GL_LINES, prevstart*2, (i-prevstart)*2 );
+ GPU_buffer_draw_elements(dm->drawObject->edges, GL_LINES, prevstart * 2, (i - prevstart) * 2);
}
prevstart = i;
}
prevdraw = draw;
}
if( prevdraw > 0 && (i-prevstart) > 0 ) {
- GPU_buffer_draw_elements( dm->drawObject->edges, GL_LINES, prevstart*2, (i-prevstart)*2 );
+ GPU_buffer_draw_elements(dm->drawObject->edges, GL_LINES, prevstart * 2, (i - prevstart) * 2);
}
}
GPU_buffer_unbind();
diff --git a/source/blender/blenkernel/intern/collision.c b/source/blender/blenkernel/intern/collision.c
index f19226cedf0..7d850c3576e 100644
--- a/source/blender/blenkernel/intern/collision.c
+++ b/source/blender/blenkernel/intern/collision.c
@@ -75,7 +75,7 @@ Collision modifier code start
***********************************/
/* step is limited from 0 (frame start position) to 1 (frame end position) */
-void collision_move_object ( CollisionModifierData *collmd, float step, float prevstep )
+void collision_move_object(CollisionModifierData *collmd, float step, float prevstep)
{
float tv[3] = {0, 0, 0};
unsigned int i = 0;
diff --git a/source/blender/blenkernel/intern/displist.c b/source/blender/blenkernel/intern/displist.c
index d10c060cc7f..21f897d16ff 100644
--- a/source/blender/blenkernel/intern/displist.c
+++ b/source/blender/blenkernel/intern/displist.c
@@ -62,8 +62,6 @@
#include "BLO_sys_types.h" // for intptr_t support
-extern Material defmaterial; /* material.c */
-
static void boundbox_displist(Object *ob);
void free_disp_elem(DispList *dl)
diff --git a/source/blender/blenkernel/intern/mball.c b/source/blender/blenkernel/intern/mball.c
index f3225a6b6f5..22f8d38de4a 100644
--- a/source/blender/blenkernel/intern/mball.c
+++ b/source/blender/blenkernel/intern/mball.c
@@ -696,12 +696,12 @@ float metaball(float x, float y, float z)
}
else{
for(a=0; a<totelem; a++) {
- dens+= densfunc( mainb[a], x, y, z);
+ dens += densfunc(mainb[a], x, y, z);
}
}
}
else{
- dens+= densfunc( mainb[0], x, y, z);
+ dens += densfunc(mainb[0], x, y, z);
}
return thresh - dens;
@@ -1803,7 +1803,7 @@ float init_meta(Scene *scene, Object *ob) /* return totsize */
}
for(a=0; a<totelem; a++) {
- thresh+= densfunc( mainb[a], 2.0f*totsize, 2.0f*totsize, 2.0f*totsize);
+ thresh += densfunc(mainb[a], 2.0f * totsize, 2.0f * totsize, 2.0f * totsize);
}
return totsize;
diff --git a/source/blender/blenkernel/intern/particle_system.c b/source/blender/blenkernel/intern/particle_system.c
index 8d50d3d69cf..bbe32c651a2 100644
--- a/source/blender/blenkernel/intern/particle_system.c
+++ b/source/blender/blenkernel/intern/particle_system.c
@@ -4089,7 +4089,7 @@ static void particles_fluid_step(ParticleSimulationData *sim, int UNUSED(cfra))
}
fileParts++;
}
- gzclose( gzf );
+ gzclose(gzf);
totpart = psys->totpart = activeParts;
BLI_snprintf(debugStrBuffer,sizeof(debugStrBuffer),"readFsPartData::done - particles:%d, active:%d, file:%d, mask:%d \n", psys->totpart,activeParts,fileParts,readMask);
diff --git a/source/blender/blenkernel/intern/property.c b/source/blender/blenkernel/intern/property.c
index baf682b4cb6..9daee575080 100644
--- a/source/blender/blenkernel/intern/property.c
+++ b/source/blender/blenkernel/intern/property.c
@@ -79,7 +79,7 @@ bProperty *copy_property(bProperty *prop)
void copy_properties(ListBase *lbn, ListBase *lbo)
{
bProperty *prop, *propn;
- free_properties( lbn ); /* in case we are copying to an object with props */
+ free_properties(lbn); /* in case we are copying to an object with props */
prop= lbo->first;
while(prop) {
propn= copy_property(prop);
diff --git a/source/blender/blenkernel/intern/sequencer.c b/source/blender/blenkernel/intern/sequencer.c
index 8f8874d3a3c..b57e2f3dab9 100644
--- a/source/blender/blenkernel/intern/sequencer.c
+++ b/source/blender/blenkernel/intern/sequencer.c
@@ -3755,7 +3755,7 @@ Sequence *sequencer_add_movie_strip(bContext *C, ListBase *seqbasep, SeqLoadInfo
/* basic defaults */
seq->strip= strip= MEM_callocN(sizeof(Strip), "strip");
- strip->len = seq->len = IMB_anim_get_duration( an, IMB_TC_RECORD_RUN );
+ strip->len = seq->len = IMB_anim_get_duration(an, IMB_TC_RECORD_RUN);
strip->us= 1;
/* we only need 1 element for MOVIE strips */
diff --git a/source/blender/blenkernel/intern/softbody.c b/source/blender/blenkernel/intern/softbody.c
index b0075f5c121..33da4443b6f 100644
--- a/source/blender/blenkernel/intern/softbody.c
+++ b/source/blender/blenkernel/intern/softbody.c
@@ -3610,13 +3610,13 @@ static void curve_surf_to_softbody(Scene *scene, Object *ob)
bs->v1= curindex;
bs->v2= curindex+1;
bs->springtype=SB_HANDLE;
- bs->len= globallen( bezt->vec[0], bezt->vec[1], ob );
+ bs->len= globallen(bezt->vec[0], bezt->vec[1], ob);
bs++;
bs->v1= curindex+1;
bs->v2= curindex+2;
bs->springtype=SB_HANDLE;
- bs->len= globallen( bezt->vec[1], bezt->vec[2], ob );
+ bs->len= globallen(bezt->vec[1], bezt->vec[2], ob);
bs++;
}
}
diff --git a/source/blender/blenkernel/intern/text.c b/source/blender/blenkernel/intern/text.c
index 3f382cc5543..141d390d571 100644
--- a/source/blender/blenkernel/intern/text.c
+++ b/source/blender/blenkernel/intern/text.c
@@ -600,7 +600,7 @@ void clear_text(Text *text) /* called directly from rna */
txt_set_undostate( 1 );
txt_sel_all( text );
txt_delete_sel(text);
- txt_set_undostate( oldstate );
+ txt_set_undostate(oldstate);
txt_make_dirty(text);
}
@@ -609,10 +609,10 @@ void write_text(Text *text, const char *str) /* called directly from rna */
{
int oldstate;
- oldstate = txt_get_undostate( );
- txt_insert_buf( text, str );
- txt_move_eof( text, 0 );
- txt_set_undostate( oldstate );
+ oldstate = txt_get_undostate();
+ txt_insert_buf(text, str);
+ txt_move_eof(text, 0);
+ txt_set_undostate(oldstate);
txt_make_dirty(text);
}