Commit Graph

368 Commits

Author SHA1 Message Date
0a6e8a41b9 Enable new bevel tool code in bevel modifier.
Now modifier takes a segments parameter.
Bevel edge weights will multiply the overall amount.
For vertex-only, you can give a vertex group name,
and the weights in that will multiply the overall amount.
2013-02-21 17:29:35 +00:00
b6a60fc6b8 revert own commit, caused regression - hanging on triangulation [#34214].
Postponing further changes for now, too risky before release when unexpected cases can cause eternal loop.
2013-02-13 03:20:30 +00:00
2005f7c6c0 style cleanup: also some typos 2013-02-11 00:49:00 +00:00
555bcc3298 add beauty option for triangle fill since you might want to use the initial scanfill result. 2013-02-09 15:49:20 +00:00
5e05d67436 improve beauty-fill tool for non-flat triangles.
Project the triangle pair into 2d coords before measuring.

before/after - http://www.graphicall.org/ftp/ideasman42/beauty_fill_fix.png
2013-02-09 08:16:13 +00:00
c30fb009cc problem with own changes to triabgulate: calling beauty fill directly would re-allocate the faces which mean't triangulates output slots pointers became invalid. (noticed when using from py api) 2013-02-06 15:57:12 +00:00
e7cead0994 own recent change to triangulate bmesh operator stopped filling in mapping slot 'face_map.out', not used by blender its self but useful for scripts, enable this again. 2013-02-05 11:30:50 +00:00
c649107499 when triangulating ngons, use beauty option to rotate edges. gives much nicer results and means you can preserve original edges without triangulating ngons one at a time 2013-02-03 08:07:14 +00:00
2f53741cfe bridge tool could make bow-tie quads when given 2 isolated edges. 2013-01-30 03:12:19 +00:00
37489d71c7 Triangulate modifier no longer uses bmesh operator api call, instead add a BM_mesh_triangulate() function. Gives ~2x speedup in my tests on an optimized build. 2013-01-29 10:31:05 +00:00
c411cde415 header cleanup, include BLI before BKE, also use bool for ntreeShaderExecTree 2013-01-24 21:57:13 +00:00
00ef8896fd fix for own error in recent BLI_array commit 2013-01-20 16:58:14 +00:00
bc44e81dff fix own bug with uninitialized arrays in subdivide (from recent BLI_array.h update)
also quiet warning.
2013-01-20 08:05:23 +00:00
8496a5a501 replace vertex slide with the transform operator. (MESH_OT_vert_slide -> TRANSFORM_OT_vert_slide) 2013-01-15 03:48:13 +00:00
b27854bd47 use booleans for bmesh api. 2013-01-14 16:42:43 +00:00
9f2e845181 code cleanup: use BMW_begin insode for loops body. 2013-01-14 09:53:56 +00:00
983e5fe5f1 fix for own mistake in recent changes to scanfill, bmo_triangle_fill_exec() (alt+f), was missing BLI_SCANFILL_CALC_HOLES argument.
reported as [#33819]
2013-01-10 14:28:06 +00:00
ab960eea88 Add symmetrize operator for dynamic-topology sculpt mode 2012-12-30 18:31:01 +00:00
4e88bfca1b fix [#33677] Lambda is un-settable for mesh.vertices_smooth_laplacian
lambda is python keyword.
2012-12-28 11:12:46 +00:00
4e5d5e0d84 Add 'vertex_only' option to bevel tool.
Right now, changing segments to > 1 doesn't do anything,
but intend to work on making that cause rounded corners.
2012-12-28 02:45:10 +00:00
84361f602a fix [#33651] Spin tool destroys unselected loose vertex
bmesh.ops.extrude_face_region() didn't check for isolated verts (not connected to geometry), and removed them, happened for Ctrl+LMB extrude too.
2012-12-27 01:02:32 +00:00
2cb39ea9da use BM_face_create() over BM_face_create_ngon() in bevel and extrude individual faces to get some speedup. 2012-12-19 09:45:56 +00:00
bee7c20a97 move edge split into its own function which can be called by the modifier without having to call a bmesh operator (gives some speedup). 2012-12-12 12:57:27 +00:00
b93f02042e use header only tags for edge split (to prepare to move this into tools/) 2012-12-12 12:29:37 +00:00
71730f26d7 replace BLI_array_fixedstack_declare with() new macro BLI_array_alloca() which uses stack memory always and doesn't need to be freed explicitly. 2012-12-11 15:10:19 +00:00
e2f0a1e4db own cleanup commit in bmesh branch - removed last letters from ends of some comments. 2012-12-11 14:24:27 +00:00
0526fcf13f revert part of r52720, Id rather leave these as-is, even if they give warnings under some configurations. 2012-12-03 08:11:04 +00:00
17c2621fd1 bridge tool - simple optimization, break early if edge loop length comparisons are worse then existing best loop test. 2012-12-03 05:02:32 +00:00
a490f4f7c4 fix [#33391] Bridge two Edgeloops fails in simple case 2012-12-03 04:53:30 +00:00
818a345be3 Silent a bunch of gcc warnings (usually dummy, but noisy!). 2012-12-02 16:01:06 +00:00
5446dc0bf3 fix for various asserts running operator tests - not likely any of these would cause real user bugs though. 2012-11-30 16:41:43 +00:00
07ccd3ee3f fix [#33029] Applying modifier leaks memory
Thanks for Sergey for finding the bug & patching, This fix works a bit differently.
Theres no need to allocate the customdata in the first place - since its written into. So add a flag for vert/edge/face/loop creation functions so they can skip customdata creation.
2012-11-29 16:26:39 +00:00
cac253a502 fix for minor annoyance - when extruding a circle there would always be one face flipped, now edges are all ordered in the same direction. 2012-11-28 14:15:54 +00:00
71e7f9028f Copy face attributes when creating new faces in BMO_symmetrize
Fixes bug [#33269] Symmetrize doesnt honor shadesmooth
projects.blender.org/tracker/index.php?func=detail&aid=33269&group_id=9&atid=498
2012-11-28 05:07:04 +00:00
c5a8bd498d use radians for 'spin' bmesh operator (since the rest of the py api uses radians). also rename BMO_OP_SLOT_SUBTYPE_MAP_FLOAT -> BMO_OP_SLOT_SUBTYPE_MAP_FLT for consistency. 2012-11-28 00:47:33 +00:00
8ecce451ab bmesh operator naming - use clearer names for args eg: (mat -> matrix, use_singleedge -> use_single_edge)
also remove duplicate docs for operator arg formatting.
2012-11-28 00:16:06 +00:00
c00a1b7493 use clearer names for 'single' bmesh operator args & add '%e' to BMO_op_vinitf comments. 2012-11-27 09:41:08 +00:00
a9855c227e py/bmesh api - add support for single item buffers (odd feature but used quite a bit with bmesh operators).
also add utility functions BMO_slot_buffer_from_single(), BMO_slot_buffer_get_single()
2012-11-27 09:21:57 +00:00
90666d3436 code cleanup: bmesh operator comments, readying for doc-generation. 2012-11-27 06:53:26 +00:00
9982b283e6 fix for asserts added in own recent commit with more strict type-checking
- BMO_slot_copy now only copies compatible elements.

other minor changes
- don't use text.format(...), convention for UI scripts is C style string formatting.
- rename bmo_edgenet_prepare --> bmo_edgenet_prepare_exec
- float/double warning in bevel.
2012-11-27 02:34:40 +00:00
f8bc346eff bmesh/py operator api:
add type checking for element buffers, there was nothing stopping python from passing any element type into an argument when in some cases only verts/edges/faces were expected.
now operator args define which types they support.
2012-11-27 00:50:59 +00:00
f9e339ef00 fix/workaround [#33281] script goes into not responding
scanfill remove-doubles pass assumes ordered edges (as with curves), otherwise it can hang.
workaround this problem by skipping removing-doubles for mesh ngons, since this isnt such a common case as it is with curves and we can just not support it.
2012-11-26 23:18:04 +00:00
a91814e94d style cleanup 2012-11-26 11:03:14 +00:00
cf2c459325 Fix #33285: loop cut is not supposed to cut through triangles/ngons, but it
still happened  when the loop would go all the way around the mesh with just one
triangle/ngon inbetween to close the loop.
2012-11-26 06:59:59 +00:00
3d64381e4d use more rigid type checking for bmesh slot subtypes. 2012-11-26 03:16:29 +00:00
0446e2571f fix for inset getting bad UV's/VCols at face boundaries. 2012-11-23 05:49:00 +00:00
55535b21fe fix own error - remove doubles slot name. 2012-11-22 01:00:40 +00:00
ebaf1306b8 bmesh operator api:
avoid per vert/edge/face string lookups in BMO_slot_map_* functions --- used in array modifier, subdivide, remove doubles and other tools.
2012-11-20 13:29:27 +00:00
dbdc76c9d0 code cleanup: make bmesh operator names more consistant since python has access to these as input arguments and return values.
all output values currently have ".out" suffix, this may go in the future, but for now it makes it clear in C code what are inputs and outputs.
2012-11-20 05:50:19 +00:00
e8667421ed bmesh operator api edits, add macros and NULL the buffer if BMO_slot_buffer_alloc()'s len is zero. 2012-11-20 03:29:12 +00:00