The prior naming is a bit confusing given that it returns `true` if
`brush` is `nullptr`. My initial expectation on reading the old name is
that it would only return true if both are non-null.
Pull Request: https://projects.blender.org/blender/blender/pulls/144822
Add Scene and View Layer selectors to the Scene and View Layer tabs
in the Properties Editor, matching the existing controls in the topbar.
See PR for details and screenshots.
Pull Request: https://projects.blender.org/blender/blender/pulls/143266
Currently, sequencer structs contain several pointers to data within
other structs. These pointers need to be remapped as the structs are
reallocated when reading from blend files. That has worked so far
because the pointers are exactly the values from the Blender session
that saved the file. WIth the implementation of #127706, the pointers
in the file aren't "real" anymore, and we can't offset them to get the
struct that contained the data.
This commit replaces these 4 mid-struct pointers to point to the
containing strips instead, and uses some trivial logic to access the
fallback root sequence channels and strips. This makes the pointer
remapping on file load possible again.
The downside is that this isn't strictly backward or forward compatible,
but only on a UI-level. The active meta-strip information will be lost,
and the sequencer will reset to displaying the root sequence.
Depends on #144624
Pull Request: https://projects.blender.org/blender/blender/pulls/144626
Alternative to #144563.
This fix adds a lock to the runtime data, and holds the lock whenever the
brush mesh is accessed. While there may be more efficient solutions,
dynamic paint is at the end of its life and guaranteeing correctness is
more important.
Pull Request: https://projects.blender.org/blender/blender/pulls/144816
The crash is caused by libepoxy GL functions pointing to nullptrs.
libepoxy "Automatically initializes as new GL functions are used.",
so to call a function without a GL context bound, the function must
have been called before with a bound context.
This PR ensures there's a valid GL context bound for the whole
`WM_exit` scope.
(4.5 backport candidate)
Pull Request: https://projects.blender.org/blender/blender/pulls/144572
This patch introduces a new Jitter option for the Sun Beams mode of the
Glare node. If non-zero, is uses an approximation that is faster to
compute but makes the result more noisy.
Internally, this is computed by reducing the number of samples used to
integrate the results and introducing a random offset during
integration.
Pull Request: https://projects.blender.org/blender/blender/pulls/141789
This patch unifies the Gamma node across editors:
- Compositor now uses the Shader Gamma node implementation.
- Geometry Nodes also uses the node as a new addition.
- UI-wise in the Compositor, only socket labels change to "Color".
Forward compatibility is broken for the compositor, and the python API
changed, since the node's ID name is now ShaderNodeGamma as opposed to
CompositorNodeGamma.
Pull Request: https://projects.blender.org/blender/blender/pulls/142414
- RNA Patterns Unknown to the Manual -- only print rna_ids that do not return a URL
- Undocumented Sections -- consider the case of types that do not have props (a lot of nodes were returning as false positives)
Follow up to fix for #132460, slow startup from file file-system access
has been removed as it causes problems, then added back since it seems
like a fix if we assume all file-systems are local & online.
Note why this causes problems to prevent the checks being re-introduced.
Changes the overload from accepting `const AssetWeakReference *` to
`const AssetWeakReference &` to more strongly indicate proper usage. We
should not have a usecase for setting a null `AssetWeakReference`
Pull Request: https://projects.blender.org/blender/blender/pulls/144821
Prior to this commit, determining the default brush asset used for a
particular mode was based on the object's mode. This is slightly
incorrect for the Image Editor, since it may be in Paint Mode no matter
the underlying object type. To fix this, use the runtime `PaintMode`
enum for determining these default values instead of `eObjectType` and
store the `PaintMode` on `PaintRuntime` for easy access.
Additionally, inside the toolsystem, prevent accidentally unsetting
the default brush by checking for the presence of the asset when
loading an `AssetWeakReference`.
Pull Request: https://projects.blender.org/blender/blender/pulls/144765
Use "Up Arrow" to jump to the next keyframe, and "Down Arrow" for the
previous keyframe, to be consistent within Blender and other software.
See PR for details.
Pull Request: https://projects.blender.org/blender/blender/pulls/140301
This allows to control the type of data inside the create infos for
easy variation of the same shader.
Also this wraps the last global shader resource usage for the future
SRD.
Pull Request: https://projects.blender.org/blender/blender/pulls/144769
Two formatted reports introduced in e239c7f43c used a type defined at
compile time using the PRId64 macro. Translation failed for these
messages, because the message was extracted as:
"No keyframes removed from % strip(s)"
and the type was lost at the time formatting happened.
This commit instead uses fmt to format the message, which deals with
using the proper int type depending on the platform.
Pull Request: https://projects.blender.org/blender/blender/pulls/144374
Moving the python call itself into a dedicated sub-scope allows to
ensure local variables (arguments) do not risk leaking into the
rest of the code after being released.
Also use helper macro `PyTuple_SET_ITEMS`.
Pull Request: https://projects.blender.org/blender/blender/pulls/144798
This patch lowers the priority of menu sockets from the maximum priority
to the lowest priority. That's because menu sockets are nearly never the
main socket.
The current state is blocking the adoption of menu sockets in the
compositor, since most of the compositor nodes have color and float main
sockets, which currently have lower priority than menu sockets, making
node link insertion fail.
Pull Request: https://projects.blender.org/blender/blender/pulls/144779
`world_use_portal` is not needed anymore, now that we always add world
as object (b20b4218d5).
We now check if background light is enabled only in
`test_enabled_lights()`, depending on the sample settings.
Pull Request: https://projects.blender.org/blender/blender/pulls/144710
It works with the beta we are using to build Blender 4.5, but the official
release is a bit different. This fix was tested to work with OSL 1.14.7.
Thanks to Paul Zander for finding the OSL commit that lead to this.
Pull Request: https://projects.blender.org/blender/blender/pulls/144715
So far only active color spaces were queries from the OpenColorIO, which
made sense from the list of spaces displayed in the menus. However, some
logic requires knowing more details about color spaces used by displays,
for example to check if it is data, or whether color space matches the
display one.
This change makes it so our OpenColorIO integration handles inactive color
spaces by storing them in a separate array. Config::get_color_space will
now work for both active and inactive color spaces.
Pull Request: https://projects.blender.org/blender/blender/pulls/144780
`asset_shelf::regiondata_duplicate()` first creates a shallow copy of
the `AssetShelf`, including its `AssetShelfSettings` member. So the
contained pointer point to the same memory.
While this is a rather unusual case for a copy assignment operator to
consider, I think this is fine since the API allows these shadow copies.
This is a bit of a consequence of mixing C and C++ style memory
management.
Pull Request: https://projects.blender.org/blender/blender/pulls/144613
Passing negative precision to internal units functions made the code
difficult to follow, especially when the precision is being
adjusted/clamped.
While the public API remains unchanged, detect the negative precision
early and assign it to a boolean which is passed as an argument.
Also improve doc-strings.