[Bf-committers] Making edgeloop, Faceloop, and Knife compatable...
Robert Wenzlaff
bf-committers@blender.org
Mon, 15 Sep 2003 09:35:44 -0400
This is primarily for Goofster, but I haven't seen him around since the
meeting;
I split the mouse reading code from my KnifeSubdivide to a sep. function that
returns generic data.
CutCurve *get_mouse_trail(int *length);
It returns a pointer to an length long array of structs of mouse screen coords
(members .x, .y). I've change the behavior so it returns on RETKEY, that way
all tools that use it will have similar behavior ( Hotkey or menu selection,
draw, enter ). Changing icons, and freeing the block when done are the job
of the caller.
The question is, where should this function live? It seems out of place in
editmesh.c. My bet is it belongs with borderselect() in editview.c . Any
thoughts?
As far as modifying them to cut at the mouse crossing instead of 50%.
We are both using the existing subdivideflag() routine. We could define a
beauty flag bit of B_PERCENTCUT, and set the eed-f to a value indicating the
relative percentage (or some other scalable int unit) of the cut from eed-v1
to eed->v2. I have to look further at subdivideflag() to see how to
impliment moving the cut to that point.
I've already figured out the UV remapping, so a new set_wuv_fact(evl, val1,
val2, f1, val3, val4, f2 [, f3] ) function can be written. f1 is the
percentage of distance from val1 to val2 the cut occurs at, val1-4 use the
numbering scheme from vert_from_number(). f3 could be the percentage between
the two vn's, but I don't see any reason why it would ever be anything other
than 0.5
--
********************************************
Robert Wenzlaff rwenzlaff@soylent-green.com