Caused by 2a1ac6145a
If the attribute creation failed, the modifier would try to fill in a
null UV map. The combination of CustomData and attribute API functions
was a bit confusing, so restore the old behavior more explicitly using
just the attribute API (including the slightly weird "Float2" default
name. That could be changed later.)
Simplifies the code in this area, makes it work better with other C++
code. The max length argument isn't used anymore. But at that point we
wouldn't necessarily have a unique name anyway, which opens up for other
failures.
Followup to #114755. Initialize operation results explicitly if the input is constant. This patch unifies the size inference behavior of the following nodes/operation:
- Flip node
- Kuwahara (classic)
- Lens distortion
- Tonemap node
Pull Request: https://projects.blender.org/blender/blender/pulls/115733
Horizotal blur is achieved when ratio is `< 1` but it's not possible
to slide below 1. So make softmin=hardmin (0.01) to give more control
in user interface.
Pull Request: https://projects.blender.org/blender/blender/pulls/116625
The armature join operation should preserve custom properties,
as described in the comment in the code. Previously this was
achieved by reusing the collection instances from the armature
being joined, but it was changed to create a new instance. However,
property copying was not implemented, which breaks Rigify.
This fix adds property copying behavior back.
Pull Request: https://projects.blender.org/blender/blender/pulls/116626
This adds option to bypass the raytracing pipeline
entirely and use a cheaper evaluation option.
This reuse the same evaluation as the Blended materials.
This exhibits some artifacts on Apple hardware due to
synchronization issues.
Pull Request: https://projects.blender.org/blender/blender/pulls/116622
In the last couple places, avoid retrieving the mask attribute per
vertex. Use existing attribute data pointers instead. This also avoids
function calls and branches for every vertex, since there is no PBVH
type switch at the lowest level of the loop anymore.
The cloth filter accesses the vertex mask for every length constraint.
Previously that used a cached pointer, but that was removed, and then
the access was changed to use the attribute API, which is slower since
it isn't designed to be accessed for every element. The solution is
to just let the PBVH type abstraction "leak" when accessing mask data.
Avoid the `PBVHVertRef` abstraction which is unnecesarily costly for
such a simple thing as copying data. Instead we can use abstractions
specific to each PBVH type (currently only `VArray` for meshes).
Previously they shared the same implementation with a check per vertex
for whether to smooth the mask or the positions. Though it adds a bit
of duplication for now, everything else becomes simpler if the brush
implementations are split.
Added support for importing USD instanceable primitives into Blender
as collection instances.
Added a new USDInstanceReader class for importing USD
instances as Blender objects that instance collections containing
prototype data.
Extended the USDStageReader to read USD prototype prims into
collections that are instanced on the objects created by the instance
readers.
Removed the "Import Instance Proxies" import option.
Importing instances is enabled with a new "Scene Instancing" import
option, which is true by default. If this option is off, instances will be
imported as copies (which is the functionality previously enabled by
the "Import Instance Proxies" option).
Removed calls to UsdSkelBindingAPI::Apply() in the skeleton and
blend shape import code, as these calls were unnecessary and were
generating errors when importing instance prototypes with UsdSkel
data.
Nested instancing and animated prototypes are supported.
Pull Request: https://projects.blender.org/blender/blender/pulls/115076
Make it possible to nest bone collections. The data structure on the
armature is still a flat array. It is organised as follows:
- Sibling collections (i.e. ones with the same parent) are stored
sequentially in the array.
- Each bone collection keep track of the number of children, and the
index of the first child.
- Root collections (i.e. ones without parent) are stored as the first
elements in the array.
- The number of root collections is stored on the Armature.
This commit also contains the following:
- Replaced the flat UIList of bone collections with a tree view.
- Updated the M/Shift+M operators (move/assign to collection) to work
with hierarchical bone collections.
- Updated RNA interface to expose only root collections at
`armature.collections`. All collections are available on
`armature.collections.all`, and children at `bonecollection.children`.
- Library override support. Only new roots + their subtrees can be added
via overrides.
See https://projects.blender.org/blender/blender/issues/115934
Co-authored with @nathanvegdahl and @nrupsis.
Pull Request: https://projects.blender.org/blender/blender/pulls/115945
Instead of `Collections`, describe a section as `Collection Properties`.
Otherwise it's ambiguous whether it's about that or specifically bone
collections.
No functional changes.
Remove the `OPTYPE_REGISTER` flag, to ensure the operators do not pop up
their redo panel. The flag is removed where the operator properties are
set by Python code, instead of chosen by the user. For example, it doesn't
make much sense to change which bone collection is used by the operator by
typing the name of another bone collection.
This could be revisited when Blender supports "nested enum" properties,
to make it possible to choose an item in an entire hierarchy.
Rename `bonecoll_find_index` to `armature_bonecoll_find_index` (because
it takes a `bArmature*` parameter), and move it from a static function into
the `blender::animrig` namespace. It will be used externally in upcoming
commits.
No functional changes.
Move some of the functionality of `ANIM_armature_runtime_refresh()` into
a function of its own (`ANIM_armature_bonecoll_active_runtime_refresh()`).
It will be called from another place as well in upcoming commits.
No functional changes.
The GPU compositor incorrectly extrapolates values of RGBA curves node.
That's because the code introduces a half-pixel offset to the color
values since they will be used to sample the curve maps. Those same
values are then used for extrapolation, which shouldn't take the
half-pixel value into account.
This patch fixes that by computing sampler coordinate in a separate
step.
Pull Request: https://projects.blender.org/blender/blender/pulls/116586
Adds API to allow usage of specialization constants in shaders.
Specialization constants are dynamic runtime constants which can
be compiled into a shader pipeline state object (PSO) to improve
runtime performance by reducing shader complexity through
shader compiler constant-folding.
This API allows specialization constant values to be specified
along with a default value if no constant value has been declared.
Each GPU backend is then responsible for caching PSO permutations
against the current specialization configuration.
This patch adds support for specialization constants in the
Metal backend and provides a generalised high-level solution
which can be adopted by other graphics APIs supporting
this feature.
Authored by Apple: Michael Parkin-White
Authored by Blender: Clément Foucault (files in gpu/test folder)
Pull Request: https://projects.blender.org/blender/blender/pulls/115193
The new 2.5.x version of OIIO came with the OpenEXR Core library enabled
by default. Unfortunately it's not quite ready to be used so disable it
for now.
The current issue will prevent DWA-A/B from loading correctly. There may
also be a potential ZIPS compression related quirk that upstream is
still working through as well.
Pull Request: https://projects.blender.org/blender/blender/pulls/116591
There are some tragic design flaws with the Microsoft STL
implementation of `std::dequeue`. Unless we implement our
own similar data structure or use an implementation from
another library, the change isn't worth it.
This reverts commit b26cd6a4b9.
This reverts commit cc11ba33d9.
This reverts commit c929d75054.
This reverts commit bd3d5a750d.
Some common headers were including this. Separating the includes
will ideally lead to better conceptual separation between CustomData
and the attribute API too. Mostly the change is adding the file to
places where it was included indirectly before. But some code is
shuffled around to hopefully better places as well.
The main goal is removing bmesh.hh from BKE_paint.hh, since that
includes it in many more files than necessary. Also remove more
includes from sculpt_intern.hh.
GSQueue dates back over 21 years, past the initial git commit. Nowadays
we generally prefer to use data structures from the C++ standard library
or our own C++ data structures. Previous commits replaced this container
with `std::queue` in a few areas. Now it is unused and can be removed.
Commit 91b27ab637 reveals the error.
The Poly Build code was using the wrong mesh to access the evaluated
coordinates.
It was accessing the original mesh, which wasn't affected by modifiers
or editing.
The most ideal meshes would be either the cage or even the deform, as
these better correspond to the geometry seen by the user.
This patch unifies the behavior of the scale node by removing the arbitrary limit of scaling images. The change applies to scale and transform nodes.
Note: with this change, Blender can crash for large resizing factors (around 10 000 x 10 000 relative factors). We think it's very unlikely users will run into this issue, so we agreed errors coming from failed memory allocation won't be handled, as is the case for GPU compositor.
Pull Request: https://projects.blender.org/blender/blender/pulls/114764
When exporting animation (one .obj file per animation frame), the old
Python OBJ exporter used to emit frame number with leading zeros, e.g.
"000012" which made sorting files by frame easier. The new C++ OBJ
exporter does not do that.
Fix that by reintroducing leading zeros. However, use 4 digits
("0012") since that matches 4 digits used in many other places, and
also it's very unlikely that someone would export more than several
thousand frames into OBJ. If that happens, it all works correctly
anyway, just without leading zeroes.
Fixes#116520