Prior behavior when hovering over the corner action zones the mouse
cursor would change to WM_CURSOR_EDIT (like a plus sign). With docking
that is WM_CURSOR_HAND, but on other platforms it is WM_CURSOR_MOVE.
Unfortunately on some platforms WM_CURSOR_MOVE does not show a
different cursor from default so there isn't an change when hovering
the corner. This PR changes this back to WM_CURSOR_EDIT for non-Mac
platforms.
Pull Request: https://projects.blender.org/blender/blender/pulls/127878
The behavior was unintentionally changed in 2858c3b287. This patch brings back
the old behavior when dragging objects/collections from the asset browser into
the 3d view, while still keeping the loose-data-instantiation separate from the
core import code.
The `view3d_ob_drop_copy_external_asset` and `view3d_collection_drop_copy_external_asset`
functions are turned to their old state before the refactor.
Pull Request: https://projects.blender.org/blender/blender/pulls/127452
VSE tonemap is 12-15 times faster.
1) multi-threaded image luminance calculation,
2) avoid calling into OpenColorIO per-pixel, instead do that in
larger batches,
3) for float images (which are primary target for tonemapping),
do not do "to linear space" conversion twice.
Applying tonemap on 4K resolution EXR image, on Ryzen 5950X (Win10/VS2022):
- R/D Photoreceptor mode: 405 -> 31 ms
- Rh Simple mode: 388 -> 23 ms
Pull Request: https://projects.blender.org/blender/blender/pulls/127467
This adds a new `BKE_id_name` function. It should be used in places where we
currently do something like `id.name + 2`.
This patch just adds the function and uses them in a small subset of possible
cases. Given that there are >700 cases that need to be replaced, I'd rather to
that in chunks instead of all at once.
Pull Request: https://projects.blender.org/blender/blender/pulls/127410
The issue was that `retrieve_editable_drawings_grouped_per_frame`
returned garbage memory, leading to a crash a bit further.
The fix adds a nullptr check to make sure the `current_drawing` exists
and can be safely dereferenced.
Skip the evaluation of the Action constraint when no Action is set.
Before, the constraint would run an entire animation data evaluation
cycle on a fake object, with the given (but NULL) Action. Now it's just
skipped.
Implements a simple splash screen notice displayed if an x86/Intel macOS
Blender build is ran on an Apple Silicon Mac to warn against reduced
performance.
On the technical side of things, this adds a function that detects if
the current process is currently running through Rosetta using `sysctl`.
Implementation wise, I tried to keep this function contained in a single
conditional preprocessor macro block in the same file for simplicity.
Co-authored-by: Harley Acheson <harley.acheson@gmail.com>
Pull Request: https://projects.blender.org/blender/blender/pulls/124382
This is a follow up to #126559. In that PR I temporarily removed the
strip subtypes from RNA because I didn't have the brain space to tackle
updating that at the same time.
This PR restores the strip subtypes in RNA, even though the strip
themselves don't exist as separate C++ types anymore. Now the RNA type
that we present the strip as depends on the type of strip data the strip
references.
Note that currently there is only one subtype: the keyframe strip.
Pull Request: https://projects.blender.org/blender/blender/pulls/127859
Add some F-Curve getter functions that work in all these situations:
- Built without experimental features.
- Built with experimental features, and called with legacy Action.
- Built with experimental features, and called with layered Action.
No functional changes, just useful tools for migrating to the new
Actions API.
Ref: #120406
Pull Request: https://projects.blender.org/blender/blender/pulls/127841
The `factor` property that controls the noise on the positions
was named `Offset Factor` in RNA but this name is overriden
in the modifier to `Position`.
When this property is e.g. keyed the RNA UI name is used
which can be very confusing.
This renames the RNA UI name to "Position Factor" to avoid
this confusion.
The unlit packing could write to the (non-existing) 4th
closure bin inside the gbuffer header leading to no
combined pass shader being invoked for these specific
(complex) materials.
Making sure the unlit workaround writes to bin 0 fixes the
issue.
Pull Request: https://projects.blender.org/blender/blender/pulls/127811
Object with degenerate transform matrix can lead to flat
bounds on GPU. This in turn lead to NaN intersection planes
inside `IsectBox`.
Compute (pseudo) size of matrix and bypass culling is any
axis is too small.
The other part of the patch makes sure that there is a
distinction between disabled culling and invalid
bounding boxes.
Pull Request: https://projects.blender.org/blender/blender/pulls/127807
This commit adds the `Reproject Strokes` operator in the
`Grease Pencil` > `Cleanup` menu in edit mode.
All similar operator settings have been ported over from GPv2.
Pull Request: https://projects.blender.org/blender/blender/pulls/127735
Revert part of 9530852347 as that did not
take into account that the `max` property may actually be smaller than
the `min` property.
I've also taken the liberty to document this fact in some comments.
The fix for the crash when `min == max` is still in place.
Windows/Intel and Apple drivers do not support dynamic
rendering unused attachments. Due to mistakes we made
this extension partly optional. Eg. the extension was
optional, but its settings were not.
This PR makes the extension fully optional. However
without the extension some drivers might make incorrect
assumptions. This should be solved when it is more clear
why some drivers are still crashing when using dynamic
rendering.
Pull Request: https://projects.blender.org/blender/blender/pulls/127839
As part of a more general Objective-C GHOST refactor and in an effort to
modernize the macOS backend for further works, this commit cleans up the
codestyle of Objective-C files. Based off the Blender C/C++ style guide,
in addition to some Objective-C specific style changes.
Changes:
- `const` correctness, use nullptr, initializer list for simple struct
- Reduced variable scope for simple functions, removed unused variables
- Use braces for conditional statements, no else after return
- Annotate inheritted function of GHOST Cocoa classes with override and
use `= default` to define trivial constructors
- Use #import instead of #include for Objective-C headers
This is only for correctness. As the Objective-C #import directive
is really just an #include with an implicit #pragma once.
- Use proper C-style comments instead of #pragma mark
#pragma mark is an XCode feature to mark code chapters, to follow
the Blender codestyle, and make the Objective-C code more editor
agnostic, these were replaced with multi-line C-style comments.
Ref #126772
Pull Request: https://projects.blender.org/blender/blender/pulls/126770
This requires writing selection attributes to a different domain than
the Point domain.
Note that for assigning/removing from vgroups the `adapt_domain`
function is used implicitly by always looking up attributes from the
Point domain: ".selection" may be stored on Curves and will
automatically be adapted to points. For select-by-vgroup `adapt_domain`
cannot be used because the selection has to be "greedy" (one point
selects the whole curve).
Pull Request: https://projects.blender.org/blender/blender/pulls/127799
Remove the three problematic entries:
- `aligned_free` is not a 'real' function and does not need to be
handled here. There is no symetry with the `aligned_malloc` symbol
here.
- `__end` and `_bss_start` seem to have been mis-typed from the
beginning (actual symbols seem to be `_end` and `__bss_start`).
Regardless, neither `gold` nor `mold` seem to take these directives
from the LD version script into account (result is the same for them
when removed for the `.map` file), so removing them.
Pull Request: https://projects.blender.org/blender/blender/pulls/127761
Saving for the first time or using save-as printed a summary, e.g.
`Total files 0 | Changed 0 | Failed 0`
When path operations were added it was only accessed from the UI,
where reporting a summary makes sense. Having the summary reported when
path manipulation is done as part of another action isn't useful.
It's also not clear what the summary relates to.
Now the summary is only shown in operator reports.
When we create a new window at run time, we request that it be placed
at a specific size and location, but afterward we ask the OS for
details about where it was actually made and then update the window's
size and position with the correct information. Unfortunately when we
open a window when loading a blend file we do most of this, but only
update the size from the OS, not the position. There are times a window
will need to be placed somewhere different than we request and so the
window posx and posy will be incorrect until we move or resize it. This
is more likely to happen on Macs, but is possible on any platform.
Pull Request: https://projects.blender.org/blender/blender/pulls/127819
Docking can close windows during its operation. If the current window
does not match before and after an operator has run our event handling
code can assume that a new blend file has been loaded and will rerun
the operator. This PR avoid this problem by just not starting if the
event initiating it is of type WINDEACTIVATE. There might be a later
fix that addresses the underlying issue, but this is simple, small, and
harmless.
Pull Request: https://projects.blender.org/blender/blender/pulls/126379
Since their introduction, generated UDIM images/tiles would not be
loaded in Cycles. In relative recent history 72ab6faf5d added the
ability to track which tiles were still marked as being "generated" and
unsaved. However, that check was never implemented into the Cycles code.
With this PR, these two additional scenarios should now work:
- Properly load pixels if all tiles are generated
- Properly load pixels if a UDIM image has been loaded from a file and
new generated tiles have been added but not saved yet etc.
Pull Request: https://projects.blender.org/blender/blender/pulls/127673