diff options
author | Campbell Barton <ideasman42@gmail.com> | 2011-01-12 06:41:12 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2011-01-12 06:41:12 +0300 |
commit | 63018144badeb10c858504c918a3f66047c068b0 (patch) | |
tree | 5982ba549aa3e23a68a412877f51d100ae1bb920 /source/blender/blenkernel/intern | |
parent | 21fc4cabaff9b1caa476af9d700195fb239a07c6 (diff) |
remove redundant assignments & unused vars.
also minor functional changes
- OBJECT_OT_make_links_data() type property is now assigned to the operator property (so popup menu can find it)
- removing BG image now returns cancelled if no image is removed.
Diffstat (limited to 'source/blender/blenkernel/intern')
-rw-r--r-- | source/blender/blenkernel/intern/displist.c | 1 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/font.c | 2 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/image.c | 8 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/implicit.c | 4 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/particle.c | 2 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/pointcache.c | 4 |
6 files changed, 8 insertions, 13 deletions
diff --git a/source/blender/blenkernel/intern/displist.c b/source/blender/blenkernel/intern/displist.c index 674836ac859..424d15f6a7e 100644 --- a/source/blender/blenkernel/intern/displist.c +++ b/source/blender/blenkernel/intern/displist.c @@ -1795,7 +1795,6 @@ static void do_makeDispListCurveTypes(Scene *scene, Object *ob, ListBase *dispba dl->rt= nu->flag & ~CU_2D; dl->bevelSplitFlag= MEM_callocN(sizeof(*dl->col2)*((bl->nr+0x1F)>>5), "bevelSplitFlag"); - bevp= (BevPoint *)(bl+1); /* for each point of poly make a bevel piece */ bevp= (BevPoint *)(bl+1); diff --git a/source/blender/blenkernel/intern/font.c b/source/blender/blenkernel/intern/font.c index ecaa15c8f7d..9684e18b949 100644 --- a/source/blender/blenkernel/intern/font.c +++ b/source/blender/blenkernel/intern/font.c @@ -696,7 +696,7 @@ struct chartrans *BKE_text_to_curve(Scene *scene, Object *ob, int mode) // Create unicode string utf8len = utf8slen(cu->str); - tmp = mem = MEM_callocN(((utf8len + 1) * sizeof(wchar_t)), "convertedmem"); + mem = MEM_callocN(((utf8len + 1) * sizeof(wchar_t)), "convertedmem"); utf8towchar(mem, cu->str); diff --git a/source/blender/blenkernel/intern/image.c b/source/blender/blenkernel/intern/image.c index 58e3b4ba552..d8876705ebb 100644 --- a/source/blender/blenkernel/intern/image.c +++ b/source/blender/blenkernel/intern/image.c @@ -914,10 +914,10 @@ static void stampdata(Scene *scene, StampData *stamp_data, int do_prefix) } if (scene->r.stamp & R_STAMP_TIME) { - int h, m, s, f; - h= m= s= f= 0; - f = (int)(scene->r.cfra % scene->r.frs_sec); - s = (int)(scene->r.cfra / scene->r.frs_sec); + int f = (int)(scene->r.cfra % scene->r.frs_sec); + int s = (int)(scene->r.cfra / scene->r.frs_sec); + int h= 0; + int m= 0; if (s) { m = (int)(s / 60); diff --git a/source/blender/blenkernel/intern/implicit.c b/source/blender/blenkernel/intern/implicit.c index 0df456a443d..fc9c41070dc 100644 --- a/source/blender/blenkernel/intern/implicit.c +++ b/source/blender/blenkernel/intern/implicit.c @@ -1229,7 +1229,7 @@ DO_INLINE void cloth_calc_spring_force(ClothModifierData *clmd, ClothSpring *s, float vel[3]; float k = 0.0f; float L = s->restlen; - float cb = clmd->sim_parms->structural; + float cb; /* = clmd->sim_parms->structural; */ /*UNUSED*/ float nullf[3] = {0,0,0}; float stretch_force[3] = {0,0,0}; @@ -1566,7 +1566,7 @@ static void cloth_calc_force(ClothModifierData *clmd, float UNUSED(frame), lfVec float tm2[3][3] = {{0}}; MFace *mfaces = cloth->mfaces; unsigned int numverts = cloth->numverts; - LinkNode *search = cloth->springs; + LinkNode *search; lfVector *winvec; EffectedPoint epoint; diff --git a/source/blender/blenkernel/intern/particle.c b/source/blender/blenkernel/intern/particle.c index db826b83864..7c3e90dc375 100644 --- a/source/blender/blenkernel/intern/particle.c +++ b/source/blender/blenkernel/intern/particle.c @@ -2847,7 +2847,7 @@ void psys_cache_paths(ParticleSimulationData *sim, float cfra) ParticleEditSettings *pset = &sim->scene->toolsettings->particle; ParticleSystem *psys = sim->psys; ParticleSettings *part = psys->part; - ParticleCacheKey *ca, **cache= psys->pathcache; + ParticleCacheKey *ca, **cache; DerivedMesh *hair_dm = (psys->part->type==PART_HAIR && psys->flag & PSYS_HAIR_DYNAMICS) ? psys->hair_out_dm : NULL; diff --git a/source/blender/blenkernel/intern/pointcache.c b/source/blender/blenkernel/intern/pointcache.c index 37ce6c94eb7..0044c86f4f7 100644 --- a/source/blender/blenkernel/intern/pointcache.c +++ b/source/blender/blenkernel/intern/pointcache.c @@ -2025,8 +2025,6 @@ void BKE_ptcache_id_clear(PTCacheID *pid, int mode, unsigned int cfra) PTCacheMem *pm= pid->cache->mem_cache.first; PTCacheMem *link= NULL; - pm= pid->cache->mem_cache.first; - if(mode == PTCACHE_CLEAR_ALL) { /*we want startframe if the cache starts before zero*/ pid->cache->last_exact = MIN2(pid->cache->startframe, 0); @@ -2207,8 +2205,6 @@ void BKE_ptcache_id_time(PTCacheID *pid, Scene *scene, float cfra, int *startfra else { PTCacheMem *pm= pid->cache->mem_cache.first; - pm= pid->cache->mem_cache.first; - while(pm) { if(pm->frame >= sta && pm->frame <= end) cache->cached_frames[pm->frame-sta] = 1; |