This commit contains a few mostly-related changes to this node:
- Add a warning when retrieving the geometry from the modifier object.
- Only create the output geometry when it is necessary.
- Decompose transform matrices in a more friendly way.
- Use default return callbacks like other newer nodes.
Differential Revision: https://developer.blender.org/D13232
It's valid for a node group connected to the modifier not to
have a geometry input, but I didn't consider that case
with the last change I made here, f3bdabbe24fe591dc9.
Differential Revision: https://developer.blender.org/D13231
The spline code, especially Bezier splines, often make use of lazily
evaluation and caching. In order to do that, they use mutex locks.
When multi-threading, this can lead to problems. Further detail
can be found in rBfcc844f8fbd0d1.
To fix the deadlock, isolate the task before multi-threading
when holding a lock.
Differential Revision: https://developer.blender.org/D13229
Due to asynchronous process, the preview for a given image may be
generated several times.
This regenerates many thumbs unnecessarily.
The solution is to add the `FILE_ENTRY_PREVIEW_LOADING` flag for file
entries that are still in the thread queue.
So this flag is checked not to redraw the thumb when it is still being
created on a different thread.
Differential Revision: https://developer.blender.org/D11150
Fix a crash when a hair system's `ParticleSettings` ID datablock was
linked from another file but couldn't be found. This results in default
settings, with `type = PART_EMITTER`, where the particle data still has
a non-NULL `hair` pointer. Previously, copies of such a particle system
would NOT copy hair data for non-hair particle systems, hence the
pointer of the copy pointed to the original data, which got freed (at
least) twice upon closing the blend file.
This is now fixed by always copying the hair data, regardless of the
particle system type.
Reviewed by: mont29
Differential Revision: https://developer.blender.org/D13245
Add comment explaining `MEM_dupallocN` is NULL-safe, in that it returns
NULL when it receives a NULL pointer. This is currently true for both
implementations of the function (`MEM_lockfree_dupallocN` and
`MEM_guarded_dupallocN`), and will be expected of other implementations
as well.
No functional changes.
Add a new "experimental" debug option `show_asset_debug_info`, and use
that to determine the visibility of the active asset's catalog UUID and
simple name. Previously this was only determined by the "Developer
Extras" option, which meant it was visible in too many situations. It's
not really a "developer extra", and really just a debugging tool, so the
new option is more in line with its purpose.
Reviewed by: Severin
Differential Revision: https://developer.blender.org/D13242
This patch adapts the existing volumetric read/write lambda functions for Metal. Lambda expressions are not supported on MSL, so two new macros `VOLUME_READ_LAMBDA` and `VOLUME_WRITE_LAMBDA` have been defined with a default implementation which, on Metal, is overridden to use inline function objects.
This patch also removes the last remaining mention of the now-unused `ccl_addr_space`.
Ref T92212
Reviewed By: leesonw
Maniphest Tasks: T92212
Differential Revision: https://developer.blender.org/D13234
In 499dbb626acb, the background color of drag tooltips were changed so
text becomes more readable. But multiple people were touching the same
code, so the disabled hint tooltips didn't get the same tweak. They
would benefit from them even more, since the red text is even harder to
read on the transparent background than the regular, white text.
Dispose of GHOST system paths when tearing down `BlendfileLoadingBaseTest`
and some other test cases. This prevents a memory leak.
A better solution would be to rework Blender's initialisation & teardown
structure, but that's outside the scope of this fix.
No functional changes to Blender.
While there is nothing technically that would cause issues when moving a
catalog into itself (it just changes the path of the catalog, and the
missing parent catalogs will be created), it seems broken to the user.
So disable this in the drag & drop code for asset catalogs.
Refreshing the assets requires `file_OT_asset_library_refresh` in the
asset browser, and `asset_OT_list_refresh` for the asset view. Both
are now done from `ASSET_OT_open_containing_blend_file`.
Python Operator templates made accessible from respective menus
(required to also use F3 search for quick access)
Also fixed Modal Draw Operator id_name (had duplicate name from other template)
Maniphest Tasks: T90866
Differential Revision: https://developer.blender.org/D13182
Goals of this refactor:
* Simplify creating virtual arrays.
* Simplify passing virtual arrays around.
* Simplify converting between typed and generic virtual arrays.
* Reduce memory allocations.
As a quick reminder, a virtual arrays is a data structure that behaves like an
array (i.e. it can be accessed using an index). However, it may not actually
be stored as array internally. The two most important implementations
of virtual arrays are those that correspond to an actual plain array and those
that have the same value for every index. However, many more
implementations exist for various reasons (interfacing with legacy attributes,
unified iterator over all points in multiple splines, ...).
With this refactor the core types (`VArray`, `GVArray`, `VMutableArray` and
`GVMutableArray`) can be used like "normal values". They typically live
on the stack. Before, they were usually inside a `std::unique_ptr`. This makes
passing them around much easier. Creation of new virtual arrays is also
much simpler now due to some constructors. Memory allocations are
reduced by making use of small object optimization inside the core types.
Previously, `VArray` was a class with virtual methods that had to be overridden
to change the behavior of a the virtual array. Now,`VArray` has a fixed size
and has no virtual methods. Instead it contains a `VArrayImpl` that is
similar to the old `VArray`. `VArrayImpl` should rarely ever be used directly,
unless a new virtual array implementation is added.
To support the small object optimization for many `VArrayImpl` classes,
a new `blender::Any` type is added. It is similar to `std::any` with two
additional features. It has an adjustable inline buffer size and alignment.
The inline buffer size of `std::any` can't be relied on and is usually too
small for our use case here. Furthermore, `blender::Any` can store
additional user-defined type information without increasing the
stack size.
Differential Revision: https://developer.blender.org/D12986
`ABCPointsWriter::is_supported` already checked for valid particle
system types (liquid, spray, foam, bubbles, ...).
`AbstractHierarchyIterator::make_writers_particle_systems` did not
create a writer for these though, so now bring these in line and also
create writers for these.
With transform tools, it is expected to see backgroud image when overlay
is transformed.
Alpha over caused performance to be not optimal when used with opaque
media. This should be addressed with D12914 at least partially. There
may be some corner cases not addressed.
Differential Revision: https://developer.blender.org/D12952
When scaling down image, users expect to see background, which doesn't
currently happen in VSE. This is because strips use cross blend mode by
default, because alpha over is much slower. Reason is, because any area
of image can be transparent, and therefore it can't have early out
implemented in a way that cross blend mode can.
Flag images rendered by codecs that don't support transparency as fully
opaque and implement a form of early out for alpha over blend mode.
When rendering image stack, 2-input effects are ignored on the
"way down". Alpha over needs rendered overlay image to decide whether it
will use only overlay or background too. Therefore overlay can be
rendered safely before it is used. Image flags can be checked and it can
be freed if needed. Freeing doesn't cause any performance degradation,
because image is always stored in cache.
This feature does not improve blend mode performance. In summary, it
only allowes for having alpha over blend mode on background images
without suffering from lower performance.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D12914
`v2d->tot` rect was set for backdrop drawing. Set range before drawing
scrollbars.
Reviewed By: Severin
Differential Revision: https://developer.blender.org/D13099
Some RNA properties and operators did not invalidate cache or did it
incorrectly.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D13101
Issue was caused by incorrect FFmpeg asynchronous decoding API. In most
cases, decoder returns 1 frame each time it is fed by 1 packet. Here
decoder wanted to return more frames, but our code always expected only
one.
Before sending new packets to decoder, check if there are frames to
receive. If there are, process them, otherwise continue decoding as
usual.
Reviewed By: zeddb, sergey
Differential Revision: https://developer.blender.org/D13079
When proxy size lower than 100% is used, clip strips are rendered with
incorrect image size.
This is because if proxies aren't enabled in movieclip, it automatically
falls back on rendering original media. Sequencer doesn't have knowledge
about this and since 9c99292a16df it assumes that image is proxy,
because it explicitly requested this size.
Check movieclip flag to see if proxies are enabled.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D13080
There were two issues:
- The third math node socket does not exist in old enough files.
- The comment incorrectly referred to the vector math node.
Differential Revision: https://developer.blender.org/D13219