Commit Graph

249 Commits

Author SHA1 Message Date
Nicholas Bishop
1de76baf88 Add BMesh and WM symmetrize operators
* The symmetrize operation makes the input mesh elements symmetrical,
  but unlike mirroring it only copies in one direction. The edges and
  faces that cross the plane of symmetry are split as needed to
  enforce symmetry.

* The symmetrize operator can be controlled with the "direction"
  property, which combines the choices of symmetry plane and
  positive-negative/negative-positive. The enum for this is
  BMO_SymmDirection.

* Added menu items in the top-level Mesh menu and the WKEY specials
  menu.

* Documentation:
  http://wiki.blender.org/index.php/User:Nicholasbishop/Symmetrize

* Reviewed by Brecht:
  https://codereview.appspot.com/6618059
2012-10-15 23:50:09 +00:00
Joshua Leung
977aaeb95c Streamlinining Bone Groups menu (Ctrl G)
The Ctrl-G menu for managing Bone Groups has always been a bit clunky,
especially when compared to the Hooks menu (Ctrl-H). This was because the old
menu was more data-orientated (Bone Group Management, Membership to these
groups) whereas this new arrangement should be a bit more task-orientated (Add
to new group, Add to active group, Remove from all groups, Remove active group).
2012-10-15 02:01:39 +00:00
Campbell Barton
643f331cb5 Rip-fill mesh tool (option for rip operator)
Alt+V will fill the area inbetween the ripped faces - a bit like extrude.
faces are flipped to match existing geometry and customdata (uv, vcols etc) is copied from surrounding geometry too.
2012-10-14 04:42:11 +00:00
Joshua Leung
b6b2f37f27 Lattice Editing: Distortion-Free "Flip" Operator
This operator (Ctrl-F) allows you to flip the lattice coordinates without
inverting the normals of meshes deformed by the lattice (or the lattice's
deformation space for that matter). Unlike the traditional mirror tool, this
tool is aware of the fact that the vertex order for lattice control points
matters, and that simply mirroring the coordinates will only cause the lattice
to have an inverted deform along a particular axis (i.e. it will be scaling by a
negative scaling factor along that axis).

The problems (as I discovered the other day) with having such an inverted
deformation space are that:
- the normals of meshes/objects inside that will be incorrect/flipped (and will
disappear in GLSL shading mode for instance)
- transforming objects deformed by the lattices will become really tricky and
counter-intuitive (e.g. rotate in opposite direction by asymmetric amounts to
get desired result)
- it is not always immediately obvious that problems have occurred

Specific use cases this operator is meant to solve:
1) You've created a lattice-based deformer for one cartoonish eye. Now you want
to make the second eye, but want to save some time crafting that basic shape
again but mirrored.
2) You've got an even more finely crafted setup for stretchy-rigs, and now need
to apply it to other parts of the rig.

Notes:
* I've implemented a separate operator for this vs extending/patching mirror
transform tool as it's easier to implement this way, but also because there are
still some cases where the old mirroring seems valid (i.e. you explicitly want
these sort of distortion effects).
* Currently this doesn't take selections into account, as it doesn't seem useful
to do so.
2012-10-13 10:42:38 +00:00
Campbell Barton
d81d75b20d transfer weight's now operates on selected vertices (when vertex select is enabled). 2012-10-09 22:55:05 +00:00
Campbell Barton
8730b390fb patch [#31919] limit the number of bone deform weights per vertex. Many game engines require a limit of 4.
from Kesten Broughton (kestion)


Usage: In weight paint mode, select the mesh to have its weights culled. Click on "Limit Weights" button. A sub-panel will appear "Limit Number of Vertex Weights" with a slider field "Limit" which you can set to the appropriate level. The default level is 4, and it gets executed upon pressing "Limit Weights" so you will need to do an "undo" if your max bone limit is above 4. The checkbox "All Deform Weights" will consider all vertex weights, not just bone deform weights.
2012-10-09 10:56:35 +00:00
Campbell Barton
9fa36b12cc style cleanup: pep8 2012-10-08 08:28:05 +00:00
Joshua Leung
d2833d9f0f Added convenience operator to clear animation (i.e. all keyframes = F-Curves)
from selected objects and bones
2012-10-04 10:58:03 +00:00
Brecht Van Lommel
56476248b6 Fix #32601: armature select similar missing from select menu. 2012-09-20 00:10:26 +00:00
Campbell Barton
6143acf878 hook menu was using last remembered use_bone setting 2012-08-22 15:38:03 +00:00
Campbell Barton
b0371f053c style cleanup 2012-08-17 18:36:20 +00:00
Campbell Barton
7d3e854aeb add hook now has option to add to active bone (mango request). 2012-08-13 08:54:33 +00:00
Campbell Barton
4ef8f3f537 code cleanup: assign mode to a variable in the 3d view header and remove some unused imports 2012-07-29 14:07:57 +00:00
Campbell Barton
2553cdf195 style cleanup 2012-07-29 12:07:06 +00:00
Thomas Dinges
ab38e1d379 User Interface Scripts:
* Code cleanup, removed unneeded code.
* Style cleanup, don't break lines to early 
(unless marked as pep8-80 or pep8-120 compliant) 
* Keep 1 line after layout declaration empty.
2012-07-29 10:03:46 +00:00
Thomas Dinges
2738fa99e7 3D View / Edges menu:
* Removed a redundant "Edge Crease" entry and some code cleanup.
2012-07-12 16:19:29 +00:00
Campbell Barton
2a140e93c1 style cleanup 2012-07-04 21:41:05 +00:00
Campbell Barton
72f7ab441d removing from group now shows menu to select group to remove. 2012-06-20 14:13:22 +00:00
Campbell Barton
98e6912480 style cleanup 2012-06-19 22:17:19 +00:00
Campbell Barton
46ea5670db scale node - framing offset: compatible with camera shiftX/Y and the viewport option. 2012-06-15 07:50:27 +00:00
Campbell Barton
2e72720718 apply offset to the camera view - this works exactly like camera shift (transforms X/Y in the same space). 2012-06-13 13:23:48 +00:00
Campbell Barton
91781c76c4 framing options for camera background image: stretch/fit/crop 2012-06-13 12:58:01 +00:00
Brecht Van Lommel
19dd66cf3b 3D View: add Backface Culling option, to hide faces when seen from the back side,
found in the Display panel.

Patch by Simon Kirk and Irie Shinsuke, refactored to also work for non-mesh objects
and avoid globals.
2012-05-25 09:26:47 +00:00
Thomas Dinges
03ed173fe6 3D View UI:
* Remove redundant "Delete" for Edge Loop in the Delete (X) menu.
2012-05-18 21:13:22 +00:00
Campbell Barton
eb22b52482 style cleanup: pep8 2012-05-15 18:50:51 +00:00
Campbell Barton
e79c29a1d6 style cleanup: raytree code 2012-05-15 18:45:20 +00:00
Sergey Sharybin
8496162cef Fix for second part of #31445: Surface "Control Points" menu is empty
The only difference that it should be Select Linked All operator added to the menu
2012-05-15 15:34:49 +00:00
Sergey Sharybin
fbea5692ea Fix #31445: Surface "Control Points" menu is empty
It is possible to create hook for surfaces, so display this entry
in Control points menu.
2012-05-15 15:28:59 +00:00
Bastien Montagne
800bc74a8f Adds “align” option to snap to verts/edges/faces, for bones in Pose mode.
Have to use a ugly hack, as for pose bones, rotscale transform matrix is not always the same as translate one... :/

Adresses feature request [#30979] snapping: "align rotation with the snapping target" and pose-mode.
2012-05-13 16:01:59 +00:00
Campbell Barton
9004f9f998 add access to bevel weight modal operator (only available in the Shift+E edge menu currently) 2012-05-12 23:07:52 +00:00
Thomas Dinges
ed12a5d001 3D View:
* Changed Duplicate and Exture Operator fpr Curves/Surfaces to Duplicate/Extrude and Move, like for Mesh objects, for consistency. This is also consistent with Shift+D and E shortcut. 

This fixes [#31429] Curve menu polish.

* Fixed a wrong tooltip for metaball duplication.
2012-05-12 20:50:46 +00:00
Nicholas Bishop
ee9f917f08 Add keymap and menu entries for masking.
* Add CTRL+IKEY to invert the mask.

* Add ALT+MKEY to clear the mask.

* Change the 'Hide' menu in sculpt mode to 'Hide/Mask', adds entires
  for clearing, filling, and inverting the mask, as well as hiding
  masked regions.
2012-05-10 20:36:13 +00:00
Bastien Montagne
1118b3fe3f Mesh elements sorting refactor.
Now only one operator. Same options for vertices, edges and faces (so adds edges sorting, and some options to vertices sorting).

Face sorting should behave as previously. However, XSortVerts won’t pack anymore selected vertices at the begining of the vert array (as it used to), if you want such behavior you’ll have to first run SortElements with Selected action.

Also added bug ref I forgot in r46354 (armature.c).
2012-05-06 17:14:56 +00:00
Campbell Barton
e17a708dce add back pose specials menu, also add back the ability to clear user transforms on all bones (not just selected - mango request - was possible in 2.4x).
- rename only_select op property to only_selected (both were used).
- only do mingw workaround when building with FREE_WINDOWS defined.
2012-05-06 12:13:45 +00:00
Joshua Leung
1cf2c099f7 Bugfix [#31297] Transform menu often showed operators which didn't make sense
for the contexts they appeared in

The VIEW3D_MT_transform menu was being used everywhere, although not all the
operators there applied to the current mode (e.g. the pivot point, animated
transforms to deltas, and a few others were Object-mode only). Split off the
offending parts into separate menus for the specific modes, and made these
extend the basic menu type.
2012-05-06 06:37:07 +00:00
Bastien Montagne
e9ac31bee4 Fix [#31322] Assign to Active Group adds new group 2012-05-05 17:33:18 +00:00
Campbell Barton
9b37bf21f4 feature request from VenomGfx- lock to active as an operator since its tedious setting the object and bone manually (especially if you have it right in front of you)
uses keys
- Shift+PadPeriod --- to set
- Alt+PadPeriod --- to clear (also clears cursor and camera locking)
2012-05-05 16:38:23 +00:00
Sergey Sharybin
f9663b744e Do not stick normal length slider in 3d viewport properties to display normals buttons 2012-05-01 09:38:29 +00:00
Brecht Van Lommel
144534eda8 Fix #31180: limit selection to visible button in 3d header not showing up in
material draw mode.
2012-04-30 14:52:30 +00:00
Campbell Barton
41a5e731a2 bmesh: new wireframe tool
- makes wireframe from faces.
- options similar to inset (even offset, relative scale)
- copies face settings and loops (uvs, vcolors)
- optionally replaces the existing geometry.
2012-04-29 10:44:00 +00:00
Campbell Barton
c2ede58d68 fix [#31083] "Hide Selected" through Menu Operation doesn't work well 2012-04-24 17:50:01 +00:00
Campbell Barton
6f1019e869 add inset and bridge to mesh specials menu (along side bevel) + typo fix. 2012-04-24 01:04:37 +00:00
Campbell Barton
37a79f4727 fix [#30972] Editmesh split by materials not working. 2012-04-16 13:49:04 +00:00
Bastien Montagne
20110e703e Do not hide (gray out) lens/lock to object/lock to cursor options in Quad views (View panel)... 2012-04-13 15:21:26 +00:00
Brecht Van Lommel
a52ba57b4d Fix for recent commit that changed normal display buttons to use icons, the
vertex/face icons were swapped.
2012-04-10 17:01:35 +00:00
Brecht Van Lommel
93e00af7e5 Fix #30850: bevel tool only works on edges but tooltip indicated it worked on
vertices too, fixed tooltip. Also add bevel to edge menu since it works edge
based.
2012-04-10 15:51:22 +00:00
Sergey Sharybin
4795f4b9ac mango request: option to draw background in front of all objects in the viewport.
Should be really handy for painting clean plates.
2012-04-10 14:59:06 +00:00
Campbell Barton
044b0ef2f2 use space more efficiently for normal mesh panel buttons (icons for face/vert normal) 2012-04-10 11:36:19 +00:00
Campbell Barton
01e55b6fc3 code cleanup: remove unused imports/defines + other redundant code. 2012-04-08 13:11:25 +00:00
Thomas Dinges
32c5b09192 Fix [#30851] Mesh Editmode: Specials-menu lost "Subdivide smooth"
* Subdivide Smooth was missing in the edit mode specials menu since B-Mesh merge.
2012-04-07 14:04:52 +00:00