Age | Commit message (Collapse) | Author |
|
Was crashing SculptSession data will not longer be valid if the total
number of polys is modified when rendering the mesh again.
This deletes all face sets in the mesh when slicing the mask. I'll try
to add code to generate a new face set in with faces that are created
when filling the holes, but for now this avoids the crash.
Reviewed By: brecht
Maniphest Tasks: T74500
Differential Revision: https://developer.blender.org/D7049
|
|
Create face sets by visibility needs to check if all face sets of a
vertex are visible to set the new face set. I renamed the functions to
make this more cleare in the API.
I also added a visibility check when creating by mask to avoid modifying
hidden areas.
Reviewed By: brecht
Maniphest Tasks: T74499
Differential Revision: https://developer.blender.org/D7048
|
|
Hardness is now a property implemented for all brushes, so this is no
longer needed.
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D7078
|
|
The operator was resetting the mask data when cancelling instead of the
face set data, so it was crashing because mask data was not available
when starting the operator in expand face set mode.
Reviewed By: brecht
Maniphest Tasks: T74492
Differential Revision: https://developer.blender.org/D7043
|
|
Steps to reproduce were:
* Disable tool settings region in 3D View (View > Tool Settings)
* Split the 3D View and drag all the way down
The removed code doesn't seem to be needed anymore. Tested this on hiDPI
too, seems fine.
These kind of fixes are always tricky, so I wouldn't be surprised if
there are any issues caused by this.
|
|
Differential Revision: https://developer.blender.org/D6734
|
|
Differential Revision: https://developer.blender.org/D6867
|
|
For consistency with other editors.
Differential Revision: https://developer.blender.org/D7025
|
|
Contributed by Valentin (Poulpator).
Differential Revision: https://developer.blender.org/D7027
|
|
|
|
This commit is a full refactor of the grease pencil modules including Draw Engine, Modifiers, VFX, depsgraph update, improvements in operators and conversion of Sculpt and Weight paint tools to real brushes.
Also, a huge code cleanup has been done at all levels.
Thanks to @fclem for his work and yo @pepeland and @mendio for the testing and help in the development.
Differential Revision: https://developer.blender.org/D6293
|
|
While it might be handy to have type-less functionality which is
similar to how C++ math is implemented it can not be easily achieved
with just preprocessor in a way which does not have side-effects on
wrong usage.
There macros where often used on a non-trivial expression, and there
was at least one usage where it was causing an actual side effect/bug
on Windows (see change around square_f(sh[index++]) in studiolight.c).
For such cases it is handy to have a function which is guaranteed to
have zero side-effects. The motivation behind actually removing the
macros is that there is already a way to do similar calculation. Also,
not having such macros is a way to guarantee that its usage is not
changed in a way which have side-effects and that it's not used as an
inspiration for cases where it should not be used.
Differential Revision: https://developer.blender.org/D7051
|
|
|
|
Currently, this change does not bring functional changes.
But it is necessary to extend the use of the snap system for gizmos,
since, after a Undo, the `depsgraph` pointed by the `snap_context`
has its memory invalidated.
Reviewed By: campbellbarton
Differential Revision: https://developer.blender.org/D7013
|
|
This reverts commit 62f238a65e334ccecae85134da0b05ba58382ae9.
This prevents undo steps from being stored.
|
|
This allows deleting both collections and objects in the outliner
selection at the same time. This only works using the keyboard shortcuts
(X or Delete).
While this works, a more robust solution should be implemented later to
allow deleting the whole selection from the context menu as well.
|
|
Searching back in the outliner did not require the unused SpaceOutliner
parameter.
|
|
Missing changes from one of the renamings of the initial face sets
patch.
Reviewed By: brecht
Maniphest Tasks: T74513
Differential Revision: https://developer.blender.org/D7054
|
|
The initial iteration for all symmetry areas is always 0. We were using
1 for the main stroke, so it was 1 step behind.
This was broken for expanding masks and face sets, but with face sets it
is more noticeable.
Reviewed By: brecht
Maniphest Tasks: T74501
Differential Revision: https://developer.blender.org/D7050
|
|
By using PBVH_ITER_UNIQUE hidden vertices are skipped, like in the rest of
the brushes and tools.
Reviewed By: brecht
Maniphest Tasks: T74498
Differential Revision: https://developer.blender.org/D7047
|
|
file-selector
In these cases the file selectors directory is already expanded.
|
|
Use 'BLI_join_dirfile' for joining paths that don't need to expand '//'.
|
|
Remove Windows special folder FOLDERID_Objects3D. Requires newer SDK.
Differential Revision: https://developer.blender.org/D7014
Reviewed by Brecht Van Lommel
|
|
|
|
The old convention was easy to confuse with ScrArea.
Part of https://developer.blender.org/T74432.
This is mostly a batch rename with some manual fixing. Only single word
variable names are changed, no prefixed/suffixed names.
Brecht van Lommel and Campbell Barton both gave me a green light for
this convention change.
Also ran clan clang format on affected files.
|
|
|
|
Probably got lost when resolving merge conflicts.
|
|
Part of https://developer.blender.org/T74429.
There's a chance that this causes some issues becaue in some cases we
change from getting the window from context to getting it from somewhere
else.
|
|
This moves the `alembic`, `avi`, `collada`, and `usd` modules into a common
`io` directory.
This also cleans up some `#include "../../{somedir}/{somefile}.h"` by
adding `../../io/{somedir}` to `CMakeLists.txt` and then just using
`#include "{somefile}.h"`.
No functional changes.
|
|
|
|
|
|
|
|
Currently the link limit of sockets is stored in bNodeSocket->limit.
This allows for a lot of flexibility, but is also very redundant.
In every case I've had to deal with so far, it would have "more correct"
to set the link limit per socket type and not per socket. I did not enforce
this constraint yet, because the link limit is exposed in the Python API,
which I did not want to break here.
In the future it might even make sense to only support only three kinds of link limits:
a) no links, b) at most one link, c) an arbitrary number links links. The other link
limits usually don't work well with tools (e.g. which link should be removed when a new
one is connected?) and is not used in practice. However, that is for another day.
Eventually, I would like to get rid of bNodeSocket->limit completely and replace it
either with fixed link limits or a callback in bNodeSocketType.
This patch consists of three parts:
**1. Support defining link limit in socket type**
This introduces a new `nodeSocketLinkLimit` function that serves as an indirection to
hide where the link limit of a socket is defined.
**2. Define link limits for builtin sockets on socket type**
Data sockets: one input, many outputs
Virtual sockets: one input, one output
Undefined sockets: many inputs, many outputs (to avoid that links are removed when the type of the socket is not known)
**3. Remove `bNodeSocketTemplate->limit`**
This wasn't used anymore after the second commit. Removing it simplifies socket definitions
in hundreds of places and removes a lot of redundancy.
Differential Revision: https://developer.blender.org/D7038
Reviewers: brecht
|
|
Mistake on recent changes that would fail when used in CPP.
|
|
This patch will make use of the eDrawType where it was used as a
variable or parameter name. The eObjectDrawType was renamed to eDrawType
as it is also used by `View3DShading.type`.
|
|
|
|
Motivation the functions get 3 different kind of flag parameters (ImBuf,
DrawType, OffscreenRendering) the naming of the flags were not clear,
leading to mistakes and unnecessary time spend debugging.
|
|
There are two ways in which adding/deleting keyframes can fail, but only
one of those was handled. The other would be shown as a successful
add/delete of -2 keyframes.
|
|
The `ANIM_apply_keyingset()` returns a value that indicates the number of
changed channels (if nonnegative) or an error state (negative). In the
places where the return value was actually used, this value was stored in
a badly named variable.
|
|
Resolves T54297
|
|
contect -> context
|
|
- Use 'int' for counters instead of short.
- Use 'bool' instead of a counter when only a change is being detected.
- Use typed enum for keying set flags.
- Include in comments when a negate error code may be returned.
|
|
There is no need for an insertion flag in a delete function.
|
|
- Split 'verify_fcurve' into two functions:
ED_action_fcurve_ensure which adds the f-curve if needed.
ED_action_fcurve_find which returns NULL when not found.
Callers of ED_action_fcurve_find had unused 'group'
argument which has been removed.
- Rename verify_adt_action to ED_id_action_ensure
It had an argument to add data which was always true,
remove this instead of splitting in into a separate function.
|
|
|
|
- Use 'BKE_object_defgroup' prefix for object functions.
- Rename 'defvert_verify_index' to 'defvert_ensure_index'
since this adds the group if it isn't found.
|
|
|
|
|
|
|
|
|