879889c47c
Correct own error in knife edge-net cutting
...
Need to ensure no duplicate edges in the array.
2015-12-15 18:44:21 +11:00
9df6a539a2
Knife: use BM_face_split_edgenet for detecting holes
...
Knife had its own code for detecting holes which worked quite well,
but would prefer to use generic bmesh API call here.
2015-12-13 03:46:36 +11:00
a28e014313
BMesh: Add API call BM_face_calc_point_in_face
...
Was local to knife code, but this is generally useful.
2015-11-27 22:08:16 +11:00
48b1656a6c
Cleanup: shadowing (editors)
2015-11-23 17:40:50 +11:00
a7ac59414b
Cleanup: rename line to segments, avoids confusion
...
Differentiate between lines and segments.
2015-11-13 07:48:05 +11:00
eb49a76dca
Cleanup: warnings
...
- remove NULL checks for args already set as ATTR_NONNULL.
- double promotion.
2015-10-17 16:06:45 +11:00
85f3b21cc8
error in last commit
2015-10-16 21:57:59 +11:00
7dc80097a4
Fix for missing id_lib_extern, assigning ID's
2015-10-16 21:53:01 +11:00
14de9a5982
Knife tool: generalize angle snapping code
...
Replace hard-coded snap angles with function that allows arbitrary snapping increments.
Currently no user visible change.
2015-10-16 04:04:45 +11:00
df1e9fac06
Fix error w/ printing knife header angle-snapping
2015-10-16 00:41:14 +11:00
741cf193f1
Knife: Improve clamping extents in ortho view
...
- measure extents from mesh center instead of origin.
- use clamping method, guaranteed not to flip the input vectors direction.
- use cage coords when available (since knife operates on the cage).
2015-09-24 13:34:26 +10:00
4493cac21a
Fix T46219: Knife cuts fail away from center
2015-09-24 03:00:52 +10:00
c727fc59ab
BVH-raycast: ensure input direction is unit-length
...
This was already the case for most users of ray-cast.
Doing this avoids 2x normalize calls per ray-cast in many places.
2015-08-21 17:09:18 +10:00
176b806626
BVH-overlap: add callback to BLI_bvhtree_overlap
...
The callback checks if 2 nodes intersect (not just their AABB).
Advantages:
- theres no need to allocate overlaps which are later ignored.
- expensive intersection tests will run multi-threaded.
Currently only used for Python API.
2015-08-20 17:52:26 +10:00
2e2dc9b9e3
Refactor translation code out of blenfont
...
- Add blentranslation `BLT_*` module.
- moved & split `BLF_translation.h` into (`BLT_translation.h`, `BLT_lang.h`).
- moved `BLF_*_unifont` functions from `blf_translation.c` to new source file `blf_font_i18n.c`.
2015-08-18 07:01:26 +10:00
52fa5b12e1
Cleanup: ws
2015-07-15 11:43:23 +10:00
f4f7348c41
Minor tweaking to Knife header text.
...
Confirm/cancel shall always be first, and also makes more sense to have
define cut/close cut/new cut together.
2015-07-12 21:52:59 +02:00
c2bcf2dc05
Add new modalkeymap usage in helper header message to Knife tool.
2015-07-12 21:32:16 +02:00
b8b57d2da9
BLI_listbase: match arg order with BLI_qsort_r
2015-06-11 21:54:06 +10:00
ec3c2d3be9
Fix T45009: Bad 'tri area computation' code in knife tool.
...
Was causing wrong selection of 'outside' face.
2015-06-10 16:35:52 +02:00
c760c0dbb3
Cleanup: use mul_v3_mat3_m4v3
2015-04-28 01:18:50 +10:00
3f80accfb3
Fix T44011: Ruler/Knife/Loop-cut fail in quad-view
...
This is a kind of sloppy-focus,
resolving long standing bug with loop-cut/knife/ruler /w quad-view.
Where activating a tool would lock onto one of quad-views,
especially problematic when activating from the toolbar or menus.
2015-04-27 19:17:07 +10:00
86d3a1f683
Cleanup
2015-04-25 12:29:52 +10:00
c2f861453e
Fix T44492: knife tool should cut across a split edge.
...
Added filter condition in visibility check that prevented
a "butting-up-against" face from obscuring an edge.
2015-04-24 07:29:45 -04:00
e2c24a18e3
Knife: fix glitch dragging mouse outside the face
...
Had a small gap between the last-vertex & new-cut
2015-03-03 09:29:44 +11:00
d2b6c6fd9b
Fix T43862: Knife fails with concave ngon
2015-03-03 00:26:20 +11:00
cfd176bcb1
MEM_SAFE_FREE caused issues /w const & GCC5
2015-02-27 15:26:22 +11:00
87dc01e690
Fix T43806: Knife project crashes
...
Need to re-create the bmbvh after executing the cut.
2015-02-27 09:53:23 +11:00
a8fa291b8c
Fix two potential bugs reported by latest coverity scan.
2015-01-19 17:51:25 +01:00
ef80914c99
error in last commit
2015-01-14 05:11:19 +11:00
a97c5d1f9f
Fix T42459: Knife fails at small scale
...
Occluding geometry failed when near overlapping (or cutting small objects).
2015-01-14 01:36:03 +11:00
b77dd13004
Fix T43229: Knife-project regression (broke knife-project)
...
There have been quite a few issues with knife precision,
tested reports (T43229, T42864, T42459, T41164) and this works with all.
2015-01-13 21:28:58 +11:00
aab4f2b762
cleanup: redundant casts & const cast correctness
2015-01-01 23:42:28 +11:00
5ea243bbec
cleanup: knife tools, use generic sort function
2014-12-27 12:37:11 +11:00
72341537e8
Fix T42864: Knife-project fails with 'cut-through'
...
Removing edge-hit-doubles could incorrectly de-duplicate intersections between different edges.
Gave noticeable errors cutting through geometry that overlapped exactly.
2014-12-15 21:17:10 +01:00
db0e2e7347
Fix T42864 (partial): knife-project included uncut backfaces
...
When knife-project ran with cut-through disabled,
it would still try to select faces behind the cut.
Now check if the faces are obscured.
2014-12-15 15:10:49 +01:00
2329b58fd3
Fix T42864 (partial): Knife-project had too-low precision
2014-12-15 15:10:49 +01:00
17f0a01a56
Correct last commit checking knife edges
2014-12-09 20:57:37 +01:00
6fb1e1680b
Knife: cuts along existing edges are now selected
...
This means cuts along existing edges don't have gaps in the selection.
Fixes T42616
2014-12-09 19:51:08 +01:00
2efc3211ab
Knife: rename vert & edge 'draw' to 'is_cut'
...
More logical for checking if the edge is a cut into the mesh.
2014-12-09 17:24:19 +01:00
4d9f2f7e86
Knife: fix edge aligned cuts, could add redundant verts
2014-12-09 17:23:10 +01:00
781db5f8a6
Knife: test if an edge is on the face boundary
...
Was checking if an edges midpoint was inside the face,
giving random results (point-inside for an edge location).
2014-12-09 15:57:59 +01:00
171a6bb5dc
Fix T42488: Knife (selected_only + occlude) failed
2014-12-09 15:51:58 +01:00
1cb59394ae
Cleanup: use const, avoid float -> double in matrix invert
2014-11-29 17:49:38 +01:00
6dcf8ba189
Knife: fix recent drag option /w loop close
...
It would miss adding an edge when closing the loop.
2014-11-16 14:57:28 +01:00
c31f74de6b
Cleanup: use BLI_listbase_count_ex to avoid redundant looping
2014-11-16 14:23:37 +01:00
7d040d2a08
Cleanup: use BLI_listbase_*** prefix for count,sort,sort_r
2014-11-16 13:57:58 +01:00
497a26665c
Knife: double clicking now closes the loop
2014-11-16 12:59:47 +01:00
c6ab67bffc
Fix T42611: Knife fails from an edge to a vertex
2014-11-15 22:17:37 +01:00
bfa75dc990
Knife: freehand drawing while LMB held
2014-11-15 20:50:15 +01:00