This implements a basic render time pass,
using HW-based counters to minimize render time impact.
x86-64 uses the TSC instruction for timing, while ARM64 uses the cntvct_el0
register. In theory TSC is not always super reliable (e.g. old CPUs had it tied
to their current clock rate), but for somewhat recent CPU models it should
be fine. If neither is available, it falls back to `std::chrono::steady_clock`,
which should still be very fast.
The output is in milliseconds of CPU-time per pixel.
Pull Request: https://projects.blender.org/blender/blender/pulls/125933
Before this change, any accumulated errors from OpenImageIO would be
lost and a nonsensical use of `errno` would be used instead.
An example of the new error log:
```
00:23.188 image.write | ERROR OpenImageIO write failed: sgi image resolution may not exceed 65535x65535, you asked for 65536x1
```
Pull Request: https://projects.blender.org/blender/blender/pulls/146554
The problem was that the `Pen Tool` would not add keyframes when Auto
Keying was enabled.
This also fixes a crash that could happen when auto keying was enabled
and no keyframe existed.
Pull Request: https://projects.blender.org/blender/blender/pulls/146549
With Blender 5.0 a few modifier assets are bundled. This makes the
Geometry Nodes modifier even more of a special modifier which isn't
intended for many people to use.
As such this PR moves it to the end to be a bit less prominent.
| 4.5 | PR | PR |
| - | - | - |
|<img width="217" alt="Screenshot 2025-09-22 at 16.10.17.png" src="attachments/c12fedc4-549e-4b7b-bc28-c990e17a679e">|<img width="182" alt="Screenshot 2025-09-22 at 16.11.18.png" src="attachments/ce80702e-95dd-441a-8d36-c41f64d03a64">|<img width="214" alt="Screenshot 2025-09-22 at 16.11.45.png" src="attachments/5b07d5e9-b133-4fc5-a5a4-a1989929e58e">|
The PR column shows the changes proposed here in two scenarios: with and another without Unassigned assets.
Ref: !146590
As discussed in the last geometry nodes workshop, the viewer node now
needs the flexibility to handle new features: bundles, closures, and
lists. This PR takes the opportunity to add support for an arbitrary
number of items. Values are displayed directly in the node are all
displayed in the spreadsheet, where a new tree view allows selecting
which data to view, including nested bundles. Lists, single values,
bundle items, and closure signatures are all visualized in the spreadsheet.
We also prioritize the existing viewer behavior that views a geometry
together with a field, so various special cases are added in the viewer
activation to handle this.
Bundle hierarchies are displayed in the new tree view in the spreadsheet
sidebar. The spreadsheet itself just displays bundle identifiers, types,
and the contained values. Design wise, there might be more integrated
ways to present that hierarchy, but doing it in the tree view is a very
simple starting place.
Interactively added viewer node inputs are now removed automatically
if the link is removed. There is a new "Auto Remove" flag for each input
controlling this behavior. It can't be enabled for all inputs all the time
because then one couldn't e.g. setup the viewer node properly using
a script (which might add a few inputs first and then creates links).
Also when viewer items are added with the plus icon in the sidebar,
they are not automatically removed immediately.
https://code.blender.org/2025/07/geometry-nodes-workshop-july-2025/#view-any-data
Co-authored-by: Hans Goudey <hans@blender.org>
Pull Request: https://projects.blender.org/blender/blender/pulls/144050
This probably got broken when expanding was changed to use foreach ID. In the
old code the screen was not part of expanding.
Also adds the appropriate flags for workspace pinned and sequencer scenes.
This was causing issues in particular with the new video editing template, where
appending a workspace would append the Edit scene.
Fix#146156
Pull Request: https://projects.blender.org/blender/blender/pulls/146164
- Show unassigned scene assets directly under Assets.
- Use Icons for Assets label.
- Only show "Scenes" when there are Assets.
- Don't show scene assets on the "Scenes" list.
The design about changing the operator default behaviour will be
addressed separately. This patch only changes the UI.
Design ref: #145522
Ref: !146574
`preview_id_copy_free` was trying to do its own version of
`BKE_libblock_free_data`, instead of calling directly that function.
This could easily lead to missing cleanup when modifiying ID management,
and since these IDs are managed by general ID API, there is no reason
not to do the same on destruction.
This is extracted from !146046 'making ID::runtime an allocated struct'.
If nodegroup is linked or marked as asset, show different icons in breadcrumbs inside node space.
Note: Packed data-blocks have to be tackled separately since they are not in main yet (!133801).
Ref: !146573
Mainly:
- Move 're-used' ID reset from `BKE_id_copy_in_lib` to lower-level
`BKE_libblock_copy_in_lib`.
- Remove call to `deg_tag_eval_copy_id` in `IDNode::init_copy_on_write`,
as this is already done in `deg_expand_eval_copy_datablock` for all
CoW IDs anyway (both re-used and newly allocated ones).
This is extracted from !146046 'making ID::runtime an allocated struct'.
Pull Request: https://projects.blender.org/blender/blender/pulls/146593
On its own, the main functionality of the Radial Tiling node
is the ability to divide a 2D Cartesian coordinate system into
as many radial segments as specified by the "Segments" input.
Each segment has its own affinely transformed coordinate system,
provided through the "Segment Coordinates" output, which can be
used to tile textures in a radially symmetric manner.
Additionally, a unique index is provided for every segment through
the "Segment ID" output, the width of each segment at Y-coordinate
of the "Segment Coordinates" output without normalization = 0 is
provided through the "Segment Width" output and the rotation value
of the affine transformation of the coordinate system of each segment
is provided through the "Segment Rotation" output.
The roundness of the coordinate lines of the "Segment Coordinates"
output can be controlled through the "Roundness" inputs.
This can be used to make the coordinate systems of the segments
a mix of Cartesian and polar coordinates.
Lastly, the lines of points of the "Segment Coordinates" output with
constant Y-coordinates have the shape of polygon with rounded corners,
which can be used to procedurally create rounded polygons.
Pull Request: https://projects.blender.org/blender/blender/pulls/127711
The keymap `km_image_paint` righfully includes both
`VIEW3D_AST_brush_texture_paint` and `IMAGE_AST_brush_paint` since
painting can be done in both Editors.
So we want to improve upon polling.
Three parent classes involved: `ImageAssetShelf`, `View3DAssetShelf`,
both inherit from `BrushAssetShelf`
`IMAGE_AST_brush_paint` (inherits from `ImageAssetShelf`) was already
checking for being in paint mode (so that Asset Shelf already wasnt
showing), but `VIEW3D_AST_brush_texture_paint` (inherits from
`View3DAssetShelf`) was permissive (doesnt have specialized poll, relies
on the "mother" classes `BrushAssetShelf` which only checks for an
active object and if that active objects `mode` equals the Assets Shelfs
"mode"). This can be true if you have an object in Texture Paint mode in
the 3DView.
So to make shelves like `VIEW3D_AST_brush_texture_paint` **not** pass
their poll in the Image Editor, add a specific poll case.
NOTE: the report also mentiones a crash when actually selecting a "bad"
brush from the "bad" asset shelf. Since that scenario is now impossible
to reach, the crash has not been investigated further.
Pull Request: https://projects.blender.org/blender/blender/pulls/146071
This simplifies the GBuffer packing code in a lot
of common use cases. This improves compilation
speed.
The trivial case is either a single closure (already handled)
or 2 closures with no second data layer.
We detect if reflection and refractions can
be assumed colorless depending on the nodetree config.
Colorless reflection or refraction are only using one
data layer.
Pull Request: https://projects.blender.org/blender/blender/pulls/146455
A compiler/driver bug makes so that we can't rely on image atomics.
Adding a write that is never executed after the atomics tricks
the compiler to issue the correct synchronisation instruction.
This fixes a bunch of our render tests differences.
We will keep this workaround until this is fixed upstream.
Pull Request: https://projects.blender.org/blender/blender/pulls/146442
This allows to reduce the number of includes for each
tree graph (surface, volume, displacement) and
reduce the code size significantly for most vertex
shaders, speeding up compile time.
Rel #145347
Pull Request: https://projects.blender.org/blender/blender/pulls/146419
Previously the joining code put the final data into temporary mesh
data, which meant more complexity because it couldn't use the slightly
higher level APIs more commonly used for transferring data.
The process can be simplified by just merging into the active mesh
directly (though some care must be taken when that is used by
multiple selected objects).
This process avoids iterating over attribute data twice, by processing
values at the same time as copying them. Also some of the inner hot
loops are parallelized. There is more opportunity for trivial multi-
threading in the future.
Mismatched attribute types and domains will now choose the higher
complexity type and domain, which should help avoid information loss.
There was a bug with the existing face set processing which would
modify the source meshes. That is now fixed.
- Use spans instead of raw pointers
- Construct OffsetIndices instead of accumulating offsets while iterating
- Use newly added `math::transform_points` utilities.
- Simplify topology index offsetting
- Make sure active mesh is at the start of the vector
The point is mostly to simplify a rewrite of this code that will be
the next commit. The overall motivation is to ease the switch to
AttributeStorage, solve a few issues in this code, and make it easier
to understand.
The naming was confusing as only some selection flushing functions
were intended to be used when elements had been selected or de-selected.
Replace these with a single function that takes a "select" argument.
These are causing quite a big difference in existing files, which is not
easy to address in versioning. Since the goal of removing this was to
simplify things for us and that's not the case, just revert this change.
This reverts commit ab21755aaf.
Ref #139923
Pull Request: https://projects.blender.org/blender/blender/pulls/146336
This actually matches the OpenColorIO terminology more closely, and
makes a bit more sense as the display is more of an abstract thing than
a specific device.
Pull Request: https://projects.blender.org/blender/blender/pulls/146483