After 5f7d5c0809, just translate gizmo is listening to protection flags
in global orientation. Commit doesn't specify the reason behind the
change. It intentionally ignores scale/rotate lock flags in global
orientation. Added a code comment to explicitly mention the reason
behind it.
Resolves#116666
Pull Request: https://projects.blender.org/blender/blender/pulls/133286
We recently pulled in the upstream patch to address the incorrect
validation error we were experiencing. This was the only test which
previously required the validator to be disabled.
Pull Request: https://projects.blender.org/blender/blender/pulls/138289
Calling `brush.asset_save_as` both creates an asset and also activates
the corresponding brush. When run while Blender is in background mode,
the `active_tool->runtime` field may be null. To avoid crashing in this
case, check for null when comparing active tool data.
Pull Request: https://projects.blender.org/blender/blender/pulls/138245
This PR adds an option to only show the onion skins of the active
object. The option is added to the Grease Pencil overlay menu in the
3D viewport.
When enabled, only the onion skins of the active object are shown.
This keeps the viewport a lot cleaner when working with multiple
Grease Pencil objects.
This resolves#136820.
Pull Request: https://projects.blender.org/blender/blender/pulls/137405
Part of #135062.
This PR adds an Auto Normalize option in the Vertex Group panel that
when checked will normalize the other deform-bone vertex groups' weights
when assigning the weight of a deform-bone vertex group. For example if
a selected vertex has the following weights:
| Name | Weight |
|---------|--------|
| Group 1 | 0.2 |
| Group 2 | 0.2 |
| Group 3 | 0.6 |
And the user selects Group 3, checks the Auto Normalize checkbox, sets
the weight to 0.8, and clicks Assign, the new weights will be:
| Name | Weight |
|---------|--------|
| Group 1 | 0.1 |
| Group 2 | 0.1 |
| Group 3 | 0.8 |
Co-authored-by: Andy Beers <acbeers1@gmail.com>
Pull Request: https://projects.blender.org/blender/blender/pulls/138133
Add-ons can call a batch draw command for lines using a surface shader.
This is not intended and polylines shaders should be used. This PR
lighten this restriction to automatically replace the shader with the
correct polyline shader, similar to immediate mode.
This change is done inside the python wrapper as internally we should
use the correct polyline shader.
For point shaders we don't have a work around in place and that needs
more discussion. Therefore this is only a partial fix.
Pull Request: https://projects.blender.org/blender/blender/pulls/138138
Overloaded version for utility function `get_item_as()` taking a pointer
as an argument (rather then reference) performs type verification,
avoiding the additional manual check.
Pull Request: https://projects.blender.org/blender/blender/pulls/138067
Initiliaze global context only once per test suite. Test data relevant
to the respective tests is still allocated and freed with every test
case.
Also, `scene->nodetree` will be deprecated in a future PR, so use
`material->nodetree` to test embedded trees instead.
Pull Request: https://projects.blender.org/blender/blender/pulls/137895
This patch removes the Variable Size blur option from the Blur and Bokeh
Blur nodes. So now, whatever the user connects to the size input will be
used, be it variable or constant.
The option previously could be used to force the node to ignore variable
size inputs and assume a size of 1, so it was useless.
Versioning would be difficult, as we don't know if incoming links to the
size input is variable or single. So this is a breaking change. But I
can't think of a real reason why the user might use this option, so this
seems safe from a practical point of view.
Pull Request: https://projects.blender.org/blender/blender/pulls/138261
When a keymap operator is not found, color the label and input field
in red. This can help identify issues when migrating preferences and
some operators no longer exist.
Screenshots in the pull request.
Pull Request: https://projects.blender.org/blender/blender/pulls/130675
Similar to !138193
We are going over the `bAnimListElem` nested / multiple times:
- once in `animchannels_rearrange_exec`
- then again in `rearrange_layered_action_channel_groups`
So we are basically just rearranging **multiple times** (unnecessarily
for unrelated actions)
So to resolve, pass the current action to
`rearrange_layered_action_channel_groups`, then skip `bAnimListElem` if
its action does not match the action passed in.
Pull Request: https://projects.blender.org/blender/blender/pulls/138196
Fix an issue where rearranging animation channels ("Move Up", "Move
Down", etc.) would take multiple steps. This was caused by the Action of
these channels being visited multiple times, and each visit taking a
step.
Pull Request: https://projects.blender.org/blender/blender/pulls/138257
The copy/paste function for nodes is offsetting the node centroid to the
mouse cursor. This was skipping direct children of selected frames, because
the node position was originally relative to the frame parent. This behavior
changed in 4bf34d95, which causes child nodes to remain stuck at their
original location.
All nodes should simply be offset now, since their positions are no longer
relative.
Pull Request: https://projects.blender.org/blender/blender/pulls/138252
In a profile of sculpting with the Vulkan GPU backend enabled,
This function made up 0.7% of samples. Since it's just a single
comparison, inlining it should be helpful for the compiler.
Pull Request: https://projects.blender.org/blender/blender/pulls/138210
The initial port [0] incorrectly use `sqrt` where `sqr` was used in the
original code. This mistake was made in two places but the second
causes a significant change in behavior, so this has been left as is
noting the difference in a comment.
Resolve the following issues:
- Use square instead of sqrt when calculating the peak value,
besides following the original implementation it avoids the result
being NAN when "Fetch" is below 30.
- Pass in `sqrt(m_omega)` matching the `omega` argument to
`alpha_beta_spectrum` as well as following the upstream code.
In most cases the user visible changes are subtle.
Ref !137607
Co-authored-by: Nicolas Paris <nicolas.paris490@gmail.com>
[0]: 6ce709dceb
This happend to ungrouped channels and in the case other Actions are
also visible in the Dopesheet (e.g. by having multiple objects
selected).
We are going over the `bAnimListElem` nested / twice:
- once in `animchannels_rearrange_exec`
- then again in `rearrange_layered_action_fcurves`
The inner workings are tied to specific actions from the first loop, but
we are going over FCurves possibly contained in **other** actions in the
second loop. Doing this with the "wrong" action goes wrong (e.g. in
`get_group_or_make_fake` where we try to get a channelbag for an FCurve
slot handle in the "wrong" action).
So to resolve, skip `bAnimListElem` if its action does not match the
action passed into `rearrange_layered_action_fcurves`
Pull Request: https://projects.blender.org/blender/blender/pulls/138193
There were actually two issues here:
1. The dimension reported for armatures were often wildly incorrect,
including negative values and zero!
2. The dimensions reported for objects are supposed to be invariant with
rotation, representing the dimensions along the object's local axes.
However, armature objects' reported dimensions changed with rotation.
The respective causes were:
1. `BKE_armature_min_max()` was using an incorrect formula (acknowledged
in a comment) for transforming the bounding box between spaces. This
worked fine for some of the places that `BKE_armature_min_max()` was
called, since they just reverse the transform using the same(!)
erroneous formula, but it didn't work for others.
2. `BKE_armature_min_max()` first computed the bounds in world space,
and then transformed them into object space, rather than computing
them in object space directly like the respective functions for other
object types. Even when done correctly, this causes the reported
dimension to vary with rotation.
This PR fixes these issues by simply computing the armature bounding box
in object space directly instead.
There is one place in the code base that was directly using the
world-space bounds: `view3d_calc_minmax_selected()`. However, for every
object type other than armatures, it takes the object-space bounds and
transforms them (with an incorrect formula!) to world space. So this PR
also changes `view3d_calc_minmax_selected()`'s armature code to do the
same, except with a correct formula.
Note that the reason for using the correct transform formula (departing
from other object types) is that the world-space bounds for armatures
were already correct prior to this PR due to being computed in that
space. Therefore using the incorrect formula has the potential to
introduce regressions in this case.
Pull Request: https://projects.blender.org/blender/blender/pulls/137961
Add a new node to the dependency graph, to act as a single entry point
before drivers are evaluated in parallel.
The node will take all the driven RNA properties, and write their
current value to the property again. This ensures that any implicitly
shared data is copied to ensure writability. Subsequent concurrent
writes by the driver evaluation will then be safe, as the
thread-unsafe part has already been performed.
Fixes: #132423
Pull Request: https://projects.blender.org/blender/blender/pulls/135802
Return separately for each node tree type.
This patch originally started as a refactor to change the logic of
iterating through compositing node trees but we ended up choosing
a different solution so only the small cleanup part is submitted here.
Pull Request: https://projects.blender.org/blender/blender/pulls/138205
This patch turns the options of the Bilateral Blur node into inputs.
In the process, the Sigma Space and Iterations were joined into a single
Size input, previously they were just added together then ceiled to get
the blur size. Furthermore, Sigma Color was renamed to threshold and now
represents the average color difference, not the sum, so it was
previously multiplied by 3.
Versioning and RNA compatibility is not perfect due to joining the two
size options.
Reference #137223.
Pull Request: https://projects.blender.org/blender/blender/pulls/138249
New function called immRectf_with_texco(), which resides next to the other
immRectf utilities.
Currently used in a single place in the sequencer, but it will be used in
a few other places in the future.
Pull Request: https://projects.blender.org/blender/blender/pulls/138222
Shrinks the USDPrimReader base class by 24 bytes
- Uses `StringRefNull` in place of a full `string` (prevents additional
runtime allocations)
- The `prim_path` field is only used sparingly, mostly for tracing, and
a few non-perf-critical paths. No use keeping it around when it's
easily, and quickly, accessible through other means.
Pull Request: https://projects.blender.org/blender/blender/pulls/138232
Tooltips for enum items currently show the enum name on one line, then
enum description, then the current value's name, then the value's
description on the next line. This PR changes that to display the
(short) names together then the (longer) descriptions together. This
also adds a small amount of padding under the title.
Pull Request: https://projects.blender.org/blender/blender/pulls/137571
Ref: #132179
Renames:
- `Editing.act_seq` -> `Editing.act_strip`
- `SequenceModifierData` -> `StripModifierData`
- Its member `mask_sequence` is now `mask_strip`.
- `MetaStack.parseq` -> `MetaStack.parent_strip`
- Remaining function names/parameters that were not dealt with in #132748
- Various references to `seq` or `sequence` throughout code and docs when
referring to a strip
Also moves `_get` to the end of the renamed function names where
applicable for standardization (unless "by" or "from" are used).
There should be no changes to current behavior.
Pull Request: https://projects.blender.org/blender/blender/pulls/138077
Caused by recent refactor of strip input querying in #136474.
This caused `Strip::seq1` to be set even if effect strip has no inputs.
Fix was applied to `vse::strip_effect_get_new_inputs`, so it is less
confusing during debugging, but also to `seq::add_effect_strip`, as
I think, that core function should never produce invalid strip.
Pull Request: https://projects.blender.org/blender/blender/pulls/138016
This is completely unused, not implemented for the Vulkan backend, and
seems to add quite a bit of complexity to the Metal and OpenGL backends.
It was added for EEVEE legacy motion blur, and the last use was removed
along with EEVEE legacy. We're probably better off not maintaining it since
we should avoid duplicating vertex buffer data anyway.
Pull Request: https://projects.blender.org/blender/blender/pulls/138226
This operator is very similar to the existing "Join as Shapes" operator,
which updates or adds shape key array values with the positions of
objects with the same name, but instead of creating new shape keys,
it just updates existing ones. The new operator is called "Update from
Objects" in the UI.
Internally, some logic was moved to a poll function shared between the
two operators, and a new argument for whether to ensure keys exist was
added to their shared implementation.
Part of #135095.
Pull Request: https://projects.blender.org/blender/blender/pulls/136853
This change adds MaterialX version information to the exported MaterialX
USD materials.
Details:
In USD 25.02, the MaterialXConfigAPI schema was introduced to allow
recording the MaterialX version used to author a material. When loading
MaterialX documents into USD, this schema is automatically applied and
the associated version attribute is created on the material.
Due to how the MaterialX export works (via copying the composed
MaterialX spec from a temporary stage), the MaterialXConfigAPI needs to
be explicitly applied to the final material being exported.
This change applies this MaterialXConfigAPI schema and copies the
version attribute from the temporary MaterialX stage to the final stage.
Authored by Apple: Dan Knowlton
Co-authored-by: Dan Knowlton <d_knowlton@apple.com>
Pull Request: https://projects.blender.org/blender/blender/pulls/137974
This reflects better the more detailed info in comments of each sections
of the API in that file, and the info in the on-going work for a related
handbook page at blender/blender-developer-docs!139.