Fix [#21679] add_grid "operator's subdivison" Change Dimensions
authorMatt Ebb <matt@mke3.net>
Mon, 29 Mar 2010 05:00:04 +0000 (05:00 +0000)
committerMatt Ebb <matt@mke3.net>
Mon, 29 Mar 2010 05:00:04 +0000 (05:00 +0000)
source/blender/editors/mesh/editmesh_add.c
source/blender/editors/mesh/editmesh_mods.c

index e059145393a68da0d45da7b08b97a986926583ec..c2e98e97e091c48f68703275bea992cc1ef8f03a 100644 (file)
@@ -996,25 +996,23 @@ static void make_prim(Object *obedit, int type, float mat[4][4], int tot, int se
                        eve->f= 0;
                        eve= eve->next;
                }
-               /* one segment first: the X axis */
-               phi= 1.0; 
-               phid= 2.0/((float)tot-1);
+               
+               /* one segment first: the X axis */             
+               phi = (2*dia)/(float)(tot-1);
+               phid = (2*dia)/(float)(seg-1);
                for(a=0;a<tot;a++) {
-                       vec[0]= dia*phi;
+                       vec[0] = (phi*a) - dia;
                        vec[1]= - dia;
                        vec[2]= 0.0f;
-                       mul_m4_v3(mat,vec);
                        eve= addvertlist(em, vec, NULL);
                        eve->f= 1+2+4;
                        if (a) {
                                addedgelist(em, eve->prev, eve, NULL);
                        }
-                       phi-=phid;
                }
                /* extrude and translate */
                vec[0]= vec[2]= 0.0;
-               vec[1]= dia*phid;
-               mul_mat3_m4_v3(mat, vec);
+               vec[1]= phid;
                
                for(a=0;a<seg-1;a++) {
                        extrudeflag_vert(obedit, em, 2, nor, 0);        // nor unused
index 06e8b118495860a667b7f26e52694df74d3806e3..e9437bfce8a67f586f73718848bc12d85d9a838c 100644 (file)
@@ -4541,7 +4541,7 @@ void MESH_OT_solidify(wmOperatorType *ot)
        /* flags */
        ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO;
 
-       prop= RNA_def_float(ot->srna, "thickness", 0.01f, -FLT_MAX, FLT_MAX, "thickness", "", -10.0f, 10.0f);
+       prop= RNA_def_float(ot->srna, "thickness", 0.01f, -FLT_MAX, FLT_MAX, "Thickness", "", -10.0f, 10.0f);
        RNA_def_property_ui_range(prop, -10, 10, 0.1, 4);
 }