Age | Commit message (Collapse) | Author |
|
|
|
|
|
|
|
Recent addition of 'reinsert' didn't match logic for ghash API.
Rename to BLI_heap_node_value_update,
also add BLI_heap_insert_or_update since it's a common operation.
|
|
Improves performance for high poly meshes,
~70% faster for decimate, only ~10% for beautify.
|
|
Vertex w/ a single edge wasn't detected
|
|
BM_ELEM_INTERNAL_TAG flag wasn't ensured to be cleared.
|
|
|
|
Was using an edge hash for triangle -> edge lookups,
updating triangle indices for each edge-rotation.
Replace this with half-edge which can rotate edges much more simply,
writing triangles back once the solution has been calculated.
Gives ~33% speedup in own tests.
|
|
|
|
|
|
|
|
These platforms didn't see maintenance in years.
This commit just removes ifdef's & cmake check.
|
|
|
|
|
|
This allows to have different macro headers without them sharing
similar names to regular C modules.
|
|
|
|
Also use floor division since regular division was giving a bias
on negative error values.
|
|
When 2x loops have different number of vertices,
the distribution for vertices fan-fill depended on the loop order
and was often lop-sided.
This caused noticeable inconstancies depending on the input
since edge-loops are flipped to match each others winding order.
|
|
Was using function for edge rotation which was doing unnecessary checks
Use the face normal and BLI_polyfill_beautify_quad_rotate_calc directly.
|
|
Needed for 3D iterative edge-rotation to avoid flipping when projected
from different angles,
but could keep zero area faces in 2D polygons.
|
|
|
|
|
|
|
|
This means boolean tessellation wont match viewport tessellation
however it's needed to avoid zero area triangles causing problems.
|
|
|
|
A single diagonal axis was used for sorting coordinates,
the algorithm relied on users not having vertices axis aligned.
Use BLI_kdtree to remove doubles instead.
Overall speed varies, it's more predictable than the previous method.
Some typical tests gave speedup of ~1.4x - 1.7x.
|
|
Each qsort implementation may give different results when values match.
Now fallback to sorting by index.
|
|
|
|
|
|
- Vertex only meshes never restored their selection history.
- Select history was cleared on the source instead of the target.
Simple Optimizations:
- Avoid O(n^2) linked list looping that checked the entire list before
adding elements (NULL values in the source array to prevent dupes).
- Re-use vert & edge lookup tables instead of allocating new ones.
|
|
Creating ngons with multiple axis aligned shapes in the middle of a
single face would fail in some cases.
This exposed multiple problems in BM_face_split_edgenet_connect_islands
- Islands needed to be sorted on Y axis when X was aligned.
- Checking edge intersections needed increased endpoint bias.
- BVH epsilon needed to be increased.
|
|
Old bevel 'Clamp overlap' code was very naive: just limit amount
to half edge length. This uses more accurate (but not perfect)
calculations for the max amount before (many) geometry collisions
happen. This is not a backward compatible change - meshes that
have modifiers with 'Clamp overlap' will likely have larger allowed
bevel widths now. But that can be fixed by turning off clamp overlap
and setting the amount to the desired value.
|
|
|
|
|
|
|
|
|
|
The const key is required by compiler to avoid warning
|
|
This makes sense when we want to avoid float precision error
for near co-linear edges. OTOH, this is an arbitrary decision,
so keep functions separate.
|
|
Document to avoid confusion when called from Python.
|
|
|
|
`BMO_iter_as_array()` may fill less items than requested in given array,
so we have to update number of items to work on from its returned value,
otherwise code might try to use uninitialized memory.
|
|
Use for calculating the angle between 2 directions on an axis.
Also signed version and normalized plane projection,
use when input is normalized.
|
|
Edge collapse was using bounding box center as the point to collapse to.
When collapsing multiple adjacent edges together, this caused
inconsistencies in placement of the collapsed point, depending on the
orientation of the edges in relation to the space axis.
This makes edge collapse use the mean point instead.
|
|
Colinear vertices in a same face would not be handled correctly.
|
|
faces.
This was requested by script writers. Especially needed if beveling
wire edges with vertex_only.
Should be backward compatible as just adds two new keys to returned
dict in python ('edges' and 'verts').
|
|
|
|
|
|
Note: the angle in bug isn't really reflex - using the vertex normal
for this test isn't always right, but usually is. At any rate,
shouldn't try to put vertex on edge between if a reflex angle.
|
|
VERT_VISIT was used in a nested function.
|