Campbell Barton
4401ac8c9e
finish moving bevel code out of the operator dir (it works again)
2012-11-18 08:35:27 +00:00
Campbell Barton
9a74fb5b05
moving bevel to tools dir as-is to keep svn history (breaks build, will fix next).
2012-11-18 08:20:02 +00:00
Campbell Barton
916039f520
move decimator into tools/ dir
2012-11-18 08:16:09 +00:00
Campbell Barton
b867f9f17e
style cleanup: comments & spelling
2012-11-18 01:22:31 +00:00
Campbell Barton
c3c14f862b
use quad-strip for filling even when no segments are being added, this gives quad-loops along the bevel whereas before it made ngons.
2012-11-16 21:25:11 +00:00
Campbell Barton
6de13de7ab
more straightforward way to implement quad-strip face filling suggested by Howard Trickey,
...
also some other changes - no need to check the new loops face is larger and no longer split up the ngon more times then there are subdivisions in the face strip (now ngons will remain on both sides).
2012-11-16 21:05:27 +00:00
Campbell Barton
dc06523622
rework the bevel quad strip logic to work with ngons correctly, previously it only worked properly with triangles.
2012-11-16 14:28:37 +00:00
Campbell Barton
8928344bf7
fix for own bug in quad-stip fill method, quad strips were skewed.
2012-11-16 13:41:21 +00:00
Campbell Barton
b7dbf83d19
more minor improvements to bevel use of math functions
2012-11-16 12:33:24 +00:00
Campbell Barton
6b0c200403
code cleanup: remove unneeded normalize (face normal), and unneeded call to len_v3v3
2012-11-16 12:25:15 +00:00
Campbell Barton
3edbd1d0e2
bevel: save some memory by aligning struct members.
2012-11-16 10:15:25 +00:00
Campbell Barton
f5b356bf18
wip - alternate bevel curve calculation (still disabled)
...
now USE_ALTERNATE_ADJ works, giving more stable corners that don't flicker and glitch out as the offset changes.
The shape is not a circle though and doesnt look quite as nice as the existing method.
2012-11-16 08:12:06 +00:00
Campbell Barton
b3f6c12136
bevel: wip ifdef'd code to test an alternative method of placing corner vertices.
2012-11-15 23:21:21 +00:00
Campbell Barton
8270592fa4
code cleanup: some renaming to avoid confusion.
2012-11-15 22:32:29 +00:00
Campbell Barton
987f6a7d4f
code cleanup: move local math functions into math_geom.c, math_vector.c, no functional changes.
2012-11-15 13:24:14 +00:00
Campbell Barton
283ee53085
fix for deleting lines hanging the text editor when no markers are used, presence of markers still hangs.
...
also compiler warnings and some style edits.
2012-11-15 02:11:40 +00:00
Howard Trickey
cd8584aad5
Fix 'polygon eating' problem in bevel (bug #33141 )
...
which was due to almost-parallel lines.
2012-11-15 02:05:32 +00:00
Campbell Barton
a286afe75d
use memarena for bevel allocs
2012-11-14 11:06:58 +00:00
Campbell Barton
7295d98e07
use ghash for bevel verts, saves list lookups when getting a BMVert's BevVert
2012-11-14 10:23:38 +00:00
Campbell Barton
0163ae1701
speedup bevel by tagging verts and edges to bevel, this avoids a loop over all bevel edges for each bevel vert (can use edges-of-vert instead)
2012-11-14 10:08:39 +00:00
Campbell Barton
7c3db355b1
remove ifdef'd bevel code, current bevel works better then the previous code.
...
reduce strlen check in texttool_suggest_add()
use 'del list[:]' rather then 'list[:] = []' in python scripts which clear lists.
2012-11-14 09:45:15 +00:00
Campbell Barton
66aa7e9192
add simple quad-strip filling to bevel, use to bevel edges when 2 bevel-edges share a vertex.
...
this gives more useful topology, eg:
http://www.graphicall.org/ftp/ideasman42/bevel_strip_fill.png
2012-11-12 16:08:02 +00:00
Campbell Barton
0364a83771
fan filling didnt always work well, now only apply this when its going to work properly.
2012-11-12 12:30:58 +00:00
Campbell Barton
fbdae9ca0a
change bevel do/while loops to step the pointer in the while check, no functional changes.
2012-11-12 12:16:21 +00:00
Campbell Barton
08ec3ab64e
bevel fan fill edges meeting non selected geometry rather then making ngons which often dont triangulate nicely to follow rounded corners: http://www.graphicall.org/ftp/ideasman42/bevel_fan_fill.png
2012-11-12 11:59:28 +00:00
Campbell Barton
cf6994b910
code cleanup: spelling,
...
also initialize bmesh-bevel settings struct to zero to avoid possible uninitialized memory later.
2012-11-12 07:33:01 +00:00
Campbell Barton
0bfc92ff8e
BM_iter_as_arrayN() can now take an optional existing array argument, useful to avoid many small malloc's by passing a fixes size stack variable instead.
...
Will give some speedup to edge-split modifier and bevel.
2012-11-12 05:53:43 +00:00
Campbell Barton
428e5b7a99
bmesh bevel todo: don't loop through all faces to find faces connected to a vertex.
2012-11-12 05:29:54 +00:00
Campbell Barton
97b7154142
replace BM_edge_face_count with BM_edge_is_manifold/BM_edge_is_wire/BM_edge_is_boundary
2012-11-12 04:50:45 +00:00
Campbell Barton
744378483c
style cleanup
2012-11-12 03:41:25 +00:00
Campbell Barton
d22c5d4341
update to python api Gotcha docs to reflect changes to the api. also add a section about modifying linked library data.
2012-11-12 03:23:47 +00:00
Howard Trickey
b747759698
Bevel: several bug fixes.
2012-11-12 02:52:24 +00:00
Campbell Barton
89845f280f
fix [ #33142 ] Ctrl LMB higher selection mode in edit mode sometimes selects extra elements
2012-11-11 23:33:59 +00:00
Howard Trickey
b67a297d33
Bevel: use library plane/line intersection instead of custom one.
...
Custom one had a bug, not worth tracking down.
2012-11-09 16:00:30 +00:00
Campbell Barton
6cdb555e6e
bmesh refactor - rename some of the BM_****_share_****_count() functions to BM_***_share_check()
...
some of these were only returning a boolean, others returned a count even though only a boolean was needed.
split some of the functions in two as well where check/count are both needed.
2012-11-09 14:52:05 +00:00
Campbell Barton
2bb174cfa4
style cleanup: indentation
2012-11-09 09:33:28 +00:00
Campbell Barton
eff734203f
add fallbacks for BM_vert_calc_shell_factor() and BM_vert_calc_mean_tagged_edge_length() to avoid divide by zero when a vertex has no connected geometry.
...
also style cleanup.
2012-11-09 08:28:14 +00:00
Campbell Barton
11a5c909f8
code cleanup: move shrinkwrap's benchmark macro into PIL_time.h & some minor style edits.
2012-11-09 04:01:19 +00:00
Campbell Barton
610d746c12
code cleanup: double promotion warnings with new bevel code & wrong use of NULL in cycles.
2012-11-09 03:08:02 +00:00
Campbell Barton
365935bfdd
style cleanup
2012-11-08 16:00:18 +00:00
Howard Trickey
da4441f7c5
Merge gsoc Bevel (with rounding) into trunk.
2012-11-08 15:12:21 +00:00
Campbell Barton
ae06e2cf9b
fix [ #33000 ] bmesh.ops.create_* either crash blender or do nothing
2012-11-08 10:32:11 +00:00
Campbell Barton
09cce17d84
decimator - merge flags when collapsing edges / verts, so seams and edges draw flags are kept.
2012-11-08 07:06:08 +00:00
Campbell Barton
617a73c573
code cleanup: unused defines & some formatting.
2012-11-08 06:46:10 +00:00
Campbell Barton
c0fb605a04
fix [ #26472 ] Decimate overlaps polygons
2012-11-07 22:39:47 +00:00
Campbell Barton
620a78c106
decimate - degenerate edges are now added back into the heap (with an dummy cost), so when surrounding geometry may be modified and the previously degenerate edge re-evaluated after.
...
The C++ LOD decimator did this too.
2012-11-07 22:28:50 +00:00
Campbell Barton
f727448e10
fix [ #33106 ] Decimate modifier/collapse give bad result
...
FLT_EPSILON was too small to use when checking if the edge collapse result is an error.
add invert_m3_m3_ex(), invert_m3_ex() functiosn which take an epsilon to check the determinant, saves calculating it twice per edge collapse.
2012-11-07 09:28:59 +00:00
Campbell Barton
efc44d0c4d
decimator - interpolate vertex normals rather then re-calculating them. faster and means degenerate faces wont explode.
2012-11-07 07:16:28 +00:00
Campbell Barton
be367890f7
decimator - no need to check abs() on normal length.
2012-11-07 06:28:46 +00:00
Campbell Barton
a9fb70754f
avoid using function calls in macros that result in multiple function calls.
2012-11-06 00:18:01 +00:00