Age | Commit message (Collapse) | Author |
|
Failed edge rotation could leave unselected edge between selected faces,
also report warning when edges fail to be rotated.
|
|
Just return the face or NULL, like BM_edge_exists(),
Also for BM_face_exists_overlap & bm_face_exists_tri_from_loop_vert.
No functional changes.
Old code did some partial overlap checks where this made some sense,
but it's since been removed.
|
|
|
|
Bitmap drawing is out-of-scope for a general math API,
move to BLI_bitmap_draw_2d.
|
|
Fixes T47488 and T47478.
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D2224
|
|
Yet another mismatch where code would decrease usercount (of Material here) but never increase it again
when re-assigning the datablock...
|
|
|
|
|
|
New dependency graph puts materials to the graph in order to deal with animation
assigned to them and things like that. This leads us to a requirement to update
relations when slots changes.
This fixes: T49075 Assignment of a keyframed material using the frame_change_pre handler
doesn't update the keyframe using the new dependency graph
|
|
Checking a condition right after we’ve checked it (and it hasn’t
changed). Most of these are trivial to understand.
split_quads in convertblender.c:
It seems quads should be processed and triangles should be marked as
not needing split. So I removed the outer vlr->v4 check.
Found with PVS-Studio T48917
|
|
|
|
|
|
Also allows us to get rid of a few _copy_ex() versions...
|
|
|
|
Now test_object_materials only handles one object. New test_all_objects_materials
checks the whole bmain->object list for cases where it is actually needed.
Should avoid some useless looping over all objects!
|
|
Support applying decimate to the mesh selection.
|
|
Toggling edit-node after joining objects is redundant as far as I can see -
(dates back to first revision).
Also caused all edges to be drawn w/ meshes, redundant undo step w/ curves.
|
|
|
|
Idea is to replace hard-to-track (id->lib != NULL) 'is linked datablock' check everywhere in Blender
by a macro doing the same thing. This will allow to easily spot those checks in future, and more importantly,
to easily change it (see work done in asset-engine branch).
Note: did not touch to readfile.c, since there most of the time 'id->lib' check actually concerns the pointer,
and not a check whether ID is linked or not. Will have a closer look at it later.
Reviewers: campbellbarton, brecht, sergey
Differential Revision: https://developer.blender.org/D2082
|
|
Two were actual bugs, though they existed only in unused code:
* In Freestyle it was unintentionally copying a scene rather than referencing it.
* In BLI_array_store_is_valid there was use of uninitialized memory.
|
|
instanced operand
This is quite tricky situation which combined:
- Boolean modifier which accesses other object's derived mesh
(in fact, it's nothing to do with boolean modifier, any other
modifier which uses other's DM will have same bug).
- Dependency cycles in the scene which is rather russian-roulette
from the cycle solver point of view.
- Multiple instanced objects used as boolean operand.
With all this things combined boolean modifier was accessing operand's derived
mesh which was referencing data from Mesh datablock. The issue is that those
references are becoming invalid after EDBM_mesh_load().
This function already had code to make sure object itself does not end up with
dangling pointers from derived mesh. Make it now so no possible instanced objects
are left with dangling pointers.
And who said it's a good idea to reference something from derived mesh..
|
|
Saves 8 bytes per vert/edge/face.
Gives overall ~20-25% memory saving for dyntopo sculpting
and modifiers that use BMesh.
|
|
This avoids bad-level calls.
|
|
handling).
This commit changes a lot of how IDs are handled internally, especially the unlinking/freeing
processes. So far, this was very fuzy, to summarize cleanly deleting or replacing a datablock
was pretty much impossible, except for a few special cases.
Also, unlinking was handled by each datatype, in a rather messy and prone-to-errors way (quite
a few ID usages were missed or wrongly handled that way).
One of the main goal of id-remap branch was to cleanup this, and fatorize ID links handling
by using library_query utils to allow generic handling of those, which is now the case
(now, generic ID links handling is only "knwon" from readfile.c and library_query.c).
This commit also adds backends to allow live replacement and deletion of datablocks in Blender
(so-called 'remapping' process, where we replace all usages of a given ID pointer by a new one,
or NULL one in case of unlinking).
This will allow nice new features, like ability to easily reload or relocate libraries, real immediate
deletion of datablocks in blender, replacement of one datablock by another, etc.
Some of those are for next commits.
A word of warning: this commit is highly risky, because it affects potentially a lot in Blender core.
Though it was tested rather deeply, being totally impossible to check all possible ID usage cases,
it's likely there are some remaining issues and bugs in new code... Please report them! ;)
Review task: D2027 (https://developer.blender.org/D2027).
Reviewed by campbellbarton, thanks a bunch.
|
|
|
|
Also, can use numeric input to set segments and profile when
in those respective value-adjusting modes (as per S or P toggle).
Finally, fixed problem with previous bevel commit: when changing
value-adjusting mode, would like to start off resumed value adjustment
where it was before.
|
|
|
|
The Shift key can be held while adjusting profile to make finer changes
to the profile (just as it already does when adjusting offset).
|
|
- the name of the enumerator `SNAP_NOT_OBEDIT` was changed to `SNAP_NOT_ACTIVE`.
- the parameter `snap_to_flag` was moved to outside `SnapObjectParams`.
- the member `use_object_edit` was renamed to `use_object_edit_cage`.
- added the arg `params` in `ED_transform_snap_object_project_ray`.
- simplifications in the loop of the function `snapObjectsRay`.
|
|
Previously a whole mesh was stored between undo steps,
This commit uses BLI_array_store to de-duplicate memory use between undo steps.
Memory saving depends entirely on kinds of edits performed,
in own tests 5x-15x less memory use is common.
Compacting the memory does give some overhead however its done in a background thread
so its not blocking in most cases.
New behavior and threading can be ifdef'd out to check for regressions.
See D2026 for details.
|
|
|
|
|
|
Some languages like Chinese or Japanese take three or four bytes per char...
Also fixed some missing translation markers for UI header messages.
|
|
From user perspective, last selected face is the same as the active face,
use this as a fallback.
|
|
Commit 86abddc9, caused an error when the face-region included boundary edges.
Since removing the faces first, caused the edges along the boundaries to be removed.
Add support for deleting faces and internal edges, that keeps boundaries.
|
|
bevel segments.
|
|
Typo in rBrBa48d74079, spin tool was now using the wrong view axis.
|
|
Calculating the winding failed when faces exist on both sides of the edge.
|
|
Separate the creation of trees from EditMesh from the creation of trees from DerivedMesh.
This was meant to simplify the API, but didn't work out so well.
`bvhtree_from_mesh_*` actually is working as `bvhtree_from_derivedmesh_*`.
This is inconsistent with the trees created from EditMesh. Since for create them does not use the DerivedMesh.
In such cases the dm is being used only to cache the tree in the struct DerivedMesh. What is immediately released once
bvhtree is being used in functions that change(tag) the DM cleaning the cache.
- Use a filter function so users of SnapObjectContext can define how edit-mesh elements are handled.
- Remove em_evil.
- bvhtree of EditMesh is now really cached in the snap functions.
- Code becomes organized and easier to maintain.
This is an important patch for future improvements in snapping functions.
|
|
Now CD_SHAPEKEY_INDEX customdata is stored in edit-mode when hooks and vertex parents are used.
This also fixes a bug where undo would loose key-index data.
Move to structs for BM_mesh_bm_to/from_me to avoid passing many argument, which mostly aren't used.
|
|
|
|
This changes behavior so seams aren't used for the bmesh walker.
|
|
|
|
This introduces a snap-context that can be re-used for casting rays into the scene
(by operators such as walk-mode, ruler and transform code).
This can be used to cache data between calls too.
|
|
This patch depends on D1747, which upgrades the Recast version. It exposes the new Recast partitioning methods in the navmesh generation.
Reviewers: campbellbarton, moguri
Reviewed By: moguri
Projects: #bf_blender
Differential Revision: https://developer.blender.org/D1748
|
|
The version of Recast that Blender ships with is from 2009. This patch updates the Recast version to the latest version, 1.5.0. The Detour version remains untouched.
Reviewers: campbellbarton, moguri
Reviewed By: moguri
Projects: #bf_blender
Differential Revision: https://developer.blender.org/D1747
|
|
For now leave precision at half a pixel until we have real fix.
Resolves T48023.
|
|
Rewrote to work with ngons and and more complex topology, now uses separate function.
Fixes T48009.
|
|
|
|
|