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
path: root/source
diff options
context:
space:
mode:
authorJohnny Matthews <johnny.matthews@gmail.com>2005-08-23 18:13:00 +0400
committerJohnny Matthews <johnny.matthews@gmail.com>2005-08-23 18:13:00 +0400
commit2540ca88e8521cc00ee77760d8ccf213928f849a (patch)
tree170a384a0ffc839331f171469b4916b4105ab2d2 /source
parent056a33ac699f0393b87503536b5492f03fd6b55a (diff)
Quad Adjacent edge subdivide type moved to Mesh Tools panel rather than pupmenu on all subdiv calls. This is a session value like beauty and will revert to path each time you load blender.
Diffstat (limited to 'source')
-rw-r--r--source/blender/src/buttons_editing.c13
-rw-r--r--source/blender/src/editmesh_tools.c14
2 files changed, 14 insertions, 13 deletions
diff --git a/source/blender/src/buttons_editing.c b/source/blender/src/buttons_editing.c
index 6063d751b94..822ca7d5709 100644
--- a/source/blender/src/buttons_editing.c
+++ b/source/blender/src/buttons_editing.c
@@ -155,6 +155,7 @@ static short degr= 90, step= 9, turn= 1;
static float extr_offs= 1.0;
static float editbutweight=1.0;
short editbutflag= 1;
+short cornertype = 0;
float doublimit= 0.001, editbutvweight=1;
float uv_calc_radius= 1.0, uv_calc_cubesize= 1.0;
short uv_calc_mapdir= 1, uv_calc_mapalign= 1, facesel_draw_edges= 0;
@@ -2528,11 +2529,15 @@ static void editing_panel_mesh_tools(Object *ob, Mesh *me)
uiDefButBitS(block, TOG, B_BEAUTY_SHORT, 0, "Short", 50,195,40,19, &editbutflag, 0, 0, 0, 0, "Causes 'Subdivide' to split faces in halves instead of quarters using Short Edges");
uiDefBut(block, BUT,B_SUBDIV,"Subdivide", 90,195,80,19, 0, 0, 0, 0, 0, "Splits selected faces into halves or quarters");
- uiDefBut(block, BUT,B_FRACSUBDIV, "Fract Subd", 170,195,85,19, 0, 0, 0, 0, 0, "Subdivides selected faces with a random factor");
- uiDefBut(block, BUT,B_VERTEXNOISE,"Noise", 10,175,80,19, 0, 0, 0, 0, 0, "Use vertex coordinate as texture coordinate");
- uiDefBut(block, BUT,B_HASH,"Hash", 90,175,80,19, 0, 0, 0, 0, 0, "Randomizes selected vertice sequence data");
- uiDefBut(block, BUT,B_XSORT,"Xsort", 170,175,85,19, 0, 0, 0, 0, 0, "Sorts selected vertice data in the X direction");
+ uiDefButS(block, MENU, B_DIFF, "Corner Cut Type %t|Path %x0|Innervert %x1|Fan %x2",
+ 170, 195, 85, 19, &cornertype, 0, 0, 0, 0, "Choose Quad Corner Cut Type");
+
+ uiDefBut(block, BUT,B_VERTEXNOISE,"Noise", 10,175,60,19, 0, 0, 0, 0, 0, "Use vertex coordinate as texture coordinate");
+ uiDefBut(block, BUT,B_HASH,"Hash", 70,175,60,19, 0, 0, 0, 0, 0, "Randomizes selected vertice sequence data");
+ uiDefBut(block, BUT,B_XSORT,"Xsort", 130,175,60,19, 0, 0, 0, 0, 0, "Sorts selected vertice data in the X direction");
+ uiDefBut(block, BUT,B_FRACSUBDIV, "Fractal", 190,175,65,19, 0, 0, 0, 0, 0, "Subdivides selected faces with a random factor");
+
uiDefBut(block, BUT,B_TOSPHERE,"To Sphere", 10,155,80,19, 0, 0, 0, 0, 0, "Moves selected vertices outwards into a spherical shape");
uiDefBut(block, BUT,B_VERTEXSMOOTH,"Smooth", 90,155,80,19, 0, 0, 0, 0, 0, "Flattens angles of selected faces");
diff --git a/source/blender/src/editmesh_tools.c b/source/blender/src/editmesh_tools.c
index 69b08840707..472b1375da5 100644
--- a/source/blender/src/editmesh_tools.c
+++ b/source/blender/src/editmesh_tools.c
@@ -2288,9 +2288,8 @@ void esubdivideflag(int flag, float rad, int beauty, int numcuts, int seltype)
struct GHash *gh;
int i,j,edgecount,facetype,hold;
float length[4];
- short cornerval=1;
+ extern short cornertype;
- cornerval = pupmenu("Quad Corners%t|Path%x1|Innervert%x2|Fan%x3");
//Set faces f1 to 0 cause we need it later
for(ef=em->faces.first;ef;ef = ef->next){
@@ -2368,9 +2367,6 @@ void esubdivideflag(int flag, float rad, int beauty, int numcuts, int seltype)
}
}
-
-
-
gh = BLI_ghash_new(BLI_ghashutil_ptrhash, BLI_ghashutil_ptrcmp);
// If we are knifing, We only need the selected edges that were cut, so deselect if it was not cut
@@ -2431,10 +2427,10 @@ void esubdivideflag(int flag, float rad, int beauty, int numcuts, int seltype)
(ef->e2->f & flag && ef->e4->f & flag)){
fill_quad_double_op(ef, gh, numcuts);
}else{
- switch(cornerval){
- case 1: fill_quad_double_adj_path(ef, gh, numcuts); break;
- case 2: fill_quad_double_adj_inner(ef, gh, numcuts); break;
- case 3: fill_quad_double_adj_fan(ef, gh, numcuts); break;
+ switch(cornertype){
+ case 0: fill_quad_double_adj_path(ef, gh, numcuts); break;
+ case 1: fill_quad_double_adj_inner(ef, gh, numcuts); break;
+ case 2: fill_quad_double_adj_fan(ef, gh, numcuts); break;
}
}