Cleaned up unused variables

This commit is contained in:
Howard Trickey
2011-08-25 16:47:47 +00:00
parent fd0c9afdd1
commit fe98769877
8 changed files with 10 additions and 25 deletions

View File

@@ -1301,7 +1301,6 @@ static void bmDM_copyFaceArray(DerivedMesh *dm, MFace *face_r)
static void bmDM_copyLoopArray(DerivedMesh *dm, MLoop *loop_r)
{
EditDerivedBMesh *bmdm = (EditDerivedBMesh *)dm;
BMesh *bm = ((EditDerivedBMesh *)dm)->tc->bm;
BMIter iter, liter;
BMVert *v;
@@ -1332,7 +1331,6 @@ static void bmDM_copyLoopArray(DerivedMesh *dm, MLoop *loop_r)
static void bmDM_copyPolyArray(DerivedMesh *dm, MPoly *poly_r)
{
EditDerivedBMesh *bmdm = (EditDerivedBMesh *)dm;
BMesh *bm = ((EditDerivedBMesh *)dm)->tc->bm;
BMIter iter;
BMFace *f;

View File

@@ -972,7 +972,6 @@ void multires_set_space(DerivedMesh *dm, Object *ob, int from, int to)
for(S = 0; S < numVerts; ++S, ++gIndex, ++k) {
MDisps *mdisp = &mdisps[mpoly[i].loopstart+S];
DMGridData *grid = gridData[gIndex];
DMGridData *subgrid = subGridData[gIndex];
float (*dispgrid)[3] = NULL;

View File

@@ -499,7 +499,6 @@ static int ss_sync_from_derivedmesh(CCGSubSurf *ss, DerivedMesh *dm,
BLI_array_declare(fVerts);
MVert *mvert = dm->getVertArray(dm);
MEdge *medge = dm->getEdgeArray(dm);
MFace *mface = dm->getTessFaceArray(dm);
MVert *mv;
MEdge *me;
MLoop *mloop = dm->getLoopArray(dm), *ml;
@@ -1113,7 +1112,6 @@ static void ccgDM_copyFinalLoopArray(DerivedMesh *dm, MLoop *mloop)
int edgeSize = ccgSubSurf_getEdgeSize(ss);
int i = 0;
MLoop *mv;
char *faceFlags = cgdm->faceFlags;
if (!cgdm->ehash) {
MEdge *medge;
@@ -1131,8 +1129,6 @@ static void ccgDM_copyFinalLoopArray(DerivedMesh *dm, MLoop *mloop)
for(index = 0; index < totface; index++) {
CCGFace *f = cgdm->faceMap[index].face;
int x, y, S, numVerts = ccgSubSurf_getFaceNumVerts(f);
int flag = (faceFlags)? faceFlags[index*2]: ME_SMOOTH;
int mat_nr = (faceFlags)? faceFlags[index*2+1]: 0;
for(S = 0; S < numVerts; S++) {
for(y = 0; y < gridSize - 1; y++) {
@@ -1178,7 +1174,6 @@ static void ccgDM_copyFinalPolyArray(DerivedMesh *dm, MPoly *mface)
int index;
int totface;
int gridSize = ccgSubSurf_getGridSize(ss);
int edgeSize = ccgSubSurf_getEdgeSize(ss);
int i = 0, k = 0;
char *faceFlags = cgdm->faceFlags;

View File

@@ -142,8 +142,7 @@ void bmesh_bridge_loops_exec(BMesh *bm, BMOperator *op)
BMO_ITER(e, &siter, bm, op, "edges", BM_EDGE) {
if (!BMO_TestFlag(bm, e, EDGE_DONE)) {
BMVert *v, *ov;
BMEdge *e2, *e3, *oe = e;
int i;
BMEdge *e2, *e3;
if (c > 2) {
printf("eek! more than two edge loops!\n");

View File

@@ -1155,8 +1155,6 @@ static KnifeEdge *knife_find_closest_edge(knifetool_opdata *kcd, float p[3], BMF
*fptr = f;
if (cure && p) {
float d;
if (!kcd->ignore_edge_snapping || !(cure->e)) {
if (kcd->snap_midpoints) {
interp_v3_v3v3(p, cure->v1->co, cure->v2->co, 0.5f);

View File

@@ -279,16 +279,15 @@ typedef struct StrokeCache {
static int sculpt_get_redraw_rect(ARegion *ar, RegionView3D *rv3d,
Object *ob, rcti *rect)
{
StrokeCache *cache = ob->sculpt->cache;
PBVH *pbvh= ob->sculpt->pbvh;
float bb_min[3], bb_max[3], pmat[4][4];
int i, j, k;
/* if (G.rt == 1) {
rect->xmin = cache->prect.xmin;
rect->xmax = cache->prect.xmax;
rect->ymin = cache->prect.ymin;
rect->ymax = cache->prect.ymax;
rect->xmin = ob->sculpt->cache->prect.xmin;
rect->xmax = ob->sculpt->cache->prect.xmax;
rect->ymin = ob->sculpt->cache->prect.ymin;
rect->ymax = ob->sculpt->cache->prect.ymax;
return rect->xmin < rect->xmax && rect->ymin < rect->ymax;;
}
@@ -2240,8 +2239,6 @@ static void do_scrape_brush(Sculpt *sd, Object *ob, PBVHNode **nodes, int totnod
{
SculptSession *ss = ob->sculpt;
Brush *brush = paint_brush(&sd->paint);
rctf mr;
float xrad, yrad;
float bstrength = ss->cache->bstrength;
const float radius = ss->cache->radius;

View File

@@ -606,7 +606,6 @@ static void rna_MeshTextureFaceLayer_clone_set(PointerRNA *ptr, int value)
static void rna_MeshTextureFaceLayer_name_set(PointerRNA *ptr, const char *value)
{
Mesh *me= (Mesh*)ptr->id.data;
CustomData *fdata= rna_mesh_pdata(me);
CustomDataLayer *cdl= (CustomDataLayer*)ptr->data;
BLI_strncpy(cdl->name, value, sizeof(cdl->name));
CustomData_set_layer_unique_name(&me->pdata, cdl - rna_mesh_pdata(me)->layers);
@@ -643,9 +642,9 @@ static PointerRNA rna_Mesh_active_vertex_color_get(PointerRNA *ptr)
static void rna_Mesh_active_vertex_color_set(PointerRNA *ptr, PointerRNA value)
{
Mesh *me= (Mesh*)ptr->data;
CustomData *ldata= rna_mesh_ldata(me), *fdata;
CustomData *ldata= rna_mesh_ldata(me);
CustomDataLayer *cdl;
int a, b, c;
int a, b;
b = 0;
for(cdl=ldata->layers, a=0; a<ldata->totlayer; cdl++, a++) {
@@ -723,7 +722,6 @@ static void rna_MeshColorLayer_active_set(PointerRNA *ptr, int value)
static void rna_MeshColorLayer_name_set(PointerRNA *ptr, const char *value)
{
Mesh *me= (Mesh*)ptr->id.data;
CustomData *fdata= rna_mesh_pdata(me);
CustomDataLayer *cdl= (CustomDataLayer*)ptr->data;
BLI_strncpy(cdl->name, value, sizeof(cdl->name));
CustomData_set_layer_unique_name(&me->ldata, cdl - rna_mesh_ldata(me)->layers);
@@ -1257,7 +1255,9 @@ static void rna_def_mtexpoly(BlenderRNA *brna)
{TF_ALPHA, "ALPHA", 0, "Alpha", "Render polygon transparent, depending on alpha channel of the texture"},
{TF_CLIP, "CLIPALPHA", 0, "Clip Alpha", "Use the images alpha values clipped with no blending (binary alpha)"},
{0, NULL, 0, NULL, NULL}};
#if 0 /* BMESH_TODO: needed later when do another todo */
int uv_dim[]= {4, 2};
#endif
srna= RNA_def_struct(brna, "MeshTextureFaceLayer", NULL);
RNA_def_struct_ui_text(srna, "Mesh Texture Face Layer", "Layer of texture faces in a Mesh datablock");

View File

@@ -199,7 +199,7 @@ static DerivedMesh *applyModifier(ModifierData *md, Object *ob,
int UNUSED(isFinalCalc))
{
int i;
DerivedMesh *result, *copy, *odm = dm;
DerivedMesh *result, *odm = dm;
const SolidifyModifierData *smd = (SolidifyModifierData*) md;
MVert *mv, *mvert, *orig_mvert;
@@ -215,7 +215,6 @@ static DerivedMesh *applyModifier(ModifierData *md, Object *ob,
/* only use material offsets if we have 2 or more materials */
const short mat_nr_max= ob->totcol > 1 ? ob->totcol - 1 : 0;
const short mat_ofs= mat_nr_max ? smd->mat_ofs : 0;
const short mat_ofs_rim= mat_nr_max ? smd->mat_ofs_rim : 0;
/* use for edges */
int *new_vert_arr= NULL;