diff options
author | Campbell Barton <ideasman42@gmail.com> | 2010-10-17 10:38:56 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2010-10-17 10:38:56 +0400 |
commit | 30b79ddcc6e2737add3a7ebd49b167c1776e4087 (patch) | |
tree | 8fe9bdba84b7b4cbf9f9ad3b55af892e8eed13bf /source/blender/blenkernel | |
parent | 28e144db920699a13e6cd196ac91f13e11b2877c (diff) |
- fixed remaining unused warnings.
- omit render code from this warning (cmake only), until render branch is merged.
- moved -Wunused-parameter warning to apply to all C code in blender (not just ./source/blender), (cmake only).
Diffstat (limited to 'source/blender/blenkernel')
-rw-r--r-- | source/blender/blenkernel/intern/BME_tools.c | 14 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/CCGSubSurf.c | 19 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/DerivedMesh.c | 2 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/boids.c | 6 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/customdata.c | 16 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/implicit.c | 6 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/nla.c | 2 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/particle.c | 6 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/seqeffects.c | 14 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/softbody.c | 22 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/sound.c | 2 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/subsurf_ccg.c | 8 |
12 files changed, 64 insertions, 53 deletions
diff --git a/source/blender/blenkernel/intern/BME_tools.c b/source/blender/blenkernel/intern/BME_tools.c index e5a355e5f24..444bc10d562 100644 --- a/source/blender/blenkernel/intern/BME_tools.c +++ b/source/blender/blenkernel/intern/BME_tools.c @@ -107,7 +107,7 @@ float *BME_new_transdata_float(BME_TransData_Head *td) { return BLI_memarena_alloc(td->ma, sizeof(float)); } -static int BME_is_nonmanifold_vert(BME_Mesh *bm, BME_Vert *v) { +static int BME_is_nonmanifold_vert(BME_Mesh *UNUSED(bm), BME_Vert *v) { BME_Edge *e, *oe; BME_Loop *l; int len, count, flag; @@ -217,7 +217,7 @@ static void BME_data_interp_from_verts(BME_Mesh *bm, BME_Vert *v1, BME_Vert *v2, #endif -static void BME_data_facevert_edgesplit(BME_Mesh *bm, BME_Vert *v1, BME_Vert *v2, BME_Vert *v, BME_Edge *e1, float fac){ +static void BME_data_facevert_edgesplit(BME_Mesh *bm, BME_Vert *v1, BME_Vert *UNUSED(v2), BME_Vert *v, BME_Edge *e1, float fac){ void *src[2]; float w[2]; BME_Loop *l=NULL, *v1loop = NULL, *vloop = NULL, *v2loop = NULL; @@ -356,7 +356,7 @@ static int BME_bevel_get_vec(float *vec, BME_Vert *v1, BME_Vert *v2, BME_TransDa * vec2 is the direction of projection (pointing away from vec1) * up_vec is used for orientation (expected to be normalized) * returns the length of the projected vector that lies along vec1 */ -static float BME_bevel_project_vec(float *vec1, float *vec2, float *up_vec, int is_forward, BME_TransData_Head *td) { +static float BME_bevel_project_vec(float *vec1, float *vec2, float *up_vec, int is_forward, BME_TransData_Head *UNUSED(td)) { float factor, vec3[3], tmp[3],c1,c2; cross_v3_v3v3(tmp,vec1,vec2); @@ -582,7 +582,7 @@ static float BME_bevel_set_max(BME_Vert *v1, BME_Vert *v2, float value, BME_Tran return max; } -static BME_Vert *BME_bevel_wire(BME_Mesh *bm, BME_Vert *v, float value, int res, int options, BME_TransData_Head *td) { +static BME_Vert *BME_bevel_wire(BME_Mesh *bm, BME_Vert *v, float value, int res, int UNUSED(options), BME_TransData_Head *td) { BME_Vert *ov1, *ov2, *v1, *v2; ov1 = BME_edge_getothervert(v->edge, v); @@ -607,7 +607,7 @@ static BME_Vert *BME_bevel_wire(BME_Mesh *bm, BME_Vert *v, float value, int res, return v1; } -static BME_Loop *BME_bevel_edge(BME_Mesh *bm, BME_Loop *l, float value, int options, float *up_vec, BME_TransData_Head *td) { +static BME_Loop *BME_bevel_edge(BME_Mesh *bm, BME_Loop *l, float value, int UNUSED(options), float *up_vec, BME_TransData_Head *td) { BME_Vert *v1, *v2, *kv; BME_Loop *kl=NULL, *nl; BME_Edge *e; @@ -708,7 +708,7 @@ static BME_Loop *BME_bevel_edge(BME_Mesh *bm, BME_Loop *l, float value, int opti return l; } -static BME_Loop *BME_bevel_vert(BME_Mesh *bm, BME_Loop *l, float value, int options, float *up_vec, BME_TransData_Head *td) { +static BME_Loop *BME_bevel_vert(BME_Mesh *bm, BME_Loop *l, float value, int UNUSED(options), float *up_vec, BME_TransData_Head *td) { BME_Vert *v1, *v2; BME_Poly *f; @@ -859,7 +859,7 @@ static void BME_bevel_add_vweight(BME_TransData_Head *td, BME_Mesh *bm, BME_Vert } } -static float BME_bevel_get_angle(BME_Mesh *bm, BME_Edge *e, BME_Vert *v) { +static float BME_bevel_get_angle(BME_Mesh *UNUSED(bm), BME_Edge *e, BME_Vert *v) { BME_Vert *v1, *v2; BME_Loop *l1, *l2; float vec1[3], vec2[3], vec3[3], vec4[3]; diff --git a/source/blender/blenkernel/intern/CCGSubSurf.c b/source/blender/blenkernel/intern/CCGSubSurf.c index bbd68fb797b..1cd5ae381c4 100644 --- a/source/blender/blenkernel/intern/CCGSubSurf.c +++ b/source/blender/blenkernel/intern/CCGSubSurf.c @@ -15,6 +15,13 @@ #define CCG_INLINE inline #endif +/* copied from BKE_utildefines.h ugh */ +#ifdef __GNUC__ +# define UNUSED(x) UNUSED_ ## x __attribute__((__unused__)) +#else +# define UNUSED(x) x +#endif + /* used for normalize_v3 in BLI_math_vector * float.h's FLT_EPSILON causes trouble with subsurf normals - campbell */ #define EPSILON (1.0e-35f) @@ -185,13 +192,13 @@ static int _ehashIterator_isStopped(EHashIterator *ehi) { /***/ -static void *_stdAllocator_alloc(CCGAllocatorHDL a, int numBytes) { +static void *_stdAllocator_alloc(CCGAllocatorHDL UNUSED(a), int numBytes) { return malloc(numBytes); } -static void *_stdAllocator_realloc(CCGAllocatorHDL a, void *ptr, int newSize, int oldSize) { +static void *_stdAllocator_realloc(CCGAllocatorHDL UNUSED(a), void *ptr, int newSize, int UNUSED(oldSize)) { return realloc(ptr, newSize); } -static void _stdAllocator_free(CCGAllocatorHDL a, void *ptr) { +static void _stdAllocator_free(CCGAllocatorHDL UNUSED(a), void *ptr) { free(ptr); } @@ -2601,7 +2608,7 @@ float ccgSubSurf_getEdgeCrease(CCGEdge *e) { /* Face accessors */ -CCGFaceHDL ccgSubSurf_getFaceFaceHandle(CCGSubSurf *ss, CCGFace *f) { +CCGFaceHDL ccgSubSurf_getFaceFaceHandle(CCGSubSurf *UNUSED(ss), CCGFace *f) { return f->fHDL; } int ccgSubSurf_getFaceAge(CCGSubSurf *ss, CCGFace *f) { @@ -2619,14 +2626,14 @@ void *ccgSubSurf_getFaceUserData(CCGSubSurf *ss, CCGFace *f) { int ccgSubSurf_getFaceNumVerts(CCGFace *f) { return f->numVerts; } -CCGVert *ccgSubSurf_getFaceVert(CCGSubSurf *ss, CCGFace *f, int index) { +CCGVert *ccgSubSurf_getFaceVert(CCGSubSurf *UNUSED(ss), CCGFace *f, int index) { if (index<0 || index>=f->numVerts) { return NULL; } else { return FACE_getVerts(f)[index]; } } -CCGEdge *ccgSubSurf_getFaceEdge(CCGSubSurf *ss, CCGFace *f, int index) { +CCGEdge *ccgSubSurf_getFaceEdge(CCGSubSurf *UNUSED(ss), CCGFace *f, int index) { if (index<0 || index>=f->numVerts) { return NULL; } else { diff --git a/source/blender/blenkernel/intern/DerivedMesh.c b/source/blender/blenkernel/intern/DerivedMesh.c index e70dde1474a..2e8922dec1b 100644 --- a/source/blender/blenkernel/intern/DerivedMesh.c +++ b/source/blender/blenkernel/intern/DerivedMesh.c @@ -633,6 +633,8 @@ static void emDM_drawMappedFaces(DerivedMesh *dm, int (*setDrawOptions)(void *us EditMeshDerivedMesh *emdm= (EditMeshDerivedMesh*) dm; EditFace *efa; int i, draw; + + (void)setMaterial; /* unused */ if (emdm->vertexCos) { EditVert *eve; diff --git a/source/blender/blenkernel/intern/boids.c b/source/blender/blenkernel/intern/boids.c index cfe16e089cf..943cf20720e 100644 --- a/source/blender/blenkernel/intern/boids.c +++ b/source/blender/blenkernel/intern/boids.c @@ -58,7 +58,7 @@ typedef struct BoidValues { static int apply_boid_rule(BoidBrainData *bbd, BoidRule *rule, BoidValues *val, ParticleData *pa, float fuzziness); -static int rule_none(BoidRule *rule, BoidBrainData *UNUSED(data), BoidValues *val, ParticleData *pa) +static int rule_none(BoidRule *UNUSED(rule), BoidBrainData *UNUSED(data), BoidValues *UNUSED(val), ParticleData *UNUSED(pa)) { return 0; } @@ -344,7 +344,7 @@ static int rule_avoid_collision(BoidRule *rule, BoidBrainData *bbd, BoidValues * return ret; } -static int rule_separate(BoidRule *rule, BoidBrainData *bbd, BoidValues *val, ParticleData *pa) +static int rule_separate(BoidRule *UNUSED(rule), BoidBrainData *bbd, BoidValues *val, ParticleData *pa) { KDTreeNearest *ptn = NULL; ParticleTarget *pt; @@ -384,7 +384,7 @@ static int rule_separate(BoidRule *rule, BoidBrainData *bbd, BoidValues *val, Pa } return ret; } -static int rule_flock(BoidRule *rule, BoidBrainData *bbd, BoidValues *val, ParticleData *pa) +static int rule_flock(BoidRule *UNUSED(rule), BoidBrainData *bbd, BoidValues *UNUSED(val), ParticleData *pa) { KDTreeNearest ptn[11]; float vec[3] = {0.0f, 0.0f, 0.0f}, loc[3] = {0.0f, 0.0f, 0.0f}; diff --git a/source/blender/blenkernel/intern/customdata.c b/source/blender/blenkernel/intern/customdata.c index 58cd08f1c4c..7f91df3b281 100644 --- a/source/blender/blenkernel/intern/customdata.c +++ b/source/blender/blenkernel/intern/customdata.c @@ -145,7 +145,7 @@ static void linklist_free_simple(void *link) } static void layerInterp_mdeformvert(void **sources, float *weights, - float *sub_weights, int count, void *dest) + float *UNUSED(sub_weights), int count, void *dest) { MDeformVert *dvert = dest; LinkNode *dest_dw = NULL; /* a list of lists of MDeformWeight pointers */ @@ -203,7 +203,7 @@ static void layerInterp_mdeformvert(void **sources, float *weights, static void layerInterp_msticky(void **sources, float *weights, - float *sub_weights, int count, void *dest) + float *UNUSED(sub_weights), int count, void *dest) { float co[2], w; MSticky *mst; @@ -484,8 +484,8 @@ static void layerSwap_mdisps(void *data, const int *ci) } } -static void layerInterp_mdisps(void **UNUSED(sources), float *weights, float *sub_weights, - int UNUSED(count), void *dest) +static void layerInterp_mdisps(void **UNUSED(sources), float *UNUSED(weights), + float *UNUSED(sub_weights), int UNUSED(count), void *dest) { MDisps *d = dest; int i; @@ -563,7 +563,7 @@ static void layerCopy_mdisps(const void *source, void *dest, int count) } } -static void layerFree_mdisps(void *data, int count, int size) +static void layerFree_mdisps(void *data, int count, int UNUSED(size)) { int i; MDisps *d = data; @@ -609,7 +609,7 @@ static int layerWrite_mdisps(CDataFile *cdf, void *data, int count) return 1; } -static size_t layerFilesize_mdisps(CDataFile *cdf, void *data, int count) +static size_t layerFilesize_mdisps(CDataFile *UNUSED(cdf), void *data, int count) { MDisps *d = data; size_t size = 0; @@ -2349,7 +2349,7 @@ static void customdata_external_filename(char filename[FILE_MAX], ID *id, Custom BLI_path_abs(filename, path); } -void CustomData_external_reload(CustomData *data, ID *id, CustomDataMask mask, int totelem) +void CustomData_external_reload(CustomData *data, ID *UNUSED(id), CustomDataMask mask, int totelem) { CustomDataLayer *layer; const LayerTypeInfo *typeInfo; @@ -2519,7 +2519,7 @@ void CustomData_external_write(CustomData *data, ID *id, CustomDataMask mask, in cdf_free(cdf); } -void CustomData_external_add(CustomData *data, ID *id, int type, int UNUSED(totelem), const char *filename) +void CustomData_external_add(CustomData *data, ID *UNUSED(id), int type, int UNUSED(totelem), const char *filename) { CustomDataExternal *external= data->external; CustomDataLayer *layer; diff --git a/source/blender/blenkernel/intern/implicit.c b/source/blender/blenkernel/intern/implicit.c index 9baaf7e5abc..e0077ec7d26 100644 --- a/source/blender/blenkernel/intern/implicit.c +++ b/source/blender/blenkernel/intern/implicit.c @@ -1218,7 +1218,7 @@ DO_INLINE void dfdx_damp(float to[3][3], float dir[3],float length,const float } -DO_INLINE void cloth_calc_spring_force(ClothModifierData *clmd, ClothSpring *s, lfVector *lF, lfVector *X, lfVector *V, fmatrix3x3 *dFdV, fmatrix3x3 *dFdX, float time) +DO_INLINE void cloth_calc_spring_force(ClothModifierData *clmd, ClothSpring *s, lfVector *UNUSED(lF), lfVector *X, lfVector *V, fmatrix3x3 *UNUSED(dFdV), fmatrix3x3 *UNUSED(dFdX), float time) { Cloth *cloth = clmd->clothObject; ClothVertex *verts = cloth->verts; @@ -1353,7 +1353,7 @@ DO_INLINE void cloth_calc_spring_force(ClothModifierData *clmd, ClothSpring *s, } } -DO_INLINE void cloth_apply_spring_force(ClothModifierData *clmd, ClothSpring *s, lfVector *lF, lfVector *X, lfVector *V, fmatrix3x3 *dFdV, fmatrix3x3 *dFdX) +DO_INLINE void cloth_apply_spring_force(ClothModifierData *UNUSED(clmd), ClothSpring *s, lfVector *lF, lfVector *UNUSED(X), lfVector *UNUSED(V), fmatrix3x3 *dFdV, fmatrix3x3 *dFdX) { if(s->flags & CLOTH_SPRING_FLAG_NEEDED) { @@ -1708,7 +1708,7 @@ static void cloth_calc_force(ClothModifierData *clmd, float UNUSED(frame), lfVec // printf("\n"); } -static void simulate_implicit_euler(lfVector *Vnew, lfVector *lX, lfVector *lV, lfVector *lF, fmatrix3x3 *dFdV, fmatrix3x3 *dFdX, float dt, fmatrix3x3 *A, lfVector *B, lfVector *dV, fmatrix3x3 *S, lfVector *z, lfVector *olddV, fmatrix3x3 *P, fmatrix3x3 *Pinv, fmatrix3x3 *M, fmatrix3x3 *bigI) +static void simulate_implicit_euler(lfVector *Vnew, lfVector *UNUSED(lX), lfVector *lV, lfVector *lF, fmatrix3x3 *dFdV, fmatrix3x3 *dFdX, float dt, fmatrix3x3 *A, lfVector *B, lfVector *dV, fmatrix3x3 *S, lfVector *z, lfVector *olddV, fmatrix3x3 *UNUSED(P), fmatrix3x3 *UNUSED(Pinv), fmatrix3x3 *M, fmatrix3x3 *UNUSED(bigI)) { unsigned int numverts = dFdV[0].vcount; diff --git a/source/blender/blenkernel/intern/nla.c b/source/blender/blenkernel/intern/nla.c index 09ba967e265..67c3e746a63 100644 --- a/source/blender/blenkernel/intern/nla.c +++ b/source/blender/blenkernel/intern/nla.c @@ -1585,7 +1585,7 @@ void BKE_nla_tweakmode_exit (AnimData *adt) /* Baking Tools ------------------------------------------- */ -void BKE_nla_bake (Scene *scene, ID *id, AnimData *adt, int UNUSED(flag)) +void BKE_nla_bake (Scene *scene, ID *UNUSED(id), AnimData *adt, int UNUSED(flag)) { /* verify that data is valid diff --git a/source/blender/blenkernel/intern/particle.c b/source/blender/blenkernel/intern/particle.c index f7345d6159a..624587338c9 100644 --- a/source/blender/blenkernel/intern/particle.c +++ b/source/blender/blenkernel/intern/particle.c @@ -1647,7 +1647,7 @@ int psys_particle_dm_face_lookup(Object *ob, DerivedMesh *dm, int index, float * return DMCACHE_NOTFOUND; } -static int psys_map_index_on_dm(DerivedMesh *dm, int from, int index, int index_dmcache, float *fw, float foffset, int *mapindex, float *mapfw) +static int psys_map_index_on_dm(DerivedMesh *dm, int from, int index, int index_dmcache, float *fw, float UNUSED(foffset), int *mapindex, float *mapfw) { if(index < 0) return 0; @@ -1803,7 +1803,7 @@ ParticleSystemModifierData *psys_get_modifier(Object *ob, ParticleSystem *psys) /* Particles on a shape */ /************************************************/ /* ready for future use */ -static void psys_particle_on_shape(int UNUSED(distr), int index, float *UNUSED(fuv), float *vec, float *nor, float *utan, float *vtan, float *orco, float *ornor) +static void psys_particle_on_shape(int UNUSED(distr), int UNUSED(index), float *UNUSED(fuv), float *vec, float *nor, float *utan, float *vtan, float *orco, float *ornor) { /* TODO */ float zerovec[3]={0.0f,0.0f,0.0f}; @@ -2185,7 +2185,7 @@ static void do_rough_end(float *loc, float mat[4][4], float t, float fac, float VECADDFAC(state->co,state->co,mat[0],rough[0]); VECADDFAC(state->co,state->co,mat[1],rough[1]); } -static void do_path_effectors(ParticleSimulationData *sim, int i, ParticleCacheKey *ca, int k, int steps, float *rootco, float effector, float dfra, float UNUSED(cfra), float *length, float *vec) +static void do_path_effectors(ParticleSimulationData *sim, int i, ParticleCacheKey *ca, int k, int steps, float *UNUSED(rootco), float effector, float UNUSED(dfra), float UNUSED(cfra), float *length, float *vec) { float force[3] = {0.0f,0.0f,0.0f}; ParticleKey eff_key; diff --git a/source/blender/blenkernel/intern/seqeffects.c b/source/blender/blenkernel/intern/seqeffects.c index 7ce5dcc3884..6477c6b4f75 100644 --- a/source/blender/blenkernel/intern/seqeffects.c +++ b/source/blender/blenkernel/intern/seqeffects.c @@ -524,7 +524,7 @@ static void do_alphaover_effect_float(float facf0, float facf1, int x, int y, } static struct ImBuf * do_alphaover_effect( - Main *bmain, Scene *UNUSED(scene), Sequence *UNUSED(seq), float UNUSED(cfra), + Main *UNUSED(bmain), Scene *UNUSED(scene), Sequence *UNUSED(seq), float UNUSED(cfra), float facf0, float facf1, int x, int y, int UNUSED(preview_render_size), struct ImBuf *ibuf1, struct ImBuf *ibuf2, @@ -2633,7 +2633,7 @@ static void copy_glow_effect(Sequence *dst, Sequence *src) //void do_glow_effect(Cast *cast, float facf0, float facf1, int xo, int yo, ImBuf *ibuf1, ImBuf *ibuf2, ImBuf *outbuf, ImBuf *use) static void do_glow_effect_byte(Sequence *seq, float facf0, float UNUSED(facf1), int x, int y, char *rect1, - char *rect2, char *out) + char *UNUSED(rect2), char *out) { unsigned char *outbuf=(unsigned char *)out; unsigned char *inbuf=(unsigned char *)rect1; @@ -2648,7 +2648,7 @@ static void do_glow_effect_byte(Sequence *seq, float facf0, float UNUSED(facf1), static void do_glow_effect_float(Sequence *seq, float facf0, float UNUSED(facf1), int x, int y, - float *rect1, float *rect2, float *out) + float *rect1, float *UNUSED(rect2), float *out) { float *outbuf = out; float *inbuf = rect1; @@ -2822,8 +2822,8 @@ static struct ImBuf * do_multicam( Main *bmain, Scene *scene, Sequence *seq, float cfra, float UNUSED(facf0), float UNUSED(facf1), int x, int y, int preview_render_size, - struct ImBuf *ibuf1, struct ImBuf *ibuf2, - struct ImBuf *ibuf3) + struct ImBuf *UNUSED(ibuf1), struct ImBuf *UNUSED(ibuf2), + struct ImBuf *UNUSED(ibuf3)) { struct ImBuf * i; struct ImBuf * out; @@ -2914,7 +2914,7 @@ static int early_out_speed(struct Sequence *UNUSED(seq), } static void store_icu_yrange_speed(struct Sequence * seq, - short adrcode, float * ymin, float * ymax) + short UNUSED(adrcode), float * ymin, float * ymax) { SpeedControlVars * v = (SpeedControlVars *)seq->effectdata; @@ -3091,7 +3091,7 @@ static int early_out_mul_input2(struct Sequence *UNUSED(seq), } static void store_icu_yrange_noop(struct Sequence * UNUSED(seq), - short adrcode, float * ymin, float * ymax) + short UNUSED(adrcode), float *UNUSED(ymin), float *UNUSED(ymax)) { /* defaults are fine */ } diff --git a/source/blender/blenkernel/intern/softbody.c b/source/blender/blenkernel/intern/softbody.c index 58aa171e97b..978b3c9864f 100644 --- a/source/blender/blenkernel/intern/softbody.c +++ b/source/blender/blenkernel/intern/softbody.c @@ -678,7 +678,7 @@ static void add_mesh_quad_diag_springs(Object *ob) } } -static void add_2nd_order_roller(Object *ob,float stiffness,int *counter, int addsprings) +static void add_2nd_order_roller(Object *ob,float UNUSED(stiffness), int *counter, int addsprings) { /*assume we have a softbody*/ SoftBody *sb= ob->soft; /* is supposed to be there */ @@ -1029,7 +1029,7 @@ static int query_external_colliders(Scene *scene, Object *me) /* +++ the aabb "force" section*/ -static int sb_detect_aabb_collisionCached( float force[3], unsigned int par_layer,struct Object *vertexowner,float UNUSED(time)) +static int sb_detect_aabb_collisionCached( float UNUSED(force[3]), unsigned int UNUSED(par_layer),struct Object *vertexowner,float UNUSED(time)) { Object *ob; SoftBody *sb=vertexowner->soft; @@ -1094,7 +1094,7 @@ static int sb_detect_aabb_collisionCached( float force[3], unsigned int par_laye /* +++ the face external section*/ static int sb_detect_face_pointCached(float face_v1[3],float face_v2[3],float face_v3[3],float *damp, - float force[3], unsigned int par_layer,struct Object *vertexowner,float time) + float force[3], unsigned int UNUSED(par_layer),struct Object *vertexowner,float time) { Object *ob; GHash *hash; @@ -1192,7 +1192,7 @@ static int sb_detect_face_pointCached(float face_v1[3],float face_v2[3],float fa static int sb_detect_face_collisionCached(float face_v1[3],float face_v2[3],float face_v3[3],float *damp, - float force[3], unsigned int par_layer,struct Object *vertexowner,float time) + float force[3], unsigned int UNUSED(par_layer),struct Object *vertexowner,float time) { Object *ob; GHash *hash; @@ -1418,7 +1418,7 @@ static void scan_for_ext_face_forces(Object *ob,float timenow) /* +++ the spring external section*/ static int sb_detect_edge_collisionCached(float edge_v1[3],float edge_v2[3],float *damp, - float force[3], unsigned int par_layer,struct Object *vertexowner,float time) + float force[3], unsigned int UNUSED(par_layer),struct Object *vertexowner,float time) { Object *ob; GHash *hash; @@ -1659,7 +1659,7 @@ static void *exec_scan_for_ext_spring_forces(void *data) return 0; } -static void sb_sfesf_threads_run(Scene *scene, struct Object *ob, float timenow,int totsprings,int *ptr_to_break_func()) +static void sb_sfesf_threads_run(Scene *scene, struct Object *ob, float timenow,int totsprings,int *UNUSED(ptr_to_break_func())) { ListBase *do_effector = NULL; ListBase threads; @@ -1749,7 +1749,7 @@ static int choose_winner(float*w, float* pos,float*a,float*b,float*c,float*ca,fl static int sb_detect_vertex_collisionCached(float opco[3], float facenormal[3], float *damp, - float force[3], unsigned int par_layer,struct Object *vertexowner, + float force[3], unsigned int UNUSED(par_layer), struct Object *vertexowner, float time,float vel[3], float *intrusion) { Object *ob= NULL; @@ -2084,7 +2084,7 @@ static void dfdv_goal(int ia, int ic,float factor) for(i=0;i<3;i++) nlMatrixAdd(ia+i,ic+i,factor); } */ -static void sb_spring_force(Object *ob,int bpi,BodySpring *bs,float iks,float forcetime,int nl_flags) +static void sb_spring_force(Object *ob,int bpi,BodySpring *bs,float iks,float UNUSED(forcetime), int nl_flags) { SoftBody *sb= ob->soft; /* is supposed to be there */ BodyPoint *bp1,*bp2; @@ -2175,7 +2175,7 @@ static void sb_spring_force(Object *ob,int bpi,BodySpring *bs,float iks,float fo /* since this is definitely the most CPU consuming task here .. try to spread it */ /* core function _softbody_calc_forces_slice_in_a_thread */ /* result is int to be able to flag user break */ -static int _softbody_calc_forces_slice_in_a_thread(Scene *scene, Object *ob, float forcetime, float timenow,int ifirst,int ilast,int *ptr_to_break_func(),ListBase *do_effector,int do_deflector,float fieldfactor, float windfactor) +static int _softbody_calc_forces_slice_in_a_thread(Scene *scene, Object *ob, float forcetime, float timenow,int ifirst,int ilast,int *UNUSED(ptr_to_break_func()),ListBase *do_effector,int do_deflector,float fieldfactor, float windfactor) { float iks; int bb,do_selfcollision,do_springcollision,do_aero; @@ -2386,7 +2386,7 @@ static void *exec_softbody_calc_forces(void *data) return 0; } -static void sb_cf_threads_run(Scene *scene, Object *ob, float forcetime, float timenow,int totpoint,int *ptr_to_break_func(),struct ListBase *do_effector,int do_deflector,float fieldfactor, float windfactor) +static void sb_cf_threads_run(Scene *scene, Object *ob, float forcetime, float timenow,int totpoint,int *UNUSED(ptr_to_break_func()),struct ListBase *do_effector,int do_deflector,float fieldfactor, float windfactor) { ListBase threads; SB_thread_context *sb_threads; @@ -2444,7 +2444,7 @@ static void sb_cf_threads_run(Scene *scene, Object *ob, float forcetime, float t MEM_freeN(sb_threads); } -static void softbody_calc_forcesEx(Scene *scene, Object *ob, float forcetime, float timenow, int nl_flags) +static void softbody_calc_forcesEx(Scene *scene, Object *ob, float forcetime, float timenow, int UNUSED(nl_flags)) { /* rule we never alter free variables :bp->vec bp->pos in here ! * this will ruin adaptive stepsize AKA heun! (BM) diff --git a/source/blender/blenkernel/intern/sound.c b/source/blender/blenkernel/intern/sound.c index ca1fd80b406..b2e5209a4fc 100644 --- a/source/blender/blenkernel/intern/sound.c +++ b/source/blender/blenkernel/intern/sound.c @@ -110,6 +110,8 @@ void sound_init(struct Main *bmain) #ifdef WITH_JACK AUD_setSyncCallback(sound_sync_callback, bmain); +#else + (void)bmain; /* unused */ #endif } diff --git a/source/blender/blenkernel/intern/subsurf_ccg.c b/source/blender/blenkernel/intern/subsurf_ccg.c index 6323e1e3c79..26bd981db4a 100644 --- a/source/blender/blenkernel/intern/subsurf_ccg.c +++ b/source/blender/blenkernel/intern/subsurf_ccg.c @@ -83,13 +83,13 @@ static void *arena_realloc(CCGAllocatorHDL a, void *ptr, int newSize, int oldSiz } return p2; } -static void arena_free(CCGAllocatorHDL a, void *ptr) { +static void arena_free(CCGAllocatorHDL UNUSED(a), void *UNUSED(ptr)) { } static void arena_release(CCGAllocatorHDL a) { BLI_memarena_free(a); } -static CCGSubSurf *_getSubSurf(CCGSubSurf *prevSS, int subdivLevels, int useAging, int useArena, int useFlatSubdiv) { +static CCGSubSurf *_getSubSurf(CCGSubSurf *prevSS, int subdivLevels, int useAging, int useArena, int UNUSED(useFlatSubdiv)) { CCGMeshIFC ifc; CCGSubSurf *ccgSS; @@ -1146,7 +1146,7 @@ static void ccgDM_drawVerts(DerivedMesh *dm) { ccgFaceIterator_free(fi); glEnd(); } -static void ccgDM_drawEdges(DerivedMesh *dm, int drawLooseEdges, int drawAllEdges) { +static void ccgDM_drawEdges(DerivedMesh *dm, int drawLooseEdges, int UNUSED(drawAllEdges)) { CCGDerivedMesh *ccgdm = (CCGDerivedMesh*) dm; CCGSubSurf *ss = ccgdm->ss; CCGEdgeIterator *ei = ccgSubSurf_getEdgeIterator(ss); @@ -1514,7 +1514,7 @@ static void ccgDM_drawFacesGLSL(DerivedMesh *dm, int (*setMaterial)(int, void *a dm->drawMappedFacesGLSL(dm, setMaterial, NULL, NULL); } -static void ccgDM_drawFacesColored(DerivedMesh *dm, int useTwoSided, unsigned char *col1, unsigned char *col2) { +static void ccgDM_drawFacesColored(DerivedMesh *dm, int UNUSED(useTwoSided), unsigned char *col1, unsigned char *col2) { CCGDerivedMesh *ccgdm = (CCGDerivedMesh*) dm; CCGSubSurf *ss = ccgdm->ss; CCGFaceIterator *fi = ccgSubSurf_getFaceIterator(ss); |